Validate a meter number before making an electricity payment.

Meter Validation

Validate a meter number to confirm the customer name and meter details before processing an electricity bill payment.

Endpoint

GET https://example.com/api/validate_meter

Request Headers

{
  "Accept": "application/json",
  "Authorization": "Bearer YOUR_API_TOKEN"
}

Query Parameters

ParameterTypeRequiredDescription
meter_numberstringYesThe meter number to validate
disco_namestringYesDistributor name (e.g., "ikeja-electric")
meter_typestringYesMeter type: "prepaid" or "postpaid"

Example Request

curl -X GET "https://example.com/api/validate_meter?meter_number=1111111111111&disco_name=ikeja-electric&meter_type=prepaid" \
  -H "Accept: application/json" \
  -H "Authorization: Bearer YOUR_API_TOKEN"

Response

Success (200)

{
  "status": "success",
  "name": "John Doe",
  "address": "123 Main Street, Lagos",
  "meter_type": "prepaid"
}

Error (422)

When the meter number is invalid or cannot be verified:

{
  "message": "The given data was invalid.",
  "errors": {
    "status": ["Something Went Wrong! Try again Letter"]
  }
}

Response Fields

FieldTypeDescription
statusstring"success" if validated
namestringCustomer name registered on the meter
addressstringCustomer address
meter_typestringConfirmed meter type

Best Practices

  • Always validate the meter number before calling the Electricity Bill Payment endpoint
  • Display the returned name to the user for confirmation before proceeding with payment