Accept the pre-payment agreement and enable the payment gateway
Submits the user's agreement acceptance and calls the payment gateway's enable_payment method. On success, the payment gateway is enabled and the flow advances to ConfirmationPaymentSelectedPage.
Required Fields:
agreement: Must betrue. Submittingfalsereturns a validation error.
State Updates:
On success:
agreement_signed = true,agreement_required = false,agreement_idandis_agreement_expiredare cleared frompre_order.data.On gateway failure:
agreement_signed = false
Backward Navigation:
When navigating backward,
agreement_signedis removed frompre_order.data.
Next Pages:
ConfirmationPaymentSelectedPage
Required header for AJAX requests. Must be set to XMLHttpRequest for all checkout requests.
XMLHttpRequestPossible values: Session cookie header (e.g. sessionid=abc123 or osessionid=<session_id>)
Must be true to accept the pre-payment terms and conditions and trigger
the gateway's enable_payment call. Submitting false returns a
validation error.
trueAgreement accepted or error
POST /orders/checkout/?page=ConfirmationPaymentAgreementConfirmPage HTTP/1.1
Host: sandbox.akinon.com
x-requested-with: XMLHttpRequest
Content-Type: application/x-www-form-urlencoded
Accept: */*
Content-Length: 18
"agreement=true"Agreement accepted or error
{
"context_list": [
{
"page_name": "ConfirmationPaymentSelectedPage",
"page_slug": "confirmationpaymentselectedpage",
"page_context": {}
}
],
"pre_order": {
"user_email": "user@akinon.com"
},
"errors": {},
"template_name": "orders/checkout.html"
}Last updated
Was this helpful?

