telegram as the
platform value in post payloads.
Telegram supports two connection modes:
- managed bot connections, where Kavenio owns the bot credential and the customer connects a channel or group by chat ID or access code
- bring-your-own bot-token connections, where the customer supplies a Telegram bot token and optional chat ID
- managed Business connections, where a Telegram user grants the Kavenio bot permission to publish Stories on their profile
Quick Reference
Connect
Use managed connect when customers should not handle bot credentials. The direct form connects an already-known Telegram chat ID:connected, pending, or expired.
Use BYO bot-token connect when the customer owns the Telegram bot credential:
Connect A Telegram Business Profile
Start an automatic pairing session:botUrl. Open it and press Start. The bot
then asks the Telegram user to open Settings > Chat Automation, add
@kavenio_bot, and enable Manage Stories. Kavenio matches the Telegram user
from the private Start message to the later Business connection and completes
the account automatically.
Poll the organization-scoped session until it reaches connected:
Fallback claim code
If a user connects the bot without starting a pairing link, Kavenio sends an eight-character recovery code. Claim it with:Create A Post
Create a Telegram post through the shared posts API:platformSpecificData.chatId only when the connected bot is allowed to post
to another Telegram chat.
Platform Options
Telegram-specific options live underplatformSpecificData:
Profile Stories
Use the same Posts API withcontentType: "story" on a claimed Telegram
Business account. The agent supplies the public image or video URL; Kavenio
downloads it with outbound-URL and size checks, then uploads a fresh file to
Telegram as required by the Bot API.
Stories require exactly one image or video. Captions are limited to 2,048
characters. Photos must be 1080x1920 and no larger than 10 MB. Videos must be
720x1280, no longer than 60 seconds, and no larger than 30 MB. The managed Bot
API publishes Business profile Stories with Everyone visibility; contacts and
other Telegram users can see them subject to Telegram’s normal Story surfaces.
Telegram account eligibility and Story quotas remain provider-enforced.
Media
AddmediaItems for images, videos, documents, or media groups. Kavenio
validates the public media URL and either passes it to Telegram by URL or
uploads it as multipart form data when the item requires upload.
content. For multi-item media groups, the
caption is attached to the first media item.
Edit And Delete
Kavenio can edit text and captions for Kavenio-published Telegram message targets, edit Kavenio-published Business Stories, and delete both through the shared post target APIs. Telegram requires Story media on edit, so Kavenio reuploads the source media recorded when the Story was published. Telegram edit behavior depends on the message type and Telegram provider rules. If Telegram reports that the message is already unchanged or already deleted, Kavenio treats the operation as idempotent.Command Menus
Telegram command menus are account scoped:Direct Messages
Kavenio exposes account-scoped Telegram inbox APIs for managed Telegram accounts:limit and includeArchived. Message listing
accepts limit. Sending a message accepts text, media, or both:
itemType: "telegram_conversation". Kavenio does not
invent Telegram read state, so Telegram conversation rows are not returned by
unreadOnly=true.
Kavenio creates the first persisted conversation when a private Telegram user
redeems a managed access code. Later inbound private messages are stored only
when the provider chat maps to exactly one existing conversation; ambiguous
private chats are ignored instead of guessed.
BYO bot-token accounts return an unsupported-provider error for Telegram DM
APIs. Read receipts, typing indicators, and arbitrary Telegram Bot API proxying
are not supported.
The CLI exposes the same managed-inbox surface:
--include-archived to include archived conversations. Pass
--archived false to unarchive a conversation.