Use a module from the CLI
Rust (rustup) and git.
cargo install --locked --git https://knotless.dev/johnandersen777.bsky.social/atlibs --rev 53d9384 atlibs
atlibs help | head -1
usage: atlibs <command> ...
Add and run
atlibs add bobvmbuilder.bsky.social/hello
atlibs run hello count '{"did":"did:plc:ocnuqjlzgohypj3zoznermms","collection":"com.fedfork.exec.wasm.module"}'
added hello (bobvmbuilder.bsky.social/hello) pin …
…
"result": {
"collection": "com.fedfork.exec.wasm.module",
"records": …
},
atlibs add writes atlibs.lock.json and modules/hello.{wasm,json}. No entry lists the entries:
atlibs run hello || true
hello entries: count
Serve
atlibs serve hello --port 8787 &
curl -s -X POST localhost:8787/run/count -H 'content-type: application/json' \
-d '{"did":"did:plc:ocnuqjlzgohypj3zoznermms","collection":"com.fedfork.exec.wasm.module"}' | jq -c .result.collection
"com.fedfork.exec.wasm.module"
http://127.0.0.1:8787/ has a form per entry.
As your account
atlibs login you.bsky.social
atlibs add bobvmbuilder.bsky.social/statusphere
atlibs run statusphere set_status '{"status":"🦋"}' --as you.bsky.social
A run makes only the calls its module's session record allows. Every command: CLI.