Klarna Web SDK v2
    Preparing search index...

    Interface KlarnaMessaging

    Messaging package. Credit promotion and placement APIs.

    gated

    interface KlarnaMessaging {
        placement(options: KlarnaPlacementOptions): KlarnaPlacement;
    }
    Index
    • Parameters

      Returns KlarnaPlacement

      "Creates a Klarna promotional messaging placement. Placements display contextual messages such as 'Pay in 4 interest-free installments' on product pages, cart pages, or footers. The key determines the placement type and layout, and amount (in minor units, e.g. 2500 for $25.00) controls the financing terms shown.

      Call mount() on the returned element to render it into a DOM container."

      label="Example"

      // Create a credit-promotion placement and mount it
      klarna.Messaging.placement({
      key: "credit-promotion-auto-size",
      locale: "en-US",
      amount: 4999, // $49.99 in minor units
      }).mount("#product-messaging");
      // Create a footer placement with dark theme
      klarna.Messaging.placement({
      key: "footer-promotion-auto-size",
      locale: "en-US",
      theme: "dark",
      }).mount("#footer-klarna");

      Messaging

      Messaging.placement

      Messaging

      gated

      Messaging.placement

      true

      true