Skip to main content
Glama
errajibadr

TwilioManager MCP

by errajibadr

list_twilio_subaccounts

Retrieve and manage Twilio subaccounts by listing all available accounts or filtering them using friendly names for better organization and oversight.

Instructions

List all Twilio subaccounts or filter by friendly name. Provide an empty string for all subaccounts

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The @mcp.tool decorator and the handler function that implements the tool logic by delegating to AsyncTwilioManager.list_subaccounts()
    @mcp.tool(
        name="list_twilio_subaccounts",
        description="List all Twilio subaccounts or filter by friendly name. Provide an empty string for all subaccounts",
    )
    async def list_all_twilio_subaccounts() -> list[dict]:
        """
        List all Twilio subaccounts or filter by friendly name.
        Args:
            friendly_name: Optional filter by friendly name (empty string for all)
        Returns:
            List of subaccount details
        """
        async with async_twilio_manager:
            return await async_twilio_manager.list_subaccounts()
  • Core helper method in AsyncTwilioManager that performs the actual Twilio API call to list subaccounts, supporting optional friendly_name filter and with_token flag.
    async def list_subaccounts(
        self, friendly_name: Optional[str] = None, with_token: bool = False
    ) -> List[Dict]:
        """
        List all subaccounts or filter by friendly name.
    
        Args:
            friendly_name: Optional filter by friendly name
    
        Returns:
            List of subaccount details
        """
        try:
            params = {}
            if friendly_name:
                params["friendly_name"] = friendly_name
    
            accounts = await self.client.api.v2010.accounts.list_async(**params)
            return [
                {
                    "sid": account.sid,
                    "friendly_name": account.friendly_name,
                    "auth_token": account.auth_token if with_token else None,
                }
                for account in accounts
            ]
    
        except Exception as e:
            self.logger.error(f"Failed to list subaccounts: {str(e)}")
            raise
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It describes the basic operation (listing/filtering subaccounts) but lacks details on permissions, rate limits, pagination, or response format. For a tool with zero annotation coverage, this is a significant gap in transparency.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that front-loads the main purpose and includes essential details without waste. It's appropriately sized for a simple tool with no parameters, making it easy to understand quickly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's low complexity (0 parameters, no output schema, no annotations), the description is adequate but has clear gaps. It covers the basic operation but lacks details on behavioral aspects like response format or error handling. Without annotations or output schema, the description should do more to compensate, but it's minimally viable for this simple case.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 0 parameters with 100% coverage, so no parameters are documented in the schema. The description adds value by explaining that filtering by friendly name is possible and that an empty string returns all subaccounts, which clarifies the tool's behavior beyond the empty schema. Since there are 0 parameters, the baseline is 4, and the description provides useful context.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose with a specific verb ('List') and resource ('Twilio subaccounts'), and mentions optional filtering by friendly name. However, it doesn't explicitly differentiate this tool from its sibling tools (get_account_phone_numbers, get_all_phone_numbers, get_regulatory_bundle_sid), which appear to be related but distinct operations. The description is clear but lacks sibling differentiation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage context by mentioning filtering by friendly name and providing an empty string for all subaccounts, but it doesn't explicitly state when to use this tool versus alternatives or any prerequisites. There's no guidance on when not to use it or comparisons with sibling tools, leaving usage somewhat ambiguous.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/errajibadr/twilio_manager_mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server