> For a complete page index, fetch https://docs.transak.com/llms.txt

# Get Price Based on User Region

The `quoteCountryCode` parameter on the [Get Price API](/api/public/get-price) lets you request a quote tied to the user's KYC country — so the price your backend fetches always matches what the Transak Widget shows.

Only [ISO Alpha-2](https://www.iban.com/country-codes) country codes are accepted for `quoteCountryCode`, for example `US`, `FR`, `IT`.

## Why use `quoteCountryCode`?

<table>
  <tbody>
    <tr>
      <td>
        <strong>
          Consistent Pricing
        </strong>

        Quotes from the Get Price API match exactly what users see inside the Transak Widget — no surprises at checkout.
      </td>
    </tr>

    <tr>
      <td>
        <strong>
          Region-Accurate Fees
        </strong>

        Pricing varies by region. Passing the correct country code ensures fees, limits, and rates are calculated for the right market.
      </td>
    </tr>
  </tbody>
</table>

## How it works

Check whether you already have the user's verified KYC country (passed via `userData`) or need to fall back to their IP-detected location.

Include `quoteCountryCode` in your API request query string with the appropriate Alpha-2 code (e.g. `FR` for France).

The API returns pricing, fees, and limits calculated specifically for that country — ready to display to the user or use for order creation.

## Usage scenarios

When the user's KYC information is already shared via the [`userData`](/customization/query-parameters) query parameter, use their KYC country directly.

**Example:** User's KYC country is France -> set `quoteCountryCode=FR`

If you don't have the user's KYC country, fall back to their IP-detected location as a best-effort approximation.

**Example:** If the user is located in Italy, then `quoteCountryCode` can be set to `IT` based on the user's IP.

## Sample request

```bash
curl --request GET \
  --url 'https://api-stg.transak.com/api/v1/pricing/public/quotes?partnerApiKey=YOUR_API_KEY&fiatCurrency=USD&cryptoCurrency=ETH&isBuyOrSell=BUY&network=ethereum&paymentMethod=credit_debit_card&fiatAmount=100&quoteCountryCode=FR' \
  --header 'accept: application/json'
```

## Sample response

```json
{
  "response": {
    "quoteId": "5b42f946-47b4-4bea-9e7e-563488d03333",
    "conversionPrice": 1.10475627488855,
    "marketConversionPrice": 1.1161162939576061,
    "slippage": 1.02,
    "fiatCurrency": "EUR",
    "cryptoCurrency": "USDC",
    "paymentMethod": "credit_debit_card",
    "fiatAmount": 100,
    "cryptoAmount": 107.68,
    "isBuyOrSell": "BUY",
    "network": "arbitrum",
    "feeDecimal": 0.0253,
    "totalFee": 2.53,
    "feeBreakdown": [
      { "name": "Transak fee", "value": 2.51, "id": "transak_fee", "ids": ["transak_fee"] },
      { "name": "Network/Exchange fee", "value": 0.02, "id": "network_fee", "ids": ["network_fee"] }
    ],
    "nonce": 1727442044,
    "cryptoLiquidityProvider": "transak",
    "notes": []
  }
}
```

## Quote accuracy by scenario

<thead>
  <tr>
    <th>
      User Flow
    </th>

    <th>
      KYC Country Code
    </th>

    <th>
      IP Country Code
    </th>

    <th>
      `quoteCountryCode`
    </th>

    <th>
      Quote Accuracy
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      When the KYC and IP Country are same (see Scenario 1 above)
    </td>

    <td>
      US
    </td>

    <td>
      US
    </td>

    <td>
      `US`
    </td>

    <td>
      ✅
    </td>
  </tr>

  <tr>
    <td>
      When the KYC and IP Country are not same (see Scenario 1 above)
    </td>

    <td>
      US
    </td>

    <td>
      UK
    </td>

    <td>
      `US`
    </td>

    <td>
      ✅
    </td>
  </tr>

  <tr>
    <td>
      When KYC Country is unknown (see Scenario 2 above)

      <br />

      <br />

      **Note:**

       This might not produce the best result considering that KYC country is unknown and the user location might be different than the actual KYC Country.
    </td>

    <td>
      N/A
    </td>

    <td>
      UK
    </td>

    <td>
      `UK`
    </td>

    <td>
      🟩
    </td>
  </tr>
</tbody>