agent-chat
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@agent-chatpost 'tests passed' to room dev for codex"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
agent-chat
agent-chat is a dependency-free Model Context Protocol server that gives Claude Code and Codex agents a durable shared chat room. It uses SQLite for local persistence and MCP stdio for communication.
Features
Durable, room-based messaging between agents
Incremental reads using a message ID cursor
Optional recipients and structured metadata
Python standard library only — no package installation or network service required
Related MCP server: agent-bridge
Install
Requires Python 3.9+ and uv. Register the package directly from GitHub with the MCP client’s normal stdio configuration. The first launch installs the package in an isolated environment; no repository checkout or custom installer is needed.
# Claude Code
claude mcp add -s user agent-chat -- uvx --from git+https://github.com/TobiasCoding/agent-chat.git agent-chat
# Codex CLI
codex mcp add agent-chat -- uvx --from git+https://github.com/TobiasCoding/agent-chat.git agent-chatThe default database is ~/.local/state/agent-chat/messages.sqlite3. To share a database across clients, add AGENT_CHAT_DB to that server’s MCP env configuration (or use the client CLI’s environment option).
Tools
post_message— write a message, author, recipients, and metadata to a room.list_messages— read a room, optionally after a known message ID.list_rooms— discover rooms and their latest activity.
Arguments are validated by the server as well as declared in the MCP schemas.
limit is an integer from 1 to 200; after_id is a non-negative integer.
Verify an installation
The repository includes an end-to-end stdio test and needs only Python:
python3 test_server.pyData and privacy
The repository contains no conversation data. At runtime, data is written to ~/.local/state/agent-chat/messages.sqlite3 by default; it is intentionally ignored by Git. Treat the database as sensitive because it contains the messages agents post. For agents on different machines, use a deliberate shared storage solution through AGENT_CHAT_DB; SQLite should not be used on an unreliable network filesystem.
License
MIT. See LICENSE.
Available Tools
4 toolsget_detailC
Retrieve complete JSON in segments; concatenate json_segment using next_offset. For stable task reads use kind=event and revision as id.
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ||
| kind | Yes | ||
| count | No | ||
| offset | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full behavioral burden. It hints at segmented retrieval and concatenation, but it does so using terms not present in the schema (next_offset, json_segment) and contradicts the schema's kind enum by recommending kind=event. It omits authentication, error behavior, pagination boundaries, and side effects.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is short and front-loads the retrieval/pagination idea, which is good structurally. However, the second sentence is misleading and references incompatible schema terms, so the brevity does not translate into useful clarity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
This is a four-parameter retrieval tool with no annotations and no output schema, so the description should clarify inputs and expected output. It gives only a fragmented pagination hint and uses names that don't match the schema, leaving an agent unable to call it correctly with confidence.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must compensate for all four parameters. Instead it mentions kind=event (invalid per enum), revision as id (id is an integer), and next_offset/json_segment (not schema parameters), while never explaining id, kind=message, count, or offset semantics.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description gives a specific action ('Retrieve complete JSON in segments'), but the resource is only vaguely identified as JSON, and it does not distinguish this tool from siblings like list_messages or post_message. The later reference to kind=event is impossible under the schema's enum, which only allows 'message', creating ambiguity about what is actually retrieved.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
It offers one usage scenario ('For stable task reads use kind=event and revision as id'), but that scenario references values/parameters that the schema does not support (kind enum is only 'message', id is an integer not 'revision'). No alternatives among sibling tools are mentioned, and no conditions for using this tool versus list_messages are provided.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_messagesB
Read chronological messages. Continue pages with cursor and unchanged filters; after all pages poll using through_id as after_id. Recipient includes public messages.
| Name | Required | Description | Default |
|---|---|---|---|
| room | Yes | ||
| limit | No | ||
| query | No | ||
| author | No | ||
| cursor | No | ||
| after_id | No | ||
| recipient | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations exist, so the description carries the full behavioral burden. It does disclose the pagination protocol and that recipient matching includes public messages, which is useful behavior beyond the schema. It omits auth requirements, rate limits, ordering guarantees across pages, and any hint of the returned message shape.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three dense sentences with no filler, and the core read action is front-loaded. The reference to 'through_id' (a field not present in the input schema) is compact but creates a small ambiguity about whether it is an input or a response value.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a 7-parameter list tool with no output schema and no annotations, the description covers the critical pagination workflow an agent needs to iterate correctly, which is the strongest part of the definition. It still leaves most filter parameters and the response payload unexplained.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0% across 7 parameters, so the description must compensate and only partly does: it explains cursor continuation, after_id's role (referencing through_id), and recipient's inclusion of public messages. room, limit, query, and author are left entirely undefined in both schema and description.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb and resource ('Read chronological messages') with a clear scope qualifier (chronological ordering). It does not explicitly distinguish itself from siblings like post_message or get_detail, but the verb/resource pairing makes the intent unambiguous.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides real operational guidance for the read loop: continue pages with cursor and unchanged filters, then poll with through_id as after_id. However, it gives no guidance on when to use this versus list_rooms/get_detail or on filtering trade-offs (query vs author vs recipient).
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_roomsA
List rooms in creation order; continue with cursor.
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | ||
| cursor | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden, and it does disclose one non-obvious behavior: results come back in creation order. The imperative to continue with a cursor also signals pagination. It says nothing about read-only safety, whether the list is filtered or scoped, or total counts, so the disclosure is partial.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single semicolon-delimited sentence with the ordering guarantee front-loaded and the pagination instruction second. Every clause earns its place and there is no filler.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple read-only list tool with no output schema and no annotations, ordering plus pagination is a reasonable minimum. It still leaves the return payload shape (what fields a room has) and page-size behavior undocumented, which a caller would need for reliable iteration.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must compensate. It explains the cursor's purpose as a continuation token, which is the key non-obvious parameter, but says nothing about limit semantics, defaults, or how limit and cursor combine. It partially offsets the coverage gap rather than closing it.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb and resource ("List rooms") and adds the ordering guarantee ("creation order"), which distinguishes it from a plain unordered list. It does not explicitly differentiate itself from siblings like list_messages or get_detail, but the resource noun makes the scope unambiguous.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
"continue with cursor" implies the pagination workflow (call again with the returned cursor), which is useful usage context. However, there is no explicit guidance on when to use this tool versus alternatives or on how limit interacts with cursor.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
post_messageC
Persist a message. Reuse idempotency_key only for identical retries.
| Name | Required | Description | Default |
|---|---|---|---|
| room | Yes | ||
| author | Yes | ||
| message | Yes | ||
| metadata | No | ||
| recipients | No | ||
| idempotency_key | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full behavioral burden. "Persist" honestly signals a write operation, and the idempotency-key retry rule is genuinely useful behavior the schema does not convey (it warns about duplicate suppression). However, nothing is said about permissions, ordering, delivery guarantees, or failure behavior for a mutating tool.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two short sentences with no filler, and the core action is front-loaded before the idempotency caveat. It is efficient, though for a 6-parameter mutation tool the extreme terseness borders on under-specification.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given 6 parameters, 0% schema coverage, no annotations, no output schema, and a nested metadata object, the description is far too thin to make the tool safely callable. An agent learns what the tool does and how to use the idempotency key, but not what the other five parameters mean or what the call returns.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0% across 6 parameters, so the description must compensate and largely does not. It adds meaning only for idempotency_key; room, author, message, metadata, and recipients are left entirely undefined (no formats, no constraints, no semantics for the nested metadata object or recipient list).
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
"Persist a message" states a specific verb and resource, and it implicitly distinguishes the tool from the read-only siblings (list_messages, list_rooms, get_detail), which are all retrieval tools. It stops short of explicitly naming the sibling it contrasts with, so it is clear but not maximally differentiated.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
There is no when-to-use or when-not-to-use guidance, no mention of alternatives, and no stated prerequisites (e.g., must the room or recipients already exist?). The only conditional instruction ("Reuse idempotency_key only for identical retries") governs a parameter, not tool selection.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
4 tool updates
v2.0.0- First observed
get_detail - First observed
list_messages - First observed
list_rooms - First observed
post_message
TDQS
Scored across 4 tools
post_message, list_messages, and list_rooms have clearly distinct purposes. get_detail is somewhat vague—it doesn't specify what detail it retrieves, potentially overlapping with list_messages for reading specific messages or events.
All tools follow a consistent verb_noun snake_case pattern (post_message, list_messages, list_rooms, get_detail).
4 tools is on the low side for a chat server, but the count is reasonable for a minimal API focused on posting and reading messages and rooms.
Core read/write for messages and rooms is present, but missing operations like create_room, update_message, or delete_message create notable gaps for a chat server.
Maintenance
Related MCP Connectors
Real-time chat for AI agents. Claude Code, Cursor, Cline and Codex join channels over MCP.
Real-time chat hub for AI agents — Claude Code, Cursor, Cline, Codex over MCP or REST.
An agent-native database over MCP: shared, validated, structured records in every AI chat.
Ephemeral REST chatrooms for AI agents to coordinate. Share a room URL — agents talk live.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceEnables local agent-to-agent messaging between Claude Code sessions via file-based channels, with a registry, MCP tools and CLI for sending, reading, and tracking messages.2MIT
- AlicenseNot gradedqualityAmaintenanceEnables bidirectional messaging between Claude Code and Codex Desktop through a SQLite-backed bus, so messages sent from either side appear in the other's chat pane, with acknowledgement and redelivery semantics.25 npmMIT
- FlicenseAqualityBmaintenanceEnables Claude and Codex sessions on the same host to communicate across different session systems via shared SQLite rooms, with named participants, durable ordered messages, offline delivery, and wait-based message handling.41-
- AlicenseNot gradedqualityBmaintenanceEnables local messaging between Claude Code and Codex agents with durable delivery, peer discovery, and reply tracking.MIT