Header menu logo FSharp.ATProto

CidBinary Module

Binary CID operations: parse, construct, compute. Supports CIDv1 with dag-cbor (0x71) or raw (0x55) codec and SHA-256 hash.

Functions and values

Function or value Description

compute data

Full Usage: compute data

Parameters:
    data : byte[]

Returns: Cid

Compute a CIDv1 (dag-cbor + SHA-256) from raw data bytes.

data : byte[]
Returns: Cid

fromBytes data

Full Usage: fromBytes data

Parameters:
    data : byte[]

Returns: Result<Cid, string>

Parse raw binary bytes as a CID, validating structure.

data : byte[]
Returns: Result<Cid, string>

toBytes cid

Full Usage: toBytes cid

Parameters:
Returns: byte[]

Convert a CID string to its raw binary representation.

cid : Cid
Returns: byte[]

Type something to start searching.