Eight methods — three for writing (upload, uploadBundle, registerOnly),
three for reading (list, getStore, fetch), two for sharing checks
(listViewers, canView).
SHA-256 → optional SEAL encrypt → publisher PUT → register_blob PTB. One
wallet signature (the PTB). Throws RegistrationError if the bytes upload
succeeds but the on-chain step fails — pass the .checkpoint to
registerOnly to retry.
const result = await client.blob.upload({ data: bytes, fileName: "report.pdf", contentType: "application/pdf", epochs: 26, senderAddress: "0x…", subscriptionId: "0x…", signer, blobStoreId: "0x…", // omit to create one encrypted: false, // true ⇒ SEAL (requires blobStoreId) initialShareViewers: ["0x…"], // bundled into the same PTB onProgress: (e) => console.log(e.stage, e.percent),});
client.blob.list({ owner: string; limit?: number }): Promise<BlobRef[]>
Walks the on-chain BlobStore.blobs Table, BCS-decodes each BlobRef,
returns newest-first. Pass limit to early-exit pagination once enough
entries are collected.
Cheap summary call — returns just the BlobStore id, total bytes, total blobs,
and viewer allowlist. No per-blob Table walk. Throws BlobStoreNotFoundError
if the user has never created a BlobStore.
GETs the blob bytes from a Walrus aggregator with retry + per-call timeout.
Returned bytes are exactly as uploaded — still encrypted if the blob was
registered as encrypted (use client.crypto.decrypt after).
Read-side mirrors of the on-chain viewer ACL. listViewers returns the
allowlisted addresses (excludes the owner — that's implicit). canView is
true when address is the owner or in the allowlist — same predicate the
seal_approve Move function runs.
Per-blob shares
This is the store-level ACL. Per-blob shares (add_blob_share calls,
marker-keyed) are a separate concept — see the
Sharing guide for the full model.