Get / Quote
New improved quote endpoint. This API returns a detailed quote and transaction package for performing a token swap. The response includes the calculated output amounts, slippage, routing plan and a serialized transaction ready to be submitted to the blockchain.
OpenAPI definition
{
"openapi": "3.0.0",
"info": {
"version": "1.0.0",
"title": "Q1"
},
"servers": [
{
"url": "https://api.carbium.io/api/v2"
}
],
"paths": {
"/quote": {
"get": {
"description": "",
"operationId": "get_quote",
"responses": {
"200": {
"description": ""
}
},
"parameters": [
{
"in": "query",
"name": "src_mint",
"schema": {
"type": "string",
"default": "So11111111111111111111111111111111111111112"
},
"required": true,
"description": "Input token address"
},
{
"in": "query",
"name": "dst_mint",
"schema": {
"type": "string",
"default": "AT79ReYU9XtHUTF5vM6Q4oa9K8w7918Fp5SU7G1MDMQY"
},
"required": true,
"description": "Output token address"
},
{
"in": "query",
"name": "amount_in",
"schema": {
"type": "integer",
"default": "1000000000"
},
"required": true,
"description": "Input amount (in lamports)"
},
{
"in": "query",
"name": "slippage_bps",
"schema": {
"type": "integer",
"default": "100"
},
"required": true,
"description": "Slippage (in BPS)"
},
{
"in": "query",
"name": "user_account",
"schema": {
"type": "string"
},
"description": "User address (if included, the response returns a base64 txn)"
}
]
}
}
},
"components": {
"securitySchemes": {
"apiKey": {
"type": "apiKey",
"in": "header",
"name": "X-API-KEY"
}
}
},
"x-readme": {
"explorer-enabled": true,
"proxy-enabled": true
},
"security": [
{
"apiKey": []
}
]
}