Items for the sister.systems pds
README.md

sdb-atproto #

Saftey deposit boxes on ATproto.

Items are stored as systems.sister.item records in your atproto repository. systems.sister.lootbox records power TF2-style crates, and systems.sister.gift records power cross-PDS social gifting. The systems.sister.recipe lexicon is reserved for future crafting.

Features #

  • Create, list, show, edit, and delete item records on your PDS.
  • TF2-style trimmed rarity set: common, uncommon, rare, epic, legendary, unusual.
  • TF2-style crates: create a crate from weighted template items and open it to receive one.
  • Helper crates that force a specific unusual effect on open.
  • Optional item icons uploaded as atproto blobs.
  • Equip/hide items; a equipped shovel lets owners hide items from public view, while glasses unlock inventory search.
  • Session caching so commands do not log in every time.
  • Config stored locally in ~/.config/sdb-atproto/config.json.
  • Cross-PDS gifting: sdb gift creates a public gift record and deletes the original item; the recipient runs sdb claim to mint a copy in their own repo.
  • Public web UI at https://items.sister.systems for browsing items, atproto OAuth login, and a mailbox for sending, claiming, and auto-returning gifts.
  • Custom lexicons published as com.atproto.lexicon.schema records.
  • Reserved lexicon for future crafting recipes.

Requirements #

  • Node.js 20+
  • A self-hosted atproto PDS. This project is deployed against https://pds.sister.systems.

Development and testing #

Run the test suite:

nix-shell -p nodejs --run "npm test"

Build the TypeScript project:

nix-shell -p nodejs --run "npm run build"

Both must pass before committing. The project uses Node's built-in test runner, tsx for development, and tsc for compilation.

Release and deploy #

From inside nix-shell:

npm run release -- "feat: describe the change"

This runs checks, tests, build, commit, and push. Pushing to main on Tangled triggers the auto-deploy webhook.

Use --wait to block until the site is back up:

npm run release -- --wait "feat: describe the change"

Other useful commands:

  • npm run deploy — manually trigger auto-deploy via the signed webhook.
  • npm run deploy:logs — tail the deploy log on the VPS.
  • npm run deploy:status — show container status and site health.
  • npm run deploy:legacy — emergency SSH/rsync fallback.

Web UI #

https://items.sister.systems

https://items.sister.systems/u/<handle-or-did> displays public item records for any identifier, defaulting to vault.pds.sister.systems. The viewer shows equipped items with active unusual effects, summed stats, a sortable inventory, and a mail panel for gifts. Search is only available when the owner has glasses equipped.

Lexicons #

The canonical record types live under lexicons/systems/sister/:

  • systems.sister.item
  • systems.sister.lootbox
  • systems.sister.gift
  • systems.sister.recipe

They are published as com.atproto.lexicon.schema records on vault.pds.sister.systems and can be republished with npm run lexicon:publish.

Development shell #

A shell.nix is provided for a reproducible Node 22 environment:

nix-shell

Security notes #

  • Credentials and session tokens are stored in ~/.config/sdb-atproto/ with restricted permissions (0o700 for the directory, 0o600 for files).
  • The deploy key for Tangled is kept at ~/.ssh/sdb_atproto_deploy.
  • See SECURITY.md for the security policy and reporting process.

License #

The spells herein are offered freely to any who would cast them:

  • Brew them for profit or pleasure, under moon or sun.
  • Fork, transmute, redistribute, or bind them into stranger works.
  • Hoard them, sell them, or leave them to gather dust on the shelf.

No warranty is provided. See https://www.wtfpl.net/about/ for the full license text.