mollie v0.3.0 Mollie.Payments
Link to this section Summary
Functions
Cancels a payment.
Creates a single payment.
Retrieve a single payment object by its payment token.
Retrieve all payments created with the current website profile, ordered from newest to oldest. Results are paginated.
Link to this section Functions
cancel(client, id, params \\ %{})
cancel(Mollie.Client.t(), binary(), map()) :: Mollie.response()
Cancels a payment.
Example
Mollie.Payments.cancel client, "tr_7UhSN1zuXS"
More info at: https://docs.mollie.com/reference/v2/payments-api/cancel-payment
create(client, body)
create(Mollie.Client.t(), map() | list()) :: Mollie.response()
Creates a single payment.
Payment body example
%{
"amount" => %{
"currency" => "USD",
"value" => "100.00"
},
"description" => "Blue suede shows",
"redirectUrl" => "https://shop.example.com/checkout"
}
Example
Mollie.Payments.create client, payment_body
More info at: https://docs.mollie.com/reference/v2/payments-api/create-payment
find(client, id, params \\ %{})
find(Mollie.Client.t(), binary(), map()) :: Mollie.response()
Retrieve a single payment object by its payment token.
Example
Mollie.Payments.find client, "tr_7UhSN1zuXS"
More info at https://docs.mollie.com/reference/v2/payments-api/get-payment
list(client, params \\ %{})
list(Mollie.Client.t(), map()) :: Mollie.response()
Retrieve all payments created with the current website profile, ordered from newest to oldest. Results are paginated.
Examples
Mollie.Payments.list client
Mollie.Payments.list client, %{limit: 100, from: "tr_7UhSN1zuXS"}
More info at: https://docs.mollie.com/reference/v2/payments-api/list-payments