Import
import { CuidSeed } from "@typed/id";Signatures
export type CuidSeed = {
readonly timestamp: number;
readonly counter: number;
readonly random: Uint8Array & {
readonly length: 32;
};
readonly fingerprint: string;
};Why
Keeping time, sequence, entropy, and caller fingerprint explicit makes generator identity rules testable and reviewable.
Ownership and lifetime
This data acquires no resources; callers own the random byte array and state services produce fresh seeds.
Property: counter
Process-local sequence value for this seed. Inherits the seed’s resource-free lifetime.
Property: fingerprint
Caller-derived discriminator captured by the CuidState instance.
Property: random
Fresh 32-byte entropy buffer owned by this seed’s consumer.
Property: timestamp
Millisecond timestamp sampled for this seed. Inherits the seed’s resource-free lifetime.
Examples
import type { CuidSeed } from "@typed/id/Cuid"
const seed: CuidSeed = { timestamp: 0, counter: 0, random: new Uint8Array(32) as CuidSeed["random"], fingerprint: "test" }Other public imports
These import paths expose the same declaration. Each page retains its own public name and signature.