Skip to main content

Crate ringo_mcp

Crate ringo_mcp 

Source
Expand description

ringo-mcp — an MCP server over stdio that exposes ringo SIP agents (user agents) to LLM agents for telephony.

Architecture: one ringo-agent worker process per configured account (each worker is one baresip UA, driven over its framed stdio protocol), managed by a hub::Hub. Agents start lazily — the hub spawns a worker on the first tool call that touches an agent (single-flight), and a dead worker is respawned the same way. The MCP tool surface in [server] is a thin layer over the per-agent ringo_agent::ProcessClient handles.

The binary re-invokes itself as ringo-mcp agent for the worker processes (see ProcessClient::spawn, which spawns current_exe with the agent argument), so this crate is both the MCP server and the worker host.

Modules§

config
The ringo-mcp config file (TOML): a list of [[agent]] tables plus the optional [backend] and [ringo] tables.
hub
The agent hub: the configured agents and their (lazily spawned) worker processes.
trace
Read access to the workers’ SIP traces for the sip_trace tool.

Functions§

event_name
Compact JSON for one event, for wait_event. The event-field name for an [AppEvent] — the single naming source for event_json and wait_event’s optional filter.
resolve_disabled_tools
Resolve the flags to the list of tools to disable (passed to the router). enabled: the --enabled-tools allowlist (None = all enabled); disable: the --disable-<name> flag values, applied on top.
serve
Serve MCP over stdio until the client disconnects.
total_tool_count
How many tools exist in total (the group table’s union).