Banks
Lookup table for NG bank codes. Returns the (code, name, slug, kind) tuples Swappr knows about, filtered to banks you can actually pay to.
code is the CBN 3-digit code — what you pass as recipient.bank_code in payouts and beneficiaries.
List banks
GET /v1/banks?currency=NGN
| Param | Required | Notes |
|---|---|---|
currency | yes | Must be NGN (only currency with a public bank list today) |
Response
{
"object": "list",
"data": [
{
"code": "044",
"name": "Access Bank",
"slug": "access-bank",
"kind": "dmb"
},
{
"code": "058",
"name": "Guaranty Trust Bank",
"slug": "gtbank",
"kind": "dmb"
},
...
]
}Bank kinds
| Kind | Description |
|---|---|
dmb | Deposit Money Bank — the major commercial banks |
mfb | Microfinance Bank |
mobile_money | Mobile money operator (e.g. OPay, PalmPay) |
psb | Payment Service Bank |
merchant_bank | Merchant bank |
fintech | Fintech / neobank |
Caching
This endpoint is heavily cached (5-minute TTL). The bank list rarely changes; safe to cache locally for hours.
// Fetch once at app start, cache in memory
let bankList: Bank[] | null = null;
let bankListExpiresAt = 0;
async function getBanks() {
if (bankList && Date.now() < bankListExpiresAt) return bankList;
const res = await fetch('https://api.swappr.me/v1/banks?currency=NGN', {
headers: { 'Authorization': `Bearer ${process.env.SWAPPR_API_KEY}` },
});
const data = await res.json();
bankList = data.data;
bankListExpiresAt = Date.now() + 60 * 60 * 1000; // 1h
return bankList;
}Notes
- Only banks marked
is_exposed_to_merchantsin our DB appear here. We curate the list — by default, ~80-90 of 906 NIBSS-registered banks are exposed. - Bank codes are CBN 3-digit codes, not NIBSS NIP codes. Some upstream rails want 6-digit NIP codes natively — Swappr handles that translation server-side; you always pass CBN codes.
slugis a stable lowercase identifier useful for icons + autocomplete.
Errors
| Code | HTTP | Cause |
|---|---|---|
unsupported_currency | 400 | Anything other than NGN |