Get the FREE Ultimate OpenClaw Setup Guide →

mcp -mattermost

MCP server using the Mattermost API

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio kakehashi-inc-mcp-server-mattermost npx -y mcp-server-mattermost --transport stdio --endpoint ${MATTERMOST_ENDPOINT} --token ${MATTERMOST_TOKEN} --team ${MATTERMOST_TEAM} --channels ${MATTERMOST_CHANNELS} \
  --env MATTERMOST_TEAM="Team name to monitor" \
  --env MATTERMOST_TOKEN="Mattermost authentication token" \
  --env MATTERMOST_CHANNELS="Comma-separated list of channel names to monitor" \
  --env MATTERMOST_ENDPOINT="Mattermost server URL"

How to use

This MCP server provides a Mattermost integration for the Model Context Protocol. It connects to your Mattermost instance using a token-based authentication scheme and exposes channel content and context through MCP transports. The server supports three transport modes: stdio (default), sse, and http-stream, allowing you to integrate Mattermost data into other MCP-enabled tooling or assistants. You can search across multiple channels, configure default channels and fetch limits, and tailor the endpoint and team to monitor via environment variables or CLI flags. To begin, configure the required environment variables (endpoint, token, team, and channels), build if needed, and run the server with the desired transport. You can also run via npx for quick testing or embed the server in Claude Desktop using the provided sample configuration. The tools exposed include browsing messages across channels and streaming updates via the chosen transport, enabling responsive, context-rich interactions with Mattermost data.

How to install

Prerequisites:

  • Node.js >= 22
  • npm >= 10

Setup steps:

  1. Clone the repository git clone https://github.com/kakehashi-inc/mcp-server-mattermost.git cd mcp-server-mattermost

  2. Install dependencies npm install

  3. Configure environment variables (recommended by environment or .env file)

  4. Build the server (if required by the project build step) npm run build

  5. Run the server (example using stdio transport) npm run start:stdio

    or via npx for quick test

    npx mcp-server-mattermost --transport stdio

Additional notes

Environment variables are central to configuring this server. If you prefer not to expose tokens or endpoint details in command lines, store them in a .env file and use a dotenv tool as described in the README. When deploying, ensure the MATTERMOST_TOKEN has appropriate permissions for the channels you monitor. If channels change, update MATTERMOST_CHANNELS accordingly. The server supports multiple transports; choose stdio for local usage, sse for server-sent events streaming, or http-stream for HTTP-based streaming. For Claude Desktop integration, you can copy the sample configuration and adjust the endpoint, token, team, and channels to match your setup.

Related MCP Servers

Sponsor this space

Reach thousands of developers