# Get Conversion Quotes (server-to-server)

Our Payment Gateway API provides a `GET` method to retrieve real-time conversion quotes for cryptocurrency prices. \
This endpoint is crucial for payment server-to-server flow.

Below you will find the details on how to use this endpoint.&#x20;

{% hint style="info" %} <mark style="color:blue;">**Reminder**</mark>\
The payment conversion rate is finalized during payment creation.\
This API returns just an informative status of the current rates.&#x20;
{% endhint %}

## Get Quotes

<mark style="color:blue;">`GET`</mark> `https://sandbox.coinbar.io/coinbar/api/v2/pay/gateway/quotes`

This endpoint returns up-to-date conversion rates between specified cryptocurrencies and fiat currencies. \
By utilizing this API, payment systems can ensure that users receive the most current exchange rate information for their cryptocurrency transactions.

#### Query Parameters

| Name             | Type   | Description                               |
| ---------------- | ------ | ----------------------------------------- |
| conversion\_fiat | String | <p>EUR,GBP<br><em>Default (EUR)</em> </p> |

#### Headers

| Name                                            | Type   | Description                                                |
| ----------------------------------------------- | ------ | ---------------------------------------------------------- |
| CBPAY-API-KEY<mark style="color:red;">\*</mark> | String | {{<mark style="color:purple;">`SERVICE_CLIENT_ID`</mark>}} |
| Content-Type                                    | String | application/json                                           |

{% tabs %}
{% tab title="200: OK " %}

```json
{
    "result": true,
    "data": [
        {
            "code": "BTC",
            "name": "Bitcoin",
            "conversion_fiat": "EUR",
            "conversion_rate": 52372.33459748911
        },
        {
            "code": "ETH",
            "name": "Ethereum",
            "conversion_fiat": "EUR",
            "conversion_rate": 2367.6994724246447
        },
        {
            "code": "USDT",
            "name": "Tether USD",
            "conversion_fiat": "EUR",
            "conversion_rate": 0.9173165543511799
        },
        {
            "code": "XDB",
            "name": "XDB Chain",
            "conversion_fiat": "EUR",
            "conversion_rate": 0.0005691800447701324
        },
        {
            "code": "XRP",
            "name": "Ripple",
            "conversion_fiat": "EUR",
            "conversion_rate": 0.5123986479693387
        }
    ]
}
```

{% endtab %}

{% tab title="401: Unauthorized " %}

```json
{
    "result": false,
    "error": "Not Authorized"
}
```

{% endtab %}

{% tab title="400: Bad Request " %}

```json
{
    "result": false,
    "error": "Bad Request"
}
```

{% endtab %}

{% tab title="500: Internal Server Error Api rate exceeded" %}

```javascript
{
    "result": false,
    "error": "Api RATE exceeded"
}
```

{% endtab %}
{% endtabs %}

{% hint style="warning" %} <mark style="color:orange;">**Warning**</mark>

Each <mark style="color:purple;">`SERVICE_CLIENT_ID`</mark> has a default API RATE limit of 1000 calls each day.\
Contact Coinbar Team to extend your limit.&#x20;
{% endhint %}


---

# 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.coinbar.io/api-web-integration/api-documentation/get-conversion-quotes-server-to-server.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.
