Payment Reconciliation API: A Developer's Guide
A practical guide for engineering teams evaluating and implementing payment reconciliation APIs. Covers what reconciliation APIs do, N:M matching, exception handling, settlement format support, and implementation patterns.
Building payment reconciliation in-house is one of those decisions that looks straightforward on a whiteboard and turns into a multi-quarter infrastructure project once you're in production. The matching logic alone is manageable. The edge cases — split settlements, timezone drift, N:M relationships between internal records and provider reports — are where teams get stuck.
A payment reconciliation API abstracts this complexity into a programmable layer. This guide explains what a reconciliation API should do, how to evaluate one, and what the implementation looks like for engineering teams.
What a Payment Reconciliation API Does
At its core, a payment reconciliation API gives you programmatic access to matching logic, exception management, and audit state. Instead of building and maintaining this layer yourself, you call an API. The API handles the complexity.
The specific operations a reconciliation API exposes:
Transaction Ingestion
POST endpoints that accept transaction records from your internal systems — your ledger, your order management system, your payment processing layer. The API normalizes these records into a consistent internal format, handling currency representation, timestamp standardization, and reference ID mapping.
For provider data, the API typically accepts webhook payloads from payment processors or pulls directly from provider settlement APIs on a schedule. Some APIs also accept batch file uploads (CSV, ISO 20022) for providers that deliver settlement data as files rather than APIs.
Matching
The matching endpoint takes two sets of records — your internal transactions and external provider records — and returns match results. Each result indicates whether the records matched, the confidence level of the match, and the specific fields that aligned or diverged.
How the matching logic handles edge cases determines whether a reconciliation API is actually useful or just moves your problem downstream:
- Reference ID normalization: the same transaction appears with different IDs in your system vs. the provider's clearing file. The API should map these automatically based on learned patterns.
- Date window matching: settlement windows mean a Friday authorization might appear in Monday's settlement report. The API should handle configurable date tolerance without creating false exceptions.
- Amount tolerance: fees, FX conversion, and rounding mean matched transactions rarely have exactly identical amounts. The API should support configurable amount tolerance rules.
- N:M matching: batch settlements, partial captures, and chargebacks create one-to-many and many-to-one relationships. The API must support N:M, not just 1:1.
Exception Management
Unmatched transactions become exceptions. A reconciliation API should expose:
- Exception listing with structured metadata: exception type, confidence score, affected records, suggested resolution
- Exception classification: amount mismatch, missing record, duplicate, timing issue, reference ID mismatch — each type has a different resolution path
- Resolution endpoints: mark an exception as resolved (with reason), link it to a corrected record, or escalate it to a human review queue
- Webhook callbacks when new exceptions are created or resolved
Ledger Position Verification
Beyond transaction-level matching, a reconciliation API should support balance reconciliation: verifying that your internal ledger positions match your provider account balances at a point in time. This catches systemic issues — a drift in your total position — that transaction-level matching might miss if exceptions accumulate without resolution.
Audit Trail
Every match decision, exception resolution, and configuration change should be retrievable via API. This serves both operational debugging and compliance: regulators want to see your reconciliation process, not just the output.
Why Fintechs Build Reconciliation APIs In-House (and Why It Gets Expensive)
The typical in-house path starts with a database query:
- Pull internal transaction records for the day
- Pull provider settlement data
- JOIN on (amount, date, reference_id)
- Flag non-matching rows as exceptions
- Dump exceptions into a spreadsheet for ops review
This works at low volume with one provider and clean data. It starts breaking when:
- You add a second PSP with a different settlement format and date convention
- Volume scales and the exception spreadsheet has 500 rows on a busy day
- Your first chargeback arrives and you realize your 1:1 matching model doesn't handle disputes
- A timezone bug causes a day's worth of transactions to appear in the wrong period
- Your ops team spends more time in reconciliation than in any other activity
Each of these requires a code change, a new heuristic, or a new matching rule. The in-house reconciliation system becomes a maintenance burden — not because the problem is impossibly complex, but because it accumulates edge cases faster than any team wants to handle them.
The break-even calculation: if your engineering team spends more than one sprint per quarter on reconciliation maintenance, you're spending more on in-house development than a reconciliation API would cost.
Evaluating a Payment Reconciliation API
When assessing reconciliation APIs, the questions that matter are usually about edge cases, not happy-path features:
Match rate on realistic data
Any reconciliation system matches clean data. The differentiator is match rate on your actual data — with your providers, your transaction patterns, your edge cases. Before committing, test with real transaction samples from your environment. A system that achieves 95%+ auto-match on your data means a small exception queue. One that achieves 80% means your ops team is doing the remaining 15-20% by hand.
N:M matching support
Ask specifically: does this API support many-to-many matching? If the answer is no or vague, it's a hard constraint. Chargebacks, refunds, and batch settlements all create N:M relationships. A 1:1-only matching engine will produce false exceptions for these cases.
Exception classification quality
Exceptions are unavoidable. What matters is whether the API tells you why a record didn't match and what to do about it. An exception classified as 'amount mismatch, $0.03 difference, likely FX rounding' is actionable. An exception classified as 'unmatched' with no context requires manual investigation.
Settlement format coverage
Your providers deliver settlement data in specific formats — ISO 20022, NACHA, custom CSV schemas, or provider-specific APIs. Confirm the reconciliation API supports your providers' formats natively, or ask about the custom connector path if it doesn't.
Latency requirements
Reconciliation happens in two modes: batch (daily or weekly settlement runs) and real-time (transaction-level verification for high-value payments). Some APIs only support batch mode. If your use case requires real-time reconciliation, verify this explicitly.
API design
Evaluate the API design directly: consistent resource naming, predictable pagination, idempotent writes, versioning strategy, and webhook reliability. A reconciliation API you integrate into core financial infrastructure needs to be as reliable as any other financial API you depend on.
Implementation Patterns
Event-driven ingestion
The most reliable architecture is event-driven: your payment processing layer emits a transaction event whenever a payment is processed, and your reconciliation API receives it via webhook or message queue. This ensures every transaction is captured at the moment it happens, rather than relying on batch exports that can miss records if something goes wrong during the export window.
Reconciliation runs
Trigger reconciliation runs after each settlement file arrives from your provider, not on a fixed schedule. Provider settlement timing varies — running reconciliation before the settlement file arrives just produces empty results. Reconciliation APIs typically support webhook triggers from provider events or schedule-based runs with idempotency.
Exception handling workflow
Build your exception handling as a separate workflow from your reconciliation run. Exceptions are a normal part of the process; they need a defined resolution path, not just a list. The reconciliation API should provide the exception data; your internal tooling or a dedicated ops workflow should handle the resolution process.
Monitoring
Track three metrics from the reconciliation API: match rate (target 95%+), exception resolution time (how long before exceptions are closed), and exception recurrence rate (are the same exception types recurring, indicating a systemic issue). Alert on match rate drops — they indicate a data quality problem, a provider change, or a bug in your ingestion pipeline.
What NAYA Provides
NAYA's reconciliation infrastructure is built API-first. The NAYA reconciliation engine exposes transaction matching, exception management, and ledger position verification through a developer-accessible API. The matching layer uses deterministic ID mapping for known patterns and probabilistic matching for edge cases, with Alfred handling exception classification and suggested resolutions.
The underlying programmable ledger maintains the source of truth for positions across all accounts, enabling reconciliation not just at the transaction level but at the balance level. Every match decision and exception resolution is logged with enough context to reconstruct the reconciliation audit trail.
For engineering teams evaluating whether to build or buy: the reconciliation matching logic itself is not the hard part. The hard part is the N:M matching, the edge case accumulation, the provider format library, and the ongoing maintenance as your provider mix and transaction patterns evolve. That's what a purpose-built reconciliation API is for.
Frequently Asked Questions
Common questions about this topic
QWhat is a payment reconciliation API?
A payment reconciliation API provides programmatic access to transaction matching, exception management, and audit trail capabilities. It ingests transaction data from internal systems and external providers, matches records across sources, classifies exceptions, and exposes the results via API endpoints and webhooks.
QWhat is the difference between payment reconciliation and payment processing?
Payment processing handles the execution of a payment transaction — authorization, capture, and routing. Payment reconciliation verifies that the transaction records in your system match the records in your payment providers' systems. They operate at different layers: processing at transaction time, reconciliation after settlement.
QWhat is N:M matching in payment reconciliation?
N:M matching handles cases where one internal transaction record corresponds to multiple external records, or multiple internal records correspond to one external record. This occurs with batch settlements, partial captures, chargebacks, and refunds. Reconciliation systems that only support 1:1 matching produce false exceptions for all N:M relationships.
QWhat match rate should a payment reconciliation API achieve?
Production reconciliation APIs should achieve 95%+ auto-match rates on representative transaction data. Match rates below 90% typically indicate either data quality problems in the source systems or a matching engine that isn't handling your specific provider and transaction patterns.
QHow does a payment reconciliation API handle exceptions?
Exceptions are unmatched transactions that couldn't be automatically reconciled. A reconciliation API classifies exceptions by type (amount mismatch, missing record, duplicate, timing difference), provides context about why the match failed, and exposes resolution endpoints. Exceptions requiring human review are surfaced with enough information to investigate without re-querying the source data.
QWhen should an engineering team use a reconciliation API instead of building in-house?
The break-even point is usually when reconciliation maintenance consumes more than one engineering sprint per quarter. Common triggers: adding a second PSP with different data formats, transaction volume scaling past 10,000 per day, chargeback and dispute handling requirements, or compliance requirements for documented daily reconciliation with audit trails.
QWhat settlement formats should a reconciliation API support?
Common settlement formats include ISO 20022, NACHA ACH files, SWIFT MT940, and provider-specific CSV schemas from major PSPs and acquirers. Verify your specific providers are supported before selecting a reconciliation API, or confirm the custom connector path and timeline.
QHow does real-time reconciliation differ from batch reconciliation?
Batch reconciliation processes settlement data after settlement files arrive — typically daily or weekly. Real-time reconciliation verifies individual transactions as they occur against live provider data. Most reconciliation APIs support batch mode; real-time is less common and requires API support from the provider for live transaction queries.
Get technical insights weekly
Join 4,000+ fintech engineers receiving our best operational patterns.