@propeller-commerce/propeller-mollie
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

Propel.us Mollie Nuxt module

Overview

propeller-mollie

Extension module

The extension module acts as a middleware between Propeller platform and Payment Service Provider. Once Extensions is configured to call PSP, for every payment created or update, Propeller GraphQL API is called to register that transaction.

Notification module

Notification module receives asynchronous notifications sent by Payment Service Provider. Through notifications, PSP provides asynchronously payment status changes like paid, authorization, charge, or refund of the payment. The notification module processes the notification sent by PSP and matches the Propeller payment for this notification, then modifies Propeller payment and order accordingly.

How to install

  1. Open your theme directory and run: -
yarn add @propeller-commerce/propeller-mollie
  1. Open your nuxt.config.js
  2. At the bottom of modules add:
['@propeller-commerce/propeller-mollie/nuxt', {
    propellerKey: 'PROPELLER_KEY',
    propellerApiUrl: 'PROPELLER_API_URL',
    mollieKey: 'MOLLIE_KEY',
    mollieIsTest: true,
    mollieRedirectUrl: '/checkout/thank-you',
}],

propellerKey is used for authentication to Propeller GraphQL queries
propellerApiUrl is Propeller GraphQL URL
mollieKey is Mollie authentication key
mollieIsTest allows to define if mollie if we are using Mollie test environment
mollieRedirectUrl is the URL used for redirect after payment is finished

Render payment handlers & finalize payment

  1. Import useMollie:
import { useMollie } from "@propeller-commerce/propeller-mollie";

In this step you need:

const { makePayment } = useMollie();
  1. Calling makePayment and redirecting to payment page:
const payment = await makePayment({
  amount: cartGetters.getTotals(cart.value).total,
  currency: "EUR",
  orderId: orderGetters.getId(order.value),
  userId: 146443,
});

const paymentUrl = payment.paymentUrl;

Readme

Keywords

none

Package Sidebar

Install

npm i @propeller-commerce/propeller-mollie

Weekly Downloads

3

Version

1.0.0

License

MIT

Unpacked Size

33 kB

Total Files

24

Last publish

Collaborators

  • antoniot13
  • adriancollier
  • milennas
  • bokjo
  • aalili