Skip to content
POST

Create an HPP session

https://api.kustom.co/hpp/v1/sessions

Use this API to create an HPP session after creating a payment session. Read more on Create a new HPP session.

Parameters1 field
  • User-Agentstringoptionalin header

    User-Agent

Request body20 fields

sessionRequest

  • merchant_urlsobjectoptional
    6 fields in merchant_urls
    • backstringoptional

      Back URL

    • cancelstringoptional

      Cancel URL

    • errorstringoptional

      System error URL

    • failurestringoptional

      Failure URL

    • status_updatestringoptional

      Status update URL

    • successstringoptional

      Success URL

  • optionsobjectoptional
    10 fields in options
    • background_images[]array<object>optional

      List of Images to use for the background. Best matching resolution will be used.

      2 fields in background_images
      • urlstringoptional

        Url for the image

      • widthinteger · int64optional

        Width of the image

    • logo_urlstringoptional

      URL of the logo to be displayed

    • page_titlestringoptional

      Title for the Payment Page

    • payment_method_categories[]array<string>optional

      Payment Method Categories to show on the Payment Page. All available categories will be given to the customer if none is specified using payment_method_category or payment_method_categories. Ignored field for KCO Orders.

    • payment_method_categorystringoptional

      Payment Method Category to show on the Payment Page. All available categories will be given to the customer if none is specified using payment_method_category or payment_method_categories. Ignored field for KCO Orders.

      • DIRECT_DEBIT
      • DIRECT_BANK_TRANSFER
      • PAY_NOW
      • PAY_LATER
      • PAY_OVER_TIME
      • KLARNA
    • place_order_modestringoptional
      • PLACE_ORDER
      • CAPTURE_ORDER
      • NONE
    • purchase_typestringoptional

      The type of this purchase

      • BUY
      • RENT
      • BOOK
      • SUBSCRIBE
      • DOWNLOAD
      • ORDER
      • CONTINUE
    • show_subtotal_detailstringoptional
      • HIDE
  • payment_session_urlstringrequired

    URL of the KP Session or KCO Order to be hosted by the HPP Session

  • profile_idstringoptional

    Profile id for default session options

201
Response11 fields

Successfully created HPP session

  • distribution_moduleobjectoptional
    3 fields in distribution_module
    • generation_urlstringoptional
    • standalone_urlstringoptional
    • tokenstringoptional
  • distribution_urlstringoptional

    Endpoint for link distribution

  • expires_atstring · date-timeoptional

    Session expiration time

  • manual_identification_check_urlstringoptional

    Endpoint for manual identification check

  • qr_code_urlstringoptional

    HPP url to download qr code image

  • redirect_urlstringoptional

    HPP url to redirect the consumer to. ECOMMERCE only

  • session_idstringoptional

    HPP session id

  • session_urlstringoptional

    Endpoint to get the session

400
Response0 fields

We were unable to create a session with the provided data. Some field constraint was violated.

No response body — this status returns headers only.

401
Response0 fields

Unauthorized

No response body — this status returns headers only.

403
Response0 fields

You were not authorized to execute this operation.

No response body — this status returns headers only.

404
Response0 fields

Payment session has expired.

No response body — this status returns headers only.

This page is also available as Markdown — append .md to its URL — and is indexed in llms.txt.