API Reference

Use this API if you need to query the status of a payment

Optionally used in Gateway Integration

Overview

This API is used when there is a use case to query the payment status in addition to the callback URLs that we redirect to in our payment gateway.

In order to use this API effectively, the original externalReference that was provided in the Pay1st Payment link should be used.

API Description

List of Statuses

StatusDescription
NEWTransaction created, but payment has not been processed.
PENDINGPayment is processing.
SUCCESSFULPayment has been completed successfully.
FAILEDPayment has failed.
CANCELLEDPayment has been cancelled by the customer.
ABANDONEDPayment was not completed, and session has expired.

HTTP Headers

HeaderDescription/Value
Content-Typeapplication/json
AuthorizationBasic <token>

Note: The basic auth credentials will need to be provided by the Pay1st representative before using this API.

URL Format

GET: /api/fulfilments/status?externalReference=<reference>

Success Response

Valid HTTP Status Codes

  • 200 - Success

HTTP Response Body

{
	"reference": "C-12345679887665-P",
  "externalReference": "EXT_REF",
	"playerId": "12345",
	"productBundleId": 1,
	"amount": 1000,
	"currency": "ZAR",
  "paymentMethod": "Kuda Bank",
	"tokensPurchased": 11,
	"digitalCurrency": {
		"name": "Credits",
		"code": "CRE"
	},
	"status": "SUCCESSFUL"
}

Failure Response

Valid

  • 400 - Bad Request
  • 404 - Not Found