Account

Get account

GEThttps://stagingapi.getelectric.ng/api/v2/reseller/me

Who this key belongs to and what it may do. Call it once at start-up to confirm a key works and to read the mode it is in: the key string itself does not say whether it is live or test, and this is the only endpoint that tells you.

Shares the budget your orders do not reserve. Works with a live or test key.

Request
curl 'https://stagingapi.getelectric.ng/api/v2/reseller/me' \
  -H 'Authorization: Bearer <your-test-key>'
Response
{
  "success": true,
  "status": "success",
  "code": 200,
  "message": "OK",
  "data": {
    "reseller_id": 7,
    "business_name": "Alpha Power Ltd",
    "label": "Alpha Power",
    "kyb_status": "APPROVED",
    "enabled": true,
    "mode": "test",
    "allowed_ips": [],
    "calling_from": "102.89.44.10",
    "webhook_configured": true,
    "max_concurrent_requests": 5,
    "abilities": [
      "reseller:test"
    ],
    "sandbox_balance": 498300,
    "address_allowlist_enforced": false
  }
}

Authorization

Authorizationstringheaderrequired

Your reseller API key, as Bearer <key>.

Response 200

The account behind the key.

successbooleanrequired
statusstringrequired

One of success, failed

codeintegerrequired

The HTTP status, repeated in the body. It is not an error code: this API has none, so the message text is the only thing distinguishing one refusal from another, and message text is not a stable contract.

messagestringrequired
dataobjectrequired
Show child attributes
reseller_idintegerrequired
business_namestringnullablerequired
labelstringnullablerequired
kyb_statusstringnullablerequired

APPROVED is the only value a live key can hold.

enabledbooleanrequired
modestringrequired

Which mode this key is in. The only place it is stated.

One of live, test

allowed_ipsarray of stringrequired

Addresses and CIDR ranges a live key may call from. Empty means anywhere. Not enforced for a test key.

calling_fromstringrequired

The address we saw this call arrive from, so you can tell what to allowlist.

webhook_configuredbooleanrequired

True once both a URL and a signing secret are set for this mode.

max_concurrent_requestsintegerrequired

Your in-flight cap as recorded on your account. 0 means none was set and the default applies: 20 live, 5 test.

abilitiesarray of stringrequired
sandbox_balancenumber

Test mode only. Play money, in naira.

address_allowlist_enforcedboolean

Test mode only, and always false: a test key may call from anywhere.

Other responses

401
No key, a malformed Authorization header, or a key that no longer exists.
403
The key is real but may not do this. Three separate causes, and only the message tells them apart: the token cannot use the reseller API at all, the calling address is not on your allowlist, or the key carries both test and live access and must be reissued for one mode.
429
You have too many requests open at once. This is a concurrency cap, not a rate limit: wait for your open requests to finish rather than backing off a fixed time. Retry-After is 1.
503
Our side could not serve this. Safe to retry.