mollie_ex

Community driven Elixir SDK for Mollie.

Hex package and Mix application name: :mollie_ex. Public SDK module namespace: MollieEx.*.

Requirements

Installation

Add mollie_ex to your dependencies in mix.exs:

def deps do
[
{:mollie_ex, "~> 0.4.0"}
]
end

Basic usage

Build an explicit client. The library does not read credentials from the environment by itself.

client =
MollieEx.Client.new!(
api_key: System.fetch_env!("MOLLIE_API_KEY")
)
{:ok, payment} =
MollieEx.Payments.create(
client,
%{
description: "Order #123",
amount: %{currency: "EUR", value: "10.00"},
redirect_url: "https://example.com/checkout/return"
},
idempotency_key: "9f0f9a78-9d56-4d2b-a7b6-7fdb8cc7d5f3"
)
checkout_url = MollieEx.Payment.checkout_url(payment)

Documentation

Full guides and API reference are available on HexDocs.