tgsend
Send Telegram messages via bot API
TLDR
Send message
SYNOPSIS
tgsend [-c chatid] [-f file] [-p photo] [options] [message_]
DESCRIPTION
tgsend sends messages, files, and photos to Telegram chats using the Telegram Bot API. It is designed for automation and scripting, enabling notifications, alerts, and file delivery from the command line or cron jobs.
Messages can be sent to specific chats using their ID, and media attachments can include captions via the -m flag. The -s flag sends messages silently without triggering a notification on the recipient's device. A bot token is required and can be passed via the -t flag or environment configuration.
PARAMETERS
-c ID
Chat ID.-f FILE
Send file.-p FILE
Send photo.-m TEXT
Caption text.-s
Silent mode.-t TOKEN
Bot token.
CAVEATS
Bot token required. Chat ID needed. Rate limits apply.
HISTORY
tgsend sends messages via Telegram Bot API, useful for notifications and automation.
SEE ALSO
telegram-desktop(1), curl(1)
