- Initialize runtime in register() to fix 'runtime not initialized' error - Move clawdbot from dependencies to devDependencies/peerDependencies - Add security adapter with DM policy (pairing, allowlist, open) - Add pairing adapter for user approval flow - Add status adapter for health checks and diagnostics - Add groups adapter for mention/tool policy resolution - Add reload config prefixes for hot reload support - Add outbound chunker for long messages - Fix verification token enforcement in webhook handler - Add allowFrom validation before processing messages - Add comprehensive input validation in webhook handler - Improve type safety and error handling throughout
36 lines
815 B
Markdown
36 lines
815 B
Markdown
# @clawdbot/lark
|
|
|
|
Feishu / Lark channel plugin for Clawdbot.
|
|
|
|
## Configuration
|
|
|
|
Add the following to your `clawdbot.config.yaml`:
|
|
|
|
```yaml
|
|
channels:
|
|
lark:
|
|
enabled: true
|
|
appId: "cli_..."
|
|
appSecret: "..."
|
|
encryptKey: "..." # Optional
|
|
verificationToken: "..." # Optional
|
|
baseUrl: "https://open.feishu.cn" # Optional, default
|
|
webhook:
|
|
port: 3000
|
|
path: "/lark/webhook"
|
|
```
|
|
|
|
## Setup
|
|
|
|
1. Create an app on [Feishu Open Platform](https://open.feishu.cn/app).
|
|
2. Get App ID and App Secret.
|
|
3. Enable "Bot" capabilities.
|
|
4. Set up "Event Subscriptions":
|
|
- Request URL: `https://your-gateway.com/lark/webhook` (must match `webhook.path` and external URL).
|
|
- Enable `im.message.receive_v1` event.
|
|
5. (Optional) Enable "Encrypt Key".
|
|
|
|
## Development
|
|
|
|
Run `pnpm build` to compile.
|