Skip to main content

Overview

The Transaction types define the structure for tracking swap and transfer operations, including their status, chain operations, and historical data.

Transaction

Represents a complete transaction record for a swap or transfer operation.

Properties

string
required
Unique identifier for the quote that generated this transaction
TransactionStatus
required
Current status of the transaction. See TransactionStatus below.
string
required
The user address who initiated the transaction
string
Optional recipient account identifier (CAIP format) for transfer operations
ChainOperation[]
required
Array of operations executed on origin chains. See ChainOperation below.
ChainOperation[]
Optional array of operations executed on destination chain. See ChainOperation below.
'SWAP' | 'TRANSFER'
required
Type of transaction:
  • SWAP: Token swap operation
  • TRANSFER: Token transfer to another account
TokenInfo
required
Information about the source token. See TokenInfo below.
TokenInfo
Optional information about the destination token (required for swaps). See TokenInfo below.
string
required
ISO 8601 timestamp when the transaction was created

Example


TransactionStatus

Enum type representing the possible states of a transaction.

Values

string
Transaction has been created but execution has not completed
string
Transaction has been successfully executed on all required chains
string
Transaction execution failed
string
Failed transaction has been refunded to the user

ChainOperation

Information about an operation executed on a specific blockchain.

Properties

string
required
Transaction hash on the blockchain
number
required
Numeric chain identifier where the transaction was executedCommon chain IDs:
  • 1: Ethereum Mainnet
  • 10: Optimism
  • 137: Polygon
  • 8453: Base
  • 42161: Arbitrum
  • 43114: Avalanche
string
required
Full URL to view the transaction on a block explorer

Example


TokenInfo

Extended token information including fiat value calculations.

Properties

string
required
The OneBalance aggregated asset identifier (e.g., ob:eth, ob:usdc, ob:dai)
string
required
Token amount as a string (represents BigInt with token’s decimals)Example: "1000000" for 1 USDC (6 decimals)
string | string[]
required
CAIP-19 format asset identifier(s)
  • Single string: Asset on one chain
  • Array of strings: Aggregated asset across multiple chains
Format: {namespace}:{chainId}/{assetNamespace}:{assetReference}Examples:
  • "eip155:1/erc20:0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48" (USDC on Ethereum)
  • "eip155:137/slip44:60" (ETH on Polygon)
string | array
Fiat value of the token amount
  • String: Total fiat value (e.g., "1000.00")
  • Array: Per-chain breakdown for aggregated assets
    • Each object contains assetType and fiatValue
string
Minimum amount required for the operation (as string)
string
Minimum fiat value required for the operation

Example - Simple Token

Example - Aggregated Token


TransactionHistoryResponse

Response structure for transaction history queries with pagination support.

Properties

Transaction[]
required
Array of transaction records. See Transaction above.
string
Pagination token to fetch the next page of results. If not present, there are no more results.

Example


TransactionHistoryParams

Parameters for querying transaction history.

Properties

string
required
User address to query transactions for
number
required
Maximum number of transactions to return per pageRecommended: 10-50 transactions per page
string
Pagination token from a previous response to fetch the next page

Example