System

public/decode_action

Runs a hex-encoded Action.data payload through the exchange's own ABI decoder and returns either the decoded fields or the exact reason the bytes were rejected, naming the 32-byte word and the field that broke. Reach for this first when a request fails signature verification (14014): every other route encodes Action.data server-side, so a client whose encoder emits a bad word never sees a decode error - the hashes simply disagree. This is the only route a client's own bytes reach the decoder. Needs no auth and executes nothing.

post/public/decode_action

Request

  • Base URL: https://api.derive.xyz/v3
  • URL: https://api.derive.xyz/v3/public/decode_action
  • Auth: none declared

Request body

action_type'order' | 'rfq_maker' | 'rfq_taker' | 'transfer' | 'external_transfer' | 'withdrawal' | 'liquidation' | 'set_session_key' | 'update_whitelisted_recipients' | 'delete_subaccount' | 'vault_deposit' | 'vault_withdraw' | 'vault_cancel' | 'vault_create' | 'vault_mint_shares' | 'vault_burn_shares' | 'vault_force_burn' required

Which action codec to run the bytes through. A module address is not enough on its own: the RFQ module signs two different layouts, and the vault module signs seven.

encoded_datastring required

ABI-encoded action data (the Action.data bytes), 0x-prefixed hex. Same value the *_debug routes return as encoded_data.

Response

Success

action_type'order' | 'rfq_maker' | 'rfq_taker' | 'transfer' | 'external_transfer' | 'withdrawal' | 'liquidation' | 'set_session_key' | 'update_whitelisted_recipients' | 'delete_subaccount' | 'vault_deposit' | 'vault_withdraw' | 'vault_cancel' | 'vault_create' | 'vault_mint_shares' | 'vault_burn_shares' | 'vault_force_burn' required

Which action codec to run the bytes through. A module address is not enough on its own: the RFQ module signs two different layouts, and the vault module signs seven.

decodedunknown required

Changes

No recorded changes to this operation across all 1 revision of this API.