Transaction Status

LIVE
Endpoint

Send a GET request with a reference code to check transaction status.

Production URL
https://pairgate.com/api/v1/transaction/status
Method GET
Test Endpoint
https://pairgate.com/api/v1/test/transaction/status?reference_code=TRXDATA20260615100238ONI
Authentication

This request requires a valid Bearer token.

Header Value Description
Authorization
Bearer {token}
Your unique API authorization token
Query Parameters

This parameter is required. Include it in the URL query string.

Parameter Type Required Description
reference_code string Yes The reference code returned when the purchase was made (e.g. TRXDATA20260615100238ONI)
Code Examples

Choose your preferred language below. Replace YOUR_API_KEY and the reference code with your actual values.

PHP (Laravel)
// Check Transaction Status
$reference = 'TRXDATA20260615100238ONI';

$response = Http::withHeaders([
    'Authorization' => 'Bearer YOUR_API_KEY',
    'Cache-Control' => 'no-cache',
])->get('https://pairgate.com/api/v1/transaction/status?reference_code=' . $reference);

$result = $response->json();

dd($result);
cURL
curl -X GET "https://pairgate.com/api/v1/transaction/status?reference_code=TRXDATA20260615100238ONI" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Cache-Control: no-cache"
Node.js
const axios = require('axios');

const checkTransactionStatus = async (referenceCode) => {
    try {
        const response = await axios.get(
            'https://pairgate.com/api/v1/transaction/status',
            {
                params: {
                    reference_code: referenceCode
                },
                headers: {
                    'Authorization': 'Bearer YOUR_API_KEY',
                    'Cache-Control': 'no-cache'
                }
            }
        );
        
        console.log(response.data);
    } catch (error) {
        console.error(error.response?.data || error.message);
    }
};

// Example
checkTransactionStatus('TRXDATA20260615100238ONI');
Python
import requests

url = "https://pairgate.com/api/v1/transaction/status"

headers = {
    "Authorization": "Bearer YOUR_API_KEY",
    "Cache-Control": "no-cache"
}

params = {
    "reference_code": "TRXDATA20260615100238ONI"
}

try:
    response = requests.get(url, headers=headers, params=params)
    response.raise_for_status()
    data = response.json()
    print(data)
except requests.exceptions.RequestException as e:
    print(f"Error: {e}")
Java
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.net.URI;
import java.net.URLEncoder;
import java.nio.charset.StandardCharsets;

HttpClient client = HttpClient.newHttpClient();

String url = "https://pairgate.com/api/v1/transaction/status"
    + "?reference_code=" + URLEncoder.encode("TRXDATA20260615100238ONI", StandardCharsets.UTF_8);

HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create(url))
    .header("Authorization", "Bearer YOUR_API_KEY")
    .header("Cache-Control", "no-cache")
    .GET()
    .build();

try {
    HttpResponse response = client.send(request, 
        HttpResponse.BodyHandlers.ofString());
    
    System.out.println(response.body());
} catch (Exception e) {
    System.err.println("Error: " + e.getMessage());
}
Response Format

A successful request returns a 200 status with full transaction details.

Success Response (200)
{
  "code": 200,
  "status": "success",
  "data": {
    "reference_code": "TRXDATA20260615100238ONI",
    "type": "data",
    "status": "successful",
    "amount": 500.00,
    "plan": "MTN 1GB Monthly",
    "recipient": "08031234567",
    "balance_before": 2000.00,
    "balance_after": 1500.00,
    "created_at": "2026-06-15T10:02:38+01:00"
  }
}
Response Fields
Field Type Description
reference_code string Your transaction reference
type string Purchase type (data, airtime, tv, electricity, bet, waec, neco, nabt)
status string Current state: processing, successful, failed, pending
amount float Amount charged
plan string Plan or item name (for data and tv purchases)
item string Item name (for airtime, electricity, bet, education purchases)
recipient string Phone number, smartcard, meter number, or customer ID
balance_before float Wallet balance before the transaction
balance_after float Wallet balance after the transaction
created_at string When the transaction was initiated
Transaction Statuses
Status Description
processing Purchase is being processed
successful Purchase completed successfully
failed Purchase failed and wallet has been refunded
pending Awaiting manual review
Error Responses

The following errors may occur when calling this endpoint.

Status Code Description
404 Transaction not found Reference code does not exist or belongs to another user
401 Missing API key No Bearer token provided
401 Invalid API key Token does not match any active key
403 Suspended API key or account has been suspended
429 Rate limited Too many requests