For the complete documentation index, see llms.txt. This page is also available as Markdown.

Payments

Payment session webhook events and example payloads.

Payment webhooks track the lifecycle of a payment session.

Use these events to update order state, trigger fulfillment, or handle failed payments.

Field descriptions

Payment webhook events use data.session.

Field
Type
Description

data.session.id

string

Unique session identifier.

data.session.reference

string

Your order or payment reference.

data.session.title

string

Session title.

data.session.description

string | null

Optional session description.

data.session.state

'open' | 'closed'

Session state.

data.session.type

string

Session type.

data.session.amount

string

Requested amount.

data.session.currency

string

Requested currency.

data.session.settlements

object | null

Settlement breakdown when the session settles.

data.session.payment.status

string

Payment status for the session.

data.session.payment.asset

string

Crypto asset code.

data.session.payment.chain

string

Blockchain network.

data.session.payment.amount

string

Required crypto amount.

data.session.payment.amountReceived

string

Actual crypto amount received.

data.session.payment.conversionRate

string

Fiat to crypto conversion rate used.

data.session.payment.gasFee

string

Network gas fee.

data.session.payment.address

string

Deposit address.

data.session.payment.feePaidBy

'merchant' | 'customer'

Who pays the network fee.

data.session.customer

object

Customer information.

data.session.metadata

object | null

Custom metadata.

data.session.successUrl

string

Redirect URL used after success.

data.session.cancelUrl

string

Redirect URL used after cancellation.

data.session.createdAt

string

Creation timestamp.

data.session.expiresAt

string

Expiry timestamp.

data.session.completedAt

string | null

Completion timestamp when available.

data.failureReason

string

Failure reason for payment.failed.

Every payment session event includes customer, metadata, successUrl, and cancelUrl.

Events

  • payment.completed

  • payment.partial

  • payment.expired

  • payment.underpaid

  • payment.failed

payment.completed

Sent when a payment session is fully paid.

Use this event to mark the order as paid.

payment.partial

Sent when a payment session receives less than the required amount and remains open.

Use this event to notify the customer, track the remaining balance, or keep the order on hold while the session can still accept more payments.

payment.expired

Sent when a payment session closes with no payment received.

Use this event to expire checkout state.

payment.underpaid

Sent when a payment session closes with less than the required amount.

Use this event when the session is final but still short.

payment.failed

Sent when a payment session is rejected after a compliance or AML failure.

Use this event to stop fulfillment and surface the failure.

Last updated

Was this helpful?