Skip to main content
GET
/
v1
/
payment
/
{reference}
/
status
curl --request GET \
  --url https://api.staging.kairosafrika.cloud/paygw/v1/payment/20416369453214532143/status \
  --header 'Authorization: Basic $(echo -n "username:password" | base64)'
{
  "statusCode": "0000",
  "statusMessage": "Successful",
  "transactionId": "20416369453214532143",
  "data": {
    "reference": "20416369453214532143",
    "status": "COMPLETED",
    "amount": 45,
    "charge": 0.68,
    "totalAmount": 45.68,
    "payee": "Kairos",
    "payer": "testOne",
    "narration": "PIZZAMAN/CHICKMAN",
    "msisdn": "233559400612",
    "completedAt": "2024-07-17T14:30:00Z"
  },
  "links": [
    {
      "rel": "payment",
      "href": "/v1/payment"
    }
  ]
}

Get Transaction Status

This endpoint allows you to check the current status of a payment transaction using its reference identifier. Endpoint: GET /v1/payment/{reference}/status
curl --request GET \
  --url https://api.staging.kairosafrika.cloud/paygw/v1/payment/20416369453214532143/status \
  --header 'Authorization: Basic $(echo -n "username:password" | base64)'

Path Parameter

  • reference (string, required): The reference identifier of the payment transaction to check.
    • Example: 20416369453214532143

Responses

200 OK - Transaction Status Retrieved Successfully

{
    "statusCode": "0000",
    "statusMessage": "Successful",
    "transactionId": "20416369453214532143",
    "data": {
        "reference": "20416369453214532143",
        "status": "COMPLETED",
        "amount": 45,
        "charge": 0.68,
        "totalAmount": 45.68,
        "payee": "Kairos",
        "payer": "testOne",
        "narration": "PIZZAMAN/CHICKMAN",
        "msisdn": "233559400612",
        "completedAt": "2024-07-17T14:30:00Z"
    },
    "links": [
        {
            "rel": "payment",
            "href": "/v1/payment"
        }
    ]
}

404 Not Found - Transaction Not Found

{
    "statusCode": "0404",
    "statusMessage": "Transaction not found",
    "transactionId": null,
    "data": null,
    "links": []
}

401 Unauthorized - Invalid Credentials

{
    "statusCode": "0401",
    "statusMessage": "Unauthorized",
    "transactionId": null,
    "data": null,
    "links": []
}

Response Fields

  • statusCode (string): Status code indicating the result of the request
    • "0000": Successful
    • "0404": Transaction not found
    • "0401": Unauthorized
  • statusMessage (string): Human-readable status message
  • transactionId (string): Unique transaction identifier for tracking
  • data (object): Transaction details when successful
    • reference (string): Reference identifier for the payment
    • status (string): Current transaction status - PENDING, COMPLETED, FAILED, CANCELLED
    • amount (number): Base payment amount
    • charge (number): Processing charge amount
    • totalAmount (number): Total amount including charges
    • payee (string): Name of the payee receiving the payment
    • payer (string): Name or identifier of the payer
    • narration (string): Payment description or narration
    • msisdn (string): Mobile subscriber identifier
    • completedAt (string): ISO 8601 timestamp when transaction was completed (null if not completed)
  • links (array): HATEOAS links for related actions

Transaction Status Values

  • PENDING: Transaction is being processed
  • COMPLETED: Transaction has been successfully completed
  • FAILED: Transaction failed to process
  • CANCELLED: Transaction was cancelled

Usage Example

Use this endpoint to check the current status of a payment transaction. This is particularly useful for:
  • Polling transaction status after initiating a payment
  • Verifying payment completion before fulfilling orders
  • Troubleshooting failed transactions

Authorizations

Authorization
string
header
required

Basic authentication using base64 encoded username:password

Path Parameters

reference
string
required

The reference identifier of the payment transaction

Response

Transaction status retrieved successfully

statusCode
string

Status code indicating the result of the request

Example:

"0000"

statusMessage
string

Human-readable status message

Example:

"Successful"

transactionId
string

Unique transaction identifier for tracking

Example:

"20416369453214532143"

data
object

Transaction details when successful

HATEOAS links for related actions