@gonkalabs/blocks-cli
v0.1.1
Published
Command-line interface for Gonka Blocks — package any project as a block, run it on the Gonka inference network, and stream results back.
Downloads
48
Maintainers
Readme
@gonkalabs/blocks-cli
Command-line interface for Gonka Blocks — package any project as a block, run it on the Gonka inference network, and stream results back to your terminal.
gonkablocks magic # interactive walkthrough
gonkablocks deploy ./mybot # ship a block
gonkablocks run alice/translate text="hello"Install
One-line installer (recommended):
curl -fsSL https://blocks.gonka.gg/install.sh | shOr with npm:
npm install -g @gonkalabs/blocks-cliThen verify:
gonkablocks --versionTwo binaries are installed: gonkablocks (full name) and gbk (short alias).
They are identical.
Requires Node.js 20 or later.
Quickstart
# 1. Connect once. Opens your browser, mints a long-lived API key,
# saves it to ~/.gonkablocks/config.json.
gonkablocks connect
# 2. Run any published block.
gonkablocks run admin/qwen-quick text="hello world"
# 3. Or wrap your own script as a Run, with the inference proxy
# auto-injected into OPENAI_API_KEY / OPENAI_BASE_URL.
gonkablocks exec --title "my agent" -- python my_agent.pyTo ship your own block:
gonkablocks init mybot # scaffold manifest.yaml + Dockerfile + main.py
gonkablocks deploy ./mybot # upload, build, publish
gonkablocks run me/mybot # invoke itCommands
| Command | What it does |
| --- | --- |
| gonkablocks magic | Interactive setup: connect + scaffold + run/deploy |
| gonkablocks connect | Mint a long-lived API key (one-shot login) |
| gonkablocks login | Classic browser cookie session |
| gonkablocks env | Print shell exports for the active key (source <(gonkablocks env)) |
| gonkablocks init [dir] | Scaffold a blank block |
| gonkablocks deploy [dir] | Auto-scaffold (if needed) + upload + build + publish |
| gonkablocks run a/b [k=v ...] | Run a published block by <author>/<slug> |
| gonkablocks runs | List your recent runs |
| gonkablocks exec -- <cmd> | Wrap a local subprocess as an observed cloud Run |
| gonkablocks proxy [--port N] | Local OpenAI-compatible HTTP forwarder |
Run any command with --help for full options.
How runs are billed
Inference is metered against the live on-chain price the Gonka validator network
charges, converted to USD via the GONKA/USD exchange rate. Today that's about
$0.00044 per 1M tokens for Qwen3-235B and Kimi K2.6 — roughly 100× cheaper
than the big clouds. Your active per-block spend cap (set in manifest.yaml)
prevents runaway costs.
Anonymous users get 10 free runs per week without any login.
Documentation
- Guides: https://blocks.gonka.gg/guides
- Block manifest reference: https://blocks.gonka.gg/docs
- Discover blocks & models: https://blocks.gonka.gg/library
License
MIT — see LICENSE.
