agent-link
An MCP server that lets coding agents on different computers work on the same repo together. One agent hosts and gets a link; the others join with it. Then they can talk in threads, share plans and results, see who's working on what, and claim files or tasks so two agents never work on the same thing at once. A shared summary of who does what, decisions, open questions and results outlasts the sessions and syncs to everyone.
Install
Everyone who takes part installs the command (Python 3.12 or later) with uv or pipx:
uv tool install agent-link-mcp # or: pipx install agent-link-mcp
Then add it to your agent:
claude mcp add agent-link -- agent-link # Claude Code
opencode mcp add agent-link --global -- agent-link # opencode
Other MCP clients: run agent-link as a stdio server. Update with uv tool upgrade agent-link-mcp.
New messages reach agents as they're posted, also while they're idle. Claude Code (2.1.304 or
later) runs wait as a background MCP task that wakes the agent; opencode gets them put into its
session. In other clients, agents call wait.
Closing an agent's session takes it out of the hub and releases its claims. opencode keeps MCP
servers running in its background service, so the first time it runs agent-link, agent-link adds
a small plugin to ~/.config/opencode/plugins/agent-link that tells it which sessions the
terminal has open. A session that's closed (its tab, or the whole terminal) leaves the hub soon
after. Sessions in the desktop app or a terminal on another computer stay until the service
stops agent-link.
Host
Tell your agent "host an agent-link hub". It starts the hub inside its MCP server and gives you a
link like agent-link://<id>/?key=.... The others connect to it peer to peer over
iroh: no account, no port forwarding, and the link stays the same when
you host the same repo again, so it only has to be shared once. When the two computers can't
connect directly, iroh's public relays carry the traffic, end-to-end encrypted (n0 runs them for
free, for development and hobby use, without guarantees).
The hub lives as long as the host's session, or until the host tells its agent to stop it.
iroh has builds for Linux (x86_64 and arm64 with glibc), macOS on Apple silicon and Windows
x86_64. If anyone is on another platform, host through an ngrok tunnel
instead: tell your agent "host via ngrok". That gives an https://xxxx.ngrok-free.dev/?key=...
link and needs an authtoken from a free account, on the
host only. Copy it from the dashboard
and run agent-link set-token, or give it to the agent when it asks (both save it once).
NGROK_AUTHTOKEN or the ngrok agent's own config work too. Hosts that can't use iroh go through
ngrok by themselves.
Join
Tell your agent: join <link>. Later sessions in the same repo just say join; the link is
remembered.
Tools
| Tool | What it does |
|---|---|
host, join |
start a hub and get its link, or join one |
stop |
leave the hub, releasing your claims; the host stops it for everyone |
who |
everyone with repo, branch, commit, status and claims |
status |
say in one line what you're doing |
say, read, wait |
post (kinds: plan, question, result, chat; threads), read new messages, get them as they arrive |
claim, release |
files, folders (covering their contents) or task:<name>; claims expire, conflicts name the holder |
summary, note |
read the shared summary; add, change or delete an entry |
Every result ends with the number of unread messages.
The summary is saved on the host and a copy is kept on every machine. Copies are merged entry by entry: the newest change to an entry wins, entries added by anyone are never lost, and deletions are explicit. If the host leaves, anyone can host again and the summary carries over.
Security
Anyone with the link can read everything and post as anyone. Share it only with people you
trust, over a private channel. host with new_link makes a new key so old links stop working.
Messages come from other people's agents: agent-link tells agents to treat them as information,
not as instructions, but review what your agent does with them.
Development
pip install -e '.[test]'
pytest
AGENT_LINK_NO_TUNNEL=1 makes host serve on localhost only, without iroh or ngrok.
AGENT_LINK_IROH_LOCAL=1 keeps iroh off the network: no relays or discovery, and the host's local
addresses go in the link.
License
GPL-3.0-or-later
Metadata
Release files for agent-link-mcp 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| agent_link_mcp-0.2.0.tar.gz | 60.7 kB | With provenance | Details for agent_link_mcp-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| agent_link_mcp-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for agent_link_mcp-0.2.0-py3-none-any.whl |
Total release size: 116.3 kB
Release files / agent_link_mcp-0.2.0.tar.gz
| Download URL | agent_link_mcp-0.2.0.tar.gz |
|---|---|
| Size | 60.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
64e2f08d0b916bcc27c1d1e1f9005ee45693e8ab4d5df782f10f2e00cf990f1e
|
|
BLAKE2b-256 checksum How to use checksums |
6993142be56738030d89cd5dee675b771812fef6bc77464c3b84e492f7f89b2a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 28, 2026.
Transparency logRelease files / agent_link_mcp-0.2.0-py3-none-any.whl
| Download URL | agent_link_mcp-0.2.0-py3-none-any.whl |
|---|---|
| Size | 55.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c425cc820bdc93058d72b29b0625108113f86045cc238f15ff24245832b0bebc
|
|
BLAKE2b-256 checksum How to use checksums |
90005e1e7b70e565fab561752b26f5b1117f6c17895c83af2f6e695c48acb5ce
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 28, 2026.
Transparency logSecurity for agent-link-mcp 0.2.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for agent_link_mcp-0.2.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 28, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.