---
title: "Bank/AR Confirmation Matcher"
method: POST
path: "/v1/tools/match_confirmations"
tags: ["TODO_TAGS_REVIEW", "TODO_AP2_EXPORT_REVIEW"]
---

# Bank/AR Confirmation Matcher

`POST /v1/tools/match_confirmations`

## Request

- Base URL: `https://ainumbers.co`
- URL: `https://ainumbers.co/v1/tools/match_confirmations`
- Auth: none declared

Joins caller-supplied bank and accounts-receivable confirmation responses against caller-supplied ledger balances on (counterparty_id, type), and classifies each pair EXACT_MATCH, TOLERANCE_MATCH, or MISMATCH, plus confirmations with no corresponding ledger balance and ledger balances with no corresponding confirmation. The match tolerance (tolerance_abs, tolerance_pct) is a caller-declared policy input; the explicit, echoed default is 0/0 (exact match required) when the caller declares neither -- there is no silent, unrecorded tolerance. A duplicate (counterparty_id, type) key on either side is reported as a data-quality flag rather than silently overwritten -- only the first occurrence on each side is joined. Third of three ARCB-K-1 substantive audit-recalculation kernels. NaN-safe. Zero network, zero PII.

**Tool URL:** https://ainumbers.co/chaingraph/art-464-confirmation-matcher.html

## Request body

- object
  - `confirmations` unknown, required
  - `ledger_balances` unknown, required
  - `tolerance_abs` unknown, required
  - `tolerance_pct` unknown, required

## Response `200`

Successful tool execution result

- object
  - `duplicate_confirmation_keys` unknown[]
    - unknown
  - `duplicate_ledger_keys` unknown[]
    - unknown
  - `exact_count` integer
  - `matched` object[]
    - `confirmation_id` string
    - `confirmed_balance` integer
    - `counterparty_id` string
    - `ledger_balance` integer
    - `match_type` string
    - `type` string
    - `variance` integer
  - `matched_count` integer
  - `tolerance_count` integer
  - `tolerance_used` object
    - `abs` integer
    - `declared_by_caller` boolean
    - `pct` integer
  - `total_confirmations` integer
  - `total_ledger_balances` integer
  - `unmatched` object[]
    - `confirmation_id` string
    - `confirmed_balance` integer
    - `counterparty_id` string
    - `ledger_balance` integer
    - `reason` string
    - `type` string
    - `variance` integer
  - `unmatched_count` integer

---

[API](https://skmtc.dev/ainumbers/apis/ainumbers-co-fintech-intelligence-suite.md) · [All operations](https://skmtc.dev/ainumbers/apis/ainumbers-co-fintech-intelligence-suite/llms.txt) · [OpenAPI document](https://skmtc.dev/ainumbers/apis/ainumbers-co-fintech-intelligence-suite/revisions/b462e4f5bb28?raw)
