Solidgate

Create a Klarna Customer Token (Solidgate orchestrated)

Save a customer's Klarna payment method by creating a Klarna Customer Token through Solidgate's subscription routine — Solidgate requests the token from Klarna via its Authorize call — so you can charge it later for subscriptions or returning-customer purchases.
This guide explains how to save a customer's Klarna payment method — creating a Klarna Customer Token — where Solidgate orchestrates the request. You do not call Klarna's tokenization APIs yourself. Token creation uses Solidgate's existing subscription routine: you initialize a subscription by including the customer_account_id parameter (the merchant-defined customer identifier), and Solidgate requests the Klarna Customer Token from Klarna through its Authorize call on your behalf. After creation, Solidgate shares the token(s) back to you for future charges.
For the full mechanics of Solidgate's subscription routine — including how customer_account_id initializes a subscription, trial options, and the subscription lifecycle — see Solidgate's Subscription overview.
Use Solidgate's subscription routine. Because Solidgate orchestrates the Klarna authorization, it also handles the Klarna Customer Token request. To create a subscription, include customer_account_id — a required parameter for subscription initialization. There is nothing Klarna-specific for you to send.
Prefer to request the token yourself? If you present Klarna and orchestrate charges yourself (Web SDK or Presentation API, Partner orchestrated), you can create the token by adding request_customer_token to Klarna's Create Payment Request. See Create a Klarna Customer Token (Partner orchestrated). To compare all tokenized flows, see the Tokenized payments overview.

Prerequisites

Before you integrate, check that you meet the following prerequisites:
  1. 1.
    Ensure that you have Klarna enabled with Solidgate.
  2. 2.
    Decide which scope the token needs (see Configure the customer token scope):
    • 2.1.
      payment:customer_present — for returning-customer, customer-initiated one-click charges.
    • 2.2.
      payment:customer_not_present — for subscriptions and on-demand charges that run without the customer.
  3. 3.
    Use a tokenization-capable Solidgate surface — Payment Form, Payment Page, or Host-to-host (server-side). Payment Link does not support tokenization.
  4. 4.
    Add Terms and Conditions covering tokenization / saved payment methods.

Integration overview

  1. 1.
    The customer consents to save Klarna at your checkout.
  2. 2.
    You initialize a subscription with Solidgate, including customer_account_id.
  3. 3.
    Solidgate requests the Klarna Customer Token from Klarna through its Authorize call.
  4. 4.
    Solidgate shares the credential(s) back to you — the Klarna Customer Token and the Solidgate token.
  5. 5.
    You store the credential(s) against the customer for future charges.
sequenceDiagram autonumber participant C as Customer participant P as Partner participant AP as Solidgate participant K as Klarna P->>AP: Create payment session Note over P,AP: request Solidgate token alt If customer authentication is required AP-->>P: Return payment_request_url P->>P: Launch Klarna purchase journey C->>K: Complete Klarna purchase journey end AP-->>P: Order completed notification Note over P,AP: Solidgate token<br/>klarna_network_customer_token P->>P: Store Solidgate token and<br/>klarna_network_customer_token P-->>C: Display confirmation message

Integration details

Surfaces that support tokenization

You can create a token through any Solidgate integration surface that supports tokenization. In every case it is the same routine: initialize a subscription and include customer_account_id.
Solidgate integration surfaceWhat it isTokenizationReference
Payment FormSolidgate's customizable form, embedded directly in your checkout page.SupportedPayment Form
Payment PageSolidgate-hosted payment page the customer is redirected to.SupportedPayment Page
Host-to-host (server-side)Your backend calls Solidgate's Init payment API directly, passing customer_account_id.SupportedInit payment API
Payment LinkNo-code shareable payment URL.Not supportedPayment Link
Building your own Klarna checkout? If you present Klarna with the Klarna Web SDK or the Klarna Presentation API (Solidgate orchestrated), token creation rides on the same Solidgate Init payment API behind the scenes — just include customer_account_id when you create the payment session with Solidgate. Present Klarna exactly as in the build-the-checkout guide:

Configure the customer token scope

The token scope defines what the token can be used for later. Solidgate's subscription routine sets the scope for you based on how you initialize the subscription.
ScopeEnablesUse it for
payment:customer_presentTokenization where subsequent charges may go through immediately or require a step-up depending on risk.Returning-customer, customer-initiated one-click charges at checkout.
payment:customer_not_presentTokenization for charges that run without the customer present.Partner-initiated charges — subscriptions and on-demand.

Receive the token

Once the customer consents and the flow completes, Solidgate shares two credentials back to you:
CredentialUse it to
Klarna Customer TokenAuthorize the Partner-initiated charge flows (you call Klarna yourself). Always required to present the customer's saved Klarna option, regardless of who authorizes.
Solidgate tokenAuthorize the charge when Solidgate initiates it. Solidgate maps it back to the Klarna Customer Token.
Solidgate will support returning the Klarna Network customer token in a future release.

Charge the token later

Store the credential(s) against the customer. To charge the token later, continue to the tokenized payments overview and pick the charge flow that matches your scenario.
For token lifetime, scopes, and management (revoking or reading a token), see the Customer Token resource. Token management operations are out of scope for this guide.
Related articles
Create a Klarna Customer Token (Partner orchestrated)
Tokenized payments overview
1. General
Build checkout form with Klarna WebSDK (Solidgate orchestrated)
Build checkout form with Klarna Presentation API (Solidgate orchestrated)