Skip to main content
Two lightweight read endpoints for building live agent dashboards. Poll /stats to show a real-time snapshot of the wallet’s balance and remaining spend allowance, and /transactions when you need a compact recent-activity feed alongside it.

Endpoints

Authentication

Both endpoints require a valid Session JWT in the Authorization header.

GET /v1/wallets/:id/stats

Path Parameters

string
required
The UUID of the wallet to summarise.

Response 200 OK

The response is a flat object containing the wallet’s current balance, configured spend limits, and how much has been spent in the current rolling period.
integer
Current available balance in kobo. This is the live spendable balance after all approved debits and top-ups have been applied.
integer
Per-transaction spend cap, in kobo. Included for convenience so dashboards can display the limit without a separate wallet-fetch call.
integer
Rolling-period cumulative spend cap, in kobo.
integer
Total amount spent within the current rolling periodWindowDays window, in kobo. Compare against spendLimitPeriod to render a spend-budget progress bar.
integer
Remaining spend capacity for the current rolling period, in kobo. Calculated as spendLimitPeriod − spentThisPeriod. Use this value to determine how much the agent can still spend before hitting its period cap.

Example Response


GET /v1/wallets/:id/transactions

A trimmed-down version of the full transactions endpoint, optimised for dashboard widgets. Returns only the most recent N transactions — no deep pagination required.

Path Parameters

string
required
The UUID of the wallet.

Query Parameters

integer
default:"20"
Maximum number of recent transactions to return. Capped at 100.

Response 200 OK

Returns an array of recent transaction records, sorted newest-first.
object[]
Array of the most recent transaction records.

Example Response

Best endpoint for a live dashboard. Poll GET /v1/wallets/:id/stats every 1–2 seconds to keep the balance and remaining allowance up to date without over-fetching. Pair it with a single call to /transactions?limit=5 on page load for the recent-activity feed, then refresh it on a slower interval (every 10–30 seconds) — transaction lists change less frequently than the balance.

Error Responses

Both endpoints return the same error shapes: