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.
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.
Verify 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.
Request 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).
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:
sendMessage
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.
Parameter
Type
Required
Description
offset
Integer
Optional
Identifier of the first update to return. Set to last received update_id + 1 to confirm.
limit
Integer
Optional
Number of updates to retrieve, 1–100. Default 100.
timeout
Integer
Optional
Long-polling timeout in seconds. 0 for short polling (testing only).
allowed_updates
Array of String
Optional
List of update types to receive, e.g. ["message","callback_query"].
{"ok":true,"result":true,"description":"Webhook was set"}
POST/bot<token>/deleteWebhook→ True
Remove the webhook and switch back to getUpdates.
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→ Message
Send a text message. Supports Markdown/HTML formatting and inline keyboards.
Parameter
Type
Required
Description
chat_id
Integer or String
Yes
Unique chat identifier or @username of a channel.
text
String
Yes
Message text, 1–4096 characters.
parse_mode
String
Optional
"MarkdownV2" or "HTML" for entity formatting.
reply_markup
Object
Optional
Inline keyboard, reply keyboard, or force-reply.
disable_notification
Boolean
Optional
Send silently, without a notification sound.
Request
curl"https://api.reyta.uz/bot<token>/sendMessage"\ -d"chat_id=987654321"\ -d"text=Salom! Reyta Bot API is live."\ -d"parse_mode=HTML"
Response
{"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.
Parameter
Type
Required
Description
chat_id
Integer or String
Yes
Target chat.
photo
String or InputFile
Yes
file_id, an HTTPS URL, or an uploaded file.
caption
String
Optional
Caption, 0–1024 characters.
POST/bot<token>/forwardMessage→ Message
Forward a message of any kind from one chat to another.
Parameter
Type
Required
Description
chat_id
Integer or String
Yes
Unique identifier of the target chat, or @channelusername.
from_chat_id
Integer or String
Yes
Chat the original message comes from.
message_id
Integer
Yes
Identifier of the message.
POST/bot<token>/copyMessage→ MessageId
Copy a message without a forward header.
Parameter
Type
Required
Description
chat_id
Integer or String
Yes
Unique identifier of the target chat, or @channelusername.
from_chat_id
Integer or String
Yes
Chat the original message comes from.
message_id
Integer
Yes
Identifier of the message.
caption
String
Optional
New caption. If omitted, the original caption is kept.
parse_mode
String
Optional
Formatting of the new caption: HTML, Markdown, or MarkdownV2.
POST/bot<token>/sendDocument→ Message
Send a general file, up to the configured size limit.
POST/bot<token>/sendVideo→ Message
Send an MP4 video.
POST/bot<token>/sendAnimation→ Message
Send a GIF or H.264/MPEG-4 animation without sound.
POST/bot<token>/sendAudio→ Message
Send an audio file to be shown in the music player.
POST/bot<token>/sendVoice→ Message
Send a voice message (OGG/OPUS).
POST/bot<token>/sendVideoNote→ Message
Send a rounded, square video note.
POST/bot<token>/sendMediaGroup→ Array of MessagePartial support
Send a group of photos/videos/documents as an album.
Returns the full array now, each item with from, date and media_group_id. The per-item media object (photo/video) is not echoed in the response yet – read the album via getUpdates if you need it.
POST/bot<token>/sendLocation→ Message
Send a point on the map; can be a live location.
Parameter
Type
Required
Description
chat_id
Integer or String
Yes
Unique identifier of the target chat, or @channelusername.
latitude
Float
Yes
Latitude of the location.
longitude
Float
Yes
Longitude of the location.
live_period
Integer
Optional
Seconds the location stays live, 60-86400. Omit for a one-shot location.
POST/bot<token>/sendVenue→ Message
Send information about a venue.
POST/bot<token>/sendContact→ Message
Send a phone contact.
POST/bot<token>/sendPoll→ MessageNot available yet
Send a native poll or quiz.
Not implemented yet – returns 501. Polls are not supported on the server side.
POST/bot<token>/sendDice→ Message
Send an animated emoji with a random value.
POST/bot<token>/sendChatAction→ True
Show a "typing…" or "uploading…" status.
POST/bot<token>/sendSticker→ MessageNot available yet
Send a static, animated, or video sticker.
Not implemented yet – returns 501. The sticker send path lands with a later phase; retry once it does.
POST/bot<token>/copyMessages→ Array of MessageId
Copy several messages at once without a link to the original.
POST/bot<token>/forwardMessages→ Array of MessageId
Forward several messages at once, keeping the original author.
Updating & deleting
POST/bot<token>/editMessageText→ Message or TruePartial support
Edit the text of a sent or inline message.
Editing by inline_message_id is not supported yet – returns 501. Editing by chat_id + message_id works.
Parameter
Type
Required
Description
text
String
Yes
New text of the message.
chat_id
Integer or String
Optional
Target chat. Required unless inline_message_id is used.
message_id
Integer
Optional
Message to edit. Required unless inline_message_id is used.
parse_mode
String
Optional
Formatting: HTML, Markdown, or MarkdownV2.
POST/bot<token>/editMessageCaption→ Message or TruePartial support
Edit the caption of a media message.
Editing by inline_message_id is not supported yet – returns 501. Editing by chat_id + message_id works.
POST/bot<token>/editMessageMedia→ Message or TruePartial support
Replace the media of a message.
Works by chat_id + message_id (media via URL or attach:// upload; the InputMedia caption replaces the message caption). file_id reuse and inline_message_id are not supported yet.
POST/bot<token>/editMessageReplyMarkup→ Message or TruePartial support
Edit only the inline keyboard of a message.
Editing by inline_message_id is not supported yet – returns 501. Editing by chat_id + message_id works.
POST/bot<token>/editMessageLiveLocation→ Message or TruePartial support
Move an active live location.
Editing by inline_message_id is not supported yet – returns 501. Editing by chat_id + message_id works.
POST/bot<token>/deleteMessage→ True
Delete a message the bot sent, or any message where it is admin.
Parameter
Type
Required
Description
chat_id
Integer or String
Yes
Unique identifier of the target chat, or @channelusername.
message_id
Integer
Yes
Identifier of the message.
POST/bot<token>/deleteMessages→ True
Delete multiple messages at once.
POST/bot<token>/stopMessageLiveLocation→ Message or TruePartial support
Stop updating an active live location before its period expires.
Stopping by inline_message_id is not supported yet – returns 501. Stopping by chat_id + message_id works.
POST/bot<token>/setMessageReaction→ True
Set or clear the bot's reaction on a message.
POST/bot<token>/stopPoll→ PollPartial support
Stop an active poll the bot sent.
Returns true instead of the final Poll object.
Inline & callbacks
POST/bot<token>/answerCallbackQuery→ True
Respond to an inline-button tap; optionally show an alert.
Parameter
Type
Required
Description
callback_query_id
String
Yes
Identifier of the callback query to answer.
text
String
Optional
Notification text, up to 200 characters.
show_alert
Boolean
Optional
Show a modal alert instead of a toast.
url
String
Optional
URL opened by the client.
cache_time
Integer
Optional
Seconds the result may be cached client-side.
POST/bot<token>/answerInlineQuery→ TruePartial support
Answer an inline query with a list of results.
Supported result types: article, photo, gif, mpeg4_gif, document. Other types return 400.