Check Payment Status
GET
Terminal window
Returns the current status of a transaction. Use this as a fallback or reconciliation check alongside the result callback — see Checking Payment Status for when to use each.
| Environment | URL |
|---|---|
| Production | https://api.pesepay.com/api/payments-engine/v1/payments/check-payment |
| Sandbox | https://api.test.sandbox.pesepay.com/payments-engine/v1/payments/check-payment |
Headers
Section titled “Headers”| Parameter | Type | Required | Description |
|---|---|---|---|
authorization | string | Yes | Your application’s integration key |
content-type | string | Yes | Must be application/json |
Query parameters
Section titled “Query parameters”| Parameter | Type | Description |
|---|---|---|
referenceNumber | string | The reference number of the transaction to check |
Code examples
Section titled “Code examples”curl -G https://api.test.sandbox.pesepay.com/payments-engine/v1/payments/check-payment \ -H "authorization: YOUR_INTEGRATION_KEY" \ -H "content-type: application/json" \ --data-urlencode "referenceNumber=YOUR_REFERENCE_NUMBER"const url = new URL( 'https://api.test.sandbox.pesepay.com/payments-engine/v1/payments/check-payment');url.searchParams.set('referenceNumber', referenceNumber);
const response = await fetch(url, { headers: { authorization: 'YOUR_INTEGRATION_KEY', 'content-type': 'application/json', },});
const { payload } = await response.json();const transaction = decrypt(payload, ENCRYPTION_KEY);console.log(transaction.transactionStatus);import requests
response = requests.get( "https://api.test.sandbox.pesepay.com/payments-engine/v1/payments/check-payment", params={"referenceNumber": reference_number}, headers={ "authorization": "YOUR_INTEGRATION_KEY", "content-type": "application/json", },)
transaction = decrypt(response.json()["payload"], ENCRYPTION_KEY)print(transaction["transactionStatus"])<?php$url = 'https://api.test.sandbox.pesepay.com/payments-engine/v1/payments/check-payment' . '?referenceNumber=' . urlencode($referenceNumber);
$ch = curl_init($url);curl_setopt($ch, CURLOPT_HTTPHEADER, [ 'authorization: YOUR_INTEGRATION_KEY', 'content-type: application/json',]);curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = json_decode(curl_exec($ch), true);curl_close($ch);
$transaction = decrypt($response['payload'], $encryptionKey);echo $transaction['transactionStatus'];HttpClient client = HttpClient.newHttpClient();HttpRequest request = HttpRequest.newBuilder() .uri(URI.create( "https://api.test.sandbox.pesepay.com/payments-engine/v1/payments/check-payment?referenceNumber=" + URLEncoder.encode(referenceNumber, StandardCharsets.UTF_8) )) .header("authorization", "YOUR_INTEGRATION_KEY") .header("content-type", "application/json") .GET() .build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());String transactionJson = decrypt(extractPayload(response.body()), encryptionKey);Response
Section titled “Response”The response body is { "payload": "..." }. Decrypt the payload with your
encryption key to get the transaction result — the same object the
result callback delivers and
Make Payment returns. Its complete field list, including
the amountDetails breakdown, is on the
result callback page.
The fields you check most often:
| Field | Type | Description |
|---|---|---|
referenceNumber | string | The transaction’s reference — match it to your order |
transactionStatus | string | Where the payment stands — see Transaction Statuses |
transactionStatusCode | number | Numeric equivalent of transactionStatus |
transactionStatusDescription | string | Human-readable status message |
amountDetails | object | Amounts and fees applied to the transaction |
This is not the full Transaction entity —
it is the smaller result view. There is no redirectUrl on it.