Validate the Apple Pay merchant
Gets an Apple Pay merchant session for this checkout. Call it from the browser's onmerchantvalidation handler with the validation URL Apple gave, then pass data to event.complete(). Only apple_pay is supported. A closed cart is 422. Any token type may call it; a limited token only for a bound cart.
AuthorizationBearer <token>A secret, trusted or limited token. See Authentication.
cart_id*stringThe id of the cart.
payment_method_type*"apple_pay"The payment method type. Only apple_pay is supported; another valid type is 404, an unknown one 400.
"apple_pay"application/json- body
The validation URL Apple Pay gave the browser.
validation_url*stringevent.validationURL from the onmerchantvalidation handler. It must be an Apple host.
uriThe Apple Pay merchant session.
application/json- response
Apple Pay's merchant session for this checkout.
data*|The merchant session object from Apple, as Apple returned it. Pass it to event.complete() in the onmerchantvalidation handler.
curl -X POST 'https://api.comecero.com/api/v1/carts/string/user_agent_payment_request/apple_pay/merchant_validate' \ -H 'Content-Type: application/json' \ -d '{ "validation_url": "https://apple-pay-gateway.apple.com/paymentservices/startSession"}'{ "data": { "epochTimestamp": 1793990400000, "expiresAt": 1793994000000, "merchantSessionIdentifier": "SSH0000000000000000000000000000000000000000", "nonce": "0a1b2c3d", "merchantIdentifier": 0, "domainName": "shop.example.com", "displayName": "Example Shop", "signature": "308006092a864886f70d0107" }}Update a browser payment request POST
Sends a change from the Apple Pay sheet (a new shipping address or shipping option) to the cart. The cart's customer and shipping method change, tax and shipping are worked out again, and the new payment request comes back for `updateWith()`. Only `apple_pay` is supported. A closed cart is `422`. Any token type may call it; a limited token only for a bound cart.
Overview
Next Page