GET /forex/current(Free plan): all current NGN rates in one call
How the rates work
Each rate is how many naira one unit of the foreign currency buys, andinverse_rate is the reverse. For example:
- USD → NGN:
amount_usd × rate - NGN → USD:
amount_ngn ÷ rate(oramount_ngn × inverse_rate)
Step 1: Fetch all rates
One call returns every supported currency pair.Sample response (trimmed)
Step 2: Conversion logic
React component (bidirectional)
Typing in either input updates the other in real time.React
Vanilla JavaScript (with a rate table)
Display all rates alongside the converter:JavaScript
Tips
Cache rates for the session. Forex rates update daily, so one fetch per page load is sufficient. No need to poll on an interval like equity prices. Always show the rate date. The response includes adate (and a last_updated per currency). Display it near your rates so users know how fresh the data is.
Cross-pair conversion routes through NGN. All rates are naira per unit, so to convert USD → GBP you multiply by the USD rate to get naira, then divide by the GBP rate. The convert() function above handles this automatically.
Forex current reference
Full response spec for
GET /forex/currentForex history reference
Historical NGN rates with date range filtering