[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill-ee5937e1-632c-421a-88d1-d6edc65c31b2":3,"$fNMecMoXcbU0FEK-B_0x1ctswxBuaEJtkl37rCnZi-Mw":43},{"id":4,"title":5,"description":6,"categoryId":7,"moduleId":8,"tags":9,"prompt":10,"icon":11,"source":12,"sourceUrl":13,"authorId":14,"authorName":15,"isPublic":16,"stars":17,"runs":18,"createdAt":19,"updatedAt":19,"module":20,"category":27,"packages":34},"ee5937e1-632c-421a-88d1-d6edc65c31b2","slack-automation","通过Composio的Slack工具包自动化Slack工作空间操作，包括消息、搜索、频道管理和反应工作流程。","cat_prod_automation","mod_productivity","sickn33,productivity","---\nname: slack-automation\ndescription: \"Automate Slack workspace operations including messaging, search, channel management, and reaction workflows through Composio's Slack toolkit.\"\nrisk: critical\nsource: community\ndate_added: \"2026-02-27\"\n---\n\n# Slack Automation via Rube MCP\n\nAutomate Slack workspace operations including messaging, search, channel management, and reaction workflows through Composio's Slack toolkit.\n\n## Prerequisites\n\n- Rube MCP must be connected (RUBE_SEARCH_TOOLS available)\n- Active Slack connection via `RUBE_MANAGE_CONNECTIONS` with toolkit `slack`\n- Always call `RUBE_SEARCH_TOOLS` first to get current tool schemas\n\n## Setup\n\n**Get Rube MCP**: Add `https:\u002F\u002Frube.app\u002Fmcp` as an MCP server in your client configuration. No API keys needed — just add the endpoint and it works.\n\n1. Verify Rube MCP is available by confirming `RUBE_SEARCH_TOOLS` responds\n2. Call `RUBE_MANAGE_CONNECTIONS` with toolkit `slack`\n3. If connection is not ACTIVE, follow the returned auth link to complete Slack OAuth\n4. Confirm connection status shows ACTIVE before running any workflows\n\n## Core Workflows\n\n### 1. Send Messages to Channels\n\n**When to use**: User wants to post a message to a Slack channel or DM\n\n**Tool sequence**:\n1. `SLACK_FIND_CHANNELS` - Resolve channel name to channel ID [Prerequisite]\n2. `SLACK_LIST_ALL_CHANNELS` - Fallback if FIND_CHANNELS returns empty\u002Fambiguous results [Fallback]\n3. `SLACK_FIND_USERS` - Resolve user for DMs or @mentions [Optional]\n4. `SLACK_OPEN_DM` - Open\u002Freuse a DM channel if messaging a user directly [Optional]\n5. `SLACK_SEND_MESSAGE` - Post the message with resolved channel ID [Required]\n6. `SLACK_UPDATES_A_SLACK_MESSAGE` - Edit the posted message if corrections needed [Optional]\n\n**Key parameters**:\n- `channel`: Channel ID or name (without '#' prefix)\n- `markdown_text`: Preferred field for formatted messages (supports headers, bold, italic, code blocks)\n- `text`: Raw text fallback (deprecated in favor of markdown_text)\n- `thread_ts`: Timestamp of parent message to reply in a thread\n- `blocks`: Block Kit layout blocks (deprecated, use markdown_text)\n\n**Pitfalls**:\n- `SLACK_FIND_CHANNELS` requires `query` param; missing it errors with \"Invalid request data provided\"\n- `SLACK_SEND_MESSAGE` requires valid channel plus one of markdown_text\u002Ftext\u002Fblocks\u002Fattachments\n- Invalid block payloads return error=invalid_blocks (max 50 blocks)\n- Replies become top-level posts if `thread_ts` is omitted\n- Persist `response.data.channel` and `response.data.message.ts` from SEND_MESSAGE for edit\u002Fthread operations\n\n### 2. Search Messages and Conversations\n\n**When to use**: User wants to find specific messages across the workspace\n\n**Tool sequence**:\n1. `SLACK_FIND_CHANNELS` - Resolve channel for scoped search with `in:#channel` [Optional]\n2. `SLACK_FIND_USERS` - Resolve user for author filter with `from:@user` [Optional]\n3. `SLACK_SEARCH_MESSAGES` - Run keyword search across accessible conversations [Required]\n4. `SLACK_FETCH_MESSAGE_THREAD_FROM_A_CONVERSATION` - Expand threads for relevant hits [Required]\n\n**Key parameters**:\n- `query`: Search string supporting modifiers (`in:#channel`, `from:@user`, `before:YYYY-MM-DD`, `after:YYYY-MM-DD`, `has:link`, `has:file`)\n- `count`: Results per page (max 100), or total with auto_paginate=true\n- `sort`: 'score' (relevance) or 'timestamp' (chronological)\n- `sort_dir`: 'asc' or 'desc'\n\n**Pitfalls**:\n- Validation fails if `query` is missing\u002Fempty\n- `ok=true` can still mean no hits (`response.data.messages.total=0`)\n- Matches are under `response.data.messages.matches` (sometimes also `response.data_preview.messages.matches`)\n- `match.text` may be empty\u002Ftruncated; key info can appear in `matches[].attachments[]`\n- Thread expansion via FETCH_MESSAGE_THREAD can truncate when `response.data.has_more=true`; paginate via `response_metadata.next_cursor`\n\n### 3. Manage Channels and Users\n\n**When to use**: User wants to list channels, users, or workspace info\n\n**Tool sequence**:\n1. `SLACK_FETCH_TEAM_INFO` - Validate connectivity and get workspace identity [Required]\n2. `SLACK_LIST_ALL_CHANNELS` - Enumerate public channels [Required]\n3. `SLACK_LIST_CONVERSATIONS` - Include private channels and DMs [Optional]\n4. `SLACK_LIST_ALL_USERS` - List workspace members [Required]\n5. `SLACK_RETRIEVE_CONVERSATION_INFORMATION` - Get detailed channel metadata [Optional]\n6. `SLACK_LIST_USER_GROUPS_FOR_TEAM_WITH_OPTIONS` - List user groups [Optional]\n\n**Key parameters**:\n- `cursor`: Pagination cursor from `response_metadata.next_cursor`\n- `limit`: Results per page (default varies; set explicitly for large workspaces)\n- `types`: Channel types filter ('public_channel', 'private_channel', 'im', 'mpim')\n\n**Pitfalls**:\n- Workspace metadata is nested under `response.data.team`, not top-level\n- `SLACK_LIST_ALL_CHANNELS` returns public channels only; use `SLACK_LIST_CONVERSATIONS` for private\u002FIM coverage\n- `SLACK_LIST_ALL_USERS` can hit HTTP 429 rate limits; honor Retry-After header\n- Always paginate via `response_metadata.next_cursor` until empty; de-duplicate by `id`\n\n### 4. React to and Thread Messages\n\n**When to use**: User wants to add reactions or manage threaded conversations\n\n**Tool sequence**:\n1. `SLACK_SEARCH_MESSAGES` or `SLACK_FETCH_CONVERSATION_HISTORY` - Find the target message [Prerequisite]\n2. `SLACK_ADD_REACTION_TO_AN_ITEM` - Add an emoji reaction [Required]\n3. `SLACK_FETCH_ITEM_REACTIONS` - List reactions on a message [Optional]\n4. `SLACK_REMOVE_REACTION_FROM_ITEM` - Remove a reaction [Optional]\n5. `SLACK_SEND_MESSAGE` - Reply in thread using `thread_ts` [Optional]\n6. `SLACK_FETCH_MESSAGE_THREAD_FROM_A_CONVERSATION` - Read full thread [Optional]\n\n**Key parameters**:\n- `channel`: Channel ID where the message lives\n- `timestamp` \u002F `ts`: Message timestamp (unique identifier like '1234567890.123456')\n- `name`: Emoji name without colons (e.g., 'thumbsup', 'wave::skin-tone-3')\n- `thread_ts`: Parent message timestamp for threaded replies\n\n**Pitfalls**:\n- Reactions require exact channel ID + message timestamp pair\n- Emoji names use Slack's naming convention without colons\n- `SLACK_FETCH_CONVERSATION_HISTORY` only returns main channel timeline, NOT threaded replies\n- Use `SLACK_FETCH_MESSAGE_THREAD_FROM_A_CONVERSATION` with parent's `thread_ts` to get thread replies\n\n### 5. Schedule Messages\n\n**When to use**: User wants to schedule a message for future delivery\n\n**Tool sequence**:\n1. `SLACK_FIND_CHANNELS` - Resolve channel ID [Prerequisite]\n2. `SLACK_SCHEDULE_MESSAGE` - Schedule the message with `post_at` timestamp [Required]\n\n**Key parameters**:\n- `channel`: Resolved channel ID\n- `post_at`: Unix timestamp for delivery (up to 120 days in advance)\n- `text` \u002F `blocks`: Message content\n\n**Pitfalls**:\n- Scheduling is limited to 120 days in advance\n- `post_at` must be a Unix timestamp, not ISO 8601\n\n## Common Patterns\n\n### ID Resolution\nAlways resolve display names to IDs before operations:\n- **Channel name -> Channel ID**: `SLACK_FIND_CHANNELS` with `query` param\n- **User name -> User ID**: `SLACK_FIND_USERS` with `search_query` or `email`\n- **DM channel**: `SLACK_OPEN_DM` with resolved user IDs\n\n### Pagination\nMost list endpoints use cursor-based pagination:\n- Follow `response_metadata.next_cursor` until empty\n- Set explicit `limit` values (e.g., 100-200) for reliable paging\n- De-duplicate results by `id` across pages\n\n### Message Formatting\n- Prefer `markdown_text` over `text` or `blocks` for formatted messages\n- Use `\u003C@USER_ID>` format to mention users (not @username)\n- Use `\\n` for line breaks in markdown_text\n\n## Known Pitfalls\n\n- **Channel resolution**: `SLACK_FIND_CHANNELS` can return empty results if channel is private and bot hasn't been invited\n- **Rate limits**: `SLACK_LIST_ALL_USERS` and other list endpoints can hit HTTP 429; honor Retry-After header\n- **Nested responses**: Results may be nested under `response.data.results[0].response.data` in wrapped executions\n- **Thread vs channel**: `SLACK_FETCH_CONVERSATION_HISTORY` returns main timeline only; use `SLACK_FETCH_MESSAGE_THREAD_FROM_A_CONVERSATION` for thread replies\n- **Message editing**: Requires both `channel` and original message `ts`; persist these from SEND_MESSAGE response\n- **Search delays**: Recently posted messages may not appear in search results immediately\n- **Scope limitations**: Missing OAuth scopes can cause 403 errors; check with `SLACK_GET_APP_PERMISSION_SCOPES`\n\n## Quick Reference\n\n| Task | Tool Slug | Key Params |\n|------|-----------|------------|\n| Find channels | `SLACK_FIND_CHANNELS` | `query` |\n| List all channels | `SLACK_LIST_ALL_CHANNELS` | `limit`, `cursor`, `types` |\n| Send message | `SLACK_SEND_MESSAGE` | `channel`, `markdown_text` |\n| Edit message | `SLACK_UPDATES_A_SLACK_MESSAGE` | `channel`, `ts`, `markdown_text` |\n| Search messages | `SLACK_SEARCH_MESSAGES` | `query`, `count`, `sort` |\n| Get thread | `SLACK_FETCH_MESSAGE_THREAD_FROM_A_CONVERSATION` | `channel`, `ts` |\n| Add reaction | `SLACK_ADD_REACTION_TO_AN_ITEM` | `channel`, `name`, `timestamp` |\n| Find users | `SLACK_FIND_USERS` | `search_query` or `email` |\n| List users | `SLACK_LIST_ALL_USERS` | `limit`, `cursor` |\n| Open DM | `SLACK_OPEN_DM` | user IDs |\n| Schedule message | `SLACK_SCHEDULE_MESSAGE` | `channel`, `post_at`, `text` |\n| Get channel info | `SLACK_RETRIEVE_CONVERSATION_INFORMATION` | channel ID |\n| Channel history | `SLACK_FETCH_CONVERSATION_HISTORY` | `channel`, `oldest`, `latest` |\n| Workspace info | `SLACK_FETCH_TEAM_INFO` | (none) |\n\n## When to Use\nThis skill is applicable to execute the workflow or actions described in the overview.\n\n## Limitations\n- Use this skill only when the task clearly matches the scope described above.\n- Do not treat the output as a substitute for environment-specific validation, testing, or expert review.\n- Stop and ask for clarification if required inputs, permissions, safety boundaries, or success criteria are missing.\n","","imported","https:\u002F\u002Fgithub.com\u002Fsickn33\u002Fantigravity-awesome-skills","user_system_seed","SkillOPIC",true,210,512,"2026-05-16 13:41:09",{"id":8,"name":21,"slug":22,"icon":23,"description":24,"sort":25,"createdAt":26},"效率工具","productivity","mdi-lightning-bolt-outline","文档处理、数据分析、自动化工作流",4,"2026-05-16 12:53:40",{"id":7,"name":28,"slug":29,"icon":30,"description":31,"moduleId":8,"sort":32,"skillCount":33,"createdAt":26},"自动化","automation","mdi-robot-outline","工作流自动化、批处理",3,101,[35],{"id":36,"skillId":4,"version":37,"fileName":38,"fileSize":39,"filePath":40,"fileHash":41,"manifest":42,"createdAt":19},"a05b4e9a-d781-4736-801e-a38aae5d7179","1.0.0","slack-automation.zip",3824,"uploads\u002Fskills\u002Fee5937e1-632c-421a-88d1-d6edc65c31b2\u002Fslack-automation.zip","9b4f0dbb9df205555e0ae5fbbbdbe86fcc42ed14dc87fcf68f76be98e554b983","[{\"path\":\"SKILL.md\",\"isDirectory\":false,\"size\":9930}]",{"code":44,"message":45,"data":46},200,"success",{"items":47,"stats":48,"page":51},[],{"averageRating":49,"totalRatings":49,"ratingCounts":50},0,[49,49,49,49,49],{"limit":52,"offset":49,"hasMore":53,"nextOffset":52,"ratedOnly":16},15,false]