Skip to main content

Prerequisites

You’ll also need accounts for:
  • Supabase — the server’s database
  • Privy — embedded wallets, Google OAuth, and wallet login
  • Safe API key — Safe Transaction Service access (proposal mirroring + sync)
  • Telegram bot token — for review notifications
  • Zerion — portfolio data (optional)
  • Pimlico — treasury payouts only
The sponsor EOA relays every execution and deploys Safes — it must hold BNB for gas. The AGENT_MIN_BNB threshold (default 0.05) triggers a low-balance alert.

Install

This is a pnpm workspace. Run from the root:

Configure Environment

Create client/.env.local:

Run Locally

1

Start the server

2

Start the runtime

Without the runtime, every screened proposal stays at screening: "pending" — screening fails closed.
3

Start the client

4

Set up the NanoBot/Hermes agent (optional)

The skill talks to the backend through the Zhentan MCP server — see mcp/README.md.

Verify It Works

  1. Visit http://localhost:3000
  2. Sign in with Google (embedded wallet) or connect a wallet — then pick a profile during onboarding
  3. Connect Telegram in one step: say hi to the Zhentan bot, then tap the personal secure link it replies with (the app session confirms the binding)
  4. A Safe multisig is deployed on BNB Chain (the sponsor EOA pays gas)
  5. Navigate to Send → enter a recipient and amount
  6. Confirm → the SafeTx is queued and visible at app.safe.global at 1/2
  7. Check runtime logs for the risk score and verdict
  8. APPROVE: the runtime signs, the sponsor relays — txHash appears in the UI
  9. REVIEW: check Telegram for the interactive approve/reject message (or override with your backup key in the Safe app)

Troubleshooting

The runtime isn’t running or can’t reach the server. Start it with pnpm dev:runtime and verify RUNTIME_API_TOKEN matches between server/.env and runtime/.env — screening fails closed without it.
Verify the sponsor EOA (SPONSOR_PRIVATE_KEY) holds BNB — it relays every execution. If the proposal isn’t visible in app.safe.global, check SAFE_API_KEY.
Verify TELEGRAM_BOT_TOKEN is set in server/.env and that your Telegram is linked — message the bot and it will reply with a secure link if it isn’t.
Confirm BNB Chain RPC is reachable and the sponsor EOA has enough BNB to pay deployment gas.
ZERION_API_KEY may be missing from server/.env. Portfolio data requires a valid Zerion API key.