- payments
- payment orchestration
- reconciliation
- PSP integration
iGaming Payment Orchestration: Route Safely and Reconcile Every Outcome

Design payment routing that handles uncertain outcomes without duplicate charges. Follow a lost deposit response through provider evidence, wallet credit, withdrawals and settlement reconciliation.
A payment service provider accepts a deposit, but the platform loses the response. Routing the player to a second provider may look like good availability; it may also charge the player twice. Marking the first attempt “failed” does not undo anything at the first provider. The orchestration layer has to preserve uncertainty long enough to resolve the financial facts.
For payment product owners, architects and finance or operations leads, useful orchestration means more than choosing a gateway. It connects a player request, every provider attempt, the wallet effect and later reconciliation. This guide works through a lost deposit response and the decisions needed to recover it. Provider documentation supplies specific examples; it does not imply that either provider accepts every iGaming operator or market.
Separate provider outcomes, wallet postings and player permissions
Start with the scope described in payments and KYC integration and platform integration services: approved operator entity, merchant accounts, markets, currencies, methods and production arrangements. Confirm commercial access and the applicable operating rules before treating a route as usable. A working sandbox request is not that confirmation.
Give each component a specific authority. The provider supplies evidence of external processing. The payment service owns the platform payment record, attempt history and interpretation of that evidence. The wallet owns postings and reservations, as explained in the wallet and ledger design article. Account and verification services supply the current permissions relevant to an action. Orchestration coordinates unfinished work; it does not create another writable balance.
Use a canonical model that preserves meaningful differences. Keep provider processing, wallet application and reconciliation status as separate dimensions. “Provider confirmed; wallet credit pending” is a useful state. One green “success” flag cannot explain that condition, a later refund or an unresolved settlement discrepancy.
Adyen’s result-code guide distinguishes intermediate statuses from final response outcomes and notes that manual capture still follows authorisation. Document your adapter’s exact credit-release evidence. Authentication, authorisation, capture and settlement must not be treated as interchangeable events.
Choose eligible routes before optimising approval or cost
Filter candidate routes by hard constraints first: approved merchant account and market, supported currency and method, amount rules, current player policy, required authentication flow and available production capacity. Keep the policy version, eligible candidates, chosen provider and decision reason with the attempt. A route with a good historic approval rate is irrelevant if it cannot lawfully or contractually process this request.
Then compare eligible routes using evidence for a comparable cohort: method, currency, market and failure category. Separate genuine payment refusals from network failures and unfinished authentication. A change in player mix can move an overall approval percentage without any provider improvement. Record the denominator, observation window and sample size rather than letting a small burst of failures automatically rewrite policy.
Define three different next actions:
- Retry the same attempt: resend the same operation to the same provider under its idempotency and retry contract, without changing significant fields.
- Create an eligible new attempt: choose another route only when the previous outcome is sufficiently resolved, the failure category allows another attempt, and current policy permits it. Link both attempts to the same player payment request.
- Investigate: retain an unknown or conflicting outcome, perform the supported status lookup or provider escalation, and prevent an automatic second charge while the first may still succeed.
Do not reroute a refusal blindly, bypass a player restriction, or assume a token and authentication result can be carried to another provider. Confirm those capabilities for the actual integration. A health circuit breaker can stop new traffic to an unhealthy route; it cannot establish that an in-flight payment failed. Route changes also need a controlled way to restore the previous policy without rewriting the history of attempts already sent.
Recover a deposit whose response was lost
Consider an illustrative deposit of EUR 120.00. The player’s wallet starts at EUR 80.00; there are no other movements. Assume the agreed provider evidence permits the credit and the player-policy checks pass. The sequence should be recoverable at each boundary:
- Before sending: persist the player payment identifier, brand, merchant account, amount and currency, route-policy version, attempt identifier and provider idempotency key. Record recoverable work before making the external call; do not rely on process memory.
- When the response is lost: record an unknown outcome for that attempt. Use the same provider’s supported lookup or safe repeat contract. Do not create a second-provider charge merely because a timer expired.
- When trusted confirmation arrives: validate its source and bind it to the expected account and attempt. Check the reference, amount, currency and relevant state. Persist accepted evidence and recoverable wallet-credit work together in the payment service’s local transaction.
- When the wallet applies it: use a stable business operation reference and atomically commit duplicate protection, the credit and its outcome in the wallet. The balance becomes EUR 200.00. Losing the wallet response or receiving the notification again must leave EUR 200.00, not another credit.
Transport delivery and financial effect are different guarantees. A message may be delivered repeatedly; the wallet must recognise the same accepted credit. Choose uniqueness at the business boundary, not only at a webhook ID: two provider events or attempts can refer to one requested deposit. Preserve their references without letting each produce the full credit independently.
If two providers actually took money, one wallet credit does not erase the second external charge. Open an exception with both attempts and amounts, then follow an authorised resolution such as a supported refund. Do not hide it by deleting an attempt or silently treating the extra charge as a new player deposit. Conversely, a legitimately separate deposit needs its own business identity; broad deduplication by player and amount would suppress real money. If the integration permits partial payments or captures, identify each approved credit part and enforce cumulative amount rules. Preventing a duplicate full credit must not discard a legitimate later part.
If the provider confirms money after the player’s permissions change, record the external fact and apply the agreed treatment for those funds. That may require a restricted or pending allocation and review rather than immediately usable funds. It is not grounds to discard the receipt or invent a universal rule that every account restriction blocks every financial or funds-return action.
Give retries and webhooks a durable processing contract
Adyen’s idempotency documentation supports repeating a timed-out request with the same key, subject to its documented contract. It also limits key scope and warns about duplication across regional endpoints. Treat provider idempotency as a specific capability, not protection shared by different PSPs or retained indefinitely.
For each adapter, document key scope and retention, significant request fields, retriable errors, status lookup, concurrent-request behaviour and what to do when protection expires. Persist the original request meaning. A changed amount or recipient is a changed operation, not a safe retry. Do not remove the key to “fix” an error and then assume duplicate protection still exists. Bound automatic retries, back off under the provider’s rules, and hand unresolved work to a named queue before retries become uncontrolled load.
Stripe’s webhook guide describes duplicate and unordered delivery, and requires the original request body for its signature verification. Implement each provider’s verification contract; a plausible payload or a successful browser redirect is not trusted payment evidence.
- Receive: verify the notification, account and environment; preserve enough protected evidence for investigation and replay. Reject invalid input, and quarantine valid but unmatchable records instead of guessing a player.
- Acknowledge: for accepted relevant input, durably save the event or recovery work before sending the provider’s success response. Keep that path short. If persistence fails, follow the provider’s failed-delivery contract rather than acknowledging work that exists only in memory.
- Apply: deduplicate delivery, interpret the event with its schema and adapter version, and enforce permitted state transitions. A late pending event must not overwrite confirmed processing; a real refund or chargeback is a separate financial fact that may need a linked action.
- Recover: track processing failures, replay safely and use supported status queries to fill gaps. Do not decide event order from receipt time alone. Replaying a stored event must not repeat its wallet effect.
Keep raw secrets and unnecessary identity or card data out of routine operational logs. Store controlled references and the fields actually needed for matching. Notification authenticity still does not prove that its amount belongs to the expected deposit, so signature verification and business validation are separate checks.
Keep withdrawal holds and compensating actions explicit
A withdrawal starts with a different money decision: reserving eligible funds before a payout can be sent. Link the reservation, withdrawal request and provider attempt. Recheck the current conditions at the agreed execution boundary, and define the race behaviour if an account restriction changes during processing. Eligibility for gambling and the treatment of a permitted funds return need distinct policy decisions.
Validate the payout-specific status, retry and cancellation contract; deposit documentation does not establish outgoing-payment finality. An accepted payout instruction is not necessarily final delivery. Keep the reservation until the documented success or failure evidence resolves it. On confirmed success, resolve the hold into the recorded outgoing movement without charging the player twice. On confirmed failure, release it through an identified wallet operation. For partial or returned payouts, resolve only the corresponding amounts under the documented accounting rules; partial success does not justify releasing the entire reservation. After a timeout, neither release funds for spending nor send another payout solely because the response is absent. Record the uncertainty, investigate the original instruction and make the next action reviewable.
Support needs permitted actions with consequences: refresh provider status, inspect evidence, approve a defined correction, or escalate a stuck withdrawal. “Mark completed” and “retry with another provider” must not be unrestricted status edits. Require scope, reason, appropriate approval and a traceable result for financial interventions.
Refunds, reversals and chargebacks also need their own linked records. Check the original transaction, amount already returned and provider capabilities; do not infer an unlimited refund right from a successful deposit. A return of money can fail or be reversed too. If a late debit creates a shortfall after the player spent funds, record and escalate that condition under the approved accounting and player policy rather than forcing a fictional balance or rewriting history.
Reconcile transactions, fees and bank settlements separately
Reconciliation should answer three different questions: does external provider evidence match the platform’s payment attempts; do accepted payment operations match wallet postings; and do provider settlements match the operator’s accounting and bank records? Compare records at the same boundary. A browser success page cannot settle the first question, and a wallet total cannot prove a bank payout arrived.
Adyen’s Settlement details report documents transaction references, gross and net currencies, costs and settlement entries, including merchant payouts. Those are provider-specific report semantics; a payout to the operator’s bank is not a withdrawal sent to a player.
For the earlier example, assume the operator bears a fee of EUR 2.40, there is no currency conversion and no other adjustment. The gross deposit is EUR 120.00; the net settlement contribution is EUR 117.60. The player still receives the agreed EUR 120.00, taking the wallet from EUR 80.00 to EUR 200.00. The fee is a separate accounting cost in this example, not an unexplained deduction from the player credit. Real fee arrangements and account mappings need finance approval.
Match using provider and merchant account, internal payment and attempt identifiers, provider transaction and modification references, currency, amount and event type. A parent payment may have partial captures, refunds or several report entries; do not force every record into a one-to-one match. Preserve gross-versus-net and currency distinctions, batch identifiers and reporting time zones. Match the bank batch payout to its contributing settlement entries and adjustments, not to a single player deposit.
Make mismatches actionable: confirmed provider money without a wallet entry; a wallet entry without accepted evidence; duplicate external charges; an unexplained amount difference; a missing report or bank receipt. Distinguish not-yet-due settlement from a genuinely overdue discrepancy under the relevant contract. Keep the original source file or protected reference, import version, match decision and exception history. Reimporting a report must not create another posting; a file changing its columns must not silently shift amount interpretation.
Operate and test the uncertain paths before adding more routes
Prove one complete route first, including uncertainty and reconciliation, before adding routing optimisation. Use controlled provider test cases and realistic local failure injection. Validate these outcomes against durable payment and wallet records, not just HTTP responses:
- Lost acknowledgement: the provider accepted a deposit but the response disappears. The attempt remains recoverable; no automatic second charge is created.
- Duplicate and late evidence: deliver the same notification concurrently, then an older pending event. There is one credit and no unexplained regression.
- Internal crash: stop processing after evidence is accepted, and again after the wallet commits but before the reply. Recovery completes the original operation without another posting.
- Wrong context: send an invalid signature, a wrong merchant account, an unexpected currency and a valid but unknown reference. Reject or quarantine according to the contract without allocating money by guesswork.
- Withdrawal uncertainty: lose the payout response and change a relevant permission. The hold and investigation remain traceable; the timeout does not release spendable funds or authorise another payout.
- Settlement difference: import the report twice, introduce a fee difference and remove a batch receipt. Matching produces the documented exceptions and no duplicate financial effect.
Measure provider acceptance separately from technical availability, wallet-application lag, age and value of unknown attempts, webhook recovery backlog, unsettled holds and reconciliation exceptions. Segment by account, method, currency and route version. Give each alert an investigation owner and a permitted next action; an approval-rate dashboard alone will miss a growing queue of accepted payments that never reached wallets.
Change route policy in controlled increments with clear observation and reversal criteria. Assess cost, customer completion, unresolved money and operational load together. A second provider can improve reach or resilience, but it also adds a contract, credential boundary, report format and exception path. The integration-layer article provides adjacent context for keeping those differences outside the core model.
Continue with the verification-workflow article for identity evidence and review states, and the back-office article for staff authority, approvals and evidence. Keep those decisions visible where payment cases cross teams; a provider’s successful response does not settle all of them.
- Route decision record: eligible accounts and methods, current hard constraints, selected route, policy version, reasons and the evidence required before creating a new attempt.
- Adapter recovery contract: status mapping, trusted confirmation, key scope and expiry, retry rules, lookup, notification validation and unresolved-outcome escalation.
- Money linkage: player request, provider attempts, accepted evidence, wallet operation, withdrawal reservation and any refund or correction, with independent duplicate protection at each effect boundary.
- Reconciliation specification: source reports, identifiers, currencies and time zones, gross/net/fee treatment, batch matching, import versioning, exception owners and observed failure-test results.
Can another PSP be tried immediately after a timeout?
A timeout does not establish that the first PSP failed to take money. Resolve the original attempt through its supported evidence and retry contract before authorising a new route. A new provider cannot deduplicate a charge made at the first provider.
Does a verified webhook make a deposit complete?
It establishes notification authenticity under the provider’s contract. You must still match the account, attempt, amount and currency, interpret the event, and apply the wallet operation. Provider processing and wallet credit are separate recorded outcomes.
Should payment fees reduce the player’s wallet credit?
Apply the approved and disclosed product and accounting rules; do not substitute a provider’s net settlement amount for the promised player credit. In the article’s example the operator bears the fee, so gross player credit and net settlement differ without a missing deposit.
What should support do with an unknown payout result?
Inspect the original withdrawal, hold, attempt and provider evidence, then follow the documented lookup or escalation path. A manual resolution needs appropriate authority and a recorded financial consequence. Do not release the hold or issue a replacement payout just to clear an old status.
Bring a deposit or withdrawal with an uncertain outcome, its provider contract and the relevant wallet and settlement records. Identify the safe next action, duplicate protection and missing evidence before expanding routing rules.



