v1

latestOpenAPI 3.0.02026-07-14395.2 KB

getQuote

post/#particle_swap_getQuote

Request body

jsonrpcstring required
idinteger required
chainIdinteger
method'particle_swap_getQuote' required

Example request

{
  "params": [
    "0x369aa8a7a7BE683E1a46d9A056806B2B3FD778C8"
  ]
}

Response

Success

jsonrpcstring required
idinteger required
chainIdinteger

Example response

{
  "result": {
    "fromToken": {
      "chainId": 1,
      "address": "0x6B175474E89094C44Da98b954EedeAC495271d0F",
      "symbol": "DAI",
      "name": "Dai Stablecoin",
      "decimals": 18,
      "logoURI": "https://static.particle.network/token-list/ethereum/0x6B175474E89094C44Da98b954EedeAC495271d0F.png"
    },
    "toToken": {
      "chainId": 1,
      "address": "0x6B175474E89094C44Da98b954EedeAC495271d0F",
      "symbol": "DAI",
      "name": "Dai Stablecoin",
      "decimals": 18,
      "logoURI": "https://static.particle.network/token-list/ethereum/0x6B175474E89094C44Da98b954EedeAC495271d0F.png"
    },
    "toTokenAmount": "781970036",
    "fromTokenAmount": "1000000000",
    "estimatedGas": "0x4079f"
  }
}