Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
LARK_APP_IDNo飞书应用 App ID,用于官方 API 鉴权(机器人等)
LARK_COOKIENo飞书 cookie,用于用户身份鉴权(发送消息等)
LARK_APP_SECRETNo飞书应用 App Secret,用于官方 API 鉴权
LARK_PROFILES_JSONNoJSON 字符串,用于配置多账号 profiles
LARK_USER_ACCESS_TOKENNo用户 OAuth 访问令牌,用于以用户身份操作(如 P2P 私聊读取)
LARK_USER_REFRESH_TOKENNo用户 OAuth 刷新令牌,用于自动刷新访问令牌

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{}
prompts
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
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 type even when only renaming), delete.

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 calendar:calendar:readonly scope on the OAuth.

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 calendar:calendar.event:write scope (re-run npx feishu-user-plugin oauth after enabling). The current identity (UAT-first) must have writer or owner permission on the calendar.

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 calendar:calendar.event:write scope.

delete_calendar_eventB

[Official API + UAT, v1.3.7] Delete a calendar event. Requires calendar:calendar.event:write scope.

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 calendar:calendar.event:write scope.

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 calendar:calendar:readonly (already in default scope set).

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 image content block so the model sees pixels. For files, the response includes the bytes as base64 (truncated for display) plus an optional save_path write.

Size cap: payloads > 2 MiB MUST pass save_path. The Anthropic API rejects responses > 5 MB; we cap at 2 MiB so multipart wrapping has headroom.

merge_forward children: Feishu keys media by the parent merge_forward id, not the child id. Use the child's parentMessageId field (returned by read_messages with expand_merge_forward) — not the child id.

download_doc_imageA

[User Identity / Official API] Download an image embedded in a docx document so the model can see it. Pass the image_token from get_doc_blocks (block.image.token), and optionally the doc/wiki/URL token to scope the lookup. UAT-first.

Size cap: payloads > 2 MiB MUST pass save_path.

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 children array (e.g. [{block_type:2, text:{...}}]). (B) Image from local file — pass image_path; plugin uploads and patches. (C) Image from token — pass image_token (already uploaded). (D) File attachment from local file — pass file_path; plugin handles VIEW-wrap + replace_file. (E) File from token — pass file_token. action=update — generic (pass update_body), image-replace (pass image_token), or file-replace (pass file_token). action=delete — pass parent_block_id + start_index + end_index (range delete). document_id accepts native ID, wiki node token, or Feishu URL.

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). type is always required (Feishu rejects with 1061002 / 1062501 otherwise).

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 member_ids do not match member_id_type — pass member_id_type explicitly when using union_id or user_id (default: open_id).

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 urls; Feishu doc links are additionally surfaced as feishuDocs so agents can feed them straight into read_doc / get_doc_blocks.

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 <at user_id="ou_xxx">Name</at> inline in text content and Feishu resolves it to a real @-notification.

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. receive_id may be a group chat_id (oc_xxx), an open_id (ou_xxx), a union_id, a user_id, or an email — set receive_id_type to match (default: chat_id).

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 text and interactive (card) messages — other types (post, image, file, etc.) are rejected by the API.

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 card as a JSON object (Feishu card schema, see https://open.feishu.cn/cardkit).

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 source_title, source_url, and a block-structured content; this tool exposes a simple content_text and auto-wraps it into the single-paragraph block format. Pass richer content directly if you need lists / mentions / docs links / images.

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 npx feishu-user-plugin setup --profile <name> --app-id ... --app-secret ... --cookie ... then npx feishu-user-plugin oauth --profile <name> for UAT.

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 title is updatable via the wiki API; the underlying resource content is edited via docx/bitable/sheet tools).

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 DELETE /open-apis/wiki/v2/spaces/{space_id}/nodes/{node_token}. The Feishu SDK does not type this endpoint, so the call goes through raw REST (UAT-first; bot fallback uses client.request). The underlying drive resource (docx / sheet / bitable / file) is NOT deleted — Feishu treats wiki nodes as pointers. To delete the actual resource as well, follow up with manage_drive_file(action=delete, type=<obj_type>, file_token=<obj_token>) (use get_wiki_node first to get obj_type / obj_token).

Prompts

Interactive templates invoked by user choice

NameDescription
digest整理飞书群聊或单聊的最近消息。
doc操作飞书云文档:搜索、读取或创建。
drive管理飞书云盘文件和文件夹。
reply读取飞书聊天的最近消息并回复。
search搜索飞书联系人或群组。
send以你本人的飞书身份发送消息(非机器人)。
status检查飞书所有认证层的登录状态。
table操作飞书多维表格(Bitable)。
wiki搜索和管理飞书知识库。

Resources

Contextual data attached and managed by the client

NameDescription

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