Getting Started
Claude Feishu Channel bridges Claude Code (Anthropic's CLI agent) and Feishu / Lark group chat. Send a message in a Feishu group, and Claude processes it with full tool access — file read/write, shell commands, search — then streams results back as interactive Feishu cards.
Prerequisites
Before you begin, make sure you have:
- Node.js >= 20
- Claude CLI — the
claudebinary must be in your$PATH(or you can setclaude.cli_pathin the config file) - A Feishu bot app — created at open.feishu.cn
Install
Install globally via npm:
npm install -g claude-feishu-channelThis gives you the cfc command.
Quick Start
1. Initialize config
cfc initThis creates a config template at ~/.claude-feishu-channel/config.toml.
2. Edit config
vim ~/.claude-feishu-channel/config.tomlFill in your Feishu credentials and allowed open_id values.
3. Run
cfcThe bot will connect to Feishu via WebSocket and start listening for messages.
CLI Options
cfc [options] Start the service
cfc init Create config template
Options:
-c, --config <path> Path to config.toml (overrides default)
-v, --version Show version number
-h, --help Show helpYou can also specify a custom config file:
cfc --config /path/to/my-config.tomlOr use the environment variable:
CLAUDE_FEISHU_CONFIG=/path/to/config.toml cfcSetting Up Your Feishu Bot
- Go to the Feishu Open Platform and create a new custom app.
- Under Credentials, copy the
App IDandApp Secretinto yourconfig.tomlunder[feishu]. - If you enabled event encryption in the developer console, also fill in
encrypt_keyandverification_token. - Enable the Bot capability for your app, and add it to the Feishu group where you want to interact with Claude.
How to find your open_id
Your open_id is a per-app user identifier that looks like ou_xxxxxxxxxxxxxxxx. To find yours, temporarily set unauthorized_behavior = "reject" and allowed_open_ids = [] in your config, then send a message to the bot. The bot will log the sender_open_id of the incoming message. Copy that value into the allowed_open_ids list.
WARNING
The bot has full shell and file access to your machine. Always configure allowed_open_ids to restrict who can interact with it.
Development Setup
If you want to develop or contribute:
git clone https://github.com/Blackman99/claude-feishu-channel.git
cd claude-feishu-channel
pnpm install
# Run in dev mode
pnpm dev
# Run tests
pnpm test
# Type check
pnpm typecheck
# Build
pnpm build