Skip to main content

Payout statuses

Payout statuses

When a payout is being performed, it changes its statuses depending on different events occurring during its processing.

You can learn the status of your payout:

  • by using the Amanpay Dashboard which is available at https://merchant.amanpay.io. Contact the Amanpay support team or your account manager to get access there
  • by checking responses and callbacks the payment platform sends to your system
  • by sending Amanpay a request to retrieve the payout status. To learn how to create such a request, see the Request a payout status section below

The following table contains the information about payout statuses occurring when performing payouts in Amanpay and the actions that you may need to perform upon these statuses.

StatusDescriptionFinalRequired action
PENDINGThe payout is being processedNoNo action required
SUCCESSThe payout is completed successfullyYesNo action required
FAILEDThe payout is declinedYesCorrect your request details, retry, or contact Amanpay support team

Request a payout status

You can check the status of a payout by sending the Amanpay payment platform a request as follows:

URLhttps://gateway.amanpay.io
API endpoint/payments/payouts/status
HTTP request methodPOST
Request body formatJSON
HeaderValueDescription
Content-Typeapplication/jsonHTTP header indicating the media type of the resource sent in the request body.
AuthorizationcalculatedSignature string. For the information on how to generate the signature, see Signature generation and verification.


Parameters of the request to retrieve a payout status:

The following table contains the parameters that have to be used in requests to retrieve a payout status.

ParameterTypeRequiredDescription
merchantIdintegerRequiredYour unique merchant ID that you got from Amanpay when integrating.
paymentIdstringRequiredPayment ID unique within your system.

Here is an example of a request to retrieve a payout status.

curl -X POST "https://gateway.amanpay.io/payments/payouts/status" \
-H "Content-Type: application/json" \
-H "Authorization: 58394ddf08b6851a30e1063758d20610c35282b4751c1c1beacbcd7e991e120135826ad877fb9fff64eb4b6402f4fc274ce7f5f1f03b93b028758ecde631e102" \
-d '{
"merchantId": 1758378,
"paymentId": "payment_812"
}'


Upon receiving your request, Amanpay sends a response to your system. The response contains the current status of your payout.

The following are examples of the data from responses to requests to retrieve the status of payout.

{
"transactionId": "62861",
"paymentID": "payment_812",
"status": "SUCCESS",
"amount": 250.51,
"currency": "BDT",
"paymentType": "payout"
}
{
"transactionId": "62861",
"paymentID": "payment_812",
"status": "FAILED",
"errorCode": "GENERAL_ERROR",
"errorMessage": "An unexpected error occurred while processing your request",
"amount": 250.51,
"currency": "BDT",
"paymentType": "payout"
}