Configure
To configure Klarna, open the file Litium.Addons.Klarna.dll.config in your web\bin directory and follow the instructions at the beginning of the file. This article explains further details about configuration options.
You need to request a test account from Klarna from https://developers.klarna.com
From Klarna you would receive following:
Username - Consists of your Merchant ID (eid) - a unique number that identifies your e-store, combined with a random string. This is the "merchantId" in the config file.
Password - a string which is associated with your Merchant ID and is used to authorize use of Klarna's APIs. This is the "sharedSecret" in the config file.
Klarna design and branding
The Klarna logotypes need to be displayed on the public website according to the Klarna specifications. It is recommended to fetch the logos and other images from the Klarna CDN as described at https://developers.klarna.com/en/gb/kco-v3/logos.
Multimarket support
It is possible to have multiple Klarna accounts in the same Litium installation.
To add a new klarna account, in the Litium.AddOns.Klarna.dll.config file
- create a new paymentAccount section (copy paste an existing paymentAccount section)
- change paymentAccountIdentifier attribute. It should be unique and should not contain spaces.
The paymentAccountIdentifier is appended at the begining of each Klarna payment method, and is used by the API to identify the correct account.
Klarna Addon can be used in a headless ECommerce scenario (where an external CMS website is used instead of Litium CMS) when Klarna Hosted Payment Pages (Klarna HPP) is used. (Klarna Checkout is an iFrame and rendering it on a cross-site scenario is not tested)
To enable Klarna for headless, set the "headlessCheckout" attribute to true. The checkout process should then be done through web API calls, as implemented in the headless api Addon.