MCP Server for the Mattermost API, enabling Claude and other MCP clients to interact with Mattermost workspaces. The server supports multiple configuration methods with the following priority (highest to lowest): 1. CLI arguments (--url, --token, --team-id) 2. Environment variables (MATTERMOSTURL, MATTERMOSTTOKEN, MATTERMOSTTEAMID) 3. config.local.json (for local overrides, gitignored) 4. config.j
Add this skill
npx mdskills install conarti/mattermost-mcpComprehensive Mattermost integration with extensive tools, clear setup, and monitoring features
MCP Server for the Mattermost API, enabling Claude and other MCP clients to interact with Mattermost workspaces.
npx @conarti/mattermost-mcp --help
MATTERMOST_URL=https://your-mattermost.com/api/v4 \
MATTERMOST_TOKEN=your-token \
MATTERMOST_TEAM_ID=your-team-id \
npx @conarti/mattermost-mcp
npx @conarti/mattermost-mcp \
--url https://your-mattermost.com/api/v4 \
--token your-token \
--team-id your-team-id
npx @conarti/mattermost-mcp
npm install -g @conarti/mattermost-mcp
mattermost-mcp --help
git clone https://github.com/conarti/mattermost-mcp.git
cd mattermost-mcp
npm install
npm run build
npm start
The server supports multiple configuration methods with the following priority (highest to lowest):
--url, --token, --team-id)MATTERMOST_URL, MATTERMOST_TOKEN, MATTERMOST_TEAM_ID)| Argument | Description |
|---|---|
--url | Mattermost API URL (e.g., https://mattermost.example.com/api/v4) |
--token | Mattermost personal access token |
--team-id | Mattermost team ID |
--run-monitoring | Run topic monitoring immediately on startup |
--exit-after-monitoring | Exit after running monitoring (use with --run-monitoring) |
--help | Show help message |
| Variable | Description |
|---|---|
MATTERMOST_URL | Mattermost API URL |
MATTERMOST_TOKEN | Mattermost personal access token |
MATTERMOST_TEAM_ID | Mattermost team ID |
Create config.local.json (gitignored) or use config.json:
{
"mattermostUrl": "https://your-mattermost-instance.com/api/v4",
"token": "your-personal-access-token",
"teamId": "your-team-id",
"monitoring": {
"enabled": false,
"schedule": "*/15 * * * *",
"channels": ["town-square", "off-topic"],
"topics": ["tv series", "champions league"],
"messageLimit": 50
}
}
Add to your Claude Code MCP settings (~/.claude/claude_desktop_config.json or via claude mcp add):
{
"mcpServers": {
"mattermost": {
"command": "npx",
"args": ["-y", "@conarti/mattermost-mcp@latest"],
"env": {
"MATTERMOST_URL": "https://your-mattermost.com/api/v4",
"MATTERMOST_TOKEN": "your-token",
"MATTERMOST_TEAM_ID": "your-team-id"
}
}
}
}
Or using a config file:
{
"mcpServers": {
"mattermost": {
"command": "node",
"args": ["/path/to/mattermost-mcp/build/index.js"]
}
}
}
| Tool | Description |
|---|---|
mattermost_list_channels | List channels in the workspace (public, private, and DMs) |
mattermost_get_channel_history | Get messages from a channel with filtering options |
mattermost_list_channels Optionslimit (default: 100): Maximum number of channels to returnpage (default: 0): Page number for paginationinclude_private (default: false): If true, returns all channels including private channels and direct messages (DMs)mattermost_get_channel_history Optionschannel_id (required): The ID of the channellimit: Number of messages to retrieve. If not specified or 0, returns ALL messagespage (default: 0): Page number for pagination (only used when limit > 0)since_date: ISO 8601 date to get messages after (e.g., "2025-01-15")before_date: ISO 8601 date to get messages before. Use with since_date for date rangesbefore_post_id: Get messages before this post ID (cursor pagination)after_post_id: Get messages after this post ID (cursor pagination)Examples:
// Get ALL messages from a channel
{ "channel_id": "abc123" }
// Get last 50 messages
{ "channel_id": "abc123", "limit": 50 }
// Get all messages from December 18, 2025
{ "channel_id": "abc123", "since_date": "2025-12-18", "before_date": "2025-12-19" }
// Get messages from a specific date onwards
{ "channel_id": "abc123", "since_date": "2025-12-15" }
| Tool | Description |
|---|---|
mattermost_post_message | Post a new message to a channel |
mattermost_reply_to_thread | Reply to a specific message thread |
mattermost_add_reaction | Add an emoji reaction to a message |
mattermost_get_thread_replies | Get all replies in a thread |
| Tool | Description |
|---|---|
mattermost_get_users | Get a list of users in the workspace |
mattermost_get_user_profile | Get detailed profile information for a user |
| Tool | Description |
|---|---|
mattermost_run_monitoring | Trigger topic monitoring immediately |
The server includes a topic monitoring system that can:
{
"monitoring": {
"enabled": true,
"schedule": "*/15 * * * *",
"channels": ["general", "random"],
"topics": ["important", "urgent"],
"messageLimit": 50,
"notificationChannelId": "optional-channel-id",
"userId": "optional-user-id"
}
}
# Run monitoring and continue server
mattermost-mcp --run-monitoring
# Run monitoring and exit (useful for cron jobs)
mattermost-mcp --run-monitoring --exit-after-monitoring
Your Mattermost API URL is typically: https://your-mattermost-domain.com/api/v4
teams/ — the ID is in the URLOr use the Mattermost API:
curl -H "Authorization: Bearer YOUR_TOKEN" \
https://your-mattermost.com/api/v4/teams
Missing required configuration:
- mattermostUrl (--url or MATTERMOST_URL)
- token (--token or MATTERMOST_TOKEN)
- teamId (--team-id or MATTERMOST_TEAM_ID)
Make sure you've provided all required configuration via CLI arguments, environment variables, or config file.
Verify that:
MIT License
Install via CLI
npx mdskills install conarti/mattermost-mcpMattermost MCP Server is a free, open-source AI agent skill. MCP Server for the Mattermost API, enabling Claude and other MCP clients to interact with Mattermost workspaces. The server supports multiple configuration methods with the following priority (highest to lowest): 1. CLI arguments (--url, --token, --team-id) 2. Environment variables (MATTERMOSTURL, MATTERMOSTTOKEN, MATTERMOSTTEAMID) 3. config.local.json (for local overrides, gitignored) 4. config.j
Install Mattermost MCP Server with a single command:
npx mdskills install conarti/mattermost-mcpThis downloads the skill files into your project and your AI agent picks them up automatically.
Mattermost MCP Server works with Claude Code, Claude Desktop, Cursor, Vscode Copilot, Windsurf, Continue Dev, Gemini Cli, Amp, Roo Code, Goose. Skills use the open SKILL.md format which is compatible with any AI coding agent that reads markdown instructions.