Click Airtime

Topup Status

Retrieve the current status and details of a specific topup transaction.

Topup Status

Get the current status and full details of a specific topup transaction by its ID.

GET /v2/topups/:id

Permission required: airtime.transactions.read

Path Parameters

ParameterTypeRequiredDescription
idstringYesThe topup transaction ID (UUID)

Example Request

curl -X GET "https://api.clickairtime.com/v2/topups/a1b2c3d4-e5f6-7890-abcd-ef1234567890" \
  -H "Authorization: Bearer ce_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
const topupId = 'a1b2c3d4-e5f6-7890-abcd-ef1234567890';
const response = await fetch(`https://api.clickairtime.com/v2/topups/${topupId}`, {
  headers: {
    'Authorization': 'Bearer ce_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
  },
});
const data = await response.json();
import requests

topup_id = 'a1b2c3d4-e5f6-7890-abcd-ef1234567890'
response = requests.get(
    f'https://api.clickairtime.com/v2/topups/{topup_id}',
    headers={
        'Authorization': 'Bearer ce_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
    }
)
data = response.json()

Example Response

{
  "success": true,
  "data": {
    "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "status": "completed",
    "phone_number": "+233541112259",
    "network": {
      "id": 42,
      "name": "MTN Ghana",
      "country": "Ghana",
      "country_code": "GH"
    },
    "amount": {
      "value": 50,
      "currency": "GHS"
    },
    "cost": {
      "value": 4.05,
      "currency": "USD"
    },
    "product_id": null,
    "product_name": null,
    "sms": {
      "enabled": true,
      "message": "Airtime top-up from Acme Corp"
    },
    "reference": "invoice-12345",
    "provider_reference": "DT-123456789",
    "failure_reason": null,
    "metadata": {
      "customer_id": "cust_001"
    },
    "created_at": "2024-01-15T10:30:00.000Z",
    "completed_at": "2024-01-15T10:30:02.500Z"
  },
  "meta": {
    "request_id": "req_x1y2z3a4b5c6",
    "timestamp": "2024-01-15T10:31:00.000Z"
  }
}

Response Fields

FieldTypeDescription
idstringUnique transaction ID (UUID)
statusstringCurrent status: pending, processing, completed, failed
phone_numberstringRecipient phone number
networkobjectNetwork operator details
amountobject | nullLocal currency amount delivered
costobjectUSD cost charged to your wallet
product_idstring | nullBundle product ID (if applicable)
product_namestring | nullBundle product name (if applicable)
smsobjectSMS notification settings
referencestringYour reference for this transaction
provider_referencestring | nullProvider's transaction reference
failure_reasonstring | nullReason for failure (if status is failed)
metadataobjectCustom metadata you attached
created_atstringISO 8601 creation timestamp
completed_atstring | nullISO 8601 completion timestamp