Skip to content

Slack Connector

The Slack connector provides access to your Slack workspace with 14 live tools for managing channels, users, messages, files, and reactions, plus ETL ingestion that maps your workspace topology into the knowledge graph.

Authentication

The Slack connector uses a Bot Token (and optionally a User Token for extended permissions). Create a Slack App at api.slack.com/apps with the required bot scopes.

json
{
  "name": "Company Slack",
  "source_type": "slack",
  "config": {
    "bot_token": "xoxb-1234567890-abcdefghijklmnop",
    "modules": ["channels", "users", "messages", "reactions", "files"]
  }
}
VariableRequiredDescription
bot_tokenYesSlack Bot User OAuth Token (xoxb-...)
user_tokenNoSlack User OAuth Token (xoxp-...) for extended permissions
modulesNoModules to enable: channels, users, messages, reactions, files, threads
channels_filterNoComma-separated channel names or IDs to limit scope
message_daysNoNumber of days of message history to ingest (default: 30)
include_privateNoInclude private channels the bot is a member of (default: false)
include_threadsNoInclude threaded replies in message ingestion (default: false)

TIP

Required bot scopes: channels:read, channels:history, users:read, chat:write, files:read, reactions:read. Add groups:read and groups:history if include_private is enabled.

Live Tools (14)

ToolDescriptionArguments
slack_send_messageSend a message to a channelchannel, text, thread_ts?
slack_send_fileSend a file to a channel with a messagechannel, content, filename, title?
slack_list_channelsList channels in the workspacetypes?, limit?
slack_list_usersList users in the workspacelimit?, include_bots?
slack_get_channel_infoGet detailed info about a channelchannel
slack_list_messagesList recent messages in a channelchannel, limit?, oldest?, latest?
slack_search_messagesSearch messages across the workspacequery, sort?, count?
slack_create_channelCreate a new channelname, is_private?, description?
slack_archive_channelArchive a channelchannel
slack_add_reactionAdd an emoji reaction to a messagechannel, timestamp, name
slack_upload_fileUpload a file to a channelchannel, file_path, title?, comment?
slack_list_filesList files shared in the workspacechannel?, types?, count?
slack_get_user_infoGet detailed info about a useruser
slack_update_profileUpdate the bot's profile statusstatus_text?, status_emoji?

Example: Agent Using Slack Tools

User: "What were the key topics discussed in #engineering this week?"

Agent: Let me check the recent messages.
→ Calls slack_list_messages(channel: "C0123ENGIN", limit: 100, oldest: "1742169600")
→ Summarizes: "Key topics in #engineering this week:
  1. Database migration to Postgres 17 (12 messages, led by @sarah)
  2. CI pipeline flakiness (8 messages, issue tracked in JIRA-456)
  3. New API versioning strategy RFC (6 messages, RFC doc shared)"
User: "Send a summary to #engineering-leads"

Agent: I'll post the summary.
→ Calls slack_send_message(channel: "C0456LEADS", text: "Weekly #engineering recap: ...")
→ Returns: "Message sent to #engineering-leads."

ETL Ingestion

When you trigger a sync, the Slack connector ingests workspace data into the knowledge graph, mapping channels, users, messages, and their relationships.

Nodes Created

Node LabelPropertiesSlack Resource
SlackChannelchannel_id, name, is_private, is_archived, topic, purpose, member_count, createdChannels
SlackUseruser_id, name, real_name, display_name, email, is_admin, is_bot, status, tzUsers
SlackMessagets, text, channel_id, user_id, thread_ts, reply_count, reaction_count, subtypeMessages
SlackFilefile_id, name, filetype, size, url, created, channelsFiles
SlackReactionname, count, message_tsReactions

Relationships Created

RelationshipFromTo
POSTED_INSlackMessageSlackChannel
SENT_BYSlackMessageSlackUser
REACTED_TOSlackReactionSlackMessage
REPLIED_TOSlackMessageSlackMessage
UPLOADED_TOSlackFileSlackChannel
MEMBER_OFSlackUserSlackChannel

Graph Queries

cypher
-- Find the most active channels by message count
MATCH (m:SlackMessage)-[:POSTED_IN]->(c:SlackChannel)
RETURN c.name, count(m) AS message_count
ORDER BY message_count DESC
LIMIT 10

-- Find top contributors across all channels
MATCH (m:SlackMessage)-[:SENT_BY]->(u:SlackUser)
WHERE u.is_bot = false
RETURN u.real_name, count(m) AS messages
ORDER BY messages DESC
LIMIT 10

-- Map cross-channel activity (users who post in multiple channels)
MATCH (u:SlackUser)<-[:SENT_BY]-(m:SlackMessage)-[:POSTED_IN]->(c:SlackChannel)
WITH u, collect(DISTINCT c.name) AS channels
WHERE size(channels) > 3
RETURN u.real_name, channels

Configuration Reference

json
{
  "name": "Company Slack",
  "source_type": "slack",
  "config": {
    "bot_token": "xoxb-...",
    "user_token": "xoxp-...",
    "modules": ["channels", "users", "messages", "reactions", "files", "threads"],
    "channels_filter": "engineering,product,support",
    "message_days": 30,
    "include_private": false,
    "include_threads": false
  }
}
FieldTypeDefaultDescription
bot_tokenstringrequiredBot User OAuth Token (xoxb-...)
user_tokenstring--User OAuth Token for extended permissions
modulesstring[]allModules to enable for ingestion
channels_filterstring--Comma-separated channel names or IDs to limit scope
message_daysnumber30Days of message history to ingest
include_privateboolfalseInclude private channels
include_threadsboolfalseInclude threaded replies

Troubleshooting

ErrorCauseFix
invalid_authBot token is invalid or revokedReinstall the Slack app to get a new token
not_in_channelBot is not a member of the target channelInvite the bot to the channel with /invite @agentcy
channel_not_foundChannel ID is incorrect or channel was deletedVerify the channel ID with slack_list_channels
missing_scopeBot lacks a required OAuth scopeAdd the missing scope in the Slack App settings and reinstall
ratelimitedSlack API rate limit exceededReduce message_days or add channels_filter to limit scope
account_inactiveUser token belongs to a deactivated userUse a bot token instead or reactivate the user

Built by AgentcyLabs. For in-house deployment or Agentcy Cloud (PaaS) access, visit agentcylabs.com.