Skip to content

Repository files navigation

Bitcoin PIR — Playground

The developer-facing site for Bitcoin PIR. Three surfaces, one app:

Surface Path Purpose
SDK playground /playground Paste an address, run a real query against the live server, get the exact TypeScript code your wallet would write.
Wire explorer /explorer Inspect every WebSocket frame and verify the four privacy invariants hold on your traffic.
API reference /docs Integration guides, SDK reference, protocol spec, privacy guarantees, attestation.

Built for wallet developers integrating PIR into Bitcoin wallets.

Quick start

npm install
npm run sync-vendor   # copy WASM + OnionPIR TS client from the main repo
npm run dev           # http://localhost:3000

The sync-vendor script copies:

  • pir-sdk-wasm/pkg/ → vendor/pir-sdk-wasm/ (DPF + HarmonyPIR clients)
  • web/src/onionpir_client.ts + transitive deps → vendor/bitcoinpir-web/ (OnionPIR client is hand-rolled TS because SEAL doesn't compile to wasm32)

The vendored snapshot is checked in. Re-run sync-vendor after upstream changes and commit the diff.

Live servers

  • wss://weikeng1.bitcoinpir.org — hint server (Hetzner, no SEV)
  • wss://bitcoin-pir-weikeng-laptop.chenweikeng.com — query server (MacBook, no TEE)
  • wss://weikeng2.bitcoinpir.org — Direct ORAM (VPSBG, AMD Milan SEV-SNP, since 2026-10-03)

See content/docs/operations/endpoints.mdx (or the deployed Live endpoints page) for the hint/query split.

Repo layout

app/                      Next.js App Router pages
  playground/             SDK playground (single-address query demo)
  explorer/               Wire explorer (per-frame WebSocket capture)
  docs/                   API reference (MDX, dynamic-route)
components/               Shared React components
content/docs/             MDX sources for the docs site
lib/                      Shared helpers (WASM loader, endpoints, constants)
vendor/
  pir-sdk-wasm/           Vendored wasm-pack output of pir-sdk-wasm
  bitcoinpir-web/         Vendored OnionPIR TS client + its TS deps
scripts/
  sync-vendor.sh          Resync the vendor/ tree from the main repo

See CLAUDE.md for the full project memory: deployment topology, vendor convention, privacy-invariant matrix, server pins, build commands, and open follow-ups.

License

MIT. See LICENSE.

The vendored WASM and TS sources are dual-licensed MIT OR Apache-2.0; this repo re-distributes them under MIT.

About

No description, website, or topics provided.

Resources

Contributing

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages