Check the status of a payment transaction
PATH PARAMS
Parameter |
Data Type |
Description |
Required |
customer_code |
alphanumeric |
Business code assigned by Pokea Pay |
Y |
account_no |
alphanumeric |
Business code assigned by Pokea Pay |
Y |
order_reference |
string |
Order reference |
Y |
HEADER PARAMS
Parameter |
Data Type |
Description |
Required |
Authorization |
alphanumeric |
bearer token used to access the API |
Y |
signature |
alphanumeric |
A SHA-256 signature to proof that this request is coming from the merchant. Build a String of concatenated values of the request fields with the following order: order_reference,customer_code,account. The resulting text is then signed with Private Key and Base64 encoded. |
Y |
200 Success Response Schema
Parameter |
Data Type |
Description |
code |
numeric |
Response code |
message |
string |
Response message. |
payment |
object |
Contains payment info. See below success and failed transaction response |
Example Request
curl --location --request GET 'https://here-prod-api-url.com/payment/status/{customer_code}/{account_no}/order_reference' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header 'signature: mW6WDUM8cJA0hXvAWa3AmWOFruosfvNY\
--header 'Authorization: Bearer aJehRkDcOlFLMQaBRfboBMT_gpvcLxHVz_8zEg6N76U' \
--data-raw ''
Example Successful Payment Transaction Response
{
"code": 0,
"success": true,
"message": "SUCCESS",
"payment": {
"channel": "549319",
"reference": "40513984",
"transaction_id": "W9MDA15L96",
"currency": "KES",
"amount": "12722",
"fees": "572.49",
"result_code": 0,
"result_description": "The service request is processed successfully.",
"firstname": "GEORGE",
"middlename": "",
"surname": "ODHIAMBO"
}
}
Example Failed Payment Transaction Response
{
"code": 0,
"success": true,
"message": "SUCCESS",
"payment": {
"channel": "549319",
"reference": "40513862",
"result_code": 1032,
"result_description": "DS timeout user cannot be reached"
}
}