Click Airtime

Authentication

Authenticate with the Click Airtime V1 API using header-based email and token credentials.

Version 1 API (v1.4) — This API is in maintenance mode. New integrations should use the Version 2 API which provides API key authentication.

Overview

The V1 API uses header-based authentication. Every request must include two custom headers containing your account email and API token.

Required Headers

HeaderDescription
X-Click-Airtime-EmailThe email address associated with your Click Airtime account
X-Click-Airtime-TokenYour API token, e.g. C8000000-000G-4474-0001-J0000 (found in your account dashboard under Settings > API Keys)

Getting Your Credentials

  1. Log in to your Click Airtime dashboard at my.clickairtime.com
  2. Navigate to Settings > API Keys
  3. Copy your API Token
  4. Use the email address you registered with as the email header value

Keep your token secret. Never expose your API token in client-side code, public repositories, or browser requests. Always make API calls from your server.

Code Examples

curl -X GET https://api.clickairtime.com/adp/balances \
  -H "X-Click-Airtime-Email: your@email.com" \
  -H "X-Click-Airtime-Token: your-api-token"
const headers = {
  'X-Click-Airtime-Email': 'your@email.com',
  'X-Click-Airtime-Token': 'your-api-token',
};

const response = await fetch('https://api.clickairtime.com/adp/balances', {
  headers,
});

const data = await response.json();
console.log(data);
import requests

headers = {
    'X-Click-Airtime-Email': 'your@email.com',
    'X-Click-Airtime-Token': 'your-api-token',
}

response = requests.get(
    'https://api.clickairtime.com/adp/balances',
    headers=headers,
)

print(response.json())

Authentication Errors

If your credentials are missing or invalid, the API returns a 401 Unauthorized response:

{
  "message": "Invalid or missing authentication credentials",
  "statusCode": 401
}

Common Issues

ProblemSolution
401 UnauthorizedVerify your email and token are correct
Token not working after resetRegenerate the token in your dashboard and update your integration
Header names are case-sensitiveEnsure exact casing: X-Click-Airtime-Email and X-Click-Airtime-Token