Skip to main content
Rowboat integrates with Slack via Composio to enable AI-powered interactions with your workspace.

Overview

The Slack integration allows you to:
  • Send messages to channels and DMs
  • Search message history
  • List channels and users
  • View conversation history
  • Execute advanced Slack actions
The Slack integration uses Composio for OAuth and tool execution.

Prerequisites

Before using Slack tools, always check if Slack is connected:
slack-checkConnection({})
If not connected, the user needs to connect Slack from settings/onboarding.

Available Tools

Check Connection

slack-checkConnection({})
Returns whether Slack is connected and ready to use.

List Users

slack-listUsers({ limit: 100 })
Lists users in the workspace. Use this to resolve a name to a user ID.

List Channels

slack-listChannels({
  types: "public_channel,private_channel",
  limit: 100
})
Lists channels the user has access to.

List DM Conversations

slack-getDirectMessages({ limit: 50 })
Lists DM channels (type “im”). Each entry includes the DM channel ID and the user ID.

Get Conversation History

slack-getChannelHistory({
  channel: "C01234567",
  limit: 20
})
Fetches recent messages for a channel or DM.

Search Messages

slack-searchMessages({
  query: "in:@username",
  count: 20
})
Searches Slack messages using Slack search syntax. Search Examples:
  • in:@alice - Messages in DMs with Alice
  • from:@bob - Messages from Bob
  • in:#engineering - Messages in #engineering channel
  • has:link - Messages containing links
  • has:attachment - Messages with attachments
  • after:2024-01-01 - Messages after a date

Send a Message

slack-sendMessage({
  channel: "C01234567",
  text: "Hello team!"
})
Sends a message to a channel or DM.
Always show the draft message to the user before sending. Never send messages without user confirmation.

Composio Tool Catalog

Rowboat includes a comprehensive catalog of 113 Slack tools from Composio:

Common Actions

ToolSlugDescription
Send MessageSLACK_SEND_MESSAGEPosts a message to a channel, DM, or group
Search MessagesSLACK_SEARCH_MESSAGESWorkspace-wide message search
List ChannelsSLACK_LIST_ALL_CHANNELSLists all conversations
Find User by EmailSLACK_FIND_USER_BY_EMAIL_ADDRESSFinds a user by email
Add ReactionSLACK_ADD_REACTION_TO_AN_ITEMAdds emoji reaction
Pin ItemSLACK_PINS_AN_ITEM_TO_A_CHANNELPins a message

Channel Management

ToolSlugDescription
Create ChannelSLACK_CREATE_CHANNELCreates a public or private channel
Archive ChannelSLACK_ARCHIVE_A_PUBLIC_OR_PRIVATE_CHANNELArchives a channel
Rename ChannelSLACK_RENAME_A_SLACK_CHANNELRenames a channel
Invite to ChannelSLACK_INVITE_USERS_TO_A_SLACK_CHANNELInvites users by ID

User Management

ToolSlugDescription
List All UsersSLACK_LIST_ALL_USERSRetrieves all users
Get User DetailsSLACK_RETRIEVE_DETAILED_USER_INFORMATIONGets user info by ID
Set User PresenceSLACK_MANUALLY_SET_USER_PRESENCESets presence (active/away)

Files & Attachments

ToolSlugDescription
Upload FileSLACK_UPLOAD_OR_CREATE_A_FILE_IN_SLACKUploads files
List FilesSLACK_LIST_FILES_WITH_FILTERS_IN_SLACKLists files
Share File PubliclySLACK_ENABLE_PUBLIC_SHARING_OF_A_FILECreates public URL

Execute Custom Action

slack-executeAction({
  toolSlug: "SLACK_SEND_MESSAGE",
  input: {
    channel: "C01234567",
    text: "Hello!"
  }
})
Executes any Slack tool using its exact slug from the catalog.

Discover Tools

slack-listAvailableTools({ search: "conversation" })
Lists available Slack tools from Composio. Use this only if a builtin tool fails and you need a specific slug.
Prefer using the pinned tool catalog slugs to avoid redundant discovery calls.

Workflows

Find the Most Recent DM with Someone

1

Search messages first

slack-searchMessages({
  query: "in:@Alice",
  count: 1
})
2

Get exact DM history (optional)

// Find user ID
const users = await slack-listUsers({});
const alice = users.find(u => u.name === 'alice');

// Find DM channel
const dms = await slack-getDirectMessages({});
const dmChannel = dms.find(dm => dm.user === alice.id);

// Get history
await slack-getChannelHistory({
  channel: dmChannel.id,
  limit: 20
});

Send a Message

1

Draft the message

Show the draft to the user:
I'll send this message to #engineering:

"Team, the deployment is scheduled for 3pm today."
2

Wait for approval

Only after user confirmation, send the message:
await slack-sendMessage({
  channel: "C01234567",
  text: "Team, the deployment is scheduled for 3pm today."
})

Cross-Reference with Knowledge Base

// Search Slack for mentions
const messages = await slack-searchMessages({
  query: "from:@alice project alpha",
  count: 10
});

// Check knowledge base for notes about Alice
const notes = searchKnowledgeBase('alice');

// Combine context for response
const context = {
  slackMessages: messages,
  personalNotes: notes,
};

Best Practices

Always Show Drafts

Never send Slack messages without user confirmation. Always show the draft first.
// ❌ Bad: Sending without approval
await slack-sendMessage({ ... });

// ✅ Good: Show draft first
console.log('I\'ll send: "Hello team!"');
// Wait for user approval...
await slack-sendMessage({ ... });

Summarize, Don’t Dump

// ❌ Bad: Dumping all messages
const history = await slack-getChannelHistory({ channel, limit: 100 });
return history; // Overwhelming

// ✅ Good: Summarize key points
const history = await slack-getChannelHistory({ channel, limit: 20 });
const summary = extractKeyPoints(history);
return `Recent discussion covered: ${summary}`;

Use Search for Speed

// ❌ Slow: List all DMs then filter
const dms = await slack-getDirectMessages({ limit: 100 });
const aliceDm = dms.find(dm => dm.user === aliceId);
const history = await slack-getChannelHistory({ channel: aliceDm.id });

// ✅ Fast: Search directly
const messages = await slack-searchMessages({
  query: "in:@alice",
  count: 10
});

Error Handling

If a Slack operation fails:
  1. Verify tool slug - Try slack-listAvailableTools to get the correct slug
  2. Check connection - Use slack-checkConnection to verify auth
  3. Inform the user - Provide specific error messages
try {
  await slack-sendMessage({ ... });
} catch (error) {
  // Check if still connected
  const connected = await slack-checkConnection({});
  
  if (!connected) {
    return "Slack is not connected. Please reconnect from settings.";
  }
  
  return `Failed to send message: ${error.message}`;
}

Configuration

The Slack skill is defined in the core package:
// apps/x/packages/core/src/application/assistant/skills/slack/skill.ts

const skill = String.raw`
# Slack Integration Skill

You can interact with Slack to help users communicate with their team.

## Prerequisites
Before using Slack tools, ALWAYS check if Slack is connected:
\`\`\`
slack-checkConnection({})
\`\`\`

// ... tool definitions ...
`;

export default skill;

Tool Catalog

The full catalog is available in:
// apps/x/packages/core/src/application/assistant/skills/slack/tool-catalog.ts

export const slackToolCatalog: SlackToolDefinition[] = [
  { 
    name: "Send Message",
    slug: "SLACK_SEND_MESSAGE",
    description: "Posts a message to a channel, DM, or group."
  },
  // ... 112 more tools
];

Privacy & Security

  • OAuth Authentication: Secure token-based auth via Composio
  • Scoped Access: Only accesses what the user authorizes
  • No Storage: Messages are not stored by Rowboat
  • Read-Only by Default: Most operations are read-only
  • MCP - Model Context Protocol for custom tools
  • Gmail - Email integration

Build docs developers (and LLMs) love