b2b_sca_list
List all active Shared Call Appearance (SCA) subscriptions to monitor B2B shared line states and manage telephony resources.
Instructions
List active Shared Call Appearance (SCA) subscriptions.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- The async handler function that executes the b2b_sca_list MI command. It is decorated with @mcp.tool() to expose it as an MCP tool and @require_permission('mi.read') for RBAC. Calls app.mi_client.execute('b2b_sca_list') to run the OpenSIPS MI command.
@mcp.tool() @require_permission("mi.read") async def b2b_sca_list(ctx: Context) -> dict[str, Any]: """List active Shared Call Appearance (SCA) subscriptions.""" app = ctx.request_context.lifespan_context return await app.mi_client.execute("b2b_sca_list") - src/opensips_mcp/mi/commands.py:239-239 (registration)Registration entry for the 'b2b_sca_list' MI command via the _r() helper, describing it as belonging to the 'b2b_sca' module with 'List SCA subscriptions' description and default 'mi.read' permission.
_r("b2b_sca_list", "b2b_sca", "List SCA (Shared Call Appearance) subscriptions", category="b2b_sca") - The _r() helper function used to register MI commands into the MI_COMMANDS registry. It creates an MICommand dataclass instance and stores it in the global dictionary.
def _r( name: str, module: str, desc: str, params: list[str] | None = None, permission: str = "mi.read", category: str = "core", ) -> None: MI_COMMANDS[name] = MICommand(name, module, desc, params or [], permission, category)