Skip to main content
POST
/
api
/
v2
/
quote
/
reverse
cURL
curl --request POST \
  --url https://api.example.com/api/v2/quote/reverse \
  --header 'Content-Type: application/json' \
  --data '
{
  "quoteID": "quote:966ee977-586b-4bca-abf1-e7def508a19c",
  "dAppID": "<string>",
  "intentExecutionTypes": [
    "SELF_PUBLISH"
  ],
  "quoteRequest": {
    "sourceChainID": 123,
    "destinationChainID": 123,
    "sourceToken": "<string>",
    "destinationToken": "<string>",
    "sourceAmount": "<string>",
    "funder": "<string>",
    "recipient": "<string>",
    "refundRecipient": "<string>"
  },
  "contracts": {
    "sourcePortal": "0x1234567890abcdef1234567890abcdef12345678",
    "destinationPortal": "0x567890abcdef1234567890abcdef1234567890ab",
    "prover": "0xabcdef1234567890abcdef1234567890abcdef12"
  },
  "gaslessIntentData": {
    "permit3": {
      "chainId": 1,
      "permitContract": "0x1234567890123456789012345678901234567890",
      "owner": "0x0987654321098765432109876543210987654321",
      "salt": "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef",
      "signature": "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef1b",
      "deadline": 1699999999,
      "timestamp": 1699988888,
      "merkleRoot": "0xabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcd",
      "leaves": [
        "0xabcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890",
        "0xfedcba0987654321fedcba0987654321fedcba0987654321fedcba0987654321"
      ],
      "allowanceOrTransfers": [
        {
          "chainID": 1,
          "modeOrExpiration": 0,
          "tokenKey": "0x000000000000000000000000a0b86a33e6441b8ec2c8c7e5b0d77d5fdda0c4e4",
          "account": "0x742d35cc6634c0532925a3b8b0eff6a2db3b51a",
          "amountDelta": "1000000000000000000"
        }
      ]
    },
    "allowPartial": false
  }
}
'

Body

application/json
quoteID
string
required

Unique identifier for the quote request

Example:

"quote:966ee977-586b-4bca-abf1-e7def508a19c"

dAppID
string
required
intentExecutionTypes
enum<string>[]
required

Array of intent execution types to fetch quotes for

Available options:
SELF_PUBLISH,
GASLESS
Example:
["SELF_PUBLISH"]
quoteRequest
object
required
contracts
object
gaslessIntentData
object

Optional gasless intent data containing permit signatures for token approvals and execution configuration

Response

201 - undefined