For the complete documentation index, see llms.txt. This page is also available as Markdown.

Select Installment Option for Masterpass REST

Sets the selected installment option for the Masterpass REST flow.

Required Fields:

  • installment: Primary key (pk) of the Installment record to apply. The PK must reference an active installment linked to the card resolved in MasterpassRestBinNumberPage.

Validation:

  • installment must be the PK of an active Installment belonging to the card in pre_order.card_info. Submitting a PK outside of that set returns a validation error.

State Update:

  • pre_order.installment is set to the resolved Installment.

  • pre_order.selected_campaign and pre_order.selected_rewards are reset to null (inherited from InstallmentSelectionPage).

  • pre_order.payment_choice is reset to null.

Backward Navigation:

  • On backward navigation, pre_order.installment is reset to null.

Next Pages:

  • MasterpassRestOrderNoPage

available_for_post_order: true

post
Header parameters
x-requested-withstring · enumRequired

Required header for AJAX requests. Must be set to XMLHttpRequest for all checkout requests.

Default: XMLHttpRequestPossible values:
CookiestringOptional

Session cookie header (e.g. sessionid=abc123 or osessionid=<session_id>)

Body
installmentintegerRequired

Primary key (pk) of the Installment record to select. The PK must reference an active installment linked to the card resolved in MasterpassRestBinNumberPage.

Example: 2
Responses
200

Installment selected successfully

application/json
errorsone of · nullableOptional
or
string[]Optional
template_namestringOptional
post/orders/checkout/?page=MasterpassRestInstallmentPage
POST /orders/checkout/?page=MasterpassRestInstallmentPage HTTP/1.1
Host: sandbox.akinon.com
x-requested-with: XMLHttpRequest
Content-Type: application/x-www-form-urlencoded
Accept: */*
Content-Length: 17

"installment=1"
200

Installment selected successfully

{
  "context_list": [
    {
      "page_name": "MasterpassRestOrderNoPage",
      "page_slug": "masterpassrestordernopage",
      "page_context": {}
    }
  ],
  "pre_order": {
    "payment_option": {
      "pk": 7,
      "slug": "masterpass-rest",
      "payment_type": "masterpass_rest"
    },
    "installment": {
      "pk": 2,
      "installment_count": 3,
      "label": "3 Installments",
      "price_with_accrued_interest": "165.59",
      "monthly_price_with_accrued_interest": "55.20"
    },
    "total_amount": "165.59",
    "total_amount_with_interest": "165.59",
    "currency_type_label": "TRY"
  },
  "errors": {},
  "template_name": "orders/checkout.html"
}

Last updated

Was this helpful?