Idempotent Transaction Requests
To mark an idempotent request, provide an additional HTTP header
request-keyin supported APIs. PayEngine saves the response of the first request regardless of its failure or success; subsequent requests with the same
request-keywill produce the same response. This is very useful if a request times out and client needs to retrieve the response of the previous request.
request-keyis a unique value generated by client and we recommend to use UUIDs or any unique key with enough entropy to avoid collision. PayEngine system will clean up the keys after 24 hours.
Subsequent calls of this request will always yield the same results as the firtst call until the
request-keyexpires (24 hours)
curl --location --request POST 'https://<PayEngine Host>/api/payment/sale' \
--header 'Authorization: Basic <Your Private Key>' \
--header 'Content-Type: application/json' \
--header 'request-key : <Unique Reqeust Key>' \
"merchant_id": "<Your Merchant ID>",
"cardToken": "<Your Card Token>",