Initial import of verae-tree-node from zapier monorepo

This commit is contained in:
George Lambert 2026-09-11 13:51:21 -04:00
commit b9184c9086
6 changed files with 169 additions and 0 deletions

13
NATS.md Normal file
View file

@ -0,0 +1,13 @@
# NATS — verae-tree-node
Tree nodes are WORM archives that store **Merkle leaf proofs**. They listen on the same archive subjects so a leaf that was never itemized on the main chain can still be found.
Zapier never connects here. Middleware aggregator broadcasts; a tree node that does not hold the leaf stays silent.
| Direction | Address | From / to | Body |
|-----------|---------|-----------|------|
| IN | `verae.archive.put` | batch splitter / merkle builder | `{ sha256, tenantId, kind: "tree", record: { merkleRoot, proof, leafIndex, chainSealJobId }, traceId }` |
| IN | `verae.archive.query` | aggregator (broadcast, **no queue group**) | `{ correlationId, sha256, tenantId, kinds: ["tree", …], traceId }` |
| OUT | `verae.archive.reply.<correlationId>` | aggregator | `{ archiveId, sha256, records[], traceId }` **only if bloom.mightHave(sha256)** |
`record.merkleRoot` is the hash sealed on the main Verae chain. `proof` lets a verifier recompute the root from this leaf.