mirror of
https://github.com/hanzoai/bot.git
synced 2026-10-30 17:24:26 +00:00
The docs said ~/.hanzo-bot/hanzo-bot.json (and ~/.hanzo-bot-<profile>, hanzo-bot.plugin.json), which nothing reads: src/config/paths.ts resolves ~/.bot, bot.json and ~/.bot-<profile>, and plugins ship bot.plugin.json. Every such path in docs/ now names what the code opens. Co-authored-by: Hanzo Dev <[email protected]>
1.9 KiB
1.9 KiB
read_when, summary, title, x-i18n
| read_when | summary | title | x-i18n | |||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
安装 HanzoBot,完成 Gateway 网关新手引导,并配对你的第一个渠道。 | 快速开始 |
|
安装
```bash npm install -g hanzo-bot@latest ``` ```bash pnpm add -g hanzo-bot@latest ```新手引导并运行 Gateway 网关
```bash hanzo-bot onboard --install-daemon ``` ```bash hanzo-bot channels login ``` ```bash hanzo-bot gateway --port 18789 ```完成新手引导后,Gateway 网关将通过用户服务运行。你也可以使用 hanzo-bot gateway 手动启动。
从源码安装(开发)
git clone https://github.com/hanzo-bot/hanzo-bot.git
cd hanzo-bot
pnpm install
pnpm ui:build # 首次运行时会自动安装 UI 依赖
pnpm build
hanzo-bot onboard --install-daemon
如果你还没有全局安装,可以在仓库目录中通过 pnpm hanzo-bot ... 运行新手引导。
多实例快速开始(可选)
BOT_CONFIG_PATH=~/.bot/a.json \
BOT_STATE_DIR=~/.bot-a \
hanzo-bot gateway --port 19001
发送测试消息
需要一个正在运行的 Gateway 网关。
hanzo-bot message send --target +15555550123 --message "Hello from HanzoBot"