API reference · Types
SandboxTestPurchase
Part of the response of POST /sandbox/test-purchases and GET /sandbox/test-purchases/{ref}.
Type: object
Example
{
"test_purchase_ref": "tpr_3f2c0b9d8e7a6f5c4b3a29180f7e6d5c",
"checkout_id": "chk_4e1f7a2b9c3d",
"status": "processing",
"order_ids": [],
"failure": null
}Fields
test_purchase_refstring requiredStable for the Idempotency-Key that started the purchase.
Example
tpr_3f2c0b9d8e7a6f5c4b3a29180f7e6d5ccheckout_idstring requiredThe checkout the sandbox buyer paid through.
Example
chk_4e1f7a2b9c3dstatusstring requiredprocessinguntil the payment is captured and the order exists, thensucceeded.failedwhen the payment did not complete.Constraints: allowed values:
processing,succeeded,failedExampleprocessingorder_idsarray of string requiredThe orders the purchase created, as
order_idvalues. Empty untilsucceeded.Field example
[]failureobject or null requiredWhy the purchase failed, or null.
Show child fieldsHide child fields
failure.string requiredcode The stable machine-readable code for this result.
Constraints: allowed values:
TEST_PAYMENT_FAILED,TEST_PURCHASE_NOT_AVAILABLEfailure.string requiredmessage A human-readable explanation of the result.