Live and test modes

Which one you are in is decided by your key, and nothing else.

There is no mode parameter, no header and no separate hostname. You send a test key and you are in test mode; you send a live key and you are in live mode, on the same base URL.

What differs

LiveTest
Moneyyour real partner balancea play balance, granted at 500,000
Meters and targetsany real onesix reserved numbers only
Providersreal vendorsnothing is contacted
Tokensreal, from the discomade up, prefixed TEST-
KYBmust be approvednot checked
Address allowlistenforced when setnot enforced
Webhooksyour live URL and secretyour test URL and secret
Orders you can readlive orderssandbox orders
Default concurrency20 in flight5 in flight

The two sets of orders never mix. A test key cannot read a live order and a live key cannot read a sandbox one, even by reference.

Telling which one you hold

The only way to knowbash
curl https://stagingapi.getelectric.ng/api/v2/reseller/me \
  -H 'Authorization: Bearer <your-api-key>'

data.mode is live or test. In test mode the response also carries sandbox_balance.

Tip

Read mode when your application starts and compare it with what that deployment is supposed to be using. A staging deployment that finds itself holding a live key should refuse to start, not discover the problem by selling something.

Staging is not the sandbox

This confuses people, so plainly:

  • Staging is one of our environments, at https://stagingapi.getelectric.ng/api/v2. It runs with live provider credentials.
  • Test mode is what your key grants, on any environment.

A live key on staging spends real money against a real meter. If you want a safe place to build, that is a test key, not a particular hostname.

Moving over

Nothing about your code changes between modes except the key and the webhook endpoint you point at us. That is deliberate: the shape of every request and response is the same, so the only thing left to get wrong when you go live is the credential. Going live is the checklist.