CORE CONCEPTS
Payments
A Payment represents a single attempt to collect money from a customer. Create one per order and confirm it with a payment method.
PARAMETER
TYPE
DESCRIPTION
amount
integer
Amount in the smallest currency unit (e.g. cents). Required.
currency
string
Three-letter ISO currency code, lowercase. Required.
methods
array
Payment methods to offer. Defaults to card.
customer
string
ID of an existing customer to attach the payment to.
metadata
object
Up to 50 key-value pairs for your own reference.
POST /v4/payments
COPY
const payment = await fluxo.payments.create({
amount: 12900,
currency: ʺeurʺ,
methods: [ʺcardʺ, ʺidealʺ],
metadata: { order_id: ʺord_8812ʺ },
});