---
title: "Get Action"
method: GET
path: "/getAction"
---

# Get Action

`GET /getAction`

Generates a transaction for cross-chain swaps, bridges, and calls. The action includes transaction data, routing information, and fee calculations for executing the requested operation.

## Query parameters

- `actionType` 'swap-action' | 'evm-calldata-tx' | 'polymarket', required — Type of action to perform.
- `sender` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
- `srcChainId` integer, required — Chain ID. Find in the list of supported networks.
- `srcToken` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
- `dstChainId` integer, required — Chain ID. Find in the list of supported networks.
- `dstToken` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
- `slippage` number, float, required
- `amount` string
- `swapDirection` 'exact-amount-in' | 'exact-amount-out' — Swap direction for the action.
- `recipient` string — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
- `to` string — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
- `data` string — Hex string with 0x prefix
- `value` string
- `erc20Amount` string
- `erc20Spender` string — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
- `solanaSponsor` string — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
- `bridgeIds` BridgeId[]
- `refundTo` string — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
- `returnDepositAddress` boolean
- `appFees` string
- `userId` string
- `side` 'BUY' | 'SELL'
- `tokenID` string
- `orderType` 'FOK' | 'FAK'
- `feeRateBps` number
- `tickSize` '0.01' | '0.001' | '0.0001'
- `negRisk` 'true' | 'false'
- `gasless` boolean

## Response `200`

Successful response with action data

- ActionResponse
  - `tx` union, required — Transaction data for execution
    - EvmTransaction
      - `to` string, required — EVM address (0x prefix + 40 hex characters)
      - `data` string, required — Hex string with 0x prefix
      - `value` string, required — Value in wei as string
      - `chainId` integer — Chain ID. Find in the list of supported networks.
    - SerializedSolTransaction
      - `base64Tx` string, required — Base64-encoded transaction
      - `recentBlockhash` string, required — Recent blockhash for transaction validity
      - `payer` string, required — Solana public key (base58 encoded, 32-44 characters)
    - AltVmTransaction
      - `to` string, required — Exchange address format
      - `toExtra` string, nullable — Additional address information (e.g., memo, tag). Can be null.
      - `value` string, required — Value as string
      - `chainId` integer, required — Chain ID. Find in the list of supported networks.
      - `chainKey` string, required — Chain key identifier
    - HyperCoreTransaction
      - `type` 'usdSend', required — HyperCore action type
      - `destination` string, required — Destination address
      - `amount` string, required — Amount to transfer
      - `chainId` integer, required — Chain ID. Find in the list of supported networks.
    - TronTransaction
      - `to` string, required — Tron address (base58, starts with 'T', 34 chars)
      - `data` string, required — Hex-encoded calldata
      - `value` string, required — Value as string
  - `txId` string, required — Hex string with 0x prefix
  - `vmId` 'evm' | 'solana' | 'alt-vm' | 'hypercore' | 'tron', required — Virtual machine identifier.
  - `amountIn` Payment, required
    - `chainId` integer, required — Chain ID. Find in the list of supported networks.
    - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
    - `name` string, required — Token name
    - `symbol` string, required — Token symbol
    - `decimals` integer, required — Token decimals
    - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
    - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
    - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
    - `amount` string, required
    - `usdAmount` number, float, nullable — USD value of the payment amount
  - `amountInMax` Payment, required
    - `chainId` integer, required — Chain ID. Find in the list of supported networks.
    - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
    - `name` string, required — Token name
    - `symbol` string, required — Token symbol
    - `decimals` integer, required — Token decimals
    - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
    - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
    - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
    - `amount` string, required
    - `usdAmount` number, float, nullable — USD value of the payment amount
  - `amountOut` Payment, required
    - `chainId` integer, required — Chain ID. Find in the list of supported networks.
    - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
    - `name` string, required — Token name
    - `symbol` string, required — Token symbol
    - `decimals` integer, required — Token decimals
    - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
    - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
    - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
    - `amount` string, required
    - `usdAmount` number, float, nullable — USD value of the payment amount
  - `amountOutMin` Payment, required
    - `chainId` integer, required — Chain ID. Find in the list of supported networks.
    - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
    - `name` string, required — Token name
    - `symbol` string, required — Token symbol
    - `decimals` integer, required — Token decimals
    - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
    - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
    - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
    - `amount` string, required
    - `usdAmount` number, float, nullable — USD value of the payment amount
  - `protocolFee` Payment, required
    - `chainId` integer, required — Chain ID. Find in the list of supported networks.
    - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
    - `name` string, required — Token name
    - `symbol` string, required — Token symbol
    - `decimals` integer, required — Token decimals
    - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
    - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
    - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
    - `amount` string, required
    - `usdAmount` number, float, nullable — USD value of the payment amount
  - `applicationFee` Payment, required
    - `chainId` integer, required — Chain ID. Find in the list of supported networks.
    - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
    - `name` string, required — Token name
    - `symbol` string, required — Token symbol
    - `decimals` integer, required — Token decimals
    - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
    - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
    - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
    - `amount` string, required
    - `usdAmount` number, float, nullable — USD value of the payment amount
  - `bridgeFee` Payment
    - `chainId` integer, required — Chain ID. Find in the list of supported networks.
    - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
    - `name` string, required — Token name
    - `symbol` string, required — Token symbol
    - `decimals` integer, required — Token decimals
    - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
    - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
    - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
    - `amount` string, required
    - `usdAmount` number, float, nullable — USD value of the payment amount
  - `bridgeIds` BridgeId[] — Bridge IDs used in the route.
  - `bridgeRoute` BridgeStep[] — Array of bridge steps
    - `srcChainId` integer, required — Chain ID. Find in the list of supported networks.
    - `dstChainId` integer, required — Chain ID. Find in the list of supported networks.
    - `srcBridgeToken` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
    - `dstBridgeToken` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
    - `bridgeId` string, required — Bridge protocol identifier (e.g. "across", "relay", "mayan").
  - `exchangeRate` number, float, required — Exchange rate for the swap.
  - `estimatedTxTime` number, float, required — Estimated transaction time in seconds.
  - `estimatedPriceImpact` number, float, nullable, required — Estimated price impact percentage.
  - `requiresTokenApproval` boolean, required — Flag indicating whether the transaction object requires a source token approval check.
  - `requiresRegisterTransaction` boolean, required — Flag indicating whether the transaction requires registration via the registerTxs endpoint. Mandatory for non-EVM transactions.
  - `allRoutes` BaseActionResponse[], required — All available routes for the action.
    - `tx` union, required — Transaction data for execution
      - EvmTransaction
        - `to` string, required — EVM address (0x prefix + 40 hex characters)
        - `data` string, required — Hex string with 0x prefix
        - `value` string, required — Value in wei as string
        - `chainId` integer — Chain ID. Find in the list of supported networks.
      - SerializedSolTransaction
        - `base64Tx` string, required — Base64-encoded transaction
        - `recentBlockhash` string, required — Recent blockhash for transaction validity
        - `payer` string, required — Solana public key (base58 encoded, 32-44 characters)
      - AltVmTransaction
        - `to` string, required — Exchange address format
        - `toExtra` string, nullable — Additional address information (e.g., memo, tag). Can be null.
        - `value` string, required — Value as string
        - `chainId` integer, required — Chain ID. Find in the list of supported networks.
        - `chainKey` string, required — Chain key identifier
      - HyperCoreTransaction
        - `type` 'usdSend', required — HyperCore action type
        - `destination` string, required — Destination address
        - `amount` string, required — Amount to transfer
        - `chainId` integer, required — Chain ID. Find in the list of supported networks.
      - TronTransaction
        - `to` string, required — Tron address (base58, starts with 'T', 34 chars)
        - `data` string, required — Hex-encoded calldata
        - `value` string, required — Value as string
    - `txId` string, required — Hex string with 0x prefix
    - `vmId` 'evm' | 'solana' | 'alt-vm' | 'hypercore' | 'tron', required — Virtual machine identifier.
    - `amountIn` Payment, required
      - `chainId` integer, required — Chain ID. Find in the list of supported networks.
      - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
      - `name` string, required — Token name
      - `symbol` string, required — Token symbol
      - `decimals` integer, required — Token decimals
      - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
      - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
      - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
      - `amount` string, required
      - `usdAmount` number, float, nullable — USD value of the payment amount
    - `amountInMax` Payment, required
      - `chainId` integer, required — Chain ID. Find in the list of supported networks.
      - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
      - `name` string, required — Token name
      - `symbol` string, required — Token symbol
      - `decimals` integer, required — Token decimals
      - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
      - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
      - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
      - `amount` string, required
      - `usdAmount` number, float, nullable — USD value of the payment amount
    - `amountOut` Payment, required
      - `chainId` integer, required — Chain ID. Find in the list of supported networks.
      - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
      - `name` string, required — Token name
      - `symbol` string, required — Token symbol
      - `decimals` integer, required — Token decimals
      - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
      - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
      - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
      - `amount` string, required
      - `usdAmount` number, float, nullable — USD value of the payment amount
    - `amountOutMin` Payment, required
      - `chainId` integer, required — Chain ID. Find in the list of supported networks.
      - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
      - `name` string, required — Token name
      - `symbol` string, required — Token symbol
      - `decimals` integer, required — Token decimals
      - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
      - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
      - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
      - `amount` string, required
      - `usdAmount` number, float, nullable — USD value of the payment amount
    - `protocolFee` Payment, required
      - `chainId` integer, required — Chain ID. Find in the list of supported networks.
      - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
      - `name` string, required — Token name
      - `symbol` string, required — Token symbol
      - `decimals` integer, required — Token decimals
      - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
      - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
      - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
      - `amount` string, required
      - `usdAmount` number, float, nullable — USD value of the payment amount
    - `applicationFee` Payment, required
      - `chainId` integer, required — Chain ID. Find in the list of supported networks.
      - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
      - `name` string, required — Token name
      - `symbol` string, required — Token symbol
      - `decimals` integer, required — Token decimals
      - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
      - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
      - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
      - `amount` string, required
      - `usdAmount` number, float, nullable — USD value of the payment amount
    - `bridgeFee` Payment
      - `chainId` integer, required — Chain ID. Find in the list of supported networks.
      - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
      - `name` string, required — Token name
      - `symbol` string, required — Token symbol
      - `decimals` integer, required — Token decimals
      - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
      - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
      - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
      - `amount` string, required
      - `usdAmount` number, float, nullable — USD value of the payment amount
    - `bridgeIds` BridgeId[] — Bridge IDs used in the route.
    - `bridgeRoute` BridgeStep[] — Array of bridge steps
      - `srcChainId` integer, required — Chain ID. Find in the list of supported networks.
      - `dstChainId` integer, required — Chain ID. Find in the list of supported networks.
      - `srcBridgeToken` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
      - `dstBridgeToken` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
      - `bridgeId` string, required — Bridge protocol identifier (e.g. "across", "relay", "mayan").
    - `exchangeRate` number, float, required — Exchange rate for the swap.
    - `estimatedTxTime` number, float, required — Estimated transaction time in seconds.
    - `estimatedPriceImpact` number, float, nullable, required — Estimated price impact percentage.
    - `requiresRegisterTransaction` boolean, required — Flag indicating whether the transaction requires registration via the registerTxs endpoint. Mandatory for non-EVM transactions.
    - `executionsType` 'DEFAULT' | 'GASLESS' — Indicates the execution mode. `GASLESS` when `gasless=true` was requested and a relay provider is available; `DEFAULT` otherwise.
    - `executions` Execution[] — Ordered list of signing steps the client must complete before calling `POST /submitTx`. Only present when `executionsType` is `GASLESS`.
      - union — A single signing step returned in the `executions` array of a gasless `getAction` response. Only available for Tron same-chain swaps. The client must sign each item in order and include the signatures when calling `POST /submitTx`.
        - EvmTransactionSignExecution
          - `txType` 'evmTransactionSign', required
          - `data` string, required — JSON string of an unsigned Tron transaction (TronWeb `raw_data` shape)
          - `signature` string — Hex-encoded signature from TronLink or compatible Tron wallet
        - EvmSignTypedDataExecution
          - `txType` 'evmSignTypedData', required
          - `data` union, required — EIP-712 typed data to sign. Accepted as either a JSON string (same format returned by `GET /getAction`) or a parsed object — both are equivalent.
            - string — JSON-encoded EIP-712 typed data
            - Eip712Data
              - …
          - `signature` string — Hex-encoded EIP-712 signature
    - `relayerFee` Payment
      - `chainId` integer, required — Chain ID. Find in the list of supported networks.
      - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
      - `name` string, required — Token name
      - `symbol` string, required — Token symbol
      - `decimals` integer, required — Token decimals
      - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
      - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
      - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
      - `amount` string, required
      - `usdAmount` number, float, nullable — USD value of the payment amount
  - `executionsType` 'DEFAULT' | 'GASLESS' — Indicates the execution mode. `GASLESS` when `gasless=true` was requested and a relay provider is available; `DEFAULT` otherwise.
  - `executions` Execution[] — Ordered list of signing steps the client must complete before calling `POST /submitTx`. Only present when `executionsType` is `GASLESS`.
    - union — A single signing step returned in the `executions` array of a gasless `getAction` response. Only available for Tron same-chain swaps. The client must sign each item in order and include the signatures when calling `POST /submitTx`.
      - EvmTransactionSignExecution
        - `txType` 'evmTransactionSign', required
        - `data` string, required — JSON string of an unsigned Tron transaction (TronWeb `raw_data` shape)
        - `signature` string — Hex-encoded signature from TronLink or compatible Tron wallet
      - EvmSignTypedDataExecution
        - `txType` 'evmSignTypedData', required
        - `data` union, required — EIP-712 typed data to sign. Accepted as either a JSON string (same format returned by `GET /getAction`) or a parsed object — both are equivalent.
          - string — JSON-encoded EIP-712 typed data
          - Eip712Data
            - `domain` Eip712Domain, required
              - …
            - `types` object, required — EIP-712 type definitions (field name → array of {name, type} pairs)
            - `message` object, required — The typed data message payload
        - `signature` string — Hex-encoded EIP-712 signature
  - `relayerFee` Payment
    - `chainId` integer, required — Chain ID. Find in the list of supported networks.
    - `address` string, required — Address type - can be EvmAddress, HyperCoreAddress, SolanaAddress, or AltVmAddress.
    - `name` string, required — Token name
    - `symbol` string, required — Token symbol
    - `decimals` integer, required — Token decimals
    - `isNative` boolean, required — Boolean flag for whether token is the chain's gas token.
    - `logo` string, nullable — URL to the token's logo image. Can be null if logo is not available.
    - `swapsXyzCode` string — Internal Swaps.xyz token identifier code.
    - `amount` string, required
    - `usdAmount` number, float, nullable — USD value of the payment amount

## Other responses

- `400` — Bad request due to missing or invalid parameters
- `401` — Unauthorized - Invalid or missing API key
- `403` — Forbidden - Access denied due to restrictions
- `405` — Method not allowed
- `500` — Internal server error

---

[API](https://skmtc.dev/swaps/apis/prediction-market-data-api.md) · [All operations](https://skmtc.dev/swaps/apis/prediction-market-data-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/swaps/prediction-market-data-api/revisions/03e917d60cb7/schema)
