cc_list_queue
List all calls currently queued in the call center to monitor and manage call flow.
Instructions
List all calls currently queued in the call center.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- The main handler function for the cc_list_queue MCP tool. Decorated with @mcp.tool() and @require_permission('mi.read'). It retrieves the lifespan context and executes the 'cc_list_queue' MI command via the MI client.
@mcp.tool() @require_permission("mi.read") async def cc_list_queue(ctx: Context) -> dict[str, Any]: """List all calls currently queued in the call center.""" app = ctx.request_context.lifespan_context result = await app.mi_client.execute("cc_list_queue") return result - src/opensips_mcp/mi/commands.py:154-154 (registration)Registration of cc_list_queue as a known MI command in the MI_COMMANDS registry. Declares it belongs to the 'call_center' module with 'mi.read' permission.
_r("cc_list_queue", "call_center", "List queued calls", category="call_center") - The cc_status tool uses cc_list_queue internally as a helper to fetch queue data as part of a combined call center status response.
@mcp.tool() @require_permission("mi.read") async def cc_status(ctx: Context) -> dict[str, Any]: """Get a combined call center status: queue, agents, and flows. Returns all three datasets in a single response for a complete overview of the call center state. """ app = ctx.request_context.lifespan_context queue = await app.mi_client.execute("cc_list_queue") agents = await app.mi_client.execute("cc_list_agents") flows = await app.mi_client.execute("cc_list_flows") return { "queue": queue, "agents": agents, "flows": flows, }