messages
Skill54 starsChanged 11 months agoMITView on GitHub
Retrieve chat message history, send messages, and manage reactions in Lark - get messages from group chats, private chats, threads, send messages to users or chats, and add/list/remove reactions. Use when user asks about chat messages, conversation history, what was discussed in a group, or wants to send a message or react.
5 other projects use a version of this, 1 of them edited.
Adopted by
Most recently taken up by
- jootsing-research/skillstheir own version, first seen Sep 10, 2026
- wende/macbeththeir own version, first seen Jul 30, 2026
- ayrshare/ayrshare-social-media-api-claude-plugintheir own version, first seen Jun 6, 2026
- github/gh-awtheir own version, first seen May 27, 2026
- seahyc/lark-cowork-pluginedited, first seen Apr 1, 2026
Other versions5 projects use a version of this.
Word for word · 0
None found.
Edited · 1
- seahyc/lark-cowork-plugin★ 094% same
Wrote their own version · 4
- github/gh-aw★ 5.3ksame name
- ayrshare/ayrshare-social-media-api-claude-plugin★ 19same name
- wende/macbeth★ 4same name
- jootsing-research/skills★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
The file
Show its rules and text
We split this skill into the rules it gives an agent
13 rules. 0 are common, 5 are distinctive, and 8 are very specific to this project.
0
Common
Most of the 4 edited versions we read keep these.
5
Distinctive
This author's own choices. Worth a look.
8
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 16
Add/list/remove emoji reactions
- Distinctive: line 18
Read chat history (chat or thread)
- Distinctive: line 21
Use clear, flag-based CLI with consistent JSON output
- Very specific: line 59
Ensure lark is in your PATH, or use the full path to the binary.
- Distinctive: line 136
Add a reaction to a message as the bot.
- Distinctive: line 169
Use this command to list the supported emoji types for reactions.
- Very specific: line 244
Use \n for line breaks and \t for indentation in --text
- Very specific: line 245
Use @{ou_xxx} to mention users in group chats
- Very specific: line 246
Use {{image}} in text to place images in order
- Very specific: line 248
Use lark msg react list to discover reaction_id for removal
- Very specific: line 266
If a message has a thread_id, it is part of a thread (or is the root).
- Distinctive: line 277
All commands output JSON.
- Very specific: line 322
Add/remove reactions requires im:message.reactions:write_only
“Common” is measured: kept by at least 6 in 10 of the 4 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Messages Skill
Retrieve chat message history, send messages, manage reactions, and search for chats/groups via the lark CLI.
🤖 Capabilities and Use Cases
- Send markdown-lite messages with links and mentions
- Send images with
--imageand{{image}}placement - Reply to messages and threads with
--parent-id/--root-id - Message recall/delete for cleanup
- Add/list/remove emoji reactions
- Browse emoji catalog reference
- Read chat history (chat or thread)
- Download message resources (images/files/audio/video)
- Find chats by name or member
- Use clear, flag-based CLI with consistent JSON output
🚀 Quick Reference
Send message:
lark msg send --to user@example.com --text "Hello!"Reply in thread:
lark msg send --to oc_12345 --parent-id om_abcdef --msg-type text --text "Replying here"Read messages:
lark msg history --chat-id oc_12345 --limit 10Find chats:
lark chat search "project team"React / list / remove reaction:
lark msg react --message-id om_123456789abcdef --reaction SMILE
lark msg react list --message-id om_123456789abcdef
lark msg react remove --message-id om_123456789abcdef --reaction-id ZCaCIjUBVVWSrm5L-3ZTw...Download resource:
lark msg resource --message-id om_xxx --file-key img_v3_xxx --type image --output ./image.pngRunning Commands
Ensure lark is in your PATH, or use the full path to the binary. Set the config directory if not using the default:
lark msg <command>
lark chat <command>
# Or with explicit config:
LARK_CONFIG_DIR=/path/to/.lark lark msg <command>Commands Reference
Search for Chats/Groups
lark chat search "project" --limit 10Available flags:
--limit: Maximum number of chats to retrieve (0 = no limit)
Output fields include:
chats[]withchat_id,name,description,owner_id,external,chat_statuscount,query
Send Messages
Send messages to users or group chats as the bot.
lark msg send --to ou_xxxx --text "Hello!"Reply in thread:
lark msg send --to oc_xxxx --parent-id om_xxxx --msg-type text --text "Replying here"Available flags:
--to(required): Recipient identifier (user ID, open_id, email, or chat_id)--to-type: Explicitly specify ID type (open_id,user_id,email,chat_id) - auto-detected if omitted--text: Message text content (markdown-lite). Use{{image}}to place images.--image: Image file path (repeatable)--msg-type: Message type:post(default) ortext--parent-id: Parent message ID to reply in thread (optional)--root-id: Root message ID for thread replies (optional)
Output:
{
"success": true,
"message_id": "om_dc13264520392913993dd051dba21dcf",
"chat_id": "oc_xxxxx",
"create_time": "2026-01-14T10:30:00+08:00"
}Get Chat History
lark msg history --chat-id oc_xxxxx --limit 50 --sort descAvailable flags:
--chat-id(required): Chat ID or thread ID--type: Container type -chat(default) orthread--start: Start time (Unix timestamp or ISO 8601)--end: End time (Unix timestamp or ISO 8601)--sort: Sort order -asc(default) ordesc--limit: Maximum number of messages (0 = no limit)
Output fields include:
messages[]withmessage_id,msg_type,content,sender,create_time,mentions,is_reply,thread_id,deletedcount,chat_id
React to Message
Add a reaction to a message as the bot.
lark msg react --message-id om_dc13264520392913993dd051dba21dcf --reaction SMILEAvailable flags:
--message-id(required): Message ID to react to--reaction(required): Reaction ID or emoji name--type: Reaction type (default:emoji)
Output:
{
"success": true,
"message_id": "om_dc13264520392913993dd051dba21dcf",
"reaction_type": "emoji",
"reaction_id": "ZCaCIjUBVVWSrm5L-3ZTw...",
"emoji_type": "SMILE"
}Notes:
- Reactions are added as the bot/app. The bot must be in the chat to react.
- Emoji types must match the Lark emoji catalog (e.g.,
SMILE,LAUGH). - Replies sent with
--parent-idare always created in a thread.
Emoji Catalog Reference
lark msg react emojisUse this command to list the supported emoji types for reactions.
Custom Emojis: Organization-specific custom emojis can be configured in .lark/config.yaml:
custom_emojis:
"7405453485858095136": "ez-pepe"Custom emoji IDs will appear in the custom_emojis field of the output.
List Message Reactions
lark msg react list --message-id om_dc13264520392913993dd051dba21dcf --reaction SMILE --limit 50Available flags:
--message-id(required): Message ID to list reactions for--reaction: Emoji type filter (e.g.,SMILE)--limit: Maximum number of reactions to retrieve (0 = no limit)
Output fields include:
message_id,reactions[],count
Remove Message Reaction
lark msg react remove --message-id om_dc13264520392913993dd051dba21dcf --reaction-id ZCaCIjUBVVWSrm5L-3ZTw...Available flags:
--message-id(required): Message ID to remove reaction from--reaction-id(required): Reaction ID to remove
Output fields include:
success,message_id,reaction_type,reaction_id,emoji_type
Recall Messages
Recall/delete previously sent messages from chats.
lark msg recall om_dc13264520392913993dd051dba21dcfOutput fields include:
success,message_id
Downloading Resource Files
Download images, files, audio, and video from messages using msg resource:
lark msg resource --message-id om_xxx --file-key img_v3_xxx --type image --output ./image.png
lark msg resource --message-id om_xxx --file-key file_v2_xxx --type file --output ./document.pdfAvailable flags:
--message-id(required): Message ID containing the resource--file-key(required): Resource key from message content (image_keyorfile_key)--type(required):imagefor images,filefor files/audio/video--output(required): Output file path
Output fields include:
success,message_id,file_key,output_path,content_type,bytes_written
Limitations:
- Maximum file size: 100MB
- Emoji resources cannot be downloaded
- Resources from card, merged, or forwarded messages are not supported
- The
message_idandfile_keymust match
Tips
- Use
\nfor line breaks and\tfor indentation in--text - Use
@{ou_xxx}to mention users in group chats - Use
{{image}}in text to place images in order - Chat IDs start with
oc_; thread IDs start withthread_oromt_ - Use
lark msg react listto discoverreaction_idfor removal - The CLI auto-detects recipient type; override with
--to-typeif needed
Message Types
text- Plain text messagepost- Rich text postimage- Imagefile- File attachmentaudio- Audio messagemedia- Video/mediasticker- Sticker/emojiinteractive- Interactive cardshare_chat- Shared chatshare_user- Shared user contact
Reading Thread Replies
If a message has a thread_id, it is part of a thread (or is the root). To fetch replies:
lark msg history --chat-id oc_xxxxx --limit 10 --sort desc
lark msg history --chat-id omt_1a3b99f9d2cfd982 --type threadThread messages will have is_reply: true for replies (root message has is_reply: false).
Output Format
All commands output JSON.
Error Handling
Errors return JSON:
{
"error": true,
"code": "ERROR_CODE",
"message": "Description"
}Common error codes:
AUTH_ERROR- Need to runlark auth loginSCOPE_ERROR- Missing messages permissionsVALIDATION_ERROR- Missing required fields (e.g., chat-id)API_ERROR- Lark API issue (e.g., bot not in group, missing permissions)
Required Permissions
This skill requires the messages scope group. If you see a SCOPE_ERROR, add permissions:
lark auth login --add --scopes messagesTo check current permissions:
lark auth statusAdditional requirements:
For reading messages:
- The bot must be in the group chat
- Group chat reads require the "Read all messages in associated group chat" permission
- Private chat reads require
im:message:readonly
For sending messages:
- Requires
im:messageorim:message:send_as_bot - The bot must be added to group chats before it can send messages to them
For reactions:
- List reactions requires
im:message.reactions:read - Add/remove reactions requires
im:message.reactions:write_only
Notes
- Messages are sent as the bot/app
- Messages are sorted by creation time ascending by default
- Time filters do not work for thread container type
- Message IDs typically start with
om_
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

