Transaction · Acts onchain
Constructs and compiles transaction calldata from structured inputs, returning a record ready for signing and submission. Hand it the steps of the transaction as action references with filled inputs and it resolves them through the catalog, compiles the calldata, and persists a transaction row that tracks the intent from here to settlement. The response carries everything a wallet needs to sign. This is the build step. Listing existing records is the GET on the same path, and the pure preview that persists nothing is the compile surface.
Send a request
Response
{links: {self: stringprev: string | undefinednext: string | undefined} | undefinedheaders: unknown | undefineddata: {id: stringstatus: stringchain_id: numberaddress: stringvalue: string | integer | undefinedgas_limit: number | nullinputs: any[] | nullsteps: any | nullcreated_at: stringupdated_at: stringtx_hash: string | nullexecution_mode: string | undefinedowner_address: string | undefinedplugs_hash: string | undefinedscheduler_status: string | undefinedlast_error: string | undefinedverdict: string | undefinedfailing_condition: number | undefinedlast_simmed_block: number | undefinedoutputs: any[] | nullrelay: {typed_data: {types: Record<string, ({name: stringtype: string})[]>primaryType: stringdomain: Record<string, any>message: Record<string, any>}plugs: string[]state: string[]manifest: ({token_in: stringtoken_out: stringamount_in: numberexecutor_slot: numberroute_slot: number})[]} | null} | null}
Code samples
Language
Prompt
Call the Plug API endpoint "Create transaction".## EndpointPOST /address/{address}/transaction/Base URL: https://api.plug.to## DescriptionConstructs and compiles transaction calldata from structured inputs, returning a record ready for signing and submission.Hand it the steps of the transaction as action references with filled inputs and it resolves them through the catalog, compiles the calldata, and persists a transaction row that tracks the intent from here to settlement. The response carries everything a wallet needs to sign.This is the build step. Listing existing records is the GET on the same path, and the pure preview that persists nothing is the compile surface.## Path Parameters- address (string, required) — The EVM address to get information for. In the case that you request an address we have never indexed, we will immediately index it.Current value: 0x62180042606624f02d8a130da8a3171e9b33894d## Query Parameters- input[chain_id] (integer, required) — The chain to create the transaction for.- input[deadline] (integer, optional) — A unix timestamp after which the transaction is no longer valid.- input[owner] (string, optional) — The account the draft executes for: a standard:wallet slot filled with "yourself" resolves to this address. Absent, the authenticated session's address; absent both, wallet-self slots stay on the executing account.- input[gas_limit] (integer, optional) — Gas limit recorded on the created transaction.- input[steps] (string, required) — The steps/actions to include in the transaction.## Headers- Accept (string, required) — For a typical single-time JSON response, set this to application/json. To receive realtime updates through a stream, set this to text/event-stream. (default: application/json) [application/json, text/event-stream]Current value: application/json## Response Schema- links (object, optional)- self (string, required)- prev (string, optional)- next (string, optional)- headers (unknown, optional)- data (object, optional)- id (string, required)- status (string, required)- chain_id (integer, required)- address (string, required)- value (string | integer, optional)- gas_limit (integer, optional)- inputs (array of any, optional)- steps (any, optional)- created_at (string, required)- updated_at (string, required)- tx_hash (string, optional)- execution_mode (string, optional)- owner_address (string, optional)- plugs_hash (string, optional)- scheduler_status (string, optional)- last_error (string, optional)- verdict (string, optional)- failing_condition (integer, optional)- last_simmed_block (integer, optional)- outputs (array of any, optional)- relay (object, optional)- typed_data (object, required)- types (Record<string, array>, required)- primaryType (string, required)- domain (Record<string, any>, required)- message (Record<string, any>, required)- plugs (array of string, required)- state (array of string, required)- manifest (array- token_in (string, required)- token_out (string, required)- amount_in (integer, required)- executor_slot (integer, required)- route_slot (integer, required), required)## Example RequestPOST https://api.plug.to/address/0x62180042606624f02d8a130da8a3171e9b33894d/transaction/