Skip to main content
Version: 1.0.0

Create a payment session

POST /checkout/v1/sessions

Once your customer has entered your checkout. You should create the payment session towards briqpay. The response will include the snippet needed to render our checkout iframe. If your customer is already logged into your systems you are able to provide Briqpay with billing and shipping details at this point.

Request Body

Mandatory method to create a payment session

  • currency Currency required
  • locale Locale required
  • country Country required
  • amount integer required

    The total amount of the order including VAT

  • cart object[] required
  • Array [
  • producttype ProductType

    Possible values: [physical, digital, discount, shipping_fee, sales_tax, deposit, surcharge]

    The type of items being sold. When using 'discount', the unitPrice should be negative.

  • reference ProductReference

    The SKU of the item

  • name string
  • quantity integer
  • quantityunit string
  • unitprice integer

    Unit price excluding VAT in minor units

  • taxrate TaxRate

    The applicable taxrate in minor units. Eg 25% = 2500

  • discount integer

    Discount value in percentages. 10% = 1000

  • ]
  • merchanturls object required
  • terms string required

    Link to your terms that the client approves at the point of purchase

  • notifications string required

    Endpoint for Briqpay to notify you of a successful purchase - ensure to handle different values in session.state

  • redirecturl string required

    Where should the customer be redirected after the purchase has been completed?

  • merchantconfig object required
  • maxamount boolean

    Should the max amount rules be applied to this purchase?

  • creditscoring boolean required

    Should the creditscoring rules be applied to this purchase?

  • productid string

    The product ID identifier to use for this purchase, only use if you have multiple setups with Briqpay

  • order_note object

    Control data of the order_note section of the checkout

  • customInputs object[]

    Avaliable custom inputs fields that should be collected in the order_note section of the checkout

  • Array [
  • key string

    The input key, must be unique between all custominputs

  • label string

    The label to be presented in relation to the input

  • minLength number
  • maxLength number
  • required boolean

    Default value: false

  • span number

    Control if the input field should span over 1 or 2 columns

  • ]
  • payment object

    Specific configurations regarding the payment module.

  • pspRulesOverride object

    Allows you to override the result of the Briqpay rule engine for a specific purchase

  • psp object[]
  • Array [
  • pspId string

    the pspId of the payment method that you wish to manually control.

  • handles object
  • enabled boolean

    Default value: true

    should this payment method be enabled in the checkout?

  • otherHandles string

    Possible values: [run_rules, disable]

    Default value: run_rules

    How should the other handles that are configured on this purchase act?

  • ]
  • otherPsps string

    Possible values: [run_rules, disable]

    Default value: run_rules

    How should the rule-engine act for remaining PSPs that you have not defined an override for?

  • billing object

    Specific configurations regarding the billing module inside of the checkout

  • lockFields object

    How should Briqpay lock the users addresses? Hard_lock means no user edits are possible. Soft_Lock means that incorrect data will be allowed to be corrected

  • companyname LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • firstname LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • lastname LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • streetaddress LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • streetaddress2 LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • zip LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • city LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • cellno LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • email LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • shipping object

    Specific configurations regarding the shipping module inside of the checkout

  • lockFields object

    How should Briqpay lock the users addresses? Hard_lock means no user edits are possible. Soft_Lock means that incorrect data will be allowed to be corrected

  • companyname LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • firstname LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • lastname LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • streetaddress LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • streetaddress2 LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • zip LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • city LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • cellno LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • email LockType

    Possible values: [soft_lock, hard_lock, none]

    Default value: none

  • upsell object

    Configure which inputs will be collected in the Upsell module.

  • customInputs object[]

    Inputs that will be collected in the Upsell module.

  • Array [
  • key string

    The input key, must be unique between all custominputs

  • label string

    The label to be presented in relation to the input

  • minLength number
  • maxLength number
  • required boolean

    Default value: false

  • span number

    Control if the input field should span over 1 or 2 columns

  • ]
  • hideModule boolean
  • header string

    Possible values: <= 64 characters

    Module header text.

  • subheader string

    Possible values: <= 512 characters

    Module sub-header text.

  • footer string

    Possible values: <= 512 characters

    Module footer text.

  • terms object

    Set/override which checkboxes exists in the Terms Module.

  • checkboxes object[]

    Checkboxes that will be collected in the Terms module.

  • Array [
  • key string

    The input key, must be unique between all inputs.

  • label string

    The label to be presented in relation to the input. Can be formatted with urls as following: "Yes, I want to subscribe to the [Newsletter](https://example.com)"

  • required boolean nullable

    Default value: false

    If true, the checkbox must be checked before the customer can complete the flow.

  • default boolean nullable

    Default value: false

    If true, the checkbox will be pre-checked in the flow.

  • ]
  • reference object
  • reference1 string
  • reference2 string
  • orgnr string
  • billingaddress Address
  • companyname string
  • firstname string
  • lastname string
  • streetaddress string
  • streetaddress2 string
  • zip string
  • city string
  • region string

    State / region. Example: "CA" for California in the US.

  • cellno string
  • email string
  • shippingaddress Address
  • companyname string
  • firstname string
  • lastname string
  • streetaddress string
  • streetaddress2 string
  • zip string
  • city string
  • region string

    State / region. Example: "CA" for California in the US.

  • cellno string
  • email string
  • merchantBilling object

    Control data of the billing module inside of the checkout

  • addresses MerchantPrefillAddress[]

    A list of pre-approved addresses that you wish your customers should be able to select as billing address for this specific purchase

  • Array [
  • companyname string
  • streetaddress string
  • streetaddress2 string
  • zip string
  • city string
  • region string

    State / region. Example: "CA" for California in the US.

  • country string
  • firstname string
  • lastname string
  • cellno string
  • ]
  • merchantShipping object

    Control data of the shipping module inside of the checkout

  • addresses MerchantPrefillAddress[]

    A list of pre-approved addresses that you wish your customers should be able to select as shipping address for this specific purchase

  • Array [
  • companyname string
  • streetaddress string
  • streetaddress2 string
  • zip string
  • city string
  • region string

    State / region. Example: "CA" for California in the US.

  • country string
  • firstname string
  • lastname string
  • cellno string
  • ]
Responses

Successfully created a payment session

Schema
  • currency Currency
  • locale Locale
  • country Country
  • orgnr string
  • billingaddress Address
  • companyname string
  • firstname string
  • lastname string
  • streetaddress string
  • streetaddress2 string
  • zip string
  • city string
  • region string

    State / region. Example: "CA" for California in the US.

  • cellno string
  • email string
  • shippingaddress Address
  • companyname string
  • firstname string
  • lastname string
  • streetaddress string
  • streetaddress2 string
  • zip string
  • city string
  • region string

    State / region. Example: "CA" for California in the US.

  • cellno string
  • email string
  • reference object
  • reference1 string
  • reference2 string
  • cart object[]
  • Array [
  • producttype ProductType

    Possible values: [physical, digital, discount, shipping_fee, sales_tax, deposit, surcharge]

    The type of items being sold. When using 'discount', the unitPrice should be negative.

  • reference ProductReference

    The SKU of the item

  • name string
  • quantity integer
  • quantityunit string
  • unitprice integer

    Unit price excluding VAT in minor units

  • taxrate TaxRate

    The applicable taxrate in minor units. Eg 25% = 2500

  • discount integer

    Discount value in percentages. 10% = 1000

  • ]
  • merchanturls object
  • terms string required

    Link to your terms that the client approves at the point of purchase

  • notifications string required

    Endpoint for Briqpay to notify you of a successful purchase - ensure to handle different values in session.state

  • redirecturl string required

    Where should the customer be redirected after the purchase has been completed?

  • amount integer

    The total amount of the order including VAT

  • snippet string
  • tags object

    Additional data regarding the purchase

  • prepaid_invoice boolean
  • manual_review boolean
  • sessionid GUID

    The unique identifier for this specific session

  • state SessionState

    Possible values: [sessioncreated, purchasecomplete, paymentprocessing, purchaserejected, clientread, tokencreated]

  • createddate date-time
  • ordernote object

    Record of optional order notes that the user has inputed - Default behaviour includes a 'note' key/value

  • property name* string
  • termsCheckboxes object

    Contains data for the checkboxes of the terms module.

  • property name* object
  • value boolean
  • header string
  • purchasepaymentmethod object

    Additional data regarding the purchase

  • reservationid string
  • sessionid string
  • pspid string
  • pspname string

    The internal PSPName used

  • name string

    The customer-facing PSPname

  • autocapture boolean

    Was this order alread captured?

  • invoicemarkdown string

    Additional data added to the invoice markdown field

  • reference string

    Additional reference added to the invoice

  • email string

    Customer added an specific email to receive the invoice

  • pspSupportedOrderOperations object

    Possible order management operations that he underlying PSP supports.

  • updateOrderSupported boolean

    Default value: false

    Is this order possible to update?

  • captureOrderSupported boolean

    Default value: true

    Is this order possible to capture?

  • refundOrderSupported boolean

    Default value: true

    Is this order possible to refund?

  • extraCompanyFields object

    Record of custom parameters that Briqpay will share on completed sessions - Contact Briqpay for complete specifications

  • property name* string
  • rulesresult object[]

    Get detailed information on what rules triggered for this purchase

  • Array [
  • pspname string

    What PSP was triggered

  • rulesResult object[]

    All rules that failed for this method

  • Array [
  • outcome boolean
  • friendlyname string
  • ]
  • ]
  • token string

    The Bearer token to use for all subsequent calls on this session - This is only return on Session Create Calls

Loading...