Reyta Bot API

Build chat bots on Reyta over a simple HTTPS API. It mirrors the Telegram Bot API, so the methods, parameters, and JSON responses you already know work here unchanged – and an existing bot moves over by changing one line.

Introduction

The Bot API is a set of HTTPS endpoints. Each call is the base URL, then your bot token, then a method name. You send parameters; you get back JSON. There is nothing else to install on the server side – any language with an HTTP client can talk to it.

Endpoint shape
https://api.reyta.uz/bot<token>/METHOD_NAME

Every response has the same envelope: a boolean ok, and either a result on success or an error_code plus a human-readable description on failure.

JSONResponse envelope
{ "ok": true,  "result": { ... } }
{ "ok": false, "error_code": 401, "description": "Unauthorized" }

Get a token by creating a bot with BotMother. That token is the only credential you need – treat it like a password.

Quick start

Call getMe to confirm your token and see your bot. Paste this into a terminal (replace <token>):

ShellRequest
curl "https://api.reyta.uz/bot<token>/getMe"
JSONResponse
{
  "ok": true,
  "result": {
    "id": 770001,
    "is_bot": true,
    "first_name": "My Bot",
    "username": "my_bot"
  }
}

That is the whole model: swap getMe for any method below, add its parameters, and read the JSON back.

Authorization

The token goes directly in the request path – there is no separate header or OAuth step. Keep it secret: anyone who has it can control the bot. If it leaks, revoke and reissue it in BotMother.

ShellVerify a token
curl "https://api.reyta.uz/bot<token>/getMe"

Making requests

Send parameters as a query string, form-encoded body (application/x-www-form-urlencoded), or JSON (application/json). To upload a file, use multipart/form-data. Both GET and POST work for most methods.

ShellRequest with JSON body
curl "https://api.reyta.uz/bot<token>/sendMessage" \
  -H "Content-Type: application/json" \
  -d '{"chat_id": 987654321, "text": "Hello from Reyta"}'

Migrate from Telegram

Because the surface matches the Telegram Bot API, migration is not a rewrite – it is a configuration change. Point your library’s API root at Reyta and use a token from BotMother. Your method calls, update handling, and types stay exactly the same. Here are the one-line changes for popular libraries (grammY and Telegraf are verified against this endpoint).

grammY (Node / TypeScript)

TypeScriptgrammy.ts
import { Bot } from "grammy";

const bot = new Bot("<token>", {
  client: { apiRoot: "https://api.reyta.uz" },
});

console.log(await bot.api.getMe());

Telegraf (Node / TypeScript)

TypeScripttelegraf.ts
import { Telegraf } from "telegraf";

const bot = new Telegraf("<token>", {
  telegram: { apiRoot: "https://api.reyta.uz" },
});

console.log(await bot.telegram.getMe());

python-telegram-bot

Pythonbot.py
from telegram.ext import ApplicationBuilder

app = (
    ApplicationBuilder()
    .token("<token>")
    .base_url("https://api.reyta.uz/bot")
    .build()
)

Any other library or raw HTTP

If your library exposes an API base URL, host, or apiRoot option, set it to https://api.reyta.uz. If you call the API directly, just change the host:

Base URL
- https://api.telegram.org/bot<token>/sendMessage
+ https://api.reyta.uz/bot<token>/sendMessage

Send a message

To message a user or chat you need its chat_id. The simplest way to get one: send your bot a message, then read it back with getUpdates – the chat.id is in the response. Then:

ShellsendMessage
curl "https://api.reyta.uz/bot<token>/sendMessage" \
  -d "chat_id=987654321" \
  -d "text=Salom! My bot is live on Reyta." \
  -d "parse_mode=HTML"

Add an inline keyboard, reply to a message, or attach media with the parameters listed under each method below.

Getting updates

Receive incoming events by long polling or webhook. Pick one – they are mutually exclusive.

POST/bot<token>/getUpdates→ Array of Update

Poll for new updates using long polling. Returns an array of Update objects.

ParameterTypeRequiredDescription
offsetIntegerOptionalIdentifier of the first update to return. Set to last received update_id + 1 to confirm.
limitIntegerOptionalNumber of updates to retrieve, 1–100. Default 100.
timeoutIntegerOptionalLong-polling timeout in seconds. 0 for short polling (testing only).
allowed_updatesArray of StringOptionalList of update types to receive, e.g. ["message","callback_query"].
ShellRequest
curl "https://api.reyta.uz/bot<token>/getUpdates" \
  -d "timeout=30&offset=1"
JSONResponse
{
  "ok": true,
  "result": [
    {
      "update_id": 100001,
      "message": {
        "message_id": 42,
        "from": { "id": 987654321, "is_bot": false, "first_name": "Aziz" },
        "chat": { "id": 987654321, "type": "private" },
        "date": 1783900000,
        "text": "/start"
      }
    }
  ]
}
POST/bot<token>/setWebhook→ True

Register an HTTPS URL to receive updates via push. Reyta delivers each update as a JSON POST.

ParameterTypeRequiredDescription
urlStringYesHTTPS URL to send updates to. An empty string removes the webhook.
secret_tokenStringOptional1–256 chars; echoed back in the X-Telegram-Bot-Api-Secret-Token header so you can verify requests.
allowed_updatesArray of StringOptionalUpdate types to receive.
max_connectionsIntegerOptionalMax simultaneous HTTPS connections for delivery, 1–100. Default 40.
ShellRequest
curl "https://api.reyta.uz/bot<token>/setWebhook" \
  -d "url=https://your-bot.example/hook&secret_token=s3cr3t"
JSONResponse
{ "ok": true, "result": true, "description": "Webhook was set" }
POST/bot<token>/deleteWebhook→ True

Remove the webhook and switch back to getUpdates.

ParameterTypeRequiredDescription
drop_pending_updatesBooleanOptionalDiscard everything queued before this call.
GET/bot<token>/getWebhookInfo→ WebhookInfo

Current webhook status, pending update count, and last error.

Sending messages

Deliver text, media, and everyday content to any chat the bot can reach.

POST/bot<token>/sendMessage→ MessagePartial support

Send a text message. Supports Markdown/HTML formatting and inline keyboards.

Reyta does not generate link previews, so a message never carries one. link_preview_options is accepted: is_disabled and show_above_text are stored on the message, while url, prefer_small_media and prefer_large_media describe a preview that does not exist and are ignored rather than refused.

ParameterTypeRequiredDescription
chat_idInteger or StringYesUnique chat identifier or @username of a channel.
textStringYesMessage text, 1–4096 characters.
parse_modeStringOptional"MarkdownV2" or "HTML" for entity formatting.
reply_markupObjectOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
disable_notificationBooleanOptionalSend silently, without a notification sound.
link_preview_optionsLinkPreviewOptionsOptionalJSON object. is_disabled suppresses the link preview and show_above_text puts it above the text; both are stored on the message. The rendering fields (url, prefer_small_media, prefer_large_media) are ignored — see the note on this method.
disable_web_page_previewBooleanOptionalThe older spelling of link_preview_options.is_disabled. Still accepted.
entitiesArray of MessageEntityOptionalJSON array of already-parsed entities. It can be given instead of parse_mode, and then it wins: the text is taken literally and the entities describe it.
reply_parametersReplyParametersOptionalJSON object describing the reply: message_id, and optionally quote, quote_parse_mode / quote_entities and quote_position. Preferred over the deprecated reply_to_message_id. reply_parameters.chat_id (a reply to a message in another chat) is refused with 400 rather than sent as a non-reply.
message_effect_idStringOptionalIdentifier of the effect played once when the message arrives.
ShellRequest
curl "https://api.reyta.uz/bot<token>/sendMessage" \
  -d "chat_id=987654321" \
  -d "text=Salom! Reyta Bot API is live." \
  -d "parse_mode=HTML"
JSONResponse
{
  "ok": true,
  "result": {
    "message_id": 43,
    "chat": { "id": 987654321, "type": "private" },
    "date": 1783900050,
    "text": "Salom! Reyta Bot API is live."
  }
}
POST/bot<token>/sendPhoto→ Message

Send a photo by file_id, HTTP URL, or multipart upload.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat.
photoString or InputFileYesfile_id, an HTTPS URL, or an uploaded file.
captionStringOptionalCaption, 0–1024 characters.
show_caption_above_mediaBooleanOptionalPut the caption above the photo instead of below it.
caption_entitiesArray of MessageEntityOptionalJSON array of already-parsed entities for the caption, instead of parse_mode. Accepted on every caption-bearing send method and on editMessageCaption and copyMessage.
ShellRequest
curl "https://api.reyta.uz/bot<token>/sendPhoto" \
  -F chat_id=1000100 -F caption="Look" -F photo=@cat.jpg
JSONResponse
{
  "ok": true,
  "result": {
    "message_id": 512,
    "from": { "id": 523722417021, "is_bot": true, "first_name": "Jokebot" },
    "chat": { "id": 1000100, "type": "private" },
    "date": 1787900000,
    "caption": "Look",
    "photo": [ { "file_id": "l8BvW8G5ZiGyZcYCX...", "file_unique_id": "k9UIku2zcCg", "width": 320, "height": 240, "file_size": 8123 } ]
  }
}
POST/bot<token>/forwardMessage→ Message

Forward a message of any kind from one chat to another.

ParameterTypeRequiredDescription
chat_idInteger or StringYesUnique identifier of the target chat, or @channelusername.
from_chat_idInteger or StringYesChat the original message comes from.
message_idIntegerYesIdentifier of the message.
ShellRequest
curl "https://api.reyta.uz/bot<token>/forwardMessage" \
  -d "chat_id=1000100&from_chat_id=-1001234567890&message_id=42"
JSONResponse
{
  "ok": true,
  "result": {
    "message_id": 516,
    "chat": { "id": 1000100, "type": "private" },
    "date": 1787900030,
    "text": "the forwarded text"
  }
}
POST/bot<token>/copyMessage→ MessageId

Copy a message without a link to the original. Either the copy lands with the caption that was asked for, or nothing is sent and the call fails.

ParameterTypeRequiredDescription
chat_idInteger or StringYesUnique identifier of the target chat, or @channelusername.
from_chat_idInteger or StringYesChat the original message comes from.
message_idIntegerYesIdentifier of the message.
captionStringOptionalNew caption. If omitted, the original caption is kept.
parse_modeStringOptionalFormatting of the new caption: HTML, Markdown, or MarkdownV2.
ShellRequest
curl "https://api.reyta.uz/bot<token>/copyMessage" \
  -d "chat_id=1000100&from_chat_id=-1001234567890&message_id=42&caption=New caption"
JSONResponse
{ "ok": true, "result": { "message_id": 517 } }
POST/bot<token>/sendDocument→ Message

Send a general file, up to the configured size limit.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
documentInputFile or StringYesThe file: a file_id, an HTTPS URL, or a multipart upload.
captionStringOptionalCaption, 0-1024 characters.
parse_modeStringOptionalMarkdown, MarkdownV2 or HTML.
reply_markupInlineKeyboardMarkupOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
thumbnailInputFileOptionalCover image, uploaded as a multipart part. The old name thumb is also accepted.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.
ShellRequest
curl "https://api.reyta.uz/bot<token>/sendDocument" \
  -F chat_id=1000100 -F [email protected]
JSONResponse
{
  "ok": true,
  "result": {
    "message_id": 513,
    "chat": { "id": 1000100, "type": "private" },
    "date": 1787900010,
    "document": { "file_id": "qWQSGcLKbVNV1I3y...", "file_unique_id": "Ch0MHHySQBAA", "file_name": "report.pdf", "mime_type": "application/pdf", "file_size": 20481 }
  }
}
POST/bot<token>/sendVideo→ Message

Send an MP4 video.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
videoInputFile or StringYesThe video: a file_id, an HTTPS URL, or a multipart upload.
captionStringOptionalCaption, 0-1024 characters.
parse_modeStringOptionalMarkdown, MarkdownV2 or HTML.
reply_markupInlineKeyboardMarkupOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
durationIntegerOptionalDuration in seconds.
widthIntegerOptionalWidth in pixels.
heightIntegerOptionalHeight in pixels.
supports_streamingBooleanOptionalMark the video as suitable for streaming.
has_spoilerBooleanOptionalCover the media with a spoiler animation.
thumbnailInputFileOptionalCover image, uploaded as a multipart part. The old name thumb is also accepted.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.
POST/bot<token>/sendAnimation→ Message

Send a GIF or H.264/MPEG-4 animation without sound.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
animationInputFile or StringYesThe animation: a file_id, an HTTPS URL, or a multipart upload.
captionStringOptionalCaption, 0-1024 characters.
parse_modeStringOptionalMarkdown, MarkdownV2 or HTML.
reply_markupInlineKeyboardMarkupOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
durationIntegerOptionalDuration in seconds.
widthIntegerOptionalWidth in pixels.
heightIntegerOptionalHeight in pixels.
has_spoilerBooleanOptionalCover the media with a spoiler animation.
thumbnailInputFileOptionalCover image, uploaded as a multipart part. The old name thumb is also accepted.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.
POST/bot<token>/sendAudio→ Message

Send an audio file to be shown in the music player.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
audioInputFile or StringYesThe audio: a file_id, an HTTPS URL, or a multipart upload.
captionStringOptionalCaption, 0-1024 characters.
parse_modeStringOptionalMarkdown, MarkdownV2 or HTML.
reply_markupInlineKeyboardMarkupOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
durationIntegerOptionalDuration in seconds.
performerStringOptionalAudio performer.
titleStringOptionalTitle.
thumbnailInputFileOptionalCover image, uploaded as a multipart part. The old name thumb is also accepted.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.
POST/bot<token>/sendVoice→ Message

Send a voice message (OGG/OPUS).

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
voiceInputFile or StringYesThe voice message: a file_id, an HTTPS URL, or a multipart upload.
captionStringOptionalCaption, 0-1024 characters.
parse_modeStringOptionalMarkdown, MarkdownV2 or HTML.
reply_markupInlineKeyboardMarkupOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
durationIntegerOptionalDuration in seconds.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.
POST/bot<token>/sendVideoNote→ Message

Send a rounded, square video note.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
video_noteInputFile or StringYesThe video note: a file_id or a multipart upload.
lengthIntegerOptionalSide length of the square video note.
durationIntegerOptionalDuration in seconds.
thumbnailInputFileOptionalCover image, uploaded as a multipart part. The old name thumb is also accepted.
reply_markupInlineKeyboardMarkupOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.
POST/bot<token>/sendMediaGroup→ Array of Message

Send a group of photos/videos/documents as an album.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
mediaArray of InputMediaYesJSON array describing the album items.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.
ShellRequest
curl "https://api.reyta.uz/bot<token>/sendMediaGroup" \
  -d chat_id=1000100 \
  -d 'media=[{"type":"photo","media":"https://reyta.uz/a.jpg","caption":"one"},{"type":"photo","media":"https://reyta.uz/b.jpg"}]'
JSONResponse
{
  "ok": true,
  "result": [
    { "message_id": 514, "chat": { "id": 1000100, "type": "private" }, "media_group_id": "2093252871779782656", "caption": "one", "photo": [] },
    { "message_id": 515, "chat": { "id": 1000100, "type": "private" }, "media_group_id": "2093252871779782656", "photo": [] }
  ]
}
POST/bot<token>/sendLocation→ Message

Send a point on the map; can be a live location.

ParameterTypeRequiredDescription
chat_idInteger or StringYesUnique identifier of the target chat, or @channelusername.
latitudeFloatYesLatitude of the location.
longitudeFloatYesLongitude of the location.
live_periodIntegerOptionalSeconds the location stays live, 60-86400. Omit for a one-shot location.
headingIntegerOptionalDirection the user is moving, 1-360 degrees.
proximity_alert_radiusIntegerOptionalDistance in metres for proximity alerts about another member.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.
reply_markupObjectOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
horizontal_accuracyFloatOptionalRadius of uncertainty in metres, 0-1500. Clients draw it as the circle around the point.
POST/bot<token>/sendVenue→ Message

Send information about a venue.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
latitudeFloatYesLatitude of the location.
longitudeFloatYesLongitude of the location.
titleStringYesTitle.
addressStringYesStreet address of the venue.
foursquare_idStringOptionalFoursquare identifier of the venue.
foursquare_typeStringOptionalFoursquare category of the venue.
google_place_idStringOptionalGoogle Places identifier of the venue.
google_place_typeStringOptionalGoogle Places category of the venue.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.
reply_markupObjectOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
POST/bot<token>/sendContact→ Message

Send a phone contact.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
phone_numberStringYesContact's phone number.
first_nameStringYesContact's first name.
last_nameStringOptionalContact's last name.
vcardStringOptionalAdditional contact data in vCard format.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.
reply_markupObjectOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
POST/bot<token>/sendPoll→ Message

Send a poll. The bot receives poll_answer for each vote in a non-anonymous poll it sent, and poll when it stops one.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
questionStringYesPoll question.
optionsArray of StringYesJSON array of answer options.
is_anonymousBooleanOptionalHide who voted. True by default; send false so the voters can be listed.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.
typeStringOptionalregular (default) or quiz.
allows_multiple_answersBooleanOptionalLet a voter pick several options. Ignored for a quiz.
correct_option_idIntegerOptional0-based index of the right answer. Required for a quiz.
explanationStringOptionalShown after a quiz is answered. Never sent before that — it is the answer key.
open_periodIntegerOptionalSeconds the poll stays open, 5-600.
close_dateIntegerOptionalUnix time when the poll closes by itself.
is_closedBooleanOptionalSend the poll already closed, for previews.
reply_markupObjectOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
question_parse_modeStringOptionalFormatting of the question: HTML, Markdown or MarkdownV2. The markup is parsed and removed — the poll store keeps the question as plain text, so the bold is lost but the asterisks are not left on screen.
explanation_parse_modeStringOptionalFormatting of a quiz explanation. Entities are kept for the explanation, unlike for the question.
ShellRequest
curl "https://api.reyta.uz/bot<token>/sendPoll" \
  -d chat_id=1000100 \
  -d question="Lunch?" \
  -d options='["Plov","Lagman","Manti"]'
JSONResponse
{
  "ok": true,
  "result": {
    "message_id": 517,
    "from": { "id": 523722417021, "is_bot": true, "first_name": "Jokebot" },
    "chat": { "id": 1000100, "type": "private" },
    "date": 1792334000,
    "poll": {
      "id": "2111827868622262272",
      "question": "Lunch?",
      "options": [
        { "text": "Plov", "voter_count": 0 },
        { "text": "Lagman", "voter_count": 0 },
        { "text": "Manti", "voter_count": 0 }
      ],
      "total_voter_count": 0,
      "is_closed": false,
      "is_anonymous": true,
      "type": "regular",
      "allows_multiple_answers": false
    }
  }
}
POST/bot<token>/sendDice→ Message

Send an animated emoji with a random value.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
emojiStringOptionalEmoji the dice animation is based on.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.
reply_markupObjectOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
POST/bot<token>/sendChatAction→ True

Show a "typing…" or "uploading…" status.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
actionStringYesAction to show: typing, upload_photo, record_video and so on.
POST/bot<token>/sendSticker→ Message

Send a static, animated, or video sticker.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
stickerStringYesA file_id of a sticker that already exists on the server – take it from getStickerSet or from an incoming update.
reply_to_message_idIntegerOptionalSend the sticker as a reply to this message.
reply_markupInlineKeyboardMarkupOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
ShellRequest
curl "https://api.reyta.uz/bot<token>/sendSticker" \
  -d "chat_id=1000100&sticker=CAQAAAABHGv42k_AEABAvG9SmO6EnQAAAAEAAAAAAAAAAA"
JSONResponse
{
  "ok": true,
  "result": {
    "message_id": 1022,
    "from": { "id": 523722417021, "is_bot": true, "first_name": "Jokebot", "username": "Jokeformebot" },
    "chat": { "id": 1000100, "type": "private" },
    "date": 1787863074,
    "sticker": {
      "file_id": "CAQAAAABHGv42k_AEABAvG9SmO6EnQAAAAEAAAAAAAAAAA",
      "file_unique_id": "Chxr-NpPwBAA",
      "type": "regular",
      "width": 512,
      "height": 512,
      "is_video": true,
      "emoji": "\uD83D\uDC4D",
      "file_size": 126387
    }
  }
}
POST/bot<token>/copyMessages→ Array of MessageId

Copy several messages at once without a link to the original.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
from_chat_idInteger or StringYesChat the message is taken from.
message_idsArray of IntegerYesJSON array of message ids.
remove_captionBooleanOptionalCopy without the original caption.
POST/bot<token>/forwardMessages→ Array of MessageId

Forward several messages at once, keeping the original author.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
from_chat_idInteger or StringYesChat the message is taken from.
message_idsArray of IntegerYesJSON array of message ids.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
protect_contentBooleanOptionalForbid forwarding and saving of the sent message.
reply_to_message_idIntegerOptionalSend as a reply to this message.
message_thread_idIntegerOptionalForum topic the message belongs to.

Updating & deleting

Edit or delete messages the bot already sent. Editing by chat_id + message_id works everywhere; editing an inline message by inline_message_id is not supported yet.

POST/bot<token>/editMessageText→ Message or True

Edit the text of a sent or inline message.

ParameterTypeRequiredDescription
textStringYesNew text of the message.
chat_idInteger or StringOptionalTarget chat. Required unless inline_message_id is used.
message_idIntegerOptionalMessage to edit. Required unless inline_message_id is used.
parse_modeStringOptionalFormatting: HTML, Markdown, or MarkdownV2.
inline_message_idStringOptionalIdentifier of an inline message, from chosen_inline_result. Use instead of chat_id + message_id; sending both is an error. The reply is then true rather than a Message.
ShellRequest
curl "https://api.reyta.uz/bot<token>/editMessageText" \
  -d "chat_id=1000100&message_id=512&text=Updated&parse_mode=HTML"
JSONResponse
{
  "ok": true,
  "result": {
    "message_id": 512,
    "chat": { "id": 1000100, "type": "private" },
    "date": 1787900000,
    "text": "Updated"
  }
}
POST/bot<token>/editMessageCaption→ Message or True

Edit the caption of a media message.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_idIntegerYesTarget message.
inline_message_idStringOptionalIdentifier of an inline message.
captionStringOptionalCaption, 0-1024 characters.
parse_modeStringOptionalMarkdown, MarkdownV2 or HTML.
reply_markupInlineKeyboardMarkupOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
POST/bot<token>/editMessageMedia→ Message or True

Replace the media of a message. Accepts a file_id, an http(s) URL or an attach:// upload; the InputMedia caption replaces the message caption.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_idIntegerYesTarget message.
mediaArray of InputMediaYesJSON array describing the album items.
inline_message_idStringOptionalIdentifier of an inline message.
reply_markupInlineKeyboardMarkupOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
POST/bot<token>/editMessageReplyMarkup→ Message or True

Edit only the inline keyboard of a message.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_idIntegerYesTarget message.
inline_message_idStringOptionalIdentifier of an inline message.
reply_markupInlineKeyboardMarkupOptionalJSON keyboard: inline_keyboard, keyboard, remove_keyboard or force_reply. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400 rather than quietly dropped.
POST/bot<token>/editMessageLiveLocation→ Message or True

Move an active live location.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_idIntegerYesTarget message.
inline_message_idStringOptionalIdentifier of an inline message.
latitudeFloatOptionalLatitude of the location.
longitudeFloatOptionalLongitude of the location.
live_periodIntegerOptionalHow long the location stays live, in seconds.
headingIntegerOptionalDirection the user is moving in, 1-360 degrees.
proximity_alert_radiusIntegerOptionalDistance in metres for proximity alerts.
POST/bot<token>/deleteMessage→ True

Delete a message the bot sent, or any message where it is admin.

ParameterTypeRequiredDescription
chat_idInteger or StringYesUnique identifier of the target chat, or @channelusername.
message_idIntegerYesIdentifier of the message.
ShellRequest
curl "https://api.reyta.uz/bot<token>/deleteMessage" -d "chat_id=1000100&message_id=512"
JSONResponse
{ "ok": true, "result": true }
POST/bot<token>/deleteMessages→ True

Delete multiple messages at once.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_idsArray of IntegerYesJSON array of message ids.
POST/bot<token>/stopMessageLiveLocation→ Message or True

Stop updating an active live location before its period expires.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_idIntegerYesTarget message.
inline_message_idStringOptionalIdentifier of an inline message.
POST/bot<token>/setMessageReaction→ True

Set or clear the bot's reaction on a message.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_idIntegerYesTarget message.
is_bigBooleanOptionalPlay a big reaction animation.
reactionArray of ReactionTypeOptionalJSON array of reactions; an empty array clears them.
POST/bot<token>/stopPoll→ Poll

Stop an active poll the bot sent.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_idIntegerYesTarget message.
reply_markupObjectOptionalJSON keyboard to leave on the message, usually swapping Vote for See results. Button types this server has no backend for — web_app, login_url, pay, callback_game, switch_inline_query_chosen_chat, request_poll, request_user, request_chat — are refused with 400.
ShellRequest
curl "https://api.reyta.uz/bot<token>/stopPoll" \
  -d chat_id=1000100 -d message_id=517
JSONResponse
{
  "ok": true,
  "result": {
    "id": "2111827868622262272",
    "question": "Lunch?",
    "options": [
      { "text": "Plov", "voter_count": 4 },
      { "text": "Lagman", "voter_count": 7 },
      { "text": "Manti", "voter_count": 2 }
    ],
    "total_voter_count": 13,
    "is_closed": true,
    "is_anonymous": true,
    "type": "regular",
    "allows_multiple_answers": false
  }
}

Inline & callbacks

Answer inline queries and the taps on your inline keyboards. Every answer is tied to a query id and expires with it, so reply promptly.

POST/bot<token>/answerCallbackQuery→ True

Respond to an inline-button tap; optionally show an alert.

ParameterTypeRequiredDescription
callback_query_idStringYesIdentifier of the callback query to answer.
textStringOptionalNotification text, up to 200 characters.
show_alertBooleanOptionalShow a modal alert instead of a toast.
urlStringOptionalURL opened by the client.
cache_timeIntegerOptionalSeconds the result may be cached client-side.
ShellRequest
curl "https://api.reyta.uz/bot<token>/answerCallbackQuery" \
  -d "callback_query_id=4382bfdwdsb323b2d9&text=Saved"
JSONResponse
{ "ok": true, "result": true }
POST/bot<token>/answerInlineQuery→ TruePartial support

Answer an inline query with a list of results.

Every result type is served except game: article, photo, gif, mpeg4_gif, video, audio, voice, document, sticker, location, venue and contact, each in both the URL and the cached (*_file_id) flavour. Reyta has no games platform at all — sendGame, setGameScore and getGameHighScores do not exist — so an InlineQueryResultGame names nothing and is refused with 400.

ParameterTypeRequiredDescription
inline_query_idStringYesIdentifier of the inline query to answer.
resultsArray of InlineQueryResultYesJSON array of results. Supported types: article, photo, gif, mpeg4_gif, document.
cache_timeIntegerOptionalSeconds the result may be cached, 1-300 (default 300).
is_personalBooleanOptionalCache the results per user instead of globally.
next_offsetStringOptionalOffset for the next page, up to 64 bytes.
ShellRequest
curl "https://api.reyta.uz/bot<token>/answerInlineQuery" \
  -d inline_query_id=1234567890 \
  -d 'results=[{"type":"article","id":"1","title":"Hello","input_message_content":{"message_text":"Hello!"}}]'
JSONResponse
{ "ok": true, "result": true }

Chats & members

Inspect and manage chats, members, invite links, and admin rights.

GET/bot<token>/getChat→ Chat

Get up-to-date information about a chat as a full ChatFullInfo, including the pinned message.

ParameterTypeRequiredDescription
chat_idInteger or StringYesUnique identifier of the target chat, or @channelusername.
ShellRequest
curl "https://api.reyta.uz/bot<token>/getChat" -d chat_id=-1001234567890
JSONResponse
{
  "ok": true,
  "result": {
    "id": -1001234567890,
    "type": "supergroup",
    "title": "Reyta devs",
    "username": "reytadevs",
    "description": "Server talk",
    "invite_link": "https://t.me/+abcdef",
    "member_count": 128,
    "permissions": { "can_send_messages": true, "can_send_photos": true, "can_pin_messages": false }
  }
}
GET/bot<token>/getChatAdministrators→ Array of ChatMember

List a chat's administrators.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
return_botsBooleanOptionalPass True to additionally receive the bots that administer the chat. By default bots other than the calling one are omitted.
GET/bot<token>/getChatMember→ ChatMember

Information about one member of a chat.

ParameterTypeRequiredDescription
chat_idInteger or StringYesUnique identifier of the target chat, or @channelusername.
user_idIntegerYesUnique identifier of the target user.
ShellRequest
curl "https://api.reyta.uz/bot<token>/getChatMember" -d "chat_id=-1001234567890&user_id=1000100"
JSONResponse
{
  "ok": true,
  "result": {
    "status": "administrator",
    "user": { "id": 1000100, "is_bot": false, "first_name": "Johan" },
    "custom_title": "Founder"
  }
}
GET/bot<token>/getChatMemberCount→ Integer

Number of members in a chat.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
GET/bot<token>/getUserChatBoosts→ UserChatBoostsPartial support

List the boosts a user has added to a chat. Requires administrator rights in the chat.

Reyta keeps no boost accounting: Premium is universal here, so there is nothing a boost buys and nobody boosts. The answer is a well-formed, empty UserChatBoosts rather than an error — which is the true answer, none. The method reads the real backend, so it starts reporting boosts the day boost accounting exists.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
user_idIntegerYesThe user whose boosts to list.
ShellRequest
curl "https://api.reyta.uz/bot<token>/getUserChatBoosts?chat_id=-1001234567890&user_id=1000100"
JSONResponse
{
  "ok": true,
  "result": { "boosts": [] }
}
GET/bot<token>/getUserProfilePhotos→ UserProfilePhotos

A user's profile photos.

ParameterTypeRequiredDescription
user_idIntegerYesTarget user.
offsetIntegerOptionalConfirm all updates below this id and start from it.
limitIntegerOptionalHow many updates to return, 1-100.
POST/bot<token>/setChatTitle→ True

Change the title of a group, supergroup, or channel.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
titleStringYesTitle.
POST/bot<token>/setChatDescription→ True

Change the description of a group, supergroup, or channel.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
descriptionStringOptionalDescription text.
POST/bot<token>/setChatPhoto→ True

Set a new chat photo. The bot must be an administrator.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
photoInputFileYesImage file, uploaded as a multipart part.
POST/bot<token>/deleteChatPhoto→ True

Remove the chat photo.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
POST/bot<token>/pinChatMessage→ True

Pin a message in the chat.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_idIntegerYesTarget message.
disable_notificationBooleanOptionalDeliver silently, without a notification sound.
POST/bot<token>/unpinChatMessage→ True

Unpin a pinned message. Without message_id the most recent pin is removed.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_idIntegerOptionalTarget message.
POST/bot<token>/unpinAllChatMessages→ True

Unpin every pinned message in the chat.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
POST/bot<token>/leaveChat→ True

Make the bot leave the group, supergroup, or channel.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.

Moderation

Ban, restrict, and promote members. The bot needs the matching administrator right in the chat.

POST/bot<token>/banChatMember→ True

Ban a user from a group, supergroup, or channel.

ParameterTypeRequiredDescription
chat_idInteger or StringYesUnique identifier of the target chat, or @channelusername.
user_idIntegerYesUnique identifier of the target user.
revoke_messagesBooleanOptionalDelete every message from this user in the chat.
ShellRequest
curl "https://api.reyta.uz/bot<token>/banChatMember" \
  -d "chat_id=-1001234567890&user_id=1000100&revoke_messages=true"
JSONResponse
{ "ok": true, "result": true }
POST/bot<token>/banChatSenderChat→ True

Ban a channel that posts into a supergroup on its own behalf.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget supergroup: numeric id or @username.
sender_chat_idIntegerYesId of the channel or supergroup posting into the chat.
POST/bot<token>/unbanChatSenderChat→ True

Lift a channel ban in a supergroup.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget supergroup: numeric id or @username.
sender_chat_idIntegerYesId of the channel or supergroup posting into the chat.
POST/bot<token>/setChatStickerSet→ True

Set the group sticker set of a supergroup.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget supergroup: numeric id or @username.
sticker_set_nameStringYesShort name of the set, as in getStickerSet.
POST/bot<token>/deleteChatStickerSet→ True

Remove the group sticker set from a supergroup.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget supergroup: numeric id or @username.
POST/bot<token>/unpinAllGeneralForumTopicMessages→ True

Unpin every message in the General forum topic.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget supergroup: numeric id or @username.
POST/bot<token>/unbanChatMember→ True

Lift a ban so the user can rejoin via an invite link.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
user_idIntegerYesTarget user.
only_if_bannedBooleanOptionalDo nothing when the user is not banned.
POST/bot<token>/restrictChatMember→ True

Restrict what a supergroup member is allowed to do.

ParameterTypeRequiredDescription
chat_idInteger or StringYesUnique identifier of the target chat, or @channelusername.
user_idIntegerYesUnique identifier of the target user.
permissionsChatPermissionsYesThe object is the COMPLETE new permission set, not a patch: a permission that is not passed as true is a restriction. That is what "pass True for all permissions to lift restrictions" means. Until 19 Oct 2026 this server read an absent key as granted, so a partial object quietly handed over everything it did not mention.
use_independent_chat_permissionsBooleanOptionalPass True to take the permissions exactly as given. By default can_send_other_messages and can_add_web_page_previews imply the text and media permissions, and can_send_polls implies can_send_messages.
POST/bot<token>/promoteChatMember→ True

Promote or demote a member by setting administrator rights.

ParameterTypeRequiredDescription
chat_idInteger or StringYesUnique identifier of the target chat, or @channelusername.
user_idIntegerYesUnique identifier of the target user.
can_manage_chatBooleanOptionalGrant the corresponding administrator right. Each right is a separate boolean parameter.
POST/bot<token>/setChatAdministratorCustomTitle→ True

Set a custom title for an administrator the bot promoted.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
user_idIntegerYesTarget user.
custom_titleStringYesTitle shown next to the administrator, 0-16 characters.
POST/bot<token>/setChatPermissions→ True

Set the default permissions for all members of a supergroup.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
permissionsChatPermissionsYesThe object is the COMPLETE new permission set, not a patch: a permission that is not passed as true is a restriction. That is what "pass True for all permissions to lift restrictions" means. Until 19 Oct 2026 this server read an absent key as granted, so a partial object quietly handed over everything it did not mention.
ShellRequest
curl "https://api.reyta.uz/bot<token>/setChatPermissions" \
  -d chat_id=-1001234567890 \
  -d 'permissions={"can_send_messages":true,"can_send_photos":false}'
JSONResponse
{ "ok": true, "result": true }

Bot configuration

The bot's own profile: name, descriptions, command list and default administrator rights. Each of these is per-language — pass language_code to set a localized value, or omit it for the default.

GET/bot<token>/getMe→ User

Basic information about the bot. A quick way to verify your token.

POST/bot<token>/setMyCommands→ True

Set the bot's list of commands.

ParameterTypeRequiredDescription
commandsArray of BotCommandYesJSON array of commands, 0-100 entries.
scopeBotCommandScopeOptionalWhere the commands apply. Only the default scope is honoured today.
language_codeStringOptionalTwo-letter language code the commands apply to.
ShellRequest
curl "https://api.reyta.uz/bot<token>/setMyCommands" \
  -d 'commands=[{"command":"start","description":"Begin"},{"command":"help","description":"How it works"}]' \
  -d 'scope={"type":"all_private_chats"}'
JSONResponse
{ "ok": true, "result": true }
GET/bot<token>/getMyCommands→ Array of BotCommand

Current list of the bot's commands.

ParameterTypeRequiredDescription
scopeBotCommandScopeOptionalJSON scope: default, all_private_chats, all_group_chats, all_chat_administrators, chat, chat_administrators or chat_member.
language_codeStringOptionalTwo-letter language code; empty sets the default.
POST/bot<token>/setMyName→ True

Set the bot's name.

ParameterTypeRequiredDescription
nameStringOptionalName.
language_codeStringOptionalTwo-letter language code; empty sets the default.
GET/bot<token>/getMyName→ BotName

Current bot name.

ParameterTypeRequiredDescription
language_codeStringOptionalTwo-letter language code; empty sets the default.
POST/bot<token>/setMyDescription→ True

Set the bot's description.

ParameterTypeRequiredDescription
descriptionStringOptionalDescription text.
language_codeStringOptionalTwo-letter language code; empty sets the default.
POST/bot<token>/setChatMenuButton→ True

Change the bot's menu button in a chat.

ParameterTypeRequiredDescription
menu_buttonMenuButtonOptionalJSON menu button: default or commands.
chat_idInteger or StringOptionalTarget chat: numeric id or @username.
POST/bot<token>/logOut→ True

Same release as close: the long-poll slot and this instance's webhook delivery are given up. The token is not revoked — that lives in @BotMother.

POST/bot<token>/deleteMyCommands→ True

Delete the bot's command list for the given scope and language.

ParameterTypeRequiredDescription
scopeBotCommandScopeOptionalJSON scope: default, all_private_chats, all_group_chats, all_chat_administrators, chat, chat_administrators or chat_member.
language_codeStringOptionalTwo-letter language code; empty sets the default.
GET/bot<token>/getMyDescription→ BotDescription

Read the bot's description shown on an empty chat screen.

ParameterTypeRequiredDescription
language_codeStringOptionalTwo-letter language code; empty sets the default.
POST/bot<token>/setMyShortDescription→ True

Set the short description shown on the bot's profile page.

ParameterTypeRequiredDescription
short_descriptionStringOptionalShort description shown on the bot's profile.
language_codeStringOptionalTwo-letter language code; empty sets the default.
GET/bot<token>/getMyShortDescription→ BotShortDescription

Read the bot's short description.

ParameterTypeRequiredDescription
language_codeStringOptionalTwo-letter language code; empty sets the default.
GET/bot<token>/getChatMenuButton→ MenuButton

Read the bot's menu button for a chat, or the default one.

ParameterTypeRequiredDescription
chat_idInteger or StringOptionalTarget chat: numeric id or @username.
POST/bot<token>/setMyProfilePhoto→ True

Set the bot's own profile photo.

ParameterTypeRequiredDescription
photoInputProfilePhotoYesJSON object. Either {"type":"static","photo":"attach://&lt;field&gt;"} for a JPG, or {"type":"animated","animation":"attach://&lt;field&gt;","main_frame_timestamp":0.0} for an MPEG4. A profile photo cannot be reused, so it must be uploaded in this request — a file_id is not accepted.
ShellRequest
curl "https://api.reyta.uz/bot<token>/setMyProfilePhoto" \
  -F "photo={"type":"static","photo":"attach://pic"}" \
  -F "[email protected]"
JSONResponse
{
  "ok": true,
  "result": true
}
POST/bot<token>/removeMyProfilePhoto→ True

Remove the bot's current profile photo. An earlier photo, if the bot has one, becomes current again.

ShellRequest
curl "https://api.reyta.uz/bot<token>/removeMyProfilePhoto"
JSONResponse
{
  "ok": true,
  "result": true
}
POST/bot<token>/setMyDefaultAdministratorRights→ True

Set the administrator rights requested when the bot is added to a chat.

ParameterTypeRequiredDescription
rightsChatAdministratorRightsOptionalJSON object with the default administrator rights.
for_channelsBooleanOptionalApply the rights to channels instead of groups.
GET/bot<token>/getMyDefaultAdministratorRights→ ChatAdministratorRights

Read the bot's default administrator rights.

ParameterTypeRequiredDescription
for_channelsBooleanOptionalApply the rights to channels instead of groups.
POST/bot<token>/setUserEmojiStatus→ True

Set a user's emoji status using a custom emoji the bot may use.

ParameterTypeRequiredDescription
user_idIntegerYesTarget user.
emoji_status_custom_emoji_idStringOptionalCustom emoji to show as the user's status.
emoji_status_expiration_dateIntegerOptionalUnix time when the emoji status expires.
POST/bot<token>/close→ True

Release the bot from this server before running it elsewhere: the long-poll slot is freed at once, so a bot restarting in another process does not get 409 until the lease expires, and webhook delivery from this instance stops. The webhook itself is kept — delete it first if the bot must not be reached again.

Files & stickers

Download files the bot can see, and author sticker sets. A set created through the API is owned by the bot that created it.

GET/bot<token>/getFile→ File

Prepare a file for download and return a File with its path.

ParameterTypeRequiredDescription
file_idStringYesIdentifier of the file — including sticker file_ids from getStickerSet. The response contains a file_path to download from /file/bot<token>/<file_path>.
ShellRequest
curl "https://api.reyta.uz/bot<token>/getFile" -d file_id=CAQAAAABHQwcfJJAEAAQgUZMXHglLAAAAAEAAAAAAAAAAA
JSONResponse
{
  "ok": true,
  "result": {
    "file_id": "CAQAAAABHQwcfJJAEAAQgUZMXHglLAAAAAEAAAAAAAAAAA",
    "file_unique_id": "Ch0MHHySQBAA",
    "file_size": 888,
    "file_path": "sticker/CAQAAAABHQwcfJJAEAAQgUZMXHglLAAAAAEAAAAAAAAAAA"
  }
}
GET/bot<token>/getStickerSet→ StickerSet

A sticker set by name.

ParameterTypeRequiredDescription
nameStringYesName.
GET/bot<token>/getCustomEmojiStickers→ Array of Sticker

Information about custom emoji stickers by id.

ParameterTypeRequiredDescription
custom_emoji_idsArray of StringYesJSON array of custom emoji ids.
POST/bot<token>/createNewStickerSet→ True

Create a new sticker set owned by a user.

ParameterTypeRequiredDescription
user_idIntegerYesThe user who owns the set. The creating bot keeps the right to edit it.
nameStringYesShort name of the set, 5-64 characters: a letter first, then letters, digits and underscores.
titleStringYesSet title, 1-64 characters.
stickersArray of InputStickerYesJSON array, at most 50 items. Each item needs sticker (a file_id from uploadStickerFile, or attach://&lt;field&gt; naming a part of this request), format and emoji_list; keywords and mask_position are optional.
sticker_typeStringOptionalregular (default), mask or custom_emoji.
needs_repaintingBooleanOptionalFor a custom_emoji set only: its stickers are recoloured to match the text or context they appear in. Passing it for any other sticker_type is an error.
ShellRequest
curl "https://api.reyta.uz/bot<token>/createNewStickerSet" \
  -F user_id=1000100 -F name=mypack_by_yourbot -F title="My pack" \
  -F 'stickers=[{"sticker":"attach://s1","format":"static","emoji_list":["🔥"]}]' \
  -F s1=@cat.webp
JSONResponse
{ "ok": true, "result": true }
POST/bot<token>/deleteStickerFromSet→ True

Remove a sticker from a set.

ParameterTypeRequiredDescription
stickerStringYesfile_id of the sticker.
POST/bot<token>/deleteStickerSet→ True

Delete a sticker set the bot created.

ParameterTypeRequiredDescription
nameStringYesName.
POST/bot<token>/setStickerSetTitle→ True

Rename a sticker set the bot created.

ParameterTypeRequiredDescription
nameStringYesName.
titleStringYesTitle.
POST/bot<token>/setStickerPositionInSet→ True

Move a sticker to a different position in its set.

ParameterTypeRequiredDescription
stickerStringYesfile_id of the sticker.
positionIntegerYesZero-based position in the set.
POST/bot<token>/setStickerEmojiList→ True

Replace the emoji associated with a sticker.

ParameterTypeRequiredDescription
stickerStringYesfile_id of the sticker.
emoji_listArray of StringYesJSON array of 1-20 emoji.
POST/bot<token>/setStickerKeywords→ True

Replace the search keywords of a sticker.

ParameterTypeRequiredDescription
stickerStringYesfile_id of the sticker.
keywordsArray of StringOptionalJSON array of search keywords.
POST/bot<token>/setStickerMaskPosition→ True

Change where a mask sticker is placed on a face.

ParameterTypeRequiredDescription
stickerStringYesfile_id of the sticker.
mask_positionMaskPositionOptionalJSON object: point (forehead, eyes, mouth, chin), x_shift, y_shift, scale.
POST/bot<token>/uploadStickerFile→ File

Upload a sticker file for later use in createNewStickerSet or addStickerToSet. The file is validated before it is stored — format, dimensions, TGS frame rate and duration, WebM codec — and a rejected file returns 400 naming the rule it broke.

ParameterTypeRequiredDescription
user_idIntegerYesThe user the upload is made for. In Reyta the calling bot owns every set it creates, so this only identifies the requester.
stickerInputFileYesThe sticker file, uploaded as multipart/form-data.
sticker_formatStringYesOne of static (.webp), animated (.tgs) or video (.webm).
ShellRequest
curl "https://api.reyta.uz/bot<token>/uploadStickerFile" \
  -F user_id=1000100 -F sticker_format=static -F sticker=@cat.webp
JSONResponse
{
  "ok": true,
  "result": {
    "file_id": "CAQAAAABHQwcfJJAEAAQgUZMXHglLAAAAAEAAAAAAAAAAA",
    "file_unique_id": "Ch0MHHySQBAA",
    "file_size": 888
  }
}
POST/bot<token>/addStickerToSet→ True

Add a sticker to a set the bot created. Adding a sticker that is already in the set changes nothing and answers true, so a repeated call is safe.

ParameterTypeRequiredDescription
user_idIntegerYesIdentifies the requester.
nameStringYesShort name of the set.
stickerInputStickerYesJSON object with sticker (file_id or attach://&lt;field&gt;), format and emoji_list.
POST/bot<token>/replaceStickerInSet→ True

Replace a sticker in a set with a new one. The replacement takes the replaced sticker's position, and a rejected replacement leaves the set untouched.

ParameterTypeRequiredDescription
user_idIntegerYesIdentifies the requester.
nameStringYesShort name of the set.
old_stickerStringYesfile_id of the sticker being replaced.
stickerInputStickerYesThe replacement, same shape as in addStickerToSet.
POST/bot<token>/setStickerSetThumbnail→ True

Set the thumbnail of a sticker set. Takes an uploaded 100x100 image (attach://), or a file_id — a sticker from the same set works as the cover.

ParameterTypeRequiredDescription
nameStringYesShort name of the set.
user_idIntegerYesIdentifies the requester.
thumbnailStringOptionalAn uploaded image as attach://&lt;field&gt; (exactly 100x100, up to 128 KB static or 32 KB animated/video), or a file_id — a sticker from the same set is accepted as the cover. Omit it to drop the thumbnail and fall back to the first sticker.
formatStringYesstatic for a WEBP/PNG image, animated for a TGS, video for a WEBM. It is checked against the uploaded bytes, so a mislabelled file is refused.
POST/bot<token>/setCustomEmojiStickerSetThumbnail→ True

Set the thumbnail of a custom emoji sticker set.

ParameterTypeRequiredDescription
nameStringYesShort name of the custom emoji set.
custom_emoji_idStringOptionalId of a custom emoji from the set. Both the decimal document id and the file_unique_id printed by getStickerSet are accepted. Omit to clear.

Forum topics

Manage topics in a forum supergroup. Every method here needs a supergroup with forum mode on — a channel or a basic group is rejected.

POST/bot<token>/createForumTopic→ ForumTopic

Create a topic in a forum supergroup.

ParameterTypeRequiredDescription
chat_idInteger or StringYesUnique identifier of the target chat, or @channelusername.
nameStringYesTopic name, up to 128 characters.
icon_colorIntegerOptionalIcon colour as an RGB integer.
icon_custom_emoji_idStringOptionalCustom emoji used as the topic icon.
POST/bot<token>/editForumTopic→ True

Edit name/icon of a forum topic.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_thread_idIntegerYesForum topic the message belongs to.
nameStringOptionalName.
icon_custom_emoji_idStringOptionalCustom emoji shown as the topic icon.
POST/bot<token>/deleteForumTopic→ True

Delete a forum topic along with its messages.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_thread_idIntegerYesForum topic the message belongs to.
POST/bot<token>/closeForumTopic→ True

Close a forum topic so no new messages can be posted.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_thread_idIntegerYesForum topic the message belongs to.
POST/bot<token>/reopenForumTopic→ True

Reopen a closed forum topic.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_thread_idIntegerYesForum topic the message belongs to.
POST/bot<token>/unpinAllForumTopicMessages→ True

Unpin every pinned message in a forum topic.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
message_thread_idIntegerYesForum topic the message belongs to.
POST/bot<token>/editGeneralForumTopic→ True

Rename the General topic of a forum.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
nameStringYesName.
POST/bot<token>/closeGeneralForumTopic→ True

Close the General topic of a forum.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
POST/bot<token>/reopenGeneralForumTopic→ True

Reopen the General topic of a forum.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
POST/bot<token>/hideGeneralForumTopic→ True

Hide the General topic from the forum's topic list.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
POST/bot<token>/unhideGeneralForumTopic→ True

Show the General topic again.

ParameterTypeRequiredDescription
chat_idInteger or StringYesTarget chat: numeric id or @username.
GET/bot<token>/getForumTopicIconStickers→ Array of StickerPartial support

List the stickers available as forum topic icons.

Reyta ships no curated topic-icon pack. An operator can point the server at a custom-emoji set (ForumTopicIconSet in botapid.yaml) and it is served like any other pack; until then the method returns an empty array, and clients show no custom-icon picker.