Overview
Exchange Rates Overview
The Exchange Rates API lets you fetch real-time exchange rate quotes between supported Basqet currencies. Use it when you need to preview how much one currency is worth in another currency before showing pricing, checkout estimates, funding instructions, or internal treasury calculations.
The Exchange Rates API only returns a rate quote. It does not move funds or create a wallet conversion. Use the Wallet Conversions API when you need to convert wallet balances.
How Exchange Rate Quotes Work
You send:
- The currency you are converting from.
- The currency you are converting to.
- The amount you want to quote.
Basqet returns:
- A
rate_id. - The exchange rate.
- The amount you supplied.
- The equivalent amount in the quote currency.
- The time the quote expires.
Exchange rate quotes are short-lived and should be treated as previews, not permanent pricing.
When To Use Exchange Rates
Use exchange rate quotes when you need to:
| Use Case | Description |
|---|---|
| Preview customer pricing | Show your customer an estimated equivalent amount before payment. |
| Estimate funding values | Show how much one currency may be worth in another currency. |
| Power internal dashboards | Display live conversion estimates for your operations team. |
| Compare currency values | Check a supported pair before deciding whether to convert funds. |
Exchange Rates vs Wallet Conversions
| Product | What It Does | When To Use It |
|---|---|---|
| Exchange Rates API | Returns a live rate quote and equivalent amount. | Use this when you only need a preview. |
| Wallet Conversions API | Moves funds from one Basqet wallet currency to another. | Use this when you want to update wallet balances. |
Supported Currency Behavior
The endpoint accepts currency slugs that exist on Basqet. Common supported slugs include:
| Currency | Description |
|---|---|
NGN | Nigerian Naira |
USD | United States Dollar |
GBP | British Pound |
EUR | Euro |
USDT | Tether |
BTC | Bitcoin |
ETH | Ethereum |
LTC | Litecoin |
QDX | Quidax Token |
USDC | USD Coin |
If base_currency and quote_currency are the same, Basqet returns a rate of 1 and the same amount as the quote amount.
Before You Start
Before requesting exchange rate quotes, make sure:
- You have a Basqet secret key in the form
sec_.... - You know the
base_currency,quote_currency, andamount. - Your system handles short quote expiry windows.
- Your system can retry with an
Idempotency-Keyif the request times out.
Recommended Integration Flow
- Ask your customer, dashboard, or internal system for the currency pair and amount.
- Create an exchange rate quote with
POST /v1/exchange-rates. - Display or store the returned
rate,base_amount,quote_amount, andexpires_at. - Refresh the quote by calling the api again when it expires or when the customer changes the amount.
- Use the Wallet Conversions API only if you need to move actual wallet balances.
Important Notes
- Successful responses are wrapped in a
statusanddataobject. - Use
quote_amount = base_amount * rateas the mental model for displayed conversions. - Exchange rate quotes are previews and should not be treated as guaranteed permanent rates.
- Public keys are not accepted. Always use your secret key.
Updated about 7 hours ago