Skip to content

PieceCIDInput

PieceCIDInput = PieceCID | CID | string | Hex | Uint8Array

Defined in: packages/synapse-core/src/piece/parse.ts:21

Inputs accepted by from and tryFrom.

  • PieceCID: returned as-is.
  • CID: validated and upgraded.
  • string: parsed as CID text, then validated.
  • Hex / 0x...: decoded as full CID bytes (e.g. PDPVerifier contract returns).
  • Uint8Array: decoded as full CID bytes.