Last updated

Qliro Checkout Adapter

Overview Document: Payment Adapters Overview

Overview and Unique Capabilities

The Qliro Checkout Adapter integrates Qliro Checkout with Norce Checkout. Changes made in Norce Checkout are synced with Qliro Checkout and vice versa. This page focuses on the unique technical details and configuration for Qliro.

Supported payment methods and other features: Features Overview

Qliro Adapter Architecture

Configuration in Norce Admin

The adapter is configured using the following unique details obtained from Qliro:

FieldDescriptionExample Value
apiUrlQliro API URL (test or production).https://pago.qit.nu
merchantApiKeyYour Qliro merchant API key.abc123
merchantApiSecretYour Qliro merchant API secret.xyz789

Optional Configuration

FieldDescriptionExample Value
recurringEnable recurring payment tokens.true
useIntegratedShippingEnable integrated shipping in Qliro.true
useUpsellEnable upsell offers after checkout completion. Must also be enabled in your Qliro account.true
upsellTimeoutSecondsMaximum time window (seconds) for upsell offers. Default: 300.300
primaryColorHex color for primary UI elements.#FF5733
backgroundColorHex color for background.#FFFFFF
callToActionColorHex color for call-to-action buttons.#00AA00
callToActionHoverColorHex color for call-to-action buttons on hover.#008800
cornerRadiusCorner radius for UI elements (pixels).4
buttonCornerRadiusCorner radius for buttons (pixels).4
minimumCustomerAgeMinimum customer age requirement. When set, this also prevents the customer from authenticating as a company in Qliro. Leave unset or set to 0 to allow B2B/company checkout.18
requireIdentityVerificationRequire BankID for Swedish customers.true
merchantConstraintNameEnables dynamic filtering of payment channels.my-constraint

Reference Source Configuration

FieldDescriptionExample Value
merchantReferenceSourceSource for merchant reference: OrderId or OrderCartReference.OrderId
mapDiscountPerRowWhen true, discounts are embedded in item prices. When false, separate discount line items.false
useSkuAsIdentifierWhen true, uses SKU as item reference. When false, uses item ID.false
shippingReferenceSourceSource for shipping reference: ShippingId or CustomValue.ShippingId
customShippingReferenceCustom shipping reference value (when using CustomValue).shipping-ref
voucherReferenceSourceSource for voucher reference: VoucherId or CustomValue.VoucherId
customVoucherReferenceCustom voucher reference value (when using CustomValue).voucher-ref

Redirect URLs Configuration

FieldDescription
redirectUrls.checkoutUrlURL to redirect back to checkout page.
redirectUrls.confirmationUrlURL to redirect after successful payment.
redirectUrls.merchantTermsUrlURL to merchant terms and conditions.
redirectUrls.merchantIntegrityPolicyUrlURL to merchant privacy/integrity policy.
FieldDescription
consentOptions.emailNewsletterSubscriptionConsentIdConsent ID for email newsletter subscription.

Shipping Configuration

FieldDescription
shippingConfiguration.providerMerchantProvided, NShift, or Ingrid
shippingConfiguration.unifaunCheckoutIdnShift checkout ID (when using NShift)

Qliro API Environments

In addition to the generic Norce Adapter URLs (see Payment Adapters Overview), Qliro uses the following external API environments:

EnvironmentQliro API Base URL
Productionhttps://payments.qit.nu
Testhttps://pago.qit.nu

Create Payment

To get a Qliro Checkout HTML snippet, create a Qliro Checkout payment for an existing Norce order:

POST /api/checkout/v1/orders/{order_id}/payments
Host: {slug}.api-se.stage.norce.tech
x-merchant: {merchant}
x-channel: {channel}
Authorization: Bearer {token}

The response includes an HTML snippet containing a script tag that should be rendered on your checkout page. The script tag will load an iframe which guides the customer through the Qliro Checkout UI.

Example response:

{
  "paymentId": "pyTWfWFQDxIwodoImZHAfSsZvON",
  "htmlSnippet": "<script type=\"text/javascript\">...</script><div id=\"qliro-root\"></div>"
}

The adapter also updates your Norce order with the Qliro payment details. The payments[].id property represents the paymentId from the response, and payments[].reference contains the Qliro order ID.

Confirmation Page

When the payment has been confirmed, Qliro redirects the user to the confirmationUrl. You must also include the Qliro Checkout iframe on your confirmation page, as it shows important purchase details to the customer.

To display the confirmation page, retrieve the Qliro Checkout order and render the snippet:

GET /api/checkout/v1/orders/{order_id}/payments/{payment_id}
Host: {slug}.api-se.stage.norce.tech
x-merchant: {merchant}
x-channel: {channel}
Authorization: Bearer {token}

When the Qliro Checkout order is in the state of PurchaseCompleted, it will show a "thank you" page instead of the default purchase flow.

Creating a Recurring Payment

To create an order using a previously stored recurring token:

POST /api/checkout/v1/orders/{order_id}/payments/recurring
Host: {slug}.api-se.stage.norce.tech
x-merchant: {merchant}
x-channel: {channel}
Authorization: Bearer {token}
Content-Type: application/json

{
  "token": "3d2092a6-7baf-49e3-bd34-d0d0d85744b5"
}

The token is retrieved from a previous order where the customer completed a purchase with recurring payments enabled. To use recurring payments, merchants must activate this feature on both their Qliro merchant account (by contacting Qliro support) and in the Norce Qliro configuration by setting recurring: true.

Upsell

The upsell feature allows merchants to offer additional products to customers after they have completed their initial purchase. This is useful for subscription services, accessories, or related products.

To enable upsell:

  1. Enable useUpsell in the adapter configuration
  2. Ensure upsell is also enabled in your Qliro merchant account (contact Qliro support)
  3. Configure upsellTimeoutSeconds to set the maximum time window for upsell offers (default: 300 seconds)

When an order is in the Accepted state and upsell is enabled, you can add items to the order. The adapter will call Qliro's upsell API to add the items to the existing payment. Once the upsell period expires or you explicitly complete the upsell, call the complete endpoint:

POST /api/checkout/v1/callback/orders/{order_id}/payments/{payment_id}/upsell/complete
Host: {slug}.api-se.stage.norce.tech
x-merchant: {merchant}
x-channel: {channel}
Authorization: Bearer {token}

This endpoint requires no request body. A successful response returns 200 OK with no content.

Synchronization Callbacks

The Qliro Checkout Adapter automatically handles synchronization between Qliro and Norce:

  • Cart Changed: Qliro UI is suspended, order updated, then resumed
  • Customer Update: Norce order updated with customer info from Qliro
  • Shipping Option Update: Norce order updated with shipping selection

Idempotency and Retries

Qliro's checkout system uses idempotency to ensure that repeated identical requests have the same effect. This is important for retry scenarios and webhook handling. Please read the Qliro Checkout documentation on Idempotency and retries for detailed information.

Troubleshooting (Qliro Specific)

In addition to the generic troubleshooting steps:

  • Review the order status in Qliro's merchant portal.
  • If Capture fails, verify the Norce order is in the reserved state.
  • Use the refresh endpoint to update available payment actions:
POST /api/order/v1/orders/{order_id}/payments/{payment_id}/refresh
Host: {slug}.api-se.stage.norce.tech
x-merchant: {merchant}
x-channel: {channel}
Authorization: Bearer {token}

Common Errors

  • 409 Conflict: A payment already exists for this order.
  • Validation Fails: Check stock availability and discount validity.
  • Capture Fails: Order must be in reserved state.