Skip to main content
Glama

create_cli_token

Generate a CLI token to execute Airflow commands in Amazon MWAA environments for workflow automation and management.

Instructions

Create a CLI token for executing Airflow CLI commands.

Args: name: The name of the MWAA environment

Returns: Dictionary containing the CLI token and webserver hostname

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The implementation of the 'create_cli_token' tool, which calls the MWAA client's create_cli_token method.
    async def create_cli_token(self, name: str) -> Dict[str, Any]:
        """Create a CLI token for the environment."""
        try:
            response = self.mwaa_client.create_cli_token(Name=name)
            return {
                "CliToken": response["CliToken"],
                "WebServerHostname": response["WebServerHostname"],
            }
    
        except (ClientError, BotoCoreError) as e:
            logger.error("Error creating CLI token for %s: %s", name, e)
            return {"error": str(e)}
  • The registration of the 'create_cli_token' tool in the MCP server.
    @mcp.tool(name="create_cli_token")
    async def create_cli_token(
        name: str,
    ) -> Dict[str, Any]:
        """Create a CLI token for executing Airflow CLI commands.
    
        Args:
            name: The name of the MWAA environment
    
        Returns:
            Dictionary containing the CLI token and webserver hostname
        """
        return await tools.create_cli_token(name)
Behavior3/5

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

No annotations provided, so description carries full burden. Documents return value structure (Dictionary with token and hostname), but omits critical behavioral details: token expiration/TTL, required IAM permissions, and whether creation invalidates previous tokens.

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?

Docstring format with Args/Returns sections is efficient and well-structured. Every clause earns its place; front-loaded purpose followed by input/output specifications.

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?

Adequate for a single-parameter tool with documented returns, but incomplete regarding sibling differentiation (create_web_login_token) and token lifecycle management details expected for a credential-generation tool.

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?

Schema coverage is 0% (no parameter descriptions), but description compensates by documenting 'name' as 'The name of the MWAA environment', adding crucial domain context (MWAA) absent from the raw schema.

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

Purpose5/5

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

Specific verb 'Create' with clear resource 'CLI token' and purpose 'for executing Airflow CLI commands'. Explicitly distinguishes from sibling 'create_web_login_token' by specifying 'CLI token' versus web login.

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?

Implies usage context (when you need CLI access), but lacks explicit 'when to use vs alternatives' guidance. Does not reference sibling 'create_web_login_token' to clarify selection criteria.

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/paschmaria/mwaa-mcp-server'

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