API referenceF X

Lock a conversion rate

Price a conversion and hold it until `expires_at`. Quoting needs only read permission — being told a price commits nobody. Executing needs `fx:execute`, because that moves money. 503 rather than 500 when nothing will quote the pair: no registered provider would deal it, which is a condition that clears by itself and is worth retrying. E10-11's rule stands — we do not fall back to a rate nobody offered.

POST
/api/b/v1/fx/quotes

Price a conversion and hold it until expires_at.

Quoting needs only read permission — being told a price commits nobody. Executing needs fx:execute, because that moves money.

503 rather than 500 when nothing will quote the pair: no registered provider would deal it, which is a condition that clears by itself and is worth retrying. E10-11's rule stands — we do not fall back to a rate nobody offered.

Authorization

OAuth2PasswordBearer
AuthorizationBearer <token>

In: header

admin_access_token?string|null

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

A rate, locked for a short window. IN-302.

Quoting does not move money. It reserves a rate and returns buy_minor — the exact integer the ledger will post — so the amount you show a customer is the amount they get. Execute it before expires_at or it lapses.

Response Body

application/json

application/json

curl -X POST "https://example.com/api/b/v1/fx/quotes" \  -H "Content-Type: application/json" \  -d '{    "sell_currency": "USD",    "buy_currency": "RWF",    "sell_minor": 100000  }'
{  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",  "sell_currency": "string",  "buy_currency": "string",  "sell_minor": 0,  "buy_minor": 0,  "margin_minor": 0,  "margin_bps": 0,  "provider_rate": "string",  "customer_rate": "string",  "provider": "string",  "status": "string",  "expires_at": "2019-08-24T14:15:22Z",  "transaction_id": "0fec1e58-b197-4052-99cf-2218496c5482",  "created_at": "2019-08-24T14:15:22Z"}