Skip to main content
The Wallet Top-Up API lets you programmatically add funds to a customer’s wallet balance by initiating payment collection, and configure automatic top-up rules that trigger when the balance drops below a threshold.

Manual Top-Up

Initiate a Top-Up

Response (201 Created):
The top-up creates a PaymentIntent that collects the funds. Once the payment succeeds, the amount is credited to the customer’s wallet.

List Top-Ups

Response (200 OK):

Top-Up Status

Get a Single Top-Up


Auto Top-Up Rules

Auto top-up rules automatically initiate a top-up when a customer’s wallet balance drops below a configured threshold.

Create a Rule

Response (201 Created):
Only one rule per customer per currency is allowed. Attempting to create a duplicate returns 400 Bad Request.

List Rules

Update a Rule

All fields are optional — only include the fields you want to change.

Delete a Rule

Returns 204 No Content on success.

How Auto Top-Up Works

  1. A balance-reducing transaction occurs (e.g., wallet balance applied to an invoice)
  2. Fynn checks if an enabled auto top-up rule exists for the customer and currency
  3. If the ending balance is below the threshold, a top-up is initiated automatically
  4. The top-up follows the same flow as a manual top-up (PaymentIntent → payment → credit)
Safety mechanisms:
  • Top-up transactions themselves do not trigger auto top-up (prevents loops)
  • The consecutiveFailures counter tracks sequential failures — monitor this to detect broken payment methods
  • The feature must be enabled via the WalletTopUp feature flag

Customer-Authenticated Requests

Customers authenticated via the customer portal can manage their own wallet:
  • Top-up: customerId is inferred from the authenticated session (do not include it)
  • Auto top-up rules: Customers can only view/manage their own rules
  • Attempting to access another customer’s data returns 403 Forbidden

Error Handling


Integration Example