Skip to main content
Glama

get_configuration_status

Verify if your OpenRouter API token is properly configured for image generation and editing operations.

Instructions

Check if OpenRouter API token is configured

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function that executes the tool logic. It checks if the OpenRouter API token is configured by verifying if config and openai instances are set, then returns a text response indicating the status and configuration source or instructions on how to configure.
      private async getConfigurationStatus(): Promise<CallToolResult> {
        const isConfigured = this.config !== null && this.openai !== null;
        
        let statusText: string;
        let sourceInfo = "";
        
        if (isConfigured) {
          statusText = "āœ… OpenRouter API token is configured and ready to use";
          
          switch (this.configSource) {
            case 'environment':
              sourceInfo = "\nšŸ“ Source: Environment variable (OPENROUTER_API_KEY)\nšŸ’” This is the most secure configuration method.";
              break;
            case 'config_file':
              sourceInfo = "\nšŸ“ Source: Local configuration file (.openrouter-image-config.json)\nšŸ’” Consider using environment variables for better security.";
              break;
          }
        } else {
          statusText = "āŒ OpenRouter API token is not configured";
          sourceInfo = `
    
    šŸ“ Configuration options (in priority order):
    1. šŸ„‡ MCP client environment variables (Recommended)
    2. 🄈 System environment variable: OPENROUTER_API_KEY  
    3. šŸ„‰ Use configure_openrouter_token tool
    
    šŸ’” For the most secure setup, add this to your MCP configuration:
    "env": { "OPENROUTER_API_KEY": "your-api-key-here" }
    
    šŸ”‘ Get your API key from: https://openrouter.ai/settings/keys`;
        }
        
        return {
          content: [
            {
              type: "text",
              text: statusText + sourceInfo,
            },
          ],
        };
      }
  • src/index.ts:127-135 (registration)
    Tool registration in the listTools handler, including name, description, and input schema (empty object).
    {
      name: "get_configuration_status",
      description: "Check if OpenRouter API token is configured",
      inputSchema: {
        type: "object",
        properties: {},
        additionalProperties: false,
      },
    },
  • src/index.ts:187-188 (registration)
    Dispatch case in the CallToolRequest handler that routes the tool call to the getConfigurationStatus method.
    case "get_configuration_status":
      return await this.getConfigurationStatus();
  • Input schema definition for the tool: an empty object with no additional properties.
    inputSchema: {
      type: "object",
      properties: {},
      additionalProperties: false,
    },
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states the action ('Check') but doesn't describe what the check entails (e.g., returns a boolean, error message, or status details), potential side effects, or authentication requirements. This leaves gaps in understanding the tool's behavior.

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, clear sentence that efficiently conveys the tool's purpose without unnecessary words. It is front-loaded and appropriately sized for a simple tool, with no wasted information.

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

Completeness2/5

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

Given the tool's simplicity (0 parameters, no annotations, no output schema), the description is minimal but lacks completeness. It doesn't explain what the output might be (e.g., success/failure status, configuration details), which is critical for a check operation. This leaves the agent uncertain about how to interpret results.

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 tool has 0 parameters with 100% schema description coverage, so the schema fully documents the lack of inputs. The description adds no parameter information, which is appropriate here, and the baseline score for 0 parameters is 4, as no compensation is needed.

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 ('Check') and resource ('OpenRouter API token configuration'), making it immediately understandable. It doesn't explicitly differentiate from sibling tools like 'configure_openrouter_token', but the distinction is implied through the action (checking vs. configuring).

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 (verifying token setup) but doesn't provide explicit guidance on when to use this tool versus alternatives like 'configure_openrouter_token' or other siblings. It lacks details on prerequisites, error conditions, or specific scenarios where this check is necessary.

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/WeiYu021/openrouter-image-MCP'

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