agentmux-sdk
Official Python SDK for AgentMux: health/capability discovery, direct Agent invocation (sync + SSE streaming), management resources, Console session embedding and a bootstrap installer.
The PyPI name
agentmuxbelongs to an unrelated project, so this package isagentmux-sdkand imports asagentmux_sdk.
pip install agentmux-sdk # or: uv add agentmux-sdk
Health handshake
from agentmux_sdk import AgentMuxClient
client = AgentMuxClient(
base_url="http://127.0.0.1:8765",
token="<bridge token>", # optional when bridge auth is disabled
min_version="v0.1.3", # optional consumer floor
)
report = client.health()
# report.state: ready | unauthorized | incompatible | unreachable | missing
print(report.state, report.version, report.contract_version)
Run an Agent
result = client.invoke(agent_id="agent-abc", input="summarize today's spending")
print(result.answer)
for event in client.invoke_stream(agent_id="agent-abc", input="analyze this portfolio"):
if event.type in ("output", "thinking"):
render(event.text) # full snapshot: replace previous text, don't append
elif event.type == "completed":
print(event.result.answer)
An async twin (AsyncAgentMuxClient) offers the same API with await /
async for.
Management resources
client.agents.list()
client.channels.list()
client.triggers.run("trigger-id")
client.orchestrations.create([{"id": "t1", "input": "..."}])
client.usage(period="daily")
client.send(project="myproj", text="deploy finished")
Embed the Console
session = client.console.create_session()
# Redirect the user's browser to session.enter_url (valid ~60s, single use).
# It sets an HttpOnly cookie and lands on the Console.
Install / upgrade AgentMux (bootstrap)
python -m agentmux_sdk.bootstrap --mode local --version v0.1.4
sudo AGENTMUX_BRIDGE_TOKEN=... python -m agentmux_sdk.bootstrap --mode production --version v0.1.4
Downloads are verified against the GoReleaser checksums.txt; installs use
an atomic current symlink switch with automatic rollback on failed health
checks.
Contract
This SDK speaks contract major 1 as defined in
contract/CONTRACT.md.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file agentmux_sdk-0.1.4.tar.gz.
File metadata
- Download URL: agentmux_sdk-0.1.4.tar.gz
- Upload date:
- Size: 26.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
uv/0.11.8 {"installer":{"name":"uv","version":"0.11.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b4eed099b89e59845e07b336d9f3724a96e74e78c03b091507394721a9e342a3
|
|
| MD5 |
658c33a4277a8ab1ef98cc5977ae6487
|
|
| BLAKE2b-256 |
7441ebf956910cd0fbd45599d5753b41b44fe98de429d1e2ca56ff2e55e362a5
|
File details
Details for the file agentmux_sdk-0.1.4-py3-none-any.whl.
File metadata
- Download URL: agentmux_sdk-0.1.4-py3-none-any.whl
- Upload date:
- Size: 21.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
uv/0.11.8 {"installer":{"name":"uv","version":"0.11.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2c29c5ff6f5464d85760727610d3d0d96cc1075600e6cfbc1cd2c541dbf9c8a9
|
|
| MD5 |
5d57fce2cb4b7bfff796b88f1f4beb1a
|
|
| BLAKE2b-256 |
f68895255e476b5cf4a6646b296940e539b3e8f639687ae8f729b8e5b4b1846a
|