Skip to main content
Glama
DLHellMe
by DLHellMe

api_logout

Disconnect from Telegram API to terminate active sessions and ensure secure account management by ending API connections.

Instructions

Disconnect from Telegram API

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function that executes the api_logout tool logic: disconnects the Telegram API scraper instance if it exists and returns a success message.
    async handleApiLogout(this: any): Promise<any> {
      if (this._apiScraper) {
        await this._apiScraper.disconnect();
        this._apiScraper = null;
      }
      
      return {
        content: [{
          type: 'text',
          text: '✅ Disconnected from Telegram API'
        }]
      };
    }
  • src/server.ts:373-381 (registration)
    Registration of the 'api_logout' tool in the getTools() method, including its name, description, and empty input schema.
    {
      name: 'api_logout',
      description: 'Disconnect from Telegram API',
      inputSchema: {
        type: 'object',
        properties: {},
        required: []
      }
    }
  • src/server.ts:107-108 (registration)
    Dispatch case in the tool call handler that routes 'api_logout' calls to the bound handleApiLogout method.
    case 'api_logout':
      return await this.handleApiLogout();
  • Binding of the apiHandlers.handleApiLogout method to the class instance for use in tool dispatching.
    private handleApiLogout = apiHandlers.handleApiLogout.bind(this);
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. While 'Disconnect' implies a state change, it doesn't specify whether this is reversible, what authentication is required, what side effects occur (e.g., session termination), or what happens on success/failure. For a tool with zero annotation coverage, this leaves significant behavioral gaps.

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 with zero wasted words. It's front-loaded with the essential action and resource, making it immediately understandable without any unnecessary elaboration.

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?

For a zero-parameter tool with no output schema, the description provides the basic purpose but lacks important context. It doesn't explain what 'disconnect' entails operationally, what state changes occur, or what verification might be needed. Given the complexity (simple action) but absence of annotations, this is minimally adequate but incomplete.

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 zero parameters, and schema description coverage is 100%, so there are no parameters to document. The description appropriately doesn't discuss parameters, earning a baseline score of 4 for this dimension since no parameter information 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 'Disconnect from Telegram API' clearly states the action (disconnect) and target resource (Telegram API), making the purpose immediately understandable. It doesn't explicitly differentiate from sibling tools like 'telegram_logout', but the verb+resource combination is specific enough for basic understanding.

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

Usage Guidelines2/5

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

No guidance is provided about when to use this tool versus alternatives like 'telegram_logout'. The description states what it does but offers no context about prerequisites (e.g., must be logged in first), timing considerations, or comparisons with similar tools in the sibling list.

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/DLHellMe/telegram-mcp-server'

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