Waldrop · SDK Documentation

Introduction

TypeScript SDK for uploading to Walrus, registering blobs on Sui, and reading them back — without depending on the Waldrop dapp's backend.

What's in this SDK

The SDK is intentionally narrow: it wraps the Walrus publisher / aggregator HTTP API and the Waldrop Sui Move contract. Nothing else. If a feature requires the dapp's Next.js backend (transform engine, cloud connectors, JWT-authed publisher), it lives in the dapp — not here.

01
Upload

Single blob, multi-file tar bundle, or resume a half-finished upload.

02
Encrypt

SEAL threshold encryption scoped to a BlobStore. No wallet signature needed for encryption itself.

03
Read

List, fetch, and decrypt blobs registered through Waldrop on Sui.

04
Cost

Forecast Walrus storage cost in WAL/FROST before you upload. Reads live pricing from the on-chain System object.

The one signature

Across the whole upload pipeline — SHA-256, SEAL encryption, publisher PUT, on-chain registration — the wallet only signs once: the register_blob transaction at the very end.

// SHA-256        ← pure compute, no signature
// SEAL encrypt   ← public key-server data, no signature
// publisher PUT  ← HTTP, no signature
// register_blob  ← THE one signature (the keypair signs the PTB)
Decryption is different

Reading an encrypted blob does require a wallet signature — SEAL needs a session key. That's at read time, not upload time.

Install

npm install @waldrop/sdk @mysten/sui
# Optional — only needed for encrypt / decrypt
npm install @mysten/seal

@mysten/sui is a peer dependency. @mysten/seal is lazy-loaded — SealNotInstalledError is thrown if you call encrypt/decrypt without it.

Five lines to your first upload

import { WaldropClient } from "@waldrop/sdk";

const waldrop = new WaldropClient({ network: "testnet" });
const result = await waldrop.blob.upload({
  data: new TextEncoder().encode("hello waldrop"),
  fileName: "hello.txt",
  contentType: "text/plain",
  epochs: 2,
  senderAddress,
  subscriptionId,
  signer,
});

console.log(result.blobId);

Where to go next

→ Install

Add the SDK to your project + grab a testnet wallet.

→ Your first upload

A 5-minute walkthrough that lands a real blob on testnet Walrus.

→ API reference

Every method, argument, and return type — generated from the source.

→ Recipes

Seven copy-pasteable scenarios — plaintext, encrypted, bundle, resume, cost, share, list+fetch.

Edit this page on GitHub ↗
Waldrop · 2026cryptokarigar