feishu-user-plugin
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| LARK_APP_ID | No | 飞书应用 App ID,用于官方 API 鉴权(机器人等) | |
| LARK_COOKIE | No | 飞书 cookie,用于用户身份鉴权(发送消息等) | |
| LARK_APP_SECRET | No | 飞书应用 App Secret,用于官方 API 鉴权 | |
| LARK_PROFILES_JSON | No | JSON 字符串,用于配置多账号 profiles | |
| LARK_USER_ACCESS_TOKEN | No | 用户 OAuth 访问令牌,用于以用户身份操作(如 P2P 私聊读取) | |
| LARK_USER_REFRESH_TOKEN | No | 用户 OAuth 刷新令牌,用于自动刷新访问令牌 |
Capabilities
Features and capabilities supported by this server
| Capability | Details |
|---|---|
| tools | {} |
| prompts | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| manage_bitable_appB | [Official API] Manage a Bitable app. action=create (new app, optional wiki_space_id to attach), copy (duplicate an existing app), get_meta (read app metadata). |
| manage_bitable_tableB | [Official API] Manage a table inside a Bitable app. action=list, create (with optional initial fields), update (rename), delete. |
| manage_bitable_fieldA | [Official API] Manage fields (columns) inside a Bitable table. action=list, create, update (Feishu requires |
| manage_bitable_viewA | [Official API] Manage views inside a Bitable table. action=list, create, delete. (Feishu open API does not expose view update — recreate with a new name to change.) |
| manage_bitable_recordA | [Official API] Manage records (rows) inside a Bitable table. action=search, get, create, update, delete. create/update/delete accept arrays — single record or up to 500. |
| list_calendarsA | [Official API + UAT] List the current user's calendars (primary + shared + subscribed). Requires UAT — app identity only sees calendars it was explicitly invited to. Requires |
| list_calendar_eventsA | [Official API + UAT] List events in a calendar within an optional time range. Typical usage: first list_calendars to find calendar_id (primary calendar has type="primary"), then list events in e.g. [now, now+7d] (Unix seconds). |
| get_calendar_eventA | [Official API + UAT] Get full details of a single calendar event (summary, description, start/end, attendees, location, attachments, meeting link). |
| create_calendar_eventA | [Official API + UAT, v1.3.7] Create a new calendar event. Requires Time fields: A time object: {timestamp:"", timezone?:"Asia/Shanghai"} OR {date:"YYYY-MM-DD"} for all-day events. |
| update_calendar_eventA | [Official API + UAT, v1.3.7] Patch fields on an existing calendar event. Pass only the fields you want to change. Requires |
| delete_calendar_eventB | [Official API + UAT, v1.3.7] Delete a calendar event. Requires |
| respond_calendar_eventA | [Official API + UAT, v1.3.7] Respond to an event invitation. The current identity must be in the event's attendee list. Requires |
| get_freebusyA | [Official API + UAT, v1.3.7] Query freebusy windows for one or more users in a time range. Use to find a meeting slot. Requires |
| search_contactsA | [User Identity] Search Feishu users, bots, or group chats by name. Returns IDs. |
| create_p2p_chatA | [User Identity] Create or get a P2P (direct message) chat. Returns numeric chat_id. |
| get_user_infoB | [User Identity] Look up a user's display name by user ID. |
| get_login_statusA | Check cookie session validity and app credentials status. Also refreshes session. |
| download_message_resourceA | [User Identity / Official API] Download an image or file attached to a message so the model can see / store it. v1.3.7 (C2.4) consolidates the v1.3.6 download_image (mode 1) + download_file. UAT-first, falls back to app. For images, the response includes an inline Size cap: payloads > 2 MiB MUST pass merge_forward children: Feishu keys media by the parent merge_forward id, not the child id. Use the child's |
| download_doc_imageA | [User Identity / Official API] Download an image embedded in a docx document so the model can see it. Pass the Size cap: payloads > 2 MiB MUST pass |
| search_docsC | [Official API] Search Feishu documents by keyword. |
| read_docB | [Official API] Read the raw text content of a Feishu document. |
| get_doc_blocksA | [Official API] Get structured block tree of a document. Returns block types, content, and hierarchy for precise document analysis. |
| create_docA | [Official API] Create a new Feishu document. Can place directly under a Wiki space by passing wiki_space_id (optionally wiki_parent_node_token for nested placement) — the plugin creates the doc in drive then attaches it as a Wiki node. |
| manage_doc_blockA | [Official API] Manage content blocks in a document. Single tool replaces v1.3.6 create_doc_block / update_doc_block / delete_doc_blocks.
action=create — five modes:
(A) Generic — pass |
| read_doc_markdownA | [Plugin v1.3.9] Read a Feishu doc as Markdown (vs get_doc_blocks JSON). Saves ~60% tokens for RAG / digest / summarisation use cases. Accepts native docx token, wiki node token, or full Feishu URL. Embedded images / files appear as feishu://image_token/ placeholders — call download_doc_image for the binary if needed. |
| list_filesB | [Official API] List files in a Drive folder. |
| create_folderB | [Official API] Create a new folder in Drive. |
| upload_drive_fileA | [Official API] Upload a file from disk to a Feishu Drive folder (drive/v1/files/upload_all, parent_type=explorer). Returns file_token + url. If wiki_space_id is provided, the uploaded file is then attached to that Wiki space via move_docs_to_wiki (obj_type=file). UAT-first with app fallback. |
| manage_drive_fileA | [Official API] Manage a Drive file/doc/folder. action=copy (duplicate to a new name + folder), move (relocate, returns task_id), delete (remove, returns task_id). |
| get_new_eventsA | [Plugin v1.3.9] Drain real-time events from the machine-level shared event log. v1.3.8 used per-process in-memory buffers (with duplicate-event problem); v1.3.9 uses ~/.feishu-user-plugin/events.jsonl with a single global cursor — every event delivered exactly once across all MCP processes on this machine. Default returns events from the current active profile only; pass profile="*" to see all. |
| manage_ws_statusA | [Plugin v1.3.9] Inspect or control the machine-level WS owner. Actions: info (status dump), reconnect (owner-only; restart WS), claim (try become owner; force=true to steal active lock), rotate (owner-only; force events.jsonl rotation), reconfig (owner-only; re-read credentials.json + apply event subscriptions). |
| create_groupB | [Official API] Create a new group chat (as bot). Can add initial members. |
| update_groupB | [Official API] Update group chat name or description. |
| list_membersB | [Official API] List all members in a group chat. |
| manage_membersA | [Official API] Add or remove members from a group chat. The Feishu API rejects with code 9499 when the IDs in |
| get_chat_infoA | [Official API + User Identity fallback] Get chat details: name, description, member count, owner. Supports both oc_xxx and numeric chat_id. |
| read_p2p_messagesA | [User UAT] Read P2P (direct message) chat history using user_access_token. Works for chats the bot cannot access. Returns newest messages first by default. Auto-expands merge_forward messages into their child messages by default — disable with expand_merge_forward=false. Requires OAuth setup. |
| list_user_chatsA | [User UAT] List group chats the user is in. Note: only returns groups, not P2P. For P2P chats, use search_contacts → create_p2p_chat → read_p2p_messages. Requires OAuth setup. |
| list_chatsA | [Official API] List all chats the bot has joined. Returns chat_id, name, type. |
| read_messagesA | [Official API + UAT fallback] Read message history from any group. Accepts oc_xxx ID, numeric ID, or chat name (auto-searched). Auto-falls back to UAT for external groups the bot cannot access. Returns newest messages first by default, with sender names resolved. Auto-expands merge_forward messages into their child messages (with original sender / time / content preserved) by default — disable with expand_merge_forward=false. Text messages have URLs extracted into |
| send_message_as_botA | [Official API] Send a message as the bot to any chat. Supports text, post, interactive, etc. This is the reliable path for @-mentions: include |
| reply_messageA | [Official API] Reply to a specific message by message_id (as bot). Only works for text messages; other types return error 230054. |
| forward_messageB | [Official API] Forward a message to another chat or user. |
| delete_messageA | [Official API] Recall/delete a message (bot can only delete its own messages). |
| update_messageA | [Official API] Edit a sent message (bot can only edit its own messages). Feishu supports edit only for |
| pin_messageB | [Official API] Pin or unpin a message in a chat. |
| add_reactionB | [Official API] Add an emoji reaction to a message. |
| delete_reactionC | [Official API] Remove an emoji reaction from a message. |
| send_as_userA | [User Identity] Send a text message as the logged-in Feishu user. Supports reply threading and real @-mentions (triggers push notifications). |
| send_to_userA | [User Identity] Search user by name → create P2P chat → send text message. All in one step. |
| send_to_groupC | [User Identity] Search group by name → send text message. All in one step. |
| batch_sendA | [User Identity / Official API] Send the same or different content to multiple targets in one call. Each target dispatches sequentially with a small delay (anti-rate-limit) and reports per-target success/error. Identity is the cookie user (user-identity sends) unless target.via=bot. Use for broadcast / fan-out scenarios. |
| send_image_as_userA | [User Identity, v1.3.9] Send an image as the logged-in user (NOT bot). Requires image_key from a prior upload_image call. Cookie-protobuf wire format requires both imageKey + thumbnailKey — when no separate thumbnail is provided, plugin defaults thumbnailKey to imageKey (Feishu accepts this for messenger-uploaded images). Width/height/mime/size are optional metadata; Feishu auto-derives display sizing on its side. |
| send_file_as_userA | [User Identity] Send a file as the logged-in user. Requires file_key (upload via Official API first). |
| send_post_as_userB | [User Identity] Send a rich text (POST) message with title and formatted paragraphs. Supports real @-mentions that trigger notifications. |
| send_card_as_userA | [v1.3.9+: bot-only] Send an interactive Feishu card to a chat via bot identity (Official API). User-identity cookie protobuf path is server-side disabled at the auth tier — confirmed by exhaustive brute-force in v1.3.9, see scripts/explore-card-protobuf.js. The "as_user" suffix is historical naming kept for backward compat; the tool always routes through bot. Pass |
| list_user_okrsB | [Official API + UAT] List a user's OKRs. Requires the user's open_id (get yours via get_login_status or search_contacts). Filter by period_ids to narrow to a specific quarter. |
| get_okrsA | [Official API + UAT] Batch-fetch full OKR details (objectives, key results, progress, alignments) by OKR IDs. |
| list_okr_periodsA | [Official API + UAT] List OKR periods (quarters / years) defined in the tenant. Use period_ids from this to filter list_user_okrs. |
| create_okr_progress_recordA | [Official API + UAT, v1.3.7] Add a progress note to an OKR objective or key result. Feishu requires |
| list_okr_progress_recordsA | [Official API + UAT, v1.3.7] List progress records for an OKR. Feishu has no native list endpoint — this tool calls get_okrs internally and walks the objective_list / kr_list to extract progress_record IDs (with their target_id and target_type). To read a record's full content, you currently need progressRecord.get (not yet wrapped). |
| delete_okr_progress_recordA | [Official API + UAT, v1.3.7] Delete an OKR progress record by its progress_id (from list_okr_progress_records). |
| list_profilesA | [Plugin] List all available identity profiles (each profile has its own LARK_COOKIE / APP_ID / APP_SECRET / UAT). v1.3.9 SSOT: profiles live in ~/.feishu-user-plugin/credentials.json::profiles. Legacy fallback: LARK_PROFILES_JSON env var. Marks the currently active profile. |
| switch_profileA | [Plugin v1.3.9] Switch the active identity profile. Atomically writes credentials.json::active; cached clients in this process are invalidated; cross-process MCPs (Codex / another Claude Code) auto-sync via dispatcher mtime check on next tool call (~10μs). To add a new profile, run |
| manage_profile_hintsA | [Plugin v1.3.8] Inspect / set / clear profileHints — the resourceKey → profileName cache the auto-switch middleware uses to remember which profile owns each Feishu resource. Useful when a hint goes stale (e.g., a profile lost access to a doc). |
| list_tasksB | [Official API + UAT, v1.3.7] List the current user's tasks. Filter by completion or type. |
| get_taskA | [Official API + UAT, v1.3.7] Get full details of a single task by GUID. |
| create_taskB | [Official API + UAT, v1.3.7] Create a new task. summary is required; due / members / etc. are optional. |
| update_taskB | [Official API + UAT, v1.3.7] Patch a task. update_fields is required by Feishu — list which fields to update (e.g. ["summary","due","completed_at"]). |
| complete_taskA | [Official API + UAT, v1.3.7] Mark a task complete (or uncomplete it). Convenience wrapper around update_task with completed_at. |
| delete_taskB | [Official API + UAT, v1.3.7] Permanently delete a task. |
| manage_task_membersB | [Official API + UAT, v1.3.7] Add or remove members on a task. Members are objects {id:"<open_id>", role:"assignee"|"follower", type?:"user", name?:""}. |
| upload_imageB | [Official API] Upload an image file to Feishu. Returns image_key for use with send_image_as_user. |
| upload_fileB | [Official API] Upload a file to Feishu. Returns file_key for use with send_file_as_user. |
| upload_bitable_attachmentA | [Official API] Upload a file as a Bitable attachment (drive/v1/medias/upload_all with parent_type=bitable_image or bitable_file). Returns file_token suitable for writing into a Bitable Attachment-type field via batch_create/update_bitable_records (the field value should be [{file_token}]). |
| list_wiki_spacesB | [Official API] List all accessible Wiki spaces. |
| search_wikiB | [Official API] Search Wiki nodes by keyword. |
| list_wiki_nodesC | [Official API] List nodes in a Wiki space. |
| get_wiki_nodeA | [Official API] Resolve a Wiki node token to its underlying object (docx / bitable / sheet / mindnote / file). Returns obj_type + obj_token + space_id so you can read/write the real resource via the usual docx / bitable tools. Accepts bare wiki node token (wikcnXXX), an underlying obj_token (docxXXX / bascnXXX from search_wiki), or a full Feishu /wiki/ URL — the handler tries the wiki endpoint first and falls back to a synthesized node-shape for non-wiki tokens. |
| create_wiki_nodeB | [Official API] Create a new Wiki node inside a space. obj_type picks the underlying resource (doc/sheet/bitable/mindnote/file/docx/slides). UAT-first so the resource is owned by the user. |
| update_wiki_nodeA | [Official API] Rename a Wiki node (only |
| move_wiki_nodeA | [Official API] Move a Wiki node to a different parent (within the same space) or to a different space. Pass at least one of target_parent_token / target_space_id. |
| copy_wiki_nodeB | [Official API] Deep-copy a Wiki node into a different location (and optionally a different space). Underlying resource is duplicated. |
| delete_wiki_nodeA | [Official API, v1.3.7] Delete a Wiki node. Calls |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
| digest | 整理飞书群聊或单聊的最近消息。 |
| doc | 操作飞书云文档:搜索、读取或创建。 |
| drive | 管理飞书云盘文件和文件夹。 |
| reply | 读取飞书聊天的最近消息并回复。 |
| search | 搜索飞书联系人或群组。 |
| send | 以你本人的飞书身份发送消息(非机器人)。 |
| status | 检查飞书所有认证层的登录状态。 |
| table | 操作飞书多维表格(Bitable)。 |
| wiki | 搜索和管理飞书知识库。 |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/EthanQC/feishu-user-plugin'
If you have feedback or need assistance with the MCP directory API, please join our Discord server