VTU API
Get API keys
Electricity API

Prepaid and Postpaid Electricity Meter Payment API Integration

Use the test meter numbers below in the sandbox environment to simulate prepaid token generation, postpaid bill settlements, delayed webhooks, and timeout errors without using real funds.

The Paybeta Electricity Payment API enables you to vend electricity tokens for prepaid meters and settle bills for postpaid meters using a customer's meter number or account ID.

  • Prepaid Meters: A recharge token is generated upon a successful transaction for the customer to load directly onto their meter.

  • Postpaid Meters: Payments are credited directly toward the customer's electricity bill account.

Implementation Note: For prepaid transactions, ensure your application displays the generated token immediately on the confirmation screen and delivers a copy to the customer via SMS and email.

Meter number Validation (/v2/electricity/validate) Purchase (/v2/electricity/purchase)
1111111111111 + prepaid successful successful, with token and units
1010101010101 + postpaid successful successful, no token (postpaid is a bill payment)
201000000000 successful pending, settles to successful after 2 minutes with a webhook
500000000000 HTTP 200, status: unknown HTTP 200, status: unknown, settles later
400000000000 HTTP 504, empty body HTTP 504, empty body, settles later
300000000000 answers late, 504 answers late, pending, settles later
any other number 422 "Invalid meter number" failed, test wallet refunded