# chatmux [Health: Active]

**Category:** 💬 Communication  
**Repository:** https://github.com/echoedinvoker/chatmux  
**GitHub Stars:** 1  
**Views:** 2  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/chatmux

## Description
Local-first MCP server for your own LINE and Telegram chats. Data stays on your machine.

## Tools
Capabilities this server exposes over MCP:

- **list_chats** — List chats with last message preview, search, pagination
- **read_messages** — Read messages from a chat, paginated by timestamp
- **read_events** — Tail the event log from an opaque cursor — resumable, survives backfill reordering, and re-delivers a message when it is edited or retracted
- **search_messages** — Full-text search (CJK supported via FTS5 trigram + LIKE fallback)
- **send_message** — Send message through SafetyRail (rate-limited, error-tracked)
- **get_media** — Local file path for a message's image or sticker; downloads and caches on first call
- **probe_latest** — Diagnostic, read-only: ask the adapter for a chat's newest N messages without landing them
- **get_status** — System status: adapter connection + storage stats

## Claude Desktop Quick Installation
No generated config for this server: it installs through its own setup steps.

The project's own setup steps (from https://github.com/echoedinvoker/chatmux), copied verbatim. Follow them in order; they are not an mcpServers config.

1. Install:

```sh
git clone https://github.com/echoedinvoker/chatmux.git
```

2. Install:

```sh
cd chatmux
```

3. Install:

```sh
bun install
```

4. Configure:

```sh
mkdir -p ~/.local/share/chatmux
```

5. Configure:

```sh
cat > ~/.local/share/chatmux/adapters.json <<'JSON'
{
  "adapters": [],
  "mcp": { "port": 7717 }
}
JSON
```

6. Start the server:

```sh
bun run start
```

## Documentation

## What the chatmux MCP server does

The chatmux MCP server provides a local data layer for personal conversations. Its core daemon currently includes a LINE adapter, while Telegram can be connected through the separate `chatmux-adapter-telegram` project. Adapters run below the core process, and MCP clients connect above it, so either side can be replaced without changing the other boundary.

Chat data is stored locally in an append-only JSONL log and a SQLite view with FTS5 indexing. The MCP interface exposes chat lists, message history, event-log access, full-text search, media retrieval, diagnostics, system status, and message sending. Four MCP resources also provide chat lists, recent messages, chat information, and status.

## How it works

The Bun daemon starts an adapter as a child process and communicates with it through the adapter protocol. The default LINE setup uses a Node and `tsx` process. The daemon keeps the event log as the durable record, then maintains SQLite and FTS5 data for queries.

MCP requests are served over Streamable HTTP on a TCP listener bound to `127.0.0.1` by default. Same-host sidecars can use the Unix socket. The HTTP endpoint is suitable for standard MCP clients, while the socket is intended for local consumers such as the referenced Neovim client. `read_events` accepts an opaque cursor, allowing a consumer to resume from its prior position and receive edits or retractions again.

## Setup and configuration

Install Bun dependencies from a cloned repository with `bun install`, then start the daemon with `bun run start`. With no adapter configuration, startup launches the LINE adapter and displays a QR login flow. To run the storage and MCP interface without connecting an account, create an `adapters.json` file with an empty adapter list. `CHATMUX_DATA_DIR` can point that trial run at a separate directory.

Each adapter entry specifies a platform, command string, argument array, and optionally a working directory and environment. Telegram requires the separate adapter project's credentials and login procedure. Configure the MCP TCP port with `CHATMUX_MCP_PORT` or the `mcp.port` setting; setting the port to `0` disables that listener. Container deployments must set `CHATMUX_MCP_HOST` appropriately because the default loopback binding is local to the container.

A provided systemd user unit can keep the daemon running and restart it after exits. Edit its working directory before enabling it. The container files are a reference deployment rather than an official image and intentionally run no adapters.

## Tools and capabilities

The chatmux MCP server exposes these operations:

- `list_chats` returns chats with previews, search, and pagination.
- `read_messages` reads timestamp-paginated messages.
- `read_events` tails resumable changes from an opaque cursor.
- `search_messages` searches message text, including CJK through trigram FTS5 with a `LIKE` fallback.
- `send_message` sends through a rate-limited, error-tracked SafetyRail.
- `get_media` returns a local path for an image or sticker, downloading and caching it on first use.
- `probe_latest` asks an adapter for recent messages without importing them.
- `get_status` reports adapter and storage state.

## Limitations and notes

The chat list is capped at 1,000 entries. Consumers can compare the returned total with the received results to detect overflow. The JSONL event log may contain duplicate historical entries from earlier backfills, so its size can exceed the current message view. Sending is mediated by SafetyRail, but the material does not define a broader approval policy; consumer applications decide which messages to surface or when to reply. The daemon is designed for local operation, and exposing its listener beyond the intended network boundary requires explicit host configuration.

_Full upstream README: https://allmcps.com/mcp/chatmux/readme_

