MasonXPay
Payment routing guide

How to route payments across multiple providers without turning checkout into a guessing game.

Multi-provider routing is the operating layer between checkout and PSP accounts. The goal is not random failover; it is explicit policy, capability checks, bounded fallback, and payment state that remains inspectable after provider calls finish.

Search intent

Understand how to route payment attempts across multiple providers safely.

User job

Design a payment routing approach that can choose a provider path, handle soft failures, and preserve clear financial state.

Useful artifact

Route policy checklist, fallback decision table, and routing flow.

Direct answer

A payment route should be explicit before the first provider call.

Start with a payment context: amount, currency, country, payment method, capture mode, merchant account, and whether the method can be reused with a target provider.

Match that context against a published route policy. The policy should produce an ordered provider-account path, not an improvised runtime decision.

Before calling a provider, check account capabilities. If a provider cannot support the method, currency, country, capture mode, or token reference, skip it before any PSP call.

Fallback only on bounded soft failures such as timeout, temporary provider outage, or configured retryable errors. Hard declines should stop the path.

Keep financial state in durable payment tables. Queues, cache, projections, and dashboards can support operations, but they should not be the authority for charge state.

Routing flow

The five decisions every multi-provider route needs.

01

Collect payment context

Normalize amount, currency, country, method, merchant, mode, and customer/payment-method references before route selection.

02

Match a published policy

Use deterministic policy rules to select an ordered account path. Keep draft policy edits separate from live routing behavior.

03

Check provider capability

Skip accounts that cannot process the payment context. This prevents avoidable provider calls and keeps routing decisions explainable.

04

Execute bounded fallback

Move to the next route step only for configured soft failures. Do not move provider-scoped tokens across PSPs unless portability is explicitly supported.

05

Persist and observe state

Record attempts, outcomes, provider references, and state transitions in durable tables, then project them into dashboards and webhook workflows.

Route policy checklist

Use this checklist before turning fallback on.

The goal is controlled routing. A backup provider helps only when the platform can explain why it was eligible, why fallback was allowed, and what state was persisted.

Policy has clear match conditions

A route should explain why it matched a payment instead of hiding logic in application code.

Each route step names a provider account

Routing by account, not only provider brand, keeps regional credentials and capabilities explicit.

Capability checks run before provider calls

Currency, country, method, capture mode, and token constraints should remove impossible paths early.

Fallback reasons are allowlisted

Timeouts and temporary outages may be retryable; hard issuer declines should usually stop.

Idempotency is backed by durable state

A payment platform needs DB-backed idempotency and state checks, not only client retry discipline.

Operations can inspect every attempt

Support teams need provider references, attempt history, webhook delivery state, and replay tools after checkout.

Fallback decision table

Not every failure should move to another provider.

SignalRoute actionStop condition
Provider timeoutMove to next eligible account if policy allows fallback.Stop if the original attempt later resolves as approved and state checks detect completion.
Temporary provider outageUse configured backup provider account for matching capability set.Stop when no eligible backup remains or the policy disables outage fallback.
Hard card declineDo not fallback by default.Issuer decline should preserve the failed outcome unless the merchant explicitly starts a new payment flow.
Unsupported currency or methodSkip account before provider call.Stop if no route step supports the context.
Provider-scoped tokenKeep token on its original provider unless portability is known and supported.Stop cross-provider fallback when reusable payment method cannot move safely.
MasonXPay mapping

Where this fits in a payment orchestration system.

MasonXPay uses routing, provider adapters, durable payment state, and operations tooling to keep the payment path inspectable. It is not a card network, acquirer, or replacement for PSP acquiring.

Route policies

MasonXPay models routing as explicit policies that match payment context and produce provider-account paths.

Provider adapters

Supported adapters currently include Stripe, Square, Braintree, Mollie, and TEST-only Mason Simulator.

Payment operations

Attempts, invoices, subscriptions, webhook deliveries, and read models give operators a way to inspect what happened after checkout.

State authority

Postgres payment tables and shards remain authoritative; Redis, Kafka, projections, and observability support operations.

FAQ

Payment routing questions

Is payment routing the same as payment retrying?

No. Routing chooses an eligible provider account path for a payment context. Retrying repeats or continues an attempt under explicit state and policy rules.

Should every failed payment fallback to another provider?

No. Hard declines usually stop. Fallback is most useful for bounded soft failures such as timeouts, temporary provider incidents, or unavailable capabilities.

Can a saved card token move from one PSP to another?

Usually not by default. Provider-scoped payment method references should stay with their provider unless a portability mechanism is explicitly supported.

Build payment routing you can explain.

Explore the provider catalog, inspect the open-source implementation, or compare route policy design against your current payment stack.