Rates & estimates

Show live exchange rates and the exact amount a recipient will get before you send.

Both endpoints require the payment.view scope.

Mid-market rates

GET /rates returns indicative mid-market rates against a base currency. Use them for display; the rate a payout actually gets comes from an estimate.

Prop

Type

curl "https://business-api.migrapay.com/v1/api/rates?base=CAD" \
  -H "Authorization: Bearer $MIGRAPAY_API_KEY"
200 OK
{
  "status": "success",
  "message": "Exchange rates retrieved successfully.",
  "data": {
    "base": "CAD",
    "rates": { "CAD": 1, "USD": 0.731402, "NGN": 1096.512344, "GHS": 8.946021 },
    "previous": { "CAD": 1, "USD": 0.729861, "NGN": 1093.208713, "GHS": 8.951180 },
    "refreshedAt": "2026-08-12T16:00:00.000Z"
  }
}

rates maps each currency to the amount of it one unit of base buys (up to 6 decimals). previous holds the prior snapshot so you can show movement. Errors: 400 UNSUPPORTED_BASE_CURRENCY, 503 RATES_UNAVAILABLE.

Estimate a payout

GET /payouts/estimate prices a payout with MigraPay's rate and fees, either from the amount you send or from the amount the recipient should get.

Prop

Type

curl "https://business-api.migrapay.com/v1/api/payouts/estimate?from=CAD&to=NGN&amount=250" \
  -H "Authorization: Bearer $MIGRAPAY_API_KEY"
200 OK
{
  "status": "success",
  "message": "Estimate computed successfully.",
  "data": {
    "fromCurrency": "CAD",
    "fromAmount": 250,
    "toCurrency": "NGN",
    "toAmount": 271050,
    "fees": 0,
    "amountWithFee": 250,
    "commission": 0,
    "commissionPercentage": 0,
    "payoutRate": 1084.2,
    "payinRate": 0.000909,
    "formattedRate": "CAD 1.00 = NGN 1,084.20",
    "isToCurrencyHigherInValue": false,
    "reversedEstimate": null,
    "action": "youSend"
  }
}
FieldDescription
fromAmount, toAmountWhat leaves your wallet and what the recipient gets, in major units.
feesFixed fee for this corridor, in the source currency.
amountWithFeeTotal debited from your wallet.
payoutRateDestination units per one source unit, after MigraPay’s margin.
formattedRateRate ready for display.
isToCurrencyHigherInValuetrue when the destination currency is worth more per unit (for example NGN → CAD). The display rate then reads the other way round, and reversedEstimate carries the inverse quote.

Holding a quote

Each estimate is held for 60 seconds. A payout for the same currencies and the same source amount (fromAmount) created within that minute delivers the quoted toAmount, as long as the rate has not moved. With receiverGets, send the returned fromAmount as the payout amount.

Errors: 400 VALIDATION_ERROR, 400 INVALID_AMOUNT, 503 RATES_UNAVAILABLE, 503 RATE_UNAVAILABLE (data.currency names the currency without a rate).