Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

medusa-payment-klarna

medusajs60MIT1.4.1

Klarna Payment provider for Medusa Commerce

medusa-plugin, medusa-plugin-payment

readme

Klarna

Receive payments on your Medusa commerce application using Klarna.

Klarna Plugin Documentation | Medusa Website | Medusa Repository

Features

  • Authorize payments on orders from any sales channel.
  • Capture payments from the admin dashboard.
  • Support for Webhooks.

Prerequisites


How to Install

1. Run the following command in the directory of the Medusa backend:

  npm install medusa-payment-klarna

2. Set the following environment variables in .env:

  KLARNA_BACKEND_URL=<YOUR_KLARNA_BACKEND_URL>
  KLARNA_URL=<YOUR_KLARNA_URL>
  KLARNA_USER=<YOUR_KLARNA_USER>
  KLARNA_PASSWORD=<YOUR_KLARNA_PASSWORD>
  KLARNA_TERMS_URL=<YOUR_KLARNA_TERMS_URL>
  KLARNA_CHECKOUT_URL=<YOUR_KLARNA_CHECKOUT_URL>
  KLARNA_CONFIRMATION_URL=<YOUR_KLARNA_CONFIRMATION_URL>
  KLARNA_LANGUAGE=<YOUR_KLARNA_LANGUAGE>

3. In medusa-config.js add the following at the end of the plugins array:

  const plugins = [
    // other plugins...
    {
      resolve: `medusa-payment-klarna`,
      options: {
        backend_url: process.env.KLARNA_BACKEND_URL,
        url: process.env.KLARNA_URL,
        user: process.env.KLARNA_USER,
        password: process.env.KLARNA_PASSWORD,
        language: process.env.KLARNA_LANGUAGE,
        merchant_urls: {
          terms: process.env.KLARNA_TERMS_URL,
          checkout: process.env.KLARNA_CHECKOUT_URL,
          confirmation: process.env.KLARNA_CONFIRMATION_URL,
        },
      },
    },
  ]

Test the Plugin

1. Run the following command in the directory of the Medusa backend to run the backend:

  npm run start

2. Enable Klarna in a region in the admin. You can refer to this User Guide to learn how to do that. Alternatively, you can use the Admin APIs.

3. Place an order using a storefront or the Store APIs. You should be able to use Stripe as a payment method.


Additional Resources

changelog

Change Log

1.4.1

Patch Changes

1.4.0

Minor Changes

1.3.10

Patch Changes

1.3.9

Patch Changes

1.3.9-rc.0

Patch Changes

1.3.8

Patch Changes

1.3.7

Patch Changes

1.3.6

Patch Changes

1.3.5

Patch Changes

1.3.4

Patch Changes

1.3.3

Patch Changes

1.3.2

Patch Changes

1.3.1

Patch Changes

All notable changes to this project will be documented in this file. See Conventional Commits for commit guidelines.

1.3.0 (2022-05-01)

Note: Version bump only for package medusa-payment-klarna

1.2.1 (2022-02-28)

Features

1.2.0 (2022-02-25)

Features

1.1.41 (2022-02-06)

Bug Fixes

1.1.40 (2022-02-06)

Features

1.1.39 (2022-01-11)

Note: Version bump only for package medusa-payment-klarna

1.1.38 (2021-12-29)

Note: Version bump only for package medusa-payment-klarna

1.1.37 (2021-12-17)

Bug Fixes

  • medusa-payment-klarna: Default shipping fee name in Klarna plugin (#926) (8782016)

1.1.36 (2021-12-08)

Note: Version bump only for package medusa-payment-klarna

1.1.35 (2021-11-23)

Note: Version bump only for package medusa-payment-klarna

1.1.34 (2021-11-22)

Note: Version bump only for package medusa-payment-klarna

1.1.33 (2021-11-19)

Note: Version bump only for package medusa-payment-klarna

1.1.32 (2021-11-19)

Note: Version bump only for package medusa-payment-klarna

1.1.31 (2021-10-18)

Note: Version bump only for package medusa-payment-klarna

1.1.30 (2021-10-18)

Note: Version bump only for package medusa-payment-klarna

1.1.29 (2021-10-18)

Note: Version bump only for package medusa-payment-klarna

1.1.28 (2021-10-18)

Note: Version bump only for package medusa-payment-klarna

1.1.27 (2021-09-15)

Note: Version bump only for package medusa-payment-klarna

1.1.26 (2021-09-14)

Note: Version bump only for package medusa-payment-klarna

1.1.25 (2021-08-05)

Note: Version bump only for package medusa-payment-klarna

1.1.24 (2021-07-26)

Note: Version bump only for package medusa-payment-klarna

1.1.23 (2021-07-15)

Note: Version bump only for package medusa-payment-klarna

1.1.22 (2021-07-15)

Note: Version bump only for package medusa-payment-klarna

1.1.21 (2021-07-02)

Note: Version bump only for package medusa-payment-klarna

1.1.20 (2021-06-22)

Bug Fixes

1.1.18 (2021-06-09)

Note: Version bump only for package medusa-payment-klarna

1.1.17 (2021-06-09)

Note: Version bump only for package medusa-payment-klarna

1.1.16 (2021-06-09)

Note: Version bump only for package medusa-payment-klarna

1.1.15 (2021-06-09)

Note: Version bump only for package medusa-payment-klarna

1.1.14 (2021-06-08)

Note: Version bump only for package medusa-payment-klarna

1.1.13 (2021-04-28)

Note: Version bump only for package medusa-payment-klarna

1.1.12 (2021-04-20)

Note: Version bump only for package medusa-payment-klarna

1.1.11 (2021-04-20)

Note: Version bump only for package medusa-payment-klarna

1.1.10 (2021-04-13)

Bug Fixes

1.1.9 (2021-04-13)

Bug Fixes

1.1.8 (2021-03-30)

Bug Fixes

1.1.8 (2021-03-23)

Bug Fixes

  • klarna doesn't treat negative discounts well (e275184)

1.1.7 (2021-03-17)

Note: Version bump only for package medusa-payment-klarna

1.1.6 (2021-03-17)

Note: Version bump only for package medusa-payment-klarna

1.1.5 (2021-03-17)

Note: Version bump only for package medusa-payment-klarna

1.1.4 (2021-02-17)

Note: Version bump only for package medusa-payment-klarna

1.1.3 (2021-02-09)

Bug Fixes

1.1.2 (2021-02-03)

Note: Version bump only for package medusa-payment-klarna

1.1.1 (2021-01-27)

Note: Version bump only for package medusa-payment-klarna

1.1.0 (2021-01-26)

Note: Version bump only for package medusa-payment-klarna

1.0.14 (2020-12-17)

Note: Version bump only for package medusa-payment-klarna

1.0.13 (2020-11-24)

Note: Version bump only for package medusa-payment-klarna

1.0.12 (2020-10-19)

Note: Version bump only for package medusa-payment-klarna

1.0.11 (2020-09-17)

1.0.10 (2020-09-09)

Bug Fixes

1.0.7 (2020-09-07)

1.0.1 (2020-09-05)

1.0.1-beta.0 (2020-09-04)

1.0.0 (2020-09-03)

1.0.0-y.6 (2020-08-31)

Bug Fixes

  • parse response correctly (9adc52d)

1.0.0-y.5 (2020-08-31)

Bug Fixes

  • use correct path for captures (91befc0)

1.0.0-y.3 (2020-08-31)

Bug Fixes

  • auto pick country in 1 country regions (d11eb8f)

1.0.0-y.2 (2020-08-31)

Bug Fixes

  • medusa-payment-klarna: get correct country (daa425d)

1.0.0-y.1 (2020-08-31)

Bug Fixes

  • add backend url as option (84f600c)

1.0.0-alpha.30 (2020-08-28)

1.0.0-alpha.27 (2020-08-27)

1.0.0-alpha.26 (2020-08-27)

1.0.0-alpha.24 (2020-08-27)

1.0.0-alpha.3 (2020-08-20)

1.0.0-alpha.2 (2020-08-20)

1.0.0-alpha.1 (2020-08-20)

1.0.0-alpha.0 (2020-08-20)

1.0.10 (2020-09-09)

Bug Fixes