Cancel Checkout
POST https://sandbox-checkout.payjustnow.io/v2/cancel
The OpenAPI specification for this checkout operation can be found here.
note
You can only cancel a checkout that is in PENDING_ORDER or CANCELLED_BY_CONSUMER status.
Here is an example of a successful PayJustNow checkout cancel request and response:
POST /v2/cancel HTTP/1.1X-Signature: XNZvbX+Ju47iFo/LG8hqyFIugG67Y5Dm7pAYv2mfwVM=X-Merchant-Account-ID: 1Content-Type: application/jsonUser-Agent: PostmanRuntime/7.31.1Accept: */*Postman-Token: 707e2143-4790-47c4-8d14-5c6460b453dbHost: sandbox-checkout.payjustnow.ioAccept-Encoding: gzip, deflate, brConnection: keep-aliveContent-Length: 70 { "checkoutToken": "v2.1.8b07dd97-8975-47c1-8ebc-54c93049cf2c"} HTTP/1.1 200 OKDate: Fri, 17 Mar 2023 09:45:13 GMTContent-Type: application/jsonContent-Length: 921Connection: keep-alivex-amzn-RequestId: 326f8234-1f70-4af1-8112-5eaaa0d81c94x-amz-apigw-id: B616kHryDoEFtmA=X-Amzn-Trace-Id: Root=1-641436a9-2ac34dbc71cfd8dd356259c4 { "requestId": "1dfa984b-717b-46d9-9be7-7069cf7ab283", "checkoutToken": "v2.1.8b07dd97-8975-47c1-8ebc-54c93049cf2c", "checkoutTotalCents": 240000, "paymentUrl": "https://sandbox.payjustnow.com/api/v2/app/checkout/v2.1.8b07dd97-8975-47c1-8ebc-54c93049cf2c", "checkoutPaymentStatus": "CANCELLED_BY_MERCHANT", "merchantOrderReference": "A26615830", "createdAt": "2023-03-16T11:33:28.033Z", "updatedAt": "2023-03-17T09:45:04.793Z", "cancelledAt": "2023-03-17T09:45:04.793Z", "payjustnow": { "merchantOrderReference": "A26615830", "confirmRedirectUrl": "https://storefront.com/order/3dje30", "cancelRedirectUrl": "https://storefront.com/order/3dje30", "orderAmountCents": 360000, "orderItems": [ { "quantity": 3, "searchTerms": [ "ugg", "boots", "purple" ], "imageUrl": "https://merchantstore.com/uggboots/purp6.jpeg", "name": "UGG Boots Purple Size 6", "priceCents": 120000, "pageUrl": "https://merchantstore.com/uggboots", "sku": "UGG-BB-PUR-06" } ] }, "merchantAccountId": "1"}