Combined Payment: One Action, Two Allocations

A single wire clears two expected invoice payments — attributed exactly

The scenario

Bluefield Grocers LLC pays Meridian Supply Co one wire of 3,500 USD covering two outstanding invoices: 1,250.75 and 2,249.25. One payment, two obligations.

How FORAY models it

The Action settles both Anticipations and attributes the amount across them in its allocations (F21). Each entry names its target (ref, ref_type), an amount, and a currency; entry amounts must equal the settled amount (F9) exactly, compared as decimal values — 1,250.75 + 2,249.25 = 3,500, no float tolerance, no rounding window.

What to observe in the record

  • The Action carries all three reference arrays (F22/F23/F24); the accrual references array is present and empty.
  • Every reference resolves to an element inside this record — the validator rejects dangling references.
  • Allocation entries carry exactly their defined keys; anything else would be residue outside F25 and fail validation.

Wire 4.2 record

This record is a teaching example, emitted by the FORAY generator (template multi-allocation-settlement) — not hand-written. No blockchain anchoring has occurred or is implied; anchor-related fields are placeholders. Parties, amounts, and dates are illustrative. Wire keys are catalog codes (F-codes); the readable names used in the prose above are the implementer register, which never appears in hashed bytes.

{
  "F1": "AR_2026_Q3_COMBINED_RECEIPT_031",
  "F2": "AR_2026_Q3_COMBINED_RECEIPT_031",
  "F3": "Meridian Supply Co",
  "F7": 3500,
  "F8": "USD",
  "F26": "combined_receivables_settlement",
  "schema_version": "4.2",
  "timestamp": "2026-07-24T16:30:00Z",
  "arrangements": [
    {
      "F4": "supply_contract",
      "F5": [
        {
          "jurisdiction": "US-TX",
          "name": "Meridian Supply Co",
          "role": "Supplier"
        },
        {
          "jurisdiction": "US-OK",
          "name": "Bluefield Grocers LLC",
          "role": "Buyer"
        }
      ],
      "F11": "2026-05-01T00:00:00Z",
      "F29": [],
      "id": "ARR_SUPPLY_K88"
    }
  ],
  "accruals": [],
  "anticipations": [
    {
      "F4": "expected_invoice_payment",
      "F10": 1250.75,
      "F22": [
        "ARR_SUPPLY_K88"
      ],
      "F23": [],
      "F27": "2026-07-20T00:00:00Z",
      "F28": 0.96,
      "id": "ANT_INV_5521"
    },
    {
      "F4": "expected_invoice_payment",
      "F10": 2249.25,
      "F22": [
        "ARR_SUPPLY_K88"
      ],
      "F23": [],
      "F27": "2026-07-27T00:00:00Z",
      "F28": 0.96,
      "id": "ANT_INV_5540"
    }
  ],
  "actions": [
    {
      "F4": "combined_payment_received",
      "F6": "Bluefield Grocers LLC",
      "F9": 3500,
      "F12": "2026-07-24T16:10:00Z",
      "F15": "completed",
      "F16": "wire",
      "F21": [
        {
          "allocation_type": "full",
          "amount": 1250.75,
          "currency": "USD",
          "ref": "ANT_INV_5521",
          "ref_type": "anticipation"
        },
        {
          "allocation_type": "full",
          "amount": 2249.25,
          "currency": "USD",
          "ref": "ANT_INV_5540",
          "ref_type": "anticipation"
        }
      ],
      "F22": [
        "ARR_SUPPLY_K88"
      ],
      "F23": [],
      "F24": [
        "ANT_INV_5521",
        "ANT_INV_5540"
      ],
      "id": "ACT_COMBINED_WIRE_031"
    }
  ],
  "component_hashes": {
    "actions": "sha256:PLACEHOLDER",
    "anticipations": "sha256:PLACEHOLDER",
    "arrangements": "sha256:PLACEHOLDER"
  },
  "merkle_root": "sha256:PLACEHOLDER",
  "blockchain_anchor": {
    "anchored_at": null,
    "block_height": null,
    "confirmation_time_ms": null,
    "kaspa_tx_id": null
  }
}

Canonical form — the hashed bytes

The canonical byte form is a single line: F-coded members in ascending numeric order, envelope members in their ruled enumeration, one legal spelling per number. The hash below is computed over exactly the bytes shown — copy the line into any SHA-256 tool to reproduce it.

{"F1":"AR_2026_Q3_COMBINED_RECEIPT_031","F2":"AR_2026_Q3_COMBINED_RECEIPT_031","F3":"Meridian Supply Co","F7":3500,"F8":"USD","F26":"combined_receivables_settlement","schema_version":"4.2","timestamp":"2026-07-24T16:30:00Z","arrangements":[{"F4":"supply_contract","F5":[{"jurisdiction":"US-TX","name":"Meridian Supply Co","role":"Supplier"},{"jurisdiction":"US-OK","name":"Bluefield Grocers LLC","role":"Buyer"}],"F11":"2026-05-01T00:00:00Z","F29":[],"id":"ARR_SUPPLY_K88"}],"accruals":[],"anticipations":[{"F4":"expected_invoice_payment","F10":1250.75,"F22":["ARR_SUPPLY_K88"],"F23":[],"F27":"2026-07-20T00:00:00Z","F28":0.96,"id":"ANT_INV_5521"},{"F4":"expected_invoice_payment","F10":2249.25,"F22":["ARR_SUPPLY_K88"],"F23":[],"F27":"2026-07-27T00:00:00Z","F28":0.96,"id":"ANT_INV_5540"}],"actions":[{"F4":"combined_payment_received","F6":"Bluefield Grocers LLC","F9":3500,"F12":"2026-07-24T16:10:00Z","F15":"completed","F16":"wire","F21":[{"allocation_type":"full","amount":1250.75,"currency":"USD","ref":"ANT_INV_5521","ref_type":"anticipation"},{"allocation_type":"full","amount":2249.25,"currency":"USD","ref":"ANT_INV_5540","ref_type":"anticipation"}],"F22":["ARR_SUPPLY_K88"],"F23":[],"F24":["ANT_INV_5521","ANT_INV_5540"],"id":"ACT_COMBINED_WIRE_031"}],"component_hashes":{"actions":"sha256:PLACEHOLDER","anticipations":"sha256:PLACEHOLDER","arrangements":"sha256:PLACEHOLDER"},"merkle_root":"sha256:PLACEHOLDER","blockchain_anchor":{"anchored_at":null,"block_height":null,"confirmation_time_ms":null,"kaspa_tx_id":null}}

Canonical-bytes SHA-256: 3eb8c1dfca81dd5ea33dafb64ae9e8f6c5e6c656bd45ecc690ee9335d240a917

Validated against the live validator (POST /api/validate-foray): 0 errors, 0 warnings.