Skip to main content
After Payzah redirects your customer back to your success_url or error_url, you should verify the transaction’s outcome server-side before fulfilling an order or showing a confirmation screen. This endpoint lets you query a payment’s current status by supplying the trackid you generated during initialization and the PaymentID that Payzah returned in the initialization response. Never rely solely on the redirect URL parameters to confirm payment — always confirm with this endpoint. Endpoint: POST /ws/paymentgateway/get-payment-details Refer to the API Overview for the base URLs and required authentication headers before making this request.

Request Parameters

trackid
string
required
The unique Track ID you submitted in the original payment initialization request. Alphanumeric, maximum 255 characters.
payment_id
string
required
The Payzah Payment ID returned as PaymentID in the initialization response. Maximum 255 characters.

Sample Request

cURL
curl --request POST \
  --url https://development.payzah.net/ws/paymentgateway/get-payment-details \
  --header 'Content-Type: application/json' \
  --header "Authorization: $(echo -n 'your_private_key_here' | base64)" \
  --data '{
    "trackid": "1000",
    "payment_id": "2023020818520981564303"
  }'
Request Body
{
  "trackid": "1000",
  "payment_id": "2023020818520981564303"
}

Response Fields

Success Response

status
boolean
true when a matching payment record was found.
data
object
Contains the full details of the located payment.

Error Response

status
boolean
false when no matching record was found or an error occurred.
message
string
A human-readable description of the error.
code
number
A numeric error code. See the Response Codes reference for the full list.

Sample Responses

Success
{
  "status": true,
  "data": {
    "payzahRefrenceCode": "2023020818520981564303",
    "trackId": "1000",
    "UDF1": "",
    "UDF2": "",
    "UDF3": "",
    "UDF4": "",
    "UDF5": "",
    "knetPaymentId": "100202303935749373",
    "paymentId": "100202303935749373",
    "transactionNumber": "202303935759799",
    "trackingNumber": "12992052519157",
    "paymentDate": "2023-02-08 18 52 09",
    "paymentStatus": "NOT CAPTURED"
  }
}
Error
{
  "status": false,
  "message": "No Record found for the provided details",
  "code": 10012
}

Payment Status Values

The paymentStatus field in the success response will contain one of the following values:
StatusDescription
CAPTUREDThe payment was successfully authorized and captured. Funds are secured and will be settled to your account.
NOT CAPTUREDThe payment was authorized but capture has not yet occurred. You may need to initiate capture separately depending on your account configuration.
VOIDEDThe payment was voided or cancelled after authorization. No funds were captured.
CANCELEDThe customer cancelled the payment before completion.
DENIED BY RISKThe payment was blocked by Payzah’s risk management system. No funds were collected.
HOST TIMEOUTThe payment host did not respond in time. The transaction outcome is uncertain — contact Payzah support or check your bank portal to confirm the result before retrying.