Get Loyalty Money Usage Page context
Returns the user's available loyalty money balance and a breakdown of account groups by label, enabling the user to specify how much loyalty money to apply toward the current order. This page runs as an independent step, meaning it does not reset or block other checkout steps and can be submitted at any point once the precondition is satisfied.
Preconditions:
The
LOYALTY_MONEY_ENABLEDdynamic setting must betrue
Skip Conditions:
None
Configuration:
LOYALTY_MONEY_ENABLED: Controls whether the loyalty money feature is active during checkout. Defaults tofalse. Whenfalse, this page is excluded from the checkout flow entirely.
Next Pages:
This is an independent step and does not determine the next checkout page. The checkout flow proceeds based on the current checkout state.
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>)
Loyalty Money Usage Page context retrieved
GET /orders/checkout/?page=LoyaltyMoneyUsagePage HTTP/1.1
Host: sandbox.akinon.com
x-requested-with: XMLHttpRequest
Accept: */*
Loyalty Money Usage Page context retrieved
{
"context_list": [
{
"page_name": "LoyaltyMoneyUsagePage",
"page_slug": "loyaltymoneyusagepage",
"page_context": {
"balance": "85.00",
"accounts": [
{
"label_id": 1,
"label": "Welcome Bonus",
"balance": "25.00",
"currency": "try"
},
{
"label_id": 2,
"label": "Birthday Bonus",
"balance": "20.00",
"currency": "try"
},
{
"label_id": null,
"label": null,
"balance": "40.00",
"currency": "try"
}
]
}
}
],
"pre_order": {
"user_email": "user@akinon.com",
"loyalty_amount_to_use": null
},
"errors": [],
"template_name": "orders/checkout.html"
}Last updated
Was this helpful?

