Intent Solver quote#

POST /quote#

Get a price estimate (Quote).

POST /quote
Content-Type: application/json

Request parameters.

Request parameters#

ParameterTypeRequiredDescriptionExample
chainIndexStringYESChain ID1
fromTokenAddressStringYESSell token address0xA0b8...
fromTokenTagsArrayNoSell Token Tag List["RWA_ONDO","RWA"]
toTokenAddressStringYESBuy token address0xdAC1...
toTokenTagsArrayNobuy Token Tag List["RWA_ONDO","RWA"]
swapModeStringYESOrder type:exactIn / exactOutexactIn
amountStringYESAmount to buy or sell (in the smallest units), before fees are deducted.1000000000000000000
deadlineStringYESDeadline timestamp by which a response is expected172120120102
userWalletAddressStringYESuesr wallet address0x29e2...
commissionInfosArrayNoCommission info list
┗ feePercentStringYESUp to 9 decimal places are allowed. If more decimals are provided, the system will round up automatically.20000000
┗ referrerWalletAddressStringYESCommission recipient address.0x1234...
┗ feeDirectionBooleanYESFee side::true = charge fromToken,false = charge toTokentrue
┗ commissionTypeStringYESCommission type:okx = OKX platform fee、parent = parent node share、child = child node shareokx
┗ toBBooleanYESOrder type:true = ToB、false = ToCfalse

POST /quote Request Example:

json
{
  "amount": "5000000",
  "chainIndex": "1",
  "commissionInfos": [
    {
      "commissionType": "okx",
      "feeDirection": true,
      "feePercent": "3000000",
      "referrerWalletAddress": "0x29e27c8e9979b9879de65955f172f36236446925",
      "toB": false
    },
    {
      "commissionType": "child",
      "feeDirection": true,
      "feePercent": "1000000",
      "referrerWalletAddress": "0x29e27c8e9979b9879de65955f172f36236446925",
      "toB": false
    },
    {
      "commissionType": "parent",
      "feeDirection": true,
      "feePercent": "500000",
      "referrerWalletAddress": "0x29e27c8e9979b9879de65955f172f36236446925",
      "toB": false
    }
  ],
  "deadline": "1772781826964",
  "fromTokenAddress": "0xdac17f958d2ee523a2206206994597c13d831ec7",
  "fromTokenTags": ["RWA_ONDO","RWA"],
  "swapMode": "exactIn",
  "toTokenAddress": "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
  "toTokenTags": ["RWA_ONDO","RWA"],
  "userWalletAddress": "0x29e27c8e9979b9879de65955f172f36236446925",
  "tokens": [
        {
            "address": "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee",
            "decimals": "18",
            "price": "2284.7"
        }
    ]
}

POST /quote Response Example:

json
{
  "code": 0,
  "msg": "success",
  "error_code": "0",
  "error_message": "",
  "detailMsg": ""
}