slack_channel_history
Pack: slack_connect · Endpoint: https://gateway.pipeworx.io/slack_connect/mcp
Get message history from a Slack channel. Bot auto-joins the channel if needed.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
channel | string | yes | Channel ID (e.g., “C01234ABCDE”) |
limit | number | no | Max number of messages to return (default 20, max 1000) |
cursor | string | no | Pagination cursor for next page of results |
oldest | string | no | Only messages after this Unix timestamp |
latest | string | no | Only messages before this Unix timestamp |
Example call
Arguments
{
"channel": "C01234ABCDE",
"limit": 20
}
curl
curl -X POST https://gateway.pipeworx.io/slack_connect/mcp \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"slack_channel_history","arguments":{"channel":"C01234ABCDE","limit":20}}}'
TypeScript (@pipeworx/sdk)
import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();
const result = await pipeworx.call('slack_channel_history', {
"channel": "C01234ABCDE",
"limit": 20
});
More examples
{
"channel": "C01234ABCDE",
"limit": 100,
"oldest": "1609459200"
}
Response shape
| Field | Type | Description |
|---|---|---|
ok | boolean | Whether the API call succeeded |
messages | array | List of messages in the channel |
response_metadata | object | Pagination metadata |
error | string | Error code if API call failed |
message | string | Error message or connection message |
Full JSON Schema
{
"type": "object",
"properties": {
"ok": {
"type": "boolean",
"description": "Whether the API call succeeded"
},
"messages": {
"type": "array",
"description": "List of messages in the channel",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"description": "Message type (e.g., 'message')"
},
"user": {
"type": "string",
"description": "User ID of message sender"
},
"text": {
"type": "string",
"description": "Message text content"
},
"ts": {
"type": "string",
"description": "Unix timestamp with milliseconds"
},
"thread_ts": {
"type": "string",
"description": "Thread timestamp if message is in a thread"
},
"reply_count": {
"type": "number",
"description": "Number of replies in thread"
},
"reply_users_count": {
"type": "number",
"description": "Number of unique users who replied"
}
}
}
},
"response_metadata": {
"type": "object",
"description": "Pagination metadata",
"properties": {
"next_cursor": {
"type": "string",
"description": "Cursor for next page of results"
}
}
},
"error": {
"type": "string",
"description": "Error code if API call failed"
},
"message": {
"type": "string",
"description": "Error message or connection message"
}
}
}
Connect
Add this to your MCP client config, or use one-click install buttons:
{
"mcpServers": {
"slack_connect": {
"url": "https://gateway.pipeworx.io/slack_connect/mcp"
}
}
}
See Getting Started for client-specific install steps.