Skip to main content
Glama
TONresistor

Telegram MCP Server

by TONresistor

answerPreCheckoutQuery

Answer a Telegram pre-checkout query to approve an order, or reject it with a human-readable error message when problems prevent checkout.

Instructions

Respond to pre-checkout queries. Once the user has confirmed their payment and shipping details, the Bot API sends the final confirmation in the form of an Update with the field pre_checkout_query. Use this method to respond to such pre-checkout queries. On success, True is returned. Note: The Bot API must receive an answer within 10 seconds after the pre-checkout query was sent.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
okYesSpecify True if everything is alright (goods are available, etc.) and the bot is ready to proceed with the order. Use False if there are any problems.
error_messageNoRequired if ok is False. Error message in human readable form that explains the reason for failure to proceed with the checkout.
pre_checkout_query_idYesUnique identifier for the query to be answered

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv1.0.0

TDQS

A4.2/5.0
Behavior4/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. It discloses the success return value ('True is returned') and the essential 10-second deadline. It does not detail failure behavior beyond schema hints, but the key operational constraints are present.

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?

The core purpose is front-loaded and the description is mostly concise. The sentence 'Use this method to respond to such pre-checkout queries' is somewhat redundant with the first sentence, but the remaining content about the Update field, return value, and deadline all earn their place.

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?

For a simple three-parameter method with fully documented schema, the description covers the trigger event, the required action, the return value, and the essential time limit. An agent has enough information to invoke the tool correctly without additional context.

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

Parameters3/5

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

Schema description coverage is 100%, so the baseline of 3 applies. The description does not add parameter-level meaning beyond the schema; it only provides contextual background about where the query comes from, which is useful but not necessary for parameter understanding.

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 ('Respond') and resource ('pre-checkout queries') and explains the trigger context (an Update with the pre_checkout_query field). It clearly identifies the distinct operation from related siblings like answerShippingQuery, even without naming them explicitly.

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

Usage Guidelines4/5

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

Provides clear context on when to use the method: after the user confirms payment and shipping details, when the Bot API sends a pre_checkout_query update. It also notes the critical 10-second response window, though it does not mention alternatives or exclusion cases.

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

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