Skip to main content
POST
/
transactions
cURL
curl --request POST \
  --url https://api.onchainden.com/api/v1/transactions \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'X-Idempotency-Key: <x-idempotency-key>' \
  --data '
{
  "accountId": "acc_123",
  "networkId": 1,
  "policyId": "pol_123",
  "description": "Payment to vendor",
  "to": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
  "value": "0",
  "data": "0xa9059cbb..."
}
'
{
  "data": {
    "id": "tx_123",
    "accountId": "acc_123",
    "policy": {
      "id": "pol_123",
      "threshold": 2
    },
    "type": "TOKEN_TRANSFER",
    "signatureData": {
      "status": "<string>",
      "initiatorPayload": "<string>"
    },
    "executionStatus": null,
    "approvals": [
      {
        "id": "mem_123",
        "name": "Alice",
        "type": "user",
        "walletAddress": "<string>"
      }
    ],
    "rejections": [
      {
        "id": "mem_123",
        "name": "Alice",
        "type": "user",
        "walletAddress": "<string>"
      }
    ],
    "createdAt": "2023-11-07T05:31:56Z",
    "expiresAt": "2026-01-25T00:00:00Z",
    "data": {
      "destination": "0xdef...",
      "asset": {
        "id": "usdc_1",
        "symbol": "USDC",
        "decimals": 6,
        "name": "USD Coin",
        "logoUrl": "https://assets.onchainden.com/tokens/usdc.png",
        "tokenAddress": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"
      },
      "rawAmount": "1000000000",
      "displayAmount": "1000.00",
      "networkId": 1
    }
  }
}

Authorizations

Authorization
string
header
required

API key authentication. Include your API key in the Authorization header.

Headers

X-Idempotency-Key
string<uuid>
required

Idempotency key for safely retrying mutation requests.

Body

application/json
accountId
string
required

Account ID to create the transaction for

Example:

"acc_123"

initiatorWalletAddress
string
required

Wallet address of the user initiating the transaction

Pattern: ^0x[a-fA-F0-9]{40}$
Example:

"0x1234567890123456789012345678901234567890"

networkId
integer
required

Network chain ID

Example:

1

policyId
string
required

Policy to use for this transaction

Example:

"pol_123"

description
string
required

Human-readable description

Example:

"Payment to vendor"

to
string
required

Target address. For ERC20 transfers, this is the token contract. For native transfers, this is the recipient. For contract interactions, this is the contract address.

Pattern: ^0x[a-fA-F0-9]{40}$
Example:

"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"

value
string
required

Wei value (use "0" for ERC20 transfers)

Example:

"0"

data
string
required

Encoded calldata ("0x" for native transfers)

Example:

"0xa9059cbb..."

Response

Transaction created

data
Token Transfer · object
required