# quotes

{% hint style="info" %}
This version contains experimental support for Jupiter in the `Quotes` endpoint and `Prices` stream endpoint. Note that the endpoints in Trader API are powered by Geyser, which is faster but will also result in subtly different state representations than what you'd normally get over Solana RPC. We welcome any feedback you have on these results.
{% endhint %}

### Request

#### Method:&#x20;

`GET ./api/v2/jupiter/quotes`

#### Parameters:

<table><thead><tr><th width="177.5236885968357">Parameter</th><th width="150">Type</th><th>Description</th></tr></thead><tbody><tr><td><code>inToken</code></td><td>string</td><td>Symbol of the swap-in token.</td></tr><tr><td><code>outToken</code></td><td>string</td><td>Symbol of the swap-out token.</td></tr><tr><td><code>inAmount</code></td><td>double</td><td>The amount of token wanted to be swapped from.</td></tr><tr><td><code>slippage</code></td><td>double</td><td>The maximum slippage tolerance in percentage.</td></tr><tr><td><code>fastMode</code></td><td>boolean</td><td>OPTIONAL. Lower latency option that excludes Raydium Pools.  </td></tr></tbody></table>

{% hint style="info" %}
Jupiter support for this endpoint is still experimental as we incorporate Geyser streams into Jupiter's aggregation algorithms. We welcome any feedback here.
{% endhint %}

#### Request example:

{% tabs %}
{% tab title="HTTP" %}

```bash
curl --header "Authorization: $AUTH_HEADER" \
"https://ny.solana.dex.blxrbdn.com/api/v2/jupiter/quotes?inToken=SOL&outToken=USDC&inAmount=0.1&slippage=0.1",
```

{% endtab %}

{% tab title="WebSocket" %}

```bash
wscat --header "Authorization: $AUTH_HEADER" 
-c wss://ny.solana.dex.blxrbdn.com/ws --execute '{"jsonrpc": "2.0", "id": 1, "method": "GetJupiterQuotes", "params": {"inToken": "SOL", "outToken": "USDC", "inAmount":0.1, "slippage": 0.1}}'/
```

{% endtab %}

{% tab title="Go" %}

```go
//missing
```

{% endtab %}

{% tab title="TypeScript" %}

<pre class="language-typescript"><code class="lang-typescript">await provider.getQuotes({
    inToken: "SOL",
<strong>    outToken: "USDC",
</strong>    inAmount: 1,
<strong>    slippage: 5,
</strong>    limit: 5,
    projects: ["P_RAYDIUM", "P_JUPITER"],
})
</code></pre>

{% endtab %}
{% endtabs %}

### Response:

#### Fields: <a href="#fields" id="fields"></a>

<table><thead><tr><th width="206.5236885968357">Field</th><th width="186">Type</th><th width="419.58916051319363">Description</th></tr></thead><tbody><tr><td><code>inToken</code></td><td>string</td><td>Symbol of the swap-in token.</td></tr><tr><td><code>inTokenAddress</code></td><td>string</td><td>The program address for the swap-in token.</td></tr><tr><td><code>outToken</code></td><td>string</td><td>Symbol of the swap-out token.</td></tr><tr><td><code>outTokenAddress</code></td><td>string</td><td>The program address for the swap-out token.</td></tr><tr><td><code>inAmount</code></td><td>double</td><td>The amount of token wanted to be swapped from.</td></tr><tr><td><code>quotes</code></td><td>[] <code>ProjectQuote</code></td><td>See <code>ProjectQuote</code> below for details.</td></tr></tbody></table>

`ProjectQuote`

<table><thead><tr><th width="177.5236885968357">Field</th><th width="150">Type</th><th>Description</th></tr></thead><tbody><tr><td><code>project</code></td><td>string</td><td>Symbol of the swap-in token.</td></tr><tr><td><code>routes</code></td><td>[]<code>QuoteRoute</code></td><td>See <code>QuoteRoute</code> below for details.</td></tr></tbody></table>

`QuoteRoute`

<table><thead><tr><th width="177.5236885968357">Field</th><th width="150">Type</th><th>Description</th></tr></thead><tbody><tr><td><code>inAmount</code></td><td>double</td><td>Number of the swap-in token.</td></tr><tr><td><code>outAmount</code></td><td>double</td><td>Number of the swap-out token.</td></tr><tr><td><code>steps</code></td><td>[]<code>QuoteStep</code></td><td>See <code>QuoteStep</code> below for details.</td></tr></tbody></table>

`QuoteStep`

<table><thead><tr><th width="177.5236885968357">Field</th><th width="274.6918703848952">Type</th><th>Description</th></tr></thead><tbody><tr><td><code>inToken</code></td><td>string</td><td>Symbol of the swap-in token for the current step.</td></tr><tr><td><code>inTokenAddress</code></td><td>string</td><td>The program address for the swap-in token for the current step.</td></tr><tr><td><code>outToken</code></td><td>string</td><td>Symbol of the swap-out token for the current step.</td></tr><tr><td><code>outTokenAddress</code></td><td>string</td><td>The program address for the swap-out token for the current step.</td></tr><tr><td><code>inAmount</code></td><td>double</td><td>Number of the swap-in token for the current step.</td></tr><tr><td><code>outAmount</code></td><td>double</td><td>Number of the swap-out token for the current step.</td></tr><tr><td><code>slippage</code></td><td>double</td><td>The maximum slippage tolerance in percentage.</td></tr><tr><td><code>priceImpact</code></td><td><code>PriceImpactPercent</code></td><td><code>"percent"</code> Percentage impact on price.<br><code>"infinity"</code> Indicates possible infinity values: <code>INF_NOT</code>, <code>INF_POSITIVE</code>, <code>INF_NEGATIVE</code>. Usually <code>INF_NOT</code>.</td></tr><tr><td><code>fee</code></td><td>Fee</td><td><code>"amount"</code>  Amount paid to AMM project.<br><code>"mint"</code> Token currency the fee is paid in.<br><code>"percent"</code> Percentage of the swap consumed by the fee.</td></tr></tbody></table>

`PriceImpactPercent`

<table><thead><tr><th width="177.5236885968357">Field</th><th width="150">Type</th><th width="419.58916051319363">Description</th></tr></thead><tbody><tr><td><code>percent</code></td><td>number</td><td>Percentage impact on price.</td></tr><tr><td><code>infinity</code></td><td>string</td><td>Indicates possible infinity values: <code>INF_NOT</code>, <code>INF_POSITIVE</code>, <code>INF_NEGATIVE</code>. Usually <code>INF_NOT</code>.</td></tr></tbody></table>

`Fee`

<table><thead><tr><th width="173.5236885968357">Field</th><th width="150">Type</th><th width="419.58916051319363">Description</th></tr></thead><tbody><tr><td><code>amount</code></td><td>number</td><td>Amount paid to AMM project</td></tr><tr><td><code>mint</code></td><td>string</td><td>Token currency the fee is paid in</td></tr><tr><td><code>percent</code></td><td>number</td><td>Percentage of the swap consumed by the fee</td></tr></tbody></table>

Response Example:

{% tabs %}
{% tab title="JSON" %}

```json
{
    "inToken": "SOL",
    "inTokenAddress": "So11111111111111111111111111111111111111112",
    "outToken": "USDC",
    "outTokenAddress": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v",
    "inAmount": 0.1,
    "quotes": [
        {
            "routes": [
                {
                    "inAmount": 0.1,
                    "outAmount": 5.843859,
                    "steps": [
                        {
                            "project": {
                                "label": "Raydium",
                                "id": ""
                            },
                            "inToken": "SOL",
                            "inTokenAddress": "So11111111111111111111111111111111111111112",
                            "outToken": "",
                            "outTokenAddress": "4k3Dyjzvzp8eMZWUXbBCjEvwSkkk59S5iCNLY3QrkX6R",
                            "inAmount": 0.1,
                            "outAmount": 3.328617,
                            "slippage": 0.1,
                            "priceImpactPercent": {
                                "percent": 9.899955638899446e-7,
                                "infinity": "INF_NOT"
                            },
                            "fee": {
                                "amount": 0.00025,
                                "mint": "",
                                "percent": 0
                            }
                        }
                    ]
                }
            ]
        }
    ]
}
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.bloxroute.com/solana/trader-api/api-endpoints/jupiter/quotes.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
