Connect any project or AI agent to the HONE chain — AI inference, git hosting, storage, and a token balance — all from one sovereign account.
WalletInference APIGit hostingStorageRust SDKAgent-readable · Follow in order
For AI agents
Read this before running anything
If you are an AI agent integrating a project with HONE, follow this section exactly. It gives you the decision logic, expected outputs, and failure branches for every step. The detailed commands are in the sections below — come back here first.
Decision tree — run once per project
## STEP A — Check for existing wallet (ALWAYS do this first)
ls ~/.hone/wallet.json 2>/dev/null && echo WALLET_EXISTS
ls .hone/wallet.env 2>/dev/null && echo WALLET_EXISTS
echo $HONE_ACCOUNT
# IF any of the above prints a value → wallet exists. Jump to STEP E.
# IF nothing prints → no wallet. Continue to STEP B.
## STEP B — Install CLI (skip if `hone --version` already works)
curl -fsSL https://honemesh.net/install | bash
hone --version
# Expected: hone X.Y.Z
## STEP C — Create account (only if STEP A found nothing)
hone wallet create --account <choose-a-username>
# Expected: mnemonic printed once. Write it down. It is never stored.
# Save the output — you cannot recover it later.
## STEP D — Register signing key (only after STEP C)
hone key generate
hone key register --account <username> --role posting
# Expected: {"status":"ok"} or similar. Key saved to ~/.hone/key.json.
## STEP E — Check balance
curl https://honemesh.net/api/balance/<username>
# Expected: {"balance":10.0,"hunits":1000000000,...}
# IF balance is 0 → run STEP F. Otherwise skip to STEP G.
## STEP F — Claim faucet (only if balance is 0)
hone faucet claim <username>
# Expected: {"status":"ok","amount":10,...}
# Gives 10 HONE = 1,000,000,000 hunits ≈ 100,000 inference calls.
## STEP G — Generate API key (skip if HONE_API_KEY already set)
grep HONE_API_KEY .hone/wallet.env 2>/dev/null
# IF printed a value → already done. Skip to STEP H.
hone wallet api-key-gen --mnemonic "word1 word2 ... word12"
echo '.hone/wallet.env' >> .gitignore
# Expected: .hone/wallet.env written with HONE_ACCOUNT and HONE_API_KEY.
## STEP H — Export env vars
export $(grep -v '^#' .hone/wallet.env | xargs)
# Required before making any API call. Verify:
echo $HONE_ACCOUNT $HONE_API_KEY
# Expected: <username> <64-char hex>
## STEP I — Verify with a test inference call
curl -X POST https://honemesh.net/v1/chat/completions \
-H "Authorization: Bearer $HONE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"messages":[{"role":"user","content":"ping"}],"model":"dolphin-llama3"}'
# Expected: {"choices":[{"message":{"content":"..."}}],"usage":{"fee_hunits":...}}
# 401 → API key wrong. Re-run STEP G.
# 402 → Balance too low. Re-run STEP F then retry.
# 503 → No miner online. Try model "llama3" or "mistral".
Rules for agents
Rule
Reason
Never create a wallet without checking first
Creating a second wallet overwrites access to the first — tokens are unrecoverable
Never hardcode HONE_API_URL
Always read from env — the URL changes between testnet and mainnet
On 402, claim faucet once then retry
Do not retry more than once — multiple faucet claims in rapid succession are rate-limited
Never commit .hone/wallet.env
Contains live signing keys — add to .gitignore immediately after creation
HONE_API_URL defaults to https://honemesh.net
Override to http://localhost:4242 to use a local node instead
One-time setup
Seven steps to your first inference call
From zero to a working account, API key, and first call.
Do not create a new wallet if one already exists. You will lose access to your existing account and tokens.
# Any of these means you already have a wallet:
ls ~/.hone/wallet.json 2>/dev/null && echo EXISTS
ls .hone/wallet.env 2>/dev/null && echo EXISTS
echo $HONE_ACCOUNT
If a wallet exists, skip to step 5.
3
Create your account (only if none exists)
hone wallet create --account myproject
# Prints a 12-word mnemonic. Write it down — shown once, never stored.
let client = HoneClient::from_env(); // reads env vars
let resp = client.chat_completions(
vec![json!({"role":"user","content":"Summarise this PR."})],
None,
).await?;
let text = resp["choices"][0]["message"]["content"].as_str().unwrap_or("");