Skip to main content
Glama
LoneVertex

Telegram MCP — Next Generation

Synchronize Chat History to Local Archive

sync_chat_cache
Read-onlyIdempotent

Sync recent chat messages into a local SQLite/FTS5 archive to keep your offline cache fresh. Run incrementally since the last checkpoint or do a full refresh.

Instructions

Synchronize a batch of recent messages from a chat into the local SQLite/FTS5 archive. Use periodically to keep the offline cache fresh. Supports incremental mode (since last checkpoint) or full refresh.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeNoSynchronization mode: 'incremental' (new messages since checkpoint) or 'full' (all messages in batch).incremental
limitNoMaximum number of items or records to retrieve (integer between 1 and 100).
accountNoOptional account label for multi-account environments. If omitted in single-mode, the default account is used. In multi-mode without an account, read-only tools fan out across all configured accounts.
chat_idYesTarget Telegram chat, group, supergroup, channel, or user identifier. Accepts numeric chat ID (e.g. -1001234567890 or 123456789), username (e.g. '@channel'), or phone number.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv4.1.1

TDQS

A3.6/5.0
Behavior3/5

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

Annotations already declare the full safety profile (readOnly, openWorld, idempotent, non-destructive), so the bar is lower. The description adds the persistence target and checkpoint-based incrementality, but stays silent on error/failure behavior, auth requirements, and rate limits, leaving it at the minimum-viable-plus level.

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?

Three front-loaded sentences: purpose, then when to use, then mode behavior. Each earns its place, though the mode sentence partially duplicates the schema's mode description.

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

Completeness4/5

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

With a full output schema and 100% parameter coverage, the description needn't explain return values, and it does cover purpose, cadence, and modes. It is nearly complete for a cache-sync tool; only failure/partial-sync behavior is unaddressed.

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 all four parameters (mode, limit, account, chat_id) are already documented with defaults and semantics. The description only restates the mode concept and adds no new syntax or constraints, so the baseline 3 applies.

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 names a specific verb (synchronize) plus resource (a batch of recent chat messages) and destination (local SQLite/FTS5 archive), so the tool's job is unambiguous. It implicitly separates itself from read-side siblings like search_cached_messages and cache_health, but it never explicitly names or contrasts a sibling, so it falls short of a 5.

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?

"Use periodically to keep the offline cache fresh" gives a clear context for invoking the tool, and the incremental/full modes are explained. However, it offers no exclusions and does not route the agent against alternatives such as get_messages or search_cached_messages, so the guidance is contextual but incomplete.

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