MerkleOperation - handles Merkle tree operations and on-chain storage

This class provides utilities for:

  • Generating Merkle trees from event data
  • Creating and verifying proofs
  • Splitting large data into chunks
  • Inscribing data on-chain via memo transactions

For on-chain operations, you can provide either:

  • A Solana Connection + Signer for real transaction signing
  • Just use SynapseClient (will require pre-signed transactions)

Constructors

Methods

  • Batch verify multiple Merkle proofs

    Parameters

    • proofs: {
          leaf: string;
          proof: string[];
          root: string;
      }[]

      Array of proof objects to verify

    Returns boolean[]

    Array of verification results