OuiPay
API ReferenceExchange

Exchange

The exchange resource : currency conversion with quoted rates.

Exchange converts between currencies. A conversion starts with a quote (a locked rate for a short window), then executes as an atomic two-legged transaction.

The quote object

{
  "id": "01M2S17...",
  "from_currency": "NGN",
  "to_currency": "USD",
  "from_amount_minor": 100000,
  "to_amount_minor": 65400,
  "rate": "1.53000000",
  "expires_at": "2026-09-18T02:05:00Z"
}

The exchange transaction

{
  "id": "01M2S18...",
  "type": "exchange",
  "status": "completed",
  "from_amount_minor": 100000,
  "from_currency": "NGN",
  "to_amount_minor": 65400,
  "to_currency": "USD",
  "quote_id": "01M2S17...",
  "created_at": "2026-09-18T02:04:30Z"
}

Rate semantics

Every quote states:

  • rate: the applied rate, with explicit precision
  • from_currency / to_currency: direction is never implicit
  • expires_at: how long the rate is honored
  • the fee, if any, applied to the destination leg

OuiPay never silently converts: a currency mismatch is a validation error, not an implicit conversion.

Endpoints

MethodPathDescription
POST/v1/exchange/quotesCreate a quote
POST/v1/exchangeExecute exchange

On this page