lark-event

Subscribe to Lark events via WebSocket and stream NDJSON to stdout.

Updated Jan 10, 2026
One-click install
npx skills add https://github.com/Rabbit-Ivan/Ivan-skills --skill lark-event-rabbit-ivan
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: lark-event
Source: https://github.com/Rabbit-Ivan/Ivan-skills/tree/main/skills/lark-event
Command: npx skills add https://github.com/Rabbit-Ivan/Ivan-skills --skill lark-event-rabbit-ivan

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires lark-cli, and includes references (resource) components.

What problem does it solve? Building event-driven automations on Lark (Feishu) normally requires standing up a webhook server, handling verification challenges, and parsing raw payloads. This Skill lets you listen to Lark events in real time over a WebSocket long connection and receive clean NDJSON directly on stdout, ready for shell pipelines and AI agents. ## Core Features & Use Cases - Real-time event subscription: Connect via WebSocket long connection and receive messages, contact changes, calendar updates, approvals, tasks, and drive events as NDJSON. - Agent-friendly compact output: The --compact mode flattens payloads, parses double-encoded message content, and strips noise fields so LLM pipelines can consume events directly. - Regex routing and file output: Route different event types to different directories with --route, or write each event to a file with --output-dir. - Use Case: Pipe incoming IM messages into Claude to generate replies, then respond as the bot via lark-cli api, creating a fully automated Lark chatbot loop. ## Quick Start Ask the agent to subscribe to incoming Lark messages with lark-cli event +subscribe in compact mode and reply to each message automatically.

Frequently Asked Questions about lark-event

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I subscribe to Lark events in real time from the command line?▼

Run lark-cli event +subscribe to open a WebSocket long connection and stream events as NDJSON to stdout. Use --event-types to limit which events you receive, or omit it to register 24 common event types.

How to build a Lark bot that auto-replies to messages?▼

Pipe lark-cli event +subscribe --event-types im.message.receive_v1 --compact --quiet into a shell loop that reads each NDJSON line, generates a reply with an LLM, and posts it back via lark-cli api POST to the message reply endpoint as the bot.

Does Lark event subscription require a public webhook server?▼

No. This approach uses a WebSocket long connection instead of webhooks, so no public endpoint is needed. You must still enable long-connection mode and add event types in the Lark Open Platform console.

Can I filter or route Lark events to different destinations?▼

Yes. Use --filter with a regex for client-side filtering, and --route with regex=dir:./path rules to send matching events to different directories. Unmatched events fall through to --output-dir or stdout.

Why am I only receiving some Lark events when running multiple subscribers?▼

The Lark server splits events randomly across connections for the same app, so each instance receives only a subset. The tool enforces a single-instance lock per app; only bypass it with --force if you accept partial delivery.