Payments overview
How payment providers are configured in Autonnel, what the provider cards show, and how the unified transactions view reconciles them.
The /payment page lists your payment accounts, and each domain binds the accounts it uses. The /transactions page gives you a unified view of every charge and refund across all providers.
Prerequisites
- Admin role access to Settings.
- At least one account created and bound to a domain before that domain can accept payments.
Payment accounts
A payment account holds one set of credentials for one provider. The /payment page lists accounts grouped by provider. Click Add account under a provider (/payment/accounts/new?provider=<provider>), give the account a name and enter its credentials. You can create several accounts for the same provider, for example one per brand. Credentials are stored encrypted, and secret fields are shown masked.
An account’s own page (/payment/accounts/<id>) shows its name, credentials, an Activate / Deactivate switch, the domains it is bound to, and Delete. An account cannot be deleted while it is bound to a domain or used by existing payments. The old /payment/<provider> addresses redirect to /payment.
Creating an account does not make it usable on its own: it must be bound to a domain.
Binding accounts to domains
Each domain chooses which account takes its payments. Open Pages → Domains, click the domain and use its Payment tab. There is one row per provider: select an account or Not bound. Some providers add binding fields to the row; PhotonPay asks for a Site ID, which is required and belongs to the domain, not the account.
- A domain with nothing bound shows the banner
This domain cannot take payments until an account is bound.and aNo payment accountbadge in the domains list. - An unbound domain cannot check out. The checkout request is refused with 409
no payment account bound to this domain. There is no fallback to another domain’s account. - Checkout shows only the providers bound to the domain the buyer is visiting.
- The admin page preview shows the default domain’s payment methods, but checkout is disabled there (
Checkout is disabled in preview). - Binding needs the Payment settings permission. A user with only the Domains permission sees the tab read-only.
Bindings can also be read and changed over the external API: get_domain_settings lists each domain’s bindings (never credentials), and set_domain_payment_account (PUT /api/v1.1/domains/:domain/payment) binds an account or unbinds it with accountId: null. Errors carry a code such as MISSING_FIELD: siteId. Accounts themselves cannot be created through the API.
What a payment remembers
Every payment records the account and the binding settings it was created with. Returns, webhooks, reconcile jobs, upsells and refunds use that account even if you later unbind or rebind the domain. Deactivating an account stops new charges: an upsell chain in progress skips to the thank-you page. Unbinding a domain does not stop an upsell chain that has already started.
Upgrading from a single payment configuration
Earlier versions had one tenant-wide payment configuration. After db push, run npx autonnel payments:migrate-accounts. It turns the old configuration into accounts, backfills the account on existing payments and is safe to run again. It binds no domain, so bind an account on every domain before traffic resumes: until then no domain can check out.
Unified transactions view
The /transactions page shows both charge and refund records in a single list. You can filter by type, status, provider, amount range, and date. Charges and refunds appear together, with refund records linked to the original charge.
How refunds route
Refunds always go through the same provider that processed the original charge. If an order was paid via Stripe, the refund submits to Stripe. If an order was paid via PayPal, the refund submits to PayPal.
Payment gateways from plugins
Plugins can add new payment gateways next to Stripe and PayPal. A plugin gateway gets its own section on the payment page and its own account form, is bound per domain like the built-in providers, and shows up in the checkout payment form as a pay button on the domains it is bound to.
A gateway can be a hosted-page type: the buyer is redirected to the gateway’s payment page, pays there, and comes back to the next step of the funnel. The order is confirmed from a server-side status query or the gateway’s notification, never from the browser redirect alone, so a buyer who closes the tab after paying is still recorded.
If a gateway supports charging a saved payment method without the buyer present, one-click upsells work with it as well.
The notification URL to register with the gateway is unchanged by accounts and has the form https://<storefront-domain>/api/shop/payment/webhook/<provider>, where <provider> is the lowercase gateway slug.
Caveats
- Each account requires its own set of API keys. There is no shared-credential mode between Stripe and PayPal.
- Refunds always route through the original provider; you cannot redirect a Stripe refund through PayPal or vice versa.
- Partially refunding an order creates one refund record. If you refund in multiple batches, each batch produces its own record linked to the original charge.