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

Submit address data received from the checkout provider's hosted form

Accepts address data sent by the checkout provider's hosted page (via callback or iframe postback) and saves it as the shipping and billing addresses on the pre-order. The address fields use the provider's format and are mapped to internal address structures.

Required Fields: basket_id, session_token, shipping_address, billing_address

State Updates:

  • pre_order.shipping_address set from shipping_address payload

  • pre_order.billing_address set from billing_address payload

Backward Navigation:

  • Clears billing_address and shipping_address from the pre-order.

Next Page: CheckoutProviderShippingOptionPage

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

Address data posted back from the checkout provider's hosted address form. Both shipping and billing addresses must be provided in the provider's format.

basket_idintegerRequired

Primary key of the active basket.

Example: 42
session_tokenstring · uuidRequired

Session token issued by the checkout provider for this session.

Example: 550e8400-e29b-41d4-a716-446655440000
Responses
200

Address data saved

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

"basket_id=42&session_token='550e8400-e29b-41d4-a716-446655440000'&shipping_address={'name':'John','surname':'Doe','phone_number':'+905551234567','address_title':'Home','line':'123 Main Street','hash_data':'abc123hash','country':{'name':'Turkey','code':'TR'},'city':{'name':'Istanbul','code':'34'},'town':{'name':'Besiktas','code':'34022'},'district':{'name':'Levent','code':'340220001'}}&billing_address={'name':'John','surname':'Doe','phone_number':'+905551234567','address_title':'Home','line':'123 Main Street','hash_data':'def456hash','country':{'name':'Turkey','code':'TR'},'city':{'name':'Istanbul','code':'34'},'town':{'name':'Besiktas','code':'34022'},'district':{'name':'Levent','code':'340220001'}}"
200

Address data saved

{
  "context_list": [
    {
      "page_name": "CheckoutProviderShippingOptionPage",
      "page_slug": "checkoutprovidershippingoptionpage",
      "page_context": {
        "shipping_options": [
          {
            "name": "Standard Shipping",
            "slug": "standard-shipping",
            "logo_url": "https://cdn.example.com/shipping-logo.png",
            "shipping_amount": "9.90",
            "description": "Delivery in 3-5 days",
            "key": 1
          }
        ]
      }
    }
  ],
  "pre_order": {
    "user_email": "user@akinon.com"
  },
  "errors": {},
  "template_name": "orders/checkout.html"
}

Last updated

Was this helpful?