{
  "schema_version": "d30-balance-proof-independent-v1",
  "classification": "Synthetic literal expected arithmetic and outcomes authored before proof implementation; no runtime imports",
  "cases": [
    {
      "id": "P01-two-consistent-bridges-still-differ",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "CLOSING_BALANCES_DIFFER",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0",
            "opening_minor": "10000",
            "inflow_minor": "6200",
            "outflow_minor": "1900",
            "net_movement_minor": "4300",
            "expected_closing_minor": "14300",
            "reported_closing_minor": "14300",
            "excluded_currency_count": "0"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0",
            "opening_minor": "10000",
            "inflow_minor": "6200",
            "outflow_minor": "1200",
            "net_movement_minor": "5000",
            "expected_closing_minor": "15000",
            "reported_closing_minor": "15000",
            "excluded_currency_count": "0"
          }
        },
        "comparison": {
          "opening_difference_minor": "0",
          "closing_difference_minor": "-700",
          "adjusted_internal_closing_minor": "14300",
          "adjusted_closing_residual_minor": "-700",
          "unresolved_item_count": "0"
        }
      }
    },
    {
      "id": "P02-explained-but-unresolved",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "indeterminate",
        "code": "RECONCILING_ITEMS_REMAIN",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0",
            "opening_minor": "10000",
            "inflow_minor": "6200",
            "outflow_minor": "1900",
            "net_movement_minor": "4300",
            "expected_closing_minor": "14300",
            "reported_closing_minor": "14300",
            "excluded_currency_count": "0"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0",
            "opening_minor": "10000",
            "inflow_minor": "6200",
            "outflow_minor": "1200",
            "net_movement_minor": "5000",
            "expected_closing_minor": "15000",
            "reported_closing_minor": "15000",
            "excluded_currency_count": "0"
          }
        },
        "comparison": {
          "opening_difference_minor": "0",
          "closing_difference_minor": "-700",
          "internal_item_signed_minor": "-700",
          "external_item_signed_minor": "0",
          "adjusted_internal_closing_minor": "15000",
          "adjusted_closing_residual_minor": "0",
          "unresolved_item_count": "1"
        }
      }
    },
    {
      "id": "P03-before-atomic-source-and-control-revision",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T08:59:59.999Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "CLOSING_BALANCES_DIFFER",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0",
            "inflow_minor": "6200",
            "outflow_minor": "1800",
            "net_movement_minor": "4400",
            "expected_closing_minor": "14400",
            "reported_closing_minor": "14400"
          }
        },
        "comparison": {
          "closing_difference_minor": "-100",
          "adjusted_closing_residual_minor": "-100"
        },
        "control_evidence": {
          "external": {
            "closing": {
              "selected": {
                "revision": "1",
                "amount_minor": "14400"
              }
            }
          }
        }
      }
    },
    {
      "id": "P04-clean-identical-bridges",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-CLEAN",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "pass",
        "code": "BALANCE_PROOF_PASS",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0"
          }
        },
        "comparison": {
          "opening_difference_minor": "0",
          "closing_difference_minor": "0",
          "adjusted_closing_residual_minor": "0"
        }
      }
    },
    {
      "id": "P05-wrong-internal-closing",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14301"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "SIDE_BRIDGE_FAILED",
        "bridges": {
          "internal": {
            "status": "fail",
            "expected_closing_minor": "14300",
            "residual_minor": "1"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0"
          }
        },
        "comparison": {
          "closing_difference_minor": "-699"
        }
      }
    },
    {
      "id": "P06-wrong-internal-opening",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10001"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "SIDE_BRIDGE_FAILED",
        "bridges": {
          "internal": {
            "status": "fail",
            "expected_closing_minor": "14301",
            "residual_minor": "-1"
          }
        },
        "comparison": {
          "opening_difference_minor": "1"
        }
      }
    },
    {
      "id": "P07-wrong-external-closing",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "14999"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "SIDE_BRIDGE_FAILED",
        "bridges": {
          "external": {
            "status": "fail",
            "residual_minor": "-1"
          }
        }
      }
    },
    {
      "id": "P08-equal-wrong-closing-controls",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-CLEAN",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14301"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14301"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "SIDE_BRIDGE_FAILED",
        "bridges": {
          "internal": {
            "status": "fail",
            "residual_minor": "1"
          },
          "external": {
            "status": "fail",
            "residual_minor": "1"
          }
        },
        "comparison": {
          "closing_difference_minor": "0"
        }
      }
    },
    {
      "id": "P09-item-cannot-hide-opening-gap",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-CLEAN",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "9300"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "13600"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "fail",
        "code": "OPENING_BALANCES_DIFFER",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0"
          }
        },
        "comparison": {
          "opening_difference_minor": "-700",
          "closing_difference_minor": "-700",
          "adjusted_closing_residual_minor": "0"
        }
      }
    },
    {
      "id": "P10-net-zero-unresolved-register",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-CLEAN",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "I-OUT-ITEM",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-OUT",
              "revision": "1",
              "sequence": "2",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          },
          {
            "item_id": "E-OUT-ITEM",
            "side": "external",
            "row_ref": {
              "source_id": "CEDAR-EXTERNAL",
              "row_id": "E-OUT",
              "revision": "1",
              "sequence": "2",
              "source_version_ref": "CLEAN-EXTERNAL-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "indeterminate",
        "code": "RECONCILING_ITEMS_REMAIN",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0"
          }
        },
        "comparison": {
          "internal_item_signed_minor": "-1200",
          "external_item_signed_minor": "-1200",
          "adjusted_closing_residual_minor": "0",
          "unresolved_item_count": "2"
        }
      }
    },
    {
      "id": "P11-zero-head-means-missing-control",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "0",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": []
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "indeterminate",
        "code": "EVIDENCE_INDETERMINATE",
        "bridges": {
          "internal": {
            "status": "indeterminate",
            "trace": []
          },
          "external": {
            "status": "pass",
            "residual_minor": "0"
          }
        },
        "control_evidence": {
          "internal": {
            "closing": {
              "code": "CONTROL_MISSING",
              "selected": null
            }
          }
        }
      }
    },
    {
      "id": "P12-no-control-visible-at-K",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-23T10:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-23T11:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "indeterminate",
        "code": "EVIDENCE_INDETERMINATE",
        "control_evidence": {
          "external": {
            "closing": {
              "code": "CONTROL_NOT_AVAILABLE",
              "selected": null
            }
          }
        }
      }
    },
    {
      "id": "P13-latest-withdrawal-does-not-revive-old-control",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "3",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "3",
                "supersedes_revision": "2",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-WITHDRAW",
                "action": "withdraw",
                "amount_minor": null
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "indeterminate",
        "code": "EVIDENCE_INDETERMINATE",
        "control_evidence": {
          "external": {
            "closing": {
              "code": "CONTROL_WITHDRAWN",
              "selected": {
                "revision": "3",
                "action": "withdraw",
                "amount_minor": null
              }
            }
          }
        }
      }
    },
    {
      "id": "P14-missing-unselected-control-tail",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T08:59:59.999Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "indeterminate",
        "code": "EVIDENCE_INDETERMINATE",
        "control_evidence": {
          "external": {
            "closing": {
              "code": "INCOMPLETE_CONTROL_HISTORY",
              "selected": null
            }
          }
        }
      }
    },
    {
      "id": "P15-control-observation-does-not-cover-K",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-22T08:59:59.999Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "indeterminate",
        "code": "EVIDENCE_INDETERMINATE",
        "control_evidence": {
          "external": {
            "closing": {
              "code": "KNOWLEDGE_BEYOND_CONTROL",
              "selected": null
            }
          }
        }
      }
    },
    {
      "id": "P16-complete-future-control-version-remains-hidden",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "3",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "3",
                "supersedes_revision": "2",
                "available_at": "2026-10-23T11:00:00.000Z",
                "source_version_ref": "FUTURE-SECRET-CONTROL",
                "action": "upsert",
                "amount_minor": "999"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "CLOSING_BALANCES_DIFFER",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0",
            "opening_minor": "10000",
            "inflow_minor": "6200",
            "outflow_minor": "1900",
            "net_movement_minor": "4300",
            "expected_closing_minor": "14300",
            "reported_closing_minor": "14300",
            "excluded_currency_count": "0"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0",
            "opening_minor": "10000",
            "inflow_minor": "6200",
            "outflow_minor": "1200",
            "net_movement_minor": "5000",
            "expected_closing_minor": "15000",
            "reported_closing_minor": "15000",
            "excluded_currency_count": "0"
          }
        },
        "control_evidence": {
          "external": {
            "closing": {
              "selected": {
                "revision": "2",
                "amount_minor": "15000"
              },
              "coverage": {
                "head_revision": "3",
                "visible_through_revision": "2"
              }
            }
          }
        }
      }
    },
    {
      "id": "P17-identical-control-version-duplicate",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "DUPLICATE_CONTROL_VERSION"
      }
    },
    {
      "id": "P18-changed-control-version-conflict",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15001"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "CONTROL_VERSION_CONFLICT"
      }
    },
    {
      "id": "P19-control-version-gap",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "indeterminate",
        "code": "EVIDENCE_INDETERMINATE",
        "control_evidence": {
          "external": {
            "closing": {
              "code": "INCOMPLETE_CONTROL_HISTORY"
            }
          }
        }
      }
    },
    {
      "id": "P20-impossible-control-predecessor",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "2",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_REVISION"
      }
    },
    {
      "id": "P21-control-boundary-mismatch",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-22T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "CONTROL_BOUNDARY_MISMATCH"
      }
    },
    {
      "id": "P22-available-basis-is-not-booked-basis",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "available-cash-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "UNSUPPORTED_BALANCE_BASIS"
      }
    },
    {
      "id": "P23-control-currency-mismatch",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "EUR",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "CONTROL_SCOPE_MISMATCH"
      }
    },
    {
      "id": "P24-missing-future-movement-tail",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T08:59:59.999Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "indeterminate",
        "code": "EVIDENCE_INDETERMINATE",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0"
          },
          "external": {
            "status": "indeterminate",
            "trace": []
          }
        },
        "source_evidence": {
          "external": {
            "code": "INCOMPLETE_SOURCE",
            "selected": null
          }
        }
      }
    },
    {
      "id": "P25-known-bridge-failure-dominates-other-source-gap",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14301"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "SIDE_BRIDGE_FAILED",
        "bridges": {
          "internal": {
            "status": "fail",
            "residual_minor": "1"
          },
          "external": {
            "status": "indeterminate"
          }
        }
      }
    },
    {
      "id": "P26-known-bridge-failure-dominates-other-control-gap",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14301"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "SIDE_BRIDGE_FAILED",
        "bridges": {
          "internal": {
            "status": "fail",
            "residual_minor": "1"
          },
          "external": {
            "status": "indeterminate"
          }
        }
      }
    },
    {
      "id": "P27-stale-item-version",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "2",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "indeterminate",
        "code": "EVIDENCE_INDETERMINATE",
        "comparison": {
          "internal_item_signed_minor": null,
          "adjusted_closing_residual_minor": null
        },
        "reconciling_items": [
          {
            "code": "STALE_RECONCILING_EVIDENCE",
            "signed_amount_minor": null
          }
        ]
      }
    },
    {
      "id": "P28-item-ref-does-not-belong-to-selected-side",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "external",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "indeterminate",
        "code": "EVIDENCE_INDETERMINATE",
        "reconciling_items": [
          {
            "code": "STALE_RECONCILING_EVIDENCE"
          }
        ]
      }
    },
    {
      "id": "P29-row-reuse",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          },
          {
            "item_id": "SECOND-SAME-ROW",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "rejected",
        "code": "RECONCILING_ROW_REUSED"
      }
    },
    {
      "id": "P30-free-balancing-amount-forbidden",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z",
            "amount_minor": "700"
          }
        ]
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_RECONCILING_ITEM"
      }
    },
    {
      "id": "P31-future-investigation-not-available",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-23T00:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "indeterminate",
        "code": "EVIDENCE_INDETERMINATE",
        "reconciling_items": [
          {
            "code": "RECONCILING_ITEM_NOT_AVAILABLE",
            "signed_amount_minor": null
          }
        ]
      }
    },
    {
      "id": "P32-investigation-cannot-predate-row-receipt",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-21T07:59:59.999Z"
          }
        ]
      },
      "expected": {
        "status": "rejected",
        "code": "ITEM_CLOCK_ORDER_VIOLATION"
      }
    },
    {
      "id": "P33-other-currency-counted-not-added",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "EUR",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "16200"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "CLOSING_BALANCES_DIFFER",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0",
            "net_movement_minor": "6200",
            "excluded_currency_count": "1"
          }
        },
        "comparison": {
          "closing_difference_minor": "-1900"
        }
      }
    },
    {
      "id": "P34-foreign-currency-item-is-not-USD-explanation",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "EUR",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "16200"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "external",
            "row_ref": {
              "source_id": "CEDAR-EXTERNAL",
              "row_id": "E-OUT",
              "revision": "2",
              "sequence": "5",
              "source_version_ref": "BANK-STATEMENT-V2"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "indeterminate",
        "code": "EVIDENCE_INDETERMINATE",
        "reconciling_items": [
          {
            "code": "RECONCILING_CURRENCY_MISMATCH"
          }
        ]
      }
    },
    {
      "id": "P35-negative-bank-asset-no-zero-floor",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-CLEAN",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "-10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "-5700"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "-10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "-5700"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "pass",
        "code": "BALANCE_PROOF_PASS",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0",
            "opening_minor": "-10000",
            "expected_closing_minor": "-5700"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0"
          }
        }
      }
    },
    {
      "id": "P36-zero-net-original-and-directed-reversal",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-CLEAN",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "2",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "2",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "0"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "0"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "0"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "0"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "pass",
        "code": "BALANCE_PROOF_PASS",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0",
            "inflow_minor": "1200",
            "outflow_minor": "1200",
            "net_movement_minor": "0",
            "expected_closing_minor": "0"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0"
          }
        }
      }
    },
    {
      "id": "P37-derived-total-exceeds-input-magnitude",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-CLEAN",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "SIDE_BRIDGE_FAILED",
        "bridges": {
          "internal": {
            "status": "fail",
            "expected_closing_minor": "1000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004299",
            "residual_minor": "-4300"
          },
          "external": {
            "status": "fail",
            "residual_minor": "-4300"
          }
        }
      }
    },
    {
      "id": "P38-huge-exact-movement-and-explained-gap",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "9007199254740993",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "9007199254740993",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "9007199254750293"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "9007199254750993"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "indeterminate",
        "code": "RECONCILING_ITEMS_REMAIN",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0",
            "net_movement_minor": "9007199254740293",
            "expected_closing_minor": "9007199254750293"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0",
            "net_movement_minor": "9007199254740993",
            "expected_closing_minor": "9007199254750993"
          }
        },
        "comparison": {
          "closing_difference_minor": "-700",
          "adjusted_closing_residual_minor": "0"
        }
      }
    },
    {
      "id": "P39-complete-empty-period-is-not-missing-control",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [],
      "external_groups": [],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "0",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "0",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "0"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "0"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "0"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "0"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "pass",
        "code": "BALANCE_PROOF_PASS",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0",
            "net_movement_minor": "0",
            "trace": []
          },
          "external": {
            "status": "pass",
            "residual_minor": "0"
          }
        }
      }
    },
    {
      "id": "P40-equal-net-distinct-histories",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-CLEAN",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1300",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "CLEAN-EXTERNAL-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "pass",
        "code": "BALANCE_PROOF_PASS",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0",
            "net_movement_minor": "4300"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0",
            "inflow_minor": "6300",
            "outflow_minor": "2000",
            "net_movement_minor": "4300"
          }
        }
      }
    },
    {
      "id": "P41-exclusive-end-booking-not-added",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "5",
              "row_id": "I-AT-EXCLUSIVE-END",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-21",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "5",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "CLOSING_BALANCES_DIFFER",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0",
            "opening_minor": "10000",
            "inflow_minor": "6200",
            "outflow_minor": "1900",
            "net_movement_minor": "4300",
            "expected_closing_minor": "14300",
            "reported_closing_minor": "14300",
            "excluded_currency_count": "0"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0",
            "opening_minor": "10000",
            "inflow_minor": "6200",
            "outflow_minor": "1200",
            "net_movement_minor": "5000",
            "expected_closing_minor": "15000",
            "reported_closing_minor": "15000",
            "excluded_currency_count": "0"
          }
        },
        "source_evidence": {
          "internal": {
            "selected": {
              "out_of_window_count": "1"
            }
          }
        }
      }
    },
    {
      "id": "P42-forward-value-date-does-not-change-booked-proof",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-12-31",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "fail",
        "code": "CLOSING_BALANCES_DIFFER",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0",
            "opening_minor": "10000",
            "inflow_minor": "6200",
            "outflow_minor": "1900",
            "net_movement_minor": "4300",
            "expected_closing_minor": "14300",
            "reported_closing_minor": "14300",
            "excluded_currency_count": "0"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0",
            "opening_minor": "10000",
            "inflow_minor": "6200",
            "outflow_minor": "1200",
            "net_movement_minor": "5000",
            "expected_closing_minor": "15000",
            "reported_closing_minor": "15000",
            "excluded_currency_count": "0"
          }
        }
      }
    },
    {
      "id": "P43-duplicate-movement-never-double-counted",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            },
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "DUPLICATE_EVENT"
      }
    },
    {
      "id": "P44-control-amount-minus-zero",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "-0"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_AMOUNT"
      }
    },
    {
      "id": "P44-control-amount-plus",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "+1"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_AMOUNT"
      }
    },
    {
      "id": "P44-control-amount-leading-zero",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "01"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_AMOUNT"
      }
    },
    {
      "id": "P44-control-amount-decimal",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "1.0"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_AMOUNT"
      }
    },
    {
      "id": "P44-control-amount-exponent",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "1e2"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_AMOUNT"
      }
    },
    {
      "id": "P44-control-amount-number",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": 1
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_AMOUNT"
      }
    },
    {
      "id": "P44-control-amount-bool",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": true
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_AMOUNT"
      }
    },
    {
      "id": "P44-control-amount-121digits",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "1111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_AMOUNT"
      }
    },
    {
      "id": "P45-control-unknown-field",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000",
                "extra": true
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_SCHEMA"
      }
    },
    {
      "id": "P46-control-head-unknown-field",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING",
              "extra": true
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_HEAD"
      }
    },
    {
      "id": "P47-query-unknown-field",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1",
        "extra": true
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_SCHEMA"
      }
    },
    {
      "id": "P48-control-source-side-binding",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "CONTROL_SCOPE_MISMATCH"
      }
    },
    {
      "id": "P49-control-receipt-before-boundary",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-20T23:59:59.999Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "CONTROL_CLOCK_ORDER_VIOLATION"
      }
    },
    {
      "id": "P50-control-invalid-timestamp",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z\u2028",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_TIMESTAMP"
      }
    },
    {
      "id": "P51-control-receipt-order-regression",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "CONTROL_CLOCK_ORDER_VIOLATION"
      }
    },
    {
      "id": "P52-consecutive-control-withdrawals",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "4",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "3",
                "supersedes_revision": "2",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "WITHDRAW-3",
                "action": "withdraw",
                "amount_minor": null
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "4",
                "supersedes_revision": "3",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "WITHDRAW-4",
                "action": "withdraw",
                "amount_minor": null
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_ACTION"
      }
    },
    {
      "id": "P53-item-reason-lone-surrogate",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "\ud800",
            "available_at": "2026-10-22T09:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_RECONCILING_ITEM"
      }
    },
    {
      "id": "P54-identical-item-duplicate",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          },
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "rejected",
        "code": "DUPLICATE_RECONCILING_ITEM"
      }
    },
    {
      "id": "P55-changed-item-conflict",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          },
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "1",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "Changed investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "rejected",
        "code": "RECONCILING_ITEM_CONFLICT"
      }
    },
    {
      "id": "P56-known-failure-with-stale-item",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14301"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": [
          {
            "item_id": "INVESTIGATED-700",
            "side": "internal",
            "row_ref": {
              "source_id": "CEDAR-INTERNAL",
              "row_id": "I-MISSING",
              "revision": "2",
              "sequence": "4",
              "source_version_ref": "LEDGER-EXPORT-V1"
            },
            "reason": "External evidence withdrawn; internal-only outflow remains under investigation",
            "available_at": "2026-10-22T09:00:00.000Z"
          }
        ]
      },
      "expected": {
        "status": "fail",
        "code": "SIDE_BRIDGE_FAILED",
        "bridges": {
          "internal": {
            "status": "fail",
            "residual_minor": "1"
          }
        },
        "reconciling_items": [
          {
            "code": "STALE_RECONCILING_EVIDENCE"
          }
        ]
      }
    },
    {
      "id": "P57-invalid-future-control-still-rejects",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "I-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": null,
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "4",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14300"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "3",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "3",
                "supersedes_revision": "2",
                "available_at": "2026-10-23T11:00:00.000Z",
                "source_version_ref": "FUTURE-INVALID",
                "action": "upsert",
                "amount_minor": "1111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "rejected",
        "code": "INVALID_CONTROL_AMOUNT"
      }
    },
    {
      "id": "P58-forged-trusted-head-and-control-outside-boundary",
      "query": {
        "schema_version": "d30-balance-proof-v1",
        "ledger_id": "CB-GENERAL",
        "entity_id": "CB-A",
        "reconciliation_account_id": "CEDAR-SETTLEMENT",
        "period_start": "2026-10-20",
        "period_end": "2026-10-21",
        "knowledge_cutoff": "2026-10-22T09:00:00.000Z",
        "reference_policy": "BYTE_EXACT_ASCII_V1",
        "currency": "USD",
        "basis": "booked-cash-asset-utc-v1"
      },
      "internal_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "INT-INITIAL",
          "source_id": "CEDAR-INTERNAL",
          "available_at": "2026-10-21T08:00:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "I-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "I-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "I-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "LEDGER-EXPORT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            }
          ]
        }
      ],
      "external_groups": [
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-INITIAL",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-21T08:01:00.000Z",
          "events": [
            {
              "sequence": "1",
              "row_id": "E-FUND",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "5000",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-001"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "2",
              "row_id": "E-OUT",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1100",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "3",
              "row_id": "E-REV",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "inflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "REV-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": true
              }
            },
            {
              "sequence": "4",
              "row_id": "E-MISSING",
              "revision": "1",
              "supersedes_revision": null,
              "source_version_ref": "BANK-STATEMENT-V1",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "700",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "NOTPROVIDED"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            }
          ]
        },
        {
          "schema_version": "d30-reconciliation-group-v1",
          "group_id": "EXT-REVISION",
          "source_id": "CEDAR-EXTERNAL",
          "available_at": "2026-10-22T09:00:00.000Z",
          "events": [
            {
              "sequence": "5",
              "row_id": "E-OUT",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "upsert",
              "movement": {
                "booking_status": "booked",
                "booking_date": "2026-10-20",
                "value_date": "2026-10-20",
                "currency": "USD",
                "direction": "outflow",
                "amount_minor": "1200",
                "reference": {
                  "namespace": "CEDAR-PAYMENT",
                  "value": "PAY-002"
                },
                "description": "Synthetic settlement",
                "is_reversal": false
              }
            },
            {
              "sequence": "6",
              "row_id": "E-MISSING",
              "revision": "2",
              "supersedes_revision": "1",
              "source_version_ref": "BANK-STATEMENT-V2",
              "action": "withdraw",
              "movement": null
            }
          ]
        }
      ],
      "context": {
        "internal_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-INTERNAL",
          "side": "internal",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "3",
          "receipt_ref": "HEAD-INTERNAL"
        },
        "external_head": {
          "schema_version": "d30-reconciliation-head-v1",
          "source_id": "CEDAR-EXTERNAL",
          "side": "external",
          "ledger_id": "CB-GENERAL",
          "entity_id": "CB-A",
          "reconciliation_account_id": "CEDAR-SETTLEMENT",
          "coverage_start": "2026-10-19",
          "coverage_end": "2026-10-23",
          "observed_at": "2026-10-23T12:00:00.000Z",
          "head_sequence": "6",
          "receipt_ref": "HEAD-EXTERNAL"
        },
        "internal_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-OPENING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "INTERNAL-CLOSING",
              "source_id": "CEDAR-INTERNAL",
              "side": "internal",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-INTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "INTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:00:00.000Z",
                "source_version_ref": "DOC-INTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "external_controls": {
          "opening": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-OPENING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "opening",
              "boundary_at": "2026-10-20T00:00:00.000Z",
              "head_revision": "1",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-OPENING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-OPENING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-OPENING-V1",
                "action": "upsert",
                "amount_minor": "10000"
              }
            ]
          },
          "closing": {
            "head": {
              "schema_version": "d30-balance-control-head-v1",
              "control_id": "EXTERNAL-CLOSING",
              "source_id": "CEDAR-EXTERNAL",
              "side": "external",
              "ledger_id": "CB-GENERAL",
              "entity_id": "CB-A",
              "reconciliation_account_id": "CEDAR-SETTLEMENT",
              "currency": "USD",
              "basis": "booked-cash-asset-utc-v1",
              "role": "closing",
              "boundary_at": "2026-10-21T00:00:00.000Z",
              "head_revision": "2",
              "observed_at": "2026-10-23T12:00:00.000Z",
              "receipt_ref": "HEAD-EXTERNAL-CLOSING"
            },
            "versions": [
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "1",
                "supersedes_revision": null,
                "available_at": "2026-10-21T08:01:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V1",
                "action": "upsert",
                "amount_minor": "14400"
              },
              {
                "schema_version": "d30-balance-control-v1",
                "control_id": "EXTERNAL-CLOSING",
                "revision": "2",
                "supersedes_revision": "1",
                "available_at": "2026-10-22T09:00:00.000Z",
                "source_version_ref": "DOC-EXTERNAL-CLOSING-V2",
                "action": "upsert",
                "amount_minor": "15000"
              }
            ]
          }
        },
        "reconciling_items": []
      },
      "expected": {
        "status": "pass",
        "code": "BALANCE_PROOF_PASS",
        "bridges": {
          "internal": {
            "status": "pass",
            "residual_minor": "0",
            "net_movement_minor": "5000"
          },
          "external": {
            "status": "pass",
            "residual_minor": "0"
          }
        },
        "comparison": {
          "closing_difference_minor": "0"
        }
      },
      "trust_boundary_note": "Adversarial host supplied a forged reduced head and matching closing control. Arithmetic accepts these internally consistent trusted claims; this is outside source authentication and must not be presented as proof of real-world completeness."
    }
  ]
}
