Skip to main content
Glama

Check a bot project

check_telegram_project
Read-onlyIdempotent

Scans a Python Telegram bot project to validate Bot API calls against the official schema and returns errors and warnings for invalid, unknown, or retired methods and parameters. Use before upgrades.

Instructions

Check every Bot API call in a Python bot project (aiogram, python-telegram-bot, pyTelegramBotAPI, raw HTTP requests) against the current official schema in one run.

Use it after changing an existing bot, before an upgrade, or when asked to review a bot: it reads the whole project locally and returns only findings, so the documentation does not have to enter the context. Errors: values outside the documented list (for example style="red"), unknown methods or parameters in raw API requests. Warnings: parameters Telegram retired, with the Bot API version and changelog entry that replaced them; keyword arguments that are neither Bot API parameters nor known library options; bot methods with no Bot API counterpart. It does not run code, follow variables or check required parameters. Returns findings ({file, line, severity, call, message}), errors, warnings, files_scanned, declared libraries with versions and bot_api_version. To check one request instead use check_bot_api_call. The same check runs in a shell or CI as telegram-dev check PATH.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "path": "<path>"
    },
    "name": "check_telegram_project"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYesAbsolute path to the bot project directory or a single Python file on this machine.
excludeNoGlob patterns relative to path to skip, e.g. ['tests/*', 'migrations/*'].
max_findingsNoMaximum number of findings to return; totals always count everything.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.9.0

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already cover readOnly/idempotent/non-destructive; the description goes further by stating it reads the project locally, that documentation never enters context, and exactly what counts as an error versus a warning. It also declares the limits ('does not run code, follow variables or check required parameters'), which prevents the agent from over-trusting a clean result.

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

Conciseness4/5

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

Front-loads the core action in the first sentence, then routes usage, then enumerates errors/warnings, limits, and return shape in a logical order. It is dense and slightly long, but each sentence carries information an agent needs; only the trailing shell/CI note is arguably optional.

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

Completeness5/5

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

No output schema exists, and the description compensates by listing the returned fields (findings with file/line/severity/call/message, errors, warnings, files_scanned, libraries, bot_api_version). Combined with the stated limitations and severity taxonomy, an agent has everything needed to call it and interpret the result.

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 100% and each parameter (path, exclude globs, max_findings) is documented in the schema itself, so the baseline applies. The description adds only the incidental detail that 'totals always count everything' beyond max_findings; it never mentions exclude or path semantics, so it does not meaningfully exceed the 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?

States a specific verb and resource: 'Check every Bot API call in a Python bot project ... against the current official schema in one run', and enumerates the covered libraries (aiogram, python-telegram-bot, pyTelegramBotAPI, raw HTTP). It explicitly distinguishes itself from the sibling check_bot_api_call, which handles a single request rather than a whole project.

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

Usage Guidelines5/5

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

Gives concrete triggers ('after changing an existing bot, before an upgrade, or when asked to review a bot') and names the alternative for the narrow case ('To check one request instead use check_bot_api_call'). It also notes the equivalent CI/shell invocation, so the agent knows when this tool is the right entry point versus a runtime check.

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