Simulate a payment
Changed onDrive a sandbox payment to a terminal status immediately, whatever its amount and payment method. Sandbox only: a production API key is rejected with 403 FORBIDDEN, and a production payment id is not visible to a sandbox key, so it returns 404. REFUNDED marks the payment paid if it is not already and then issues a full refund, which follows the sandbox refund matrix: a payment whose amount ends in .02 fails with 400 PSP_REFUND_FAILED; DISPUTED marks it paid if it is not already and then moves it to CHARGEBACK, which is a chargeback and not a MED.
Request
- Base URLhttps://api.yuvexpay.com
- AuthHTTP bearer
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Path parameters
The sandbox payment ID to simulate.
Headers
Optional for this endpoint. Honoured when sent — replay and payload check apply — but omitting it is not rejected.
Request body
Response
The payment after the simulated transition.
Example response
{
"payment": {
"coupon": {
"code": "BLACK10"
}
}
}Changes
- warning
added the new
FREEenum value to the/response property for the response status - info
added the optional property
/to the response with the status - info
added the optional property
/to the response with the status - info
added the optional property
/to the response with the status - info
added the optional property
/to the response with the status - info
added the optional property
/to the response with the status - info
added the optional property
/to the response with the status
- warning
- info
added the optional property
//to the response with the status - info
added the optional property
//to the response with the status - info
added the optional property
/to the response with the status
- info