curl --request POST \
--url https://quotes.eco.com/api/v3/quotes/exactIn \
--header 'Content-Type: application/json' \
--data '
{
"dAppID": "my-dapp",
"intentExecutionTypes": [
"SELF_PUBLISH"
],
"quoteRequest": {
"sourceChainID": 1,
"destinationChainID": 42161,
"sourceToken": "0xA0b86a33E6441e45C3b9d1C3D6a0b5be4b7b5b5a",
"destinationToken": "0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8",
"sourceAmount": "1000000",
"funder": "0x742d35Cc6527C92b4A1F3a2a8b1c9b3e8c4c5b2a",
"recipient": "0x8Ba1c0a8B4A4b9e8A9f1a6B7c8d9e0F1234567890",
"refundRecipient": "0x742d35Cc6527C92b4A1F3a2a8b1c9b3e8c4c5b2a"
},
"contracts": {
"sourcePortal": "0x1234567890abcdef1234567890abcdef12345678",
"destinationPortal": "0x567890abcdef1234567890abcdef1234567890ab",
"prover": "0xabcdef1234567890abcdef1234567890abcdef12"
}
}
'{
"data": [
{
"quoteID": "<string>",
"solverID": "<string>",
"receiveSignedIntentUrl": "<string>",
"quoteData": {
"contracts": {
"sourcePortal": "0x1234567890abcdef1234567890abcdef12345678",
"destinationPortal": "0x567890abcdef1234567890abcdef1234567890ab",
"prover": "0xabcdef1234567890abcdef1234567890abcdef12"
},
"quoteResponse": {
"intentExecutionType": "SELF_PUBLISH",
"sourceChainID": 1,
"destinationChainID": 42161,
"sourceToken": "0xA0b86a33E6441e45C3b9d1C3D6a0b5be4b7b5b5a",
"destinationToken": "0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8",
"sourceAmount": "1000000",
"destinationAmount": "995000",
"funder": "0x742d35Cc6527C92b4A1F3a2a8b1c9b3e8c4c5b2a",
"refundRecipient": "0x742d35Cc6527C92b4A1F3a2a8b1c9b3e8c4c5b2a",
"recipient": "0x8Ba1c0a8B4A4b9e8A9f1a6B7c8d9e0F1234567890",
"fees": [
{
"name": "Solver Fee",
"description": "Fee paid to the solver for executing the cross-chain swap",
"token": {
"address": "0xA0b86a33E6441e45C3b9d1C3D6a0b5be4b7b5b5a",
"decimals": 6,
"symbol": "USDC"
},
"amount": "1000"
}
],
"deadline": 1672531200,
"estimatedFulfillTimeSec": 300,
"encodedRoute": "0x00000000000000000000000000000000000000000000000000000000000000202810ea6d0860ce5315ef2b62b1b580f2b4ef158b76a6ea8f8982600c130e55e70000000000000000000000000000000000000000000000000000000068e56fa2000000000000000000000000b5e58a8206473dc3ab9b8d4d3b0f84c0ba68f8b5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000001200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000833589fcd6edb6e082dc7c32d4f71b54bda0291300000000000000000000000000000000000000000000000000000000004bd61000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000833589fcd6edb6e08f4c7c32d4f71b54bda02913000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000044a9059cbb0000000000000000000000002b2c52b1b63c4bfc7f16910a1734641d8e34de6200000000000000000000000000000000000000000000000000000000004bd61000000000000000000000000000000000000000000000000000000000"
}
}
}
]
}Retrieve exact in quotes from solvers for a given intent. Exact in quotes allow you to specify what you want to offer and get quotes for what will be received and can only have transfer calls.
curl --request POST \
--url https://quotes.eco.com/api/v3/quotes/exactIn \
--header 'Content-Type: application/json' \
--data '
{
"dAppID": "my-dapp",
"intentExecutionTypes": [
"SELF_PUBLISH"
],
"quoteRequest": {
"sourceChainID": 1,
"destinationChainID": 42161,
"sourceToken": "0xA0b86a33E6441e45C3b9d1C3D6a0b5be4b7b5b5a",
"destinationToken": "0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8",
"sourceAmount": "1000000",
"funder": "0x742d35Cc6527C92b4A1F3a2a8b1c9b3e8c4c5b2a",
"recipient": "0x8Ba1c0a8B4A4b9e8A9f1a6B7c8d9e0F1234567890",
"refundRecipient": "0x742d35Cc6527C92b4A1F3a2a8b1c9b3e8c4c5b2a"
},
"contracts": {
"sourcePortal": "0x1234567890abcdef1234567890abcdef12345678",
"destinationPortal": "0x567890abcdef1234567890abcdef1234567890ab",
"prover": "0xabcdef1234567890abcdef1234567890abcdef12"
}
}
'{
"data": [
{
"quoteID": "<string>",
"solverID": "<string>",
"receiveSignedIntentUrl": "<string>",
"quoteData": {
"contracts": {
"sourcePortal": "0x1234567890abcdef1234567890abcdef12345678",
"destinationPortal": "0x567890abcdef1234567890abcdef1234567890ab",
"prover": "0xabcdef1234567890abcdef1234567890abcdef12"
},
"quoteResponse": {
"intentExecutionType": "SELF_PUBLISH",
"sourceChainID": 1,
"destinationChainID": 42161,
"sourceToken": "0xA0b86a33E6441e45C3b9d1C3D6a0b5be4b7b5b5a",
"destinationToken": "0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8",
"sourceAmount": "1000000",
"destinationAmount": "995000",
"funder": "0x742d35Cc6527C92b4A1F3a2a8b1c9b3e8c4c5b2a",
"refundRecipient": "0x742d35Cc6527C92b4A1F3a2a8b1c9b3e8c4c5b2a",
"recipient": "0x8Ba1c0a8B4A4b9e8A9f1a6B7c8d9e0F1234567890",
"fees": [
{
"name": "Solver Fee",
"description": "Fee paid to the solver for executing the cross-chain swap",
"token": {
"address": "0xA0b86a33E6441e45C3b9d1C3D6a0b5be4b7b5b5a",
"decimals": 6,
"symbol": "USDC"
},
"amount": "1000"
}
],
"deadline": 1672531200,
"estimatedFulfillTimeSec": 300,
"encodedRoute": "0x00000000000000000000000000000000000000000000000000000000000000202810ea6d0860ce5315ef2b62b1b580f2b4ef158b76a6ea8f8982600c130e55e70000000000000000000000000000000000000000000000000000000068e56fa2000000000000000000000000b5e58a8206473dc3ab9b8d4d3b0f84c0ba68f8b5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000001200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000833589fcd6edb6e082dc7c32d4f71b54bda0291300000000000000000000000000000000000000000000000000000000004bd61000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000833589fcd6edb6e08f4c7c32d4f71b54bda02913000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000044a9059cbb0000000000000000000000002b2c52b1b63c4bfc7f16910a1734641d8e34de6200000000000000000000000000000000000000000000000000000000004bd61000000000000000000000000000000000000000000000000000000000"
}
}
}
]
}Unique identifier for the client application making the request
"my-dapp"
Array of intent execution types to fetch quotes for
SELF_PUBLISH, GASLESS ["SELF_PUBLISH"]Cross-chain token swap request details including source/destination tokens and addresses
Show child attributes
Chain ID of the source network where tokens will be sent from
1
Chain ID of the destination network where tokens will be received
42161
Contract address of the token being sent on the source chain
"0xA0b86a33E6441e45C3b9d1C3D6a0b5be4b7b5b5a"
Contract address of the token to be received on the destination chain
"0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8"
Amount of source tokens to send, specified as a string representation of a bigint
"1000000"
Address that will provide the tokens and pay for the transaction
"0x742d35Cc6527C92b4A1F3a2a8b1c9b3e8c4c5b2a"
Address that will receive the tokens on the destination chain
"0x8Ba1c0a8B4A4b9e8A9f1a6B7c8d9e0F1234567890"
Address to receive refunds if the intent fails (defaults to funder if not specified)
"0x742d35Cc6527C92b4A1F3a2a8b1c9b3e8c4c5b2a"
Optional contract addresses to use for the cross-chain swap (will use defaults if not specified)
Show child attributes
Contract address for the intent source (where intents are created and managed)
"0x1234567890abcdef1234567890abcdef12345678"
Contract address for the inbox (receives and processes cross-chain messages)
"0x567890abcdef1234567890abcdef1234567890ab"
Contract address for the prover (handles cross-chain proof verification)
"0xabcdef1234567890abcdef1234567890abcdef12"
Successfully retrieved exact in quotes from solvers
Array of solver quote responses
Show child attributes
Show child attributes
Contract addresses required for executing this cross-chain swap
Show child attributes
Contract address for the intent source (where intents are created and managed)
"0x1234567890abcdef1234567890abcdef12345678"
Contract address for the inbox (receives and processes cross-chain messages)
"0x567890abcdef1234567890abcdef1234567890ab"
Contract address for the prover (handles cross-chain proof verification)
"0xabcdef1234567890abcdef1234567890abcdef12"
Detailed quote information including tokens, amounts, fees, and timing
Show child attributes
The execution type for this quote entry
SELF_PUBLISH, GASLESS "SELF_PUBLISH"
Chain ID of the source network where tokens will be sent from
1
Chain ID of the destination network where tokens will be received
42161
Contract address of the token being sent on the source chain
"0xA0b86a33E6441e45C3b9d1C3D6a0b5be4b7b5b5a"
Contract address of the token to be received on the destination chain
"0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8"
Amount of source tokens to send, as a string representation of a bigint
"1000000"
Amount of destination tokens to be received, as a string representation of a bigint
"995000"
Address that will provide the tokens and pay for the transaction
"0x742d35Cc6527C92b4A1F3a2a8b1c9b3e8c4c5b2a"
Address to receive refunds if the intent fails
"0x742d35Cc6527C92b4A1F3a2a8b1c9b3e8c4c5b2a"
Address that will receive the tokens on the destination chain
"0x8Ba1c0a8B4A4b9e8A9f1a6B7c8d9e0F1234567890"
Array of fees that will be charged for executing this cross-chain swap
Show child attributes
Name identifier for the fee type
"Solver Fee"
Human-readable description of what this fee covers
"Fee paid to the solver for executing the cross-chain swap"
Token information for the fee payment
Show child attributes
Contract address of the token
"0xA0b86a33E6441e45C3b9d1C3D6a0b5be4b7b5b5a"
Number of decimal places for the token
6
Token symbol or ticker
"USDC"
Fee amount as a string representation of a bigint
"1000"
Unix timestamp (in seconds) after which this quote expires and cannot be executed
1672531200
Estimated time in seconds for the cross-chain swap to be completed
300
ABI-encoded route data for on-chain intent execution
"0x00000000000000000000000000000000000000000000000000000000000000202810ea6d0860ce5315ef2b62b1b580f2b4ef158b76a6ea8f8982600c130e55e70000000000000000000000000000000000000000000000000000000068e56fa2000000000000000000000000b5e58a8206473dc3ab9b8d4d3b0f84c0ba68f8b5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000001200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000833589fcd6edb6e082dc7c32d4f71b54bda0291300000000000000000000000000000000000000000000000000000000004bd61000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000020000000000000000000000000833589fcd6edb6e08f4c7c32d4f71b54bda02913000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000044a9059cbb0000000000000000000000002b2c52b1b63c4bfc7f16910a1734641d8e34de6200000000000000000000000000000000000000000000000000000000004bd61000000000000000000000000000000000000000000000000000000000"