api.
one vouchmorph interface. the standards sit behind it as formats.
the description, openapi 3.1: openapi.yaml · openapi.json
/api/v1/accounts/balance.php
livewe call your test system. your path: get_balance (endpoints.source.get_balance)
the customer's balance, for the dashboard and for a batch's funds check. it is a POST with the identifier in the body, like every bank call. a wallet's pin, when the customer gave one, comes as pin and wallet_pin. answer success and balance (or available_balance), at the top or under data.
- signed
- your key; signed with mutual tls
- clock
- 30 s to answer
- repeats
- a read: safe to repeat
request
POST /api/v1/accounts/balance.php
host: test.yourbank.example
Content-Type: application/json
Accept: application/json
X-API-KEY: $BANK_KEY
{
"source_identifier": "77100001",
"account_number": "77100001",
"phone": "77100001",
"wallet_phone": "77100001",
"national_id": "77100001",
"email": "77100001",
"currency": "BWP"
}curl
# set BANK_KEY first: export BANK_KEY=...
curl -sS -X POST 'https://test.yourbank.example/api/v1/accounts/balance.php' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H "X-API-KEY: $BANK_KEY" \
--data-binary '{"source_identifier":"77100001","account_number":"77100001","phone":"77100001","wallet_phone":"77100001","national_id":"77100001","email":"77100001","currency":"BWP"}'answer
200 OK
{
"success": true,
"balance": 1200.0,
"available_balance": 950.0,
"currency": "BWP"
}other answers
4xx a refusal: the call failed, with your `message` shown to staff. say why in `message`
{ "success": false, "message": "Insufficient funds" }5xx a 5xx: failed. a 502 or 504, a timeout after the request left or a cut-short answer is an unknown outcome: never sent again, confirmed with you later
{ "success": false, "message": "Service unavailable" }
formats behind this interface
- jsonlive, every call
- iso 20022live, banks
- swift mtlive, banks
- iso 8583live, cards, atm
- fspiopoff, off until a partner needs it
you choose your format and how we sign in on your connection page. next: not in this build yet.
built to
- openapi 3.1, this file
- problem details · rfc 9457, settlement messages answer application/problem+json
- idempotency-key, a courier booking carries our reference as its Idempotency-Key
- mutual tls, offered for our calls to your test system
- oauth 2.0 client credentials · rfc 6749, offered for our calls to your test system