Skip to main content
Glama

Send message to phone

send_message_to_phone
Destructive

Send text messages or files directly to a Telegram phone number, creating a temporary contact if needed. Optionally schedule delivery, save as draft, or apply markdown/HTML/rich formatting.

Instructions

Send to a phone number: may create a temporary contact, then send text or files. Supports parse_mode: classic markdown/html/auto or rich (Rich Message; dialect auto-detected). parse_mode=rich cannot be combined with files. schedule_date (ISO 8601, future) queues the message instead of delivering now; save_as_draft=true saves the text as the draft in that chat instead of sending. Success: send result plus contact_was_new / contact_removed when applicable. Full documentation: https://github.com/leshchenko1979/fast-mcp-telegram/blob/main/docs/Tools-Reference.md

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": {
      "phone_number": "<phone_number>",
      "message": "<message>"
    },
    "name": "send_message_to_phone"
  }
}

Input Schema

NameRequiredDescriptionDefault
filesNoList of attachment URLs, local paths, or data URIs (one or more strings). data: URIs (data:<mime>;base64,<payload>) work in all server modes; local paths work in stdio mode only.
messageYesMessage text. When sending files, used as caption.
last_nameNoLast name when creating a temporary contact.Name
first_nameNoFirst name when creating a temporary contact.Contact
parse_modeNo'markdown'/'html'/'auto': classic entity formatting (auto detects). 'rich': Telegram Rich Message document; dialect auto-detected (known HTML tags outside code → rich HTML, else rich markdown). Default is 'auto'. parse_mode='rich' cannot be combined with files.auto
phone_numberYesE.164 phone number with country code, e.g. +1234567890 (must be on Telegram).
remove_if_newNoIf true, delete the contact after send when it was created only for this send.
save_as_draftNoIf true, save the text as the chat's draft instead of sending it (an empty text clears the existing draft). User sessions only — bot accounts cannot call messages.saveDraft. Cannot be combined with schedule_date, files, or parse_mode='rich'.
schedule_dateNoISO 8601 instant at which Telegram should deliver the message, e.g. '2026-10-20T09:00:00Z' or '2026-10-20T12:00:00+03:00'. Must be in the future. On send: queues the message instead of delivering now. On edit: reschedules an already-queued message.
reply_to_msg_idNoReply to this message id in the target chat after resolve.

Output Schema

NameRequiredDescriptionDefault
okNo
chatNo
codeNo
dateNo
richNo
textNo
errorNo
actionNo
paramsNo
senderNo
statusNo
topic_idNo
edit_dateNo
exceptionNo
operationNo
scheduledNo
error_codeNo
message_idNo
draft_savedNo
reply_to_idNo
rich_formatNo
phone_numberNo
reply_markupNo
schedule_dateNo
contact_removedNo
contact_was_newNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed6 schema fields changedv0.46.1
    • addedInput schema / properties / save_as_draft
      Added value: +{
      +  "default": false,
      +  "description": "If true, save the text as the chat's draft instead of sending it (an empty text clears the existing draft). User sessions only — bot accounts cannot call messages.saveDraft. Cannot be combined with schedule_date, files, or parse_mode='rich'.",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / schedule_date
      Added value: +{
      +  "default": null,
      +  "description": "ISO 8601 instant at which Telegram should deliver the message, e.g. '2026-10-20T09:00:00Z' or '2026-10-20T12:00:00+03:00'. Must be in the future. On send: queues the message instead of delivering now. On edit: reschedules an already-queued message.",
      +  "type": "string"
      +}
    • addedOutput schema / properties / draft_saved
      Added value: +{
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / reply_to_id
      Added value: +{
      +  "type": "integer"
      +}
    • addedOutput schema / properties / schedule_date
      Added value: +{
      +  "type": "string"
      +}
    • addedOutput schema / properties / scheduled
      Added value: +{
      +  "type": "boolean"
      +}
  2. Changed4 schema fields changedv0.45.0
    • changedInput schema / properties / parse_mode / description
      Previous value: -"'markdown', 'html', or 'auto' (detect from content). Default is 'auto'."New value: +"'markdown'/'html'/'auto': classic entity formatting (auto detects). 'rich': Telegram Rich Message document; dialect auto-detected (known HTML tags outside code → rich HTML, else rich markdown). Default is 'auto'. parse_mode='rich' cannot be combined with files."
    • changedInput schema / properties / parse_mode / enum
      Previous value: -[
      -  "markdown",
      -  "html",
      -  "auto"
      -]New value: +[
      +  "markdown",
      +  "html",
      +  "auto",
      +  "rich"
      +]
    • addedOutput schema / properties / rich
      Added value: +{
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / rich_format
      Added value: +{
      +  "type": "string"
      +}
  3. Changed3 schema fields changedv0.36.0
    • removedOutput schema / additionalProperties
      Removed value: -true
    • addedOutput schema / description
      Added value: +"Return type for ``send_message_to_phone``."
    • addedOutput schema / properties
      Added value: +{
      +  "action": {
      +    "type": "string"
      +  },
      +  "chat": {
      +    "additionalProperties": true,
      +    "type": "object"
      +  },
      +  "code": {
      +    "type": "integer"
      +  },
      +  "contact_removed": {
      +    "type": "boolean"
      +  },
      +  "contact_was_new": {
      +    "type": "boolean"
      +  },
      +  "date": {
      +    "type": "string"
      +  },
      +  "edit_date": {
      +    "type": "string"
      +  },
      +  "error": {
      +    "type": "string"
      +  },
      +  "error_code": {
      +    "type": "string"
      +  },
      +  "exception": {
      +    "additionalProperties": true,
      +    "type": "object"
      +  },
      +  "message_id": {
      +    "type": "integer"
      +  },
      +  "ok": {
      +    "type": "boolean"
      +  },
      +  "operation": {
      +    "type": "string"
      +  },
      +  "params": {
      +    "additionalProperties": true,
      +    "type": "object"
      +  },
      +  "phone_number": {
      +    "type": "string"
      +  },
      +  "reply_markup": {
      +    "additionalProperties": true,
      +    "type": "object"
      +  },
      +  "sender": {
      +    "additionalProperties": true,
      +    "type": "object"
      +  },
      +  "status": {
      +    "type": "string"
      +  },
      +  "text": {
      +    "type": "string"
      +  },
      +  "topic_id": {
      +    "type": "integer"
      +  }
      +}
  4. Changed1 schema field changedv0.29.0
    • changedInput schema / properties / files / description
      Previous value: -"List of attachment URLs or local paths (one or more strings). Local paths work in stdio mode only."New value: +"List of attachment URLs, local paths, or data URIs (one or more strings). data: URIs (data:<mime>;base64,<payload>) work in all server modes; local paths work in stdio mode only."
  5. First observedv0.21.0

TDQS

A4.1/5.0
Behavior5/5

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

Goes well beyond the annotations by disclosing the side effect that a temporary contact may be created and optionally removed, that contact_was_new/contact_removed appear in the result, and that save_as_draft requires a user session (bots cannot call messages.saveDraft). The destructive contact mutation and the mutual-exclusion matrix are exactly the context annotations alone do not convey.

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-loaded with the core action, then organized as a constraint list with no filler; the documentation link is placed last. It is dense and long-ish for a description but each clause carries operational meaning.

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?

For a 10-parameter mutation tool with an output schema, the description covers the non-obvious behaviors: contact lifecycle, parse modes, scheduling, drafts, and the session-type restriction. Minor gaps such as reply_to_msg_id semantics are left entirely to the schema, which is acceptable given full coverage there.

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 schema already documents every parameter including the parse_mode enum and schedule_date format. The description restates the rich/files conflict and draft/schedule conflicts, which reinforces cross-parameter constraints but adds little new meaning; baseline 3 is appropriate.

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?

States a specific verb and resource ('Send to a phone number... send text or files') and distinguishes itself implicitly from the generic send_message sibling by targeting a phone number and by the temporary-contact creation step. An agent can tell what it does without opening the schema, though it never names the sibling it is not.

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?

Gives concrete conditional guidance: schedule_date queues instead of delivering, save_as_draft saves instead of sending, and parse_mode=rich cannot combine with files. It does not explicitly say 'use send_message instead when you have a chat id rather than a phone number', so the routing decision against the sibling is left partly to inference.

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