Skip to content

basalt / subscriptions/src / PaymentLedgerOptions

Interface: PaymentLedgerOptions ​

Defined in: subscriptions/src/payment.ts:215

Properties ​

onListenerError? ​

> optional onListenerError?: (error, event) => void

Defined in: subscriptions/src/payment.ts:228

Called when a lifecycle listener throws. Listeners are best-effort side effects (notifications, analytics) that never roll back a payment — a throwing one is reported here instead. Default: swallow.

Parameters ​

error ​

unknown

event ​

keyof PaymentLedgerEvents

Returns ​

void


store? ​

> optional store?: PaymentStore

Defined in: subscriptions/src/payment.ts:217

Where payments are stored. Default: in-memory.


webhooks? ​

> optional webhooks?: WebhookStore

Defined in: subscriptions/src/payment.ts:222

Webhook-id dedupe store. Default: in-memory. Share one durable store (e.g. Redis) across the app so a retried callback is applied exactly once.

Released under the MIT License.