-
-
Notifications
You must be signed in to change notification settings - Fork 5
TGSendMessage
__SyS__ edited this page Jan 21, 2019
·
5 revisions
-
Description
Sends text messages to specified chatid.
-
Parameters
-
TGBot:
bot
- bot instance id -
const
TGChatId:chatid[]
- chat id to which message to be sent -
const text[]
- message to be send in string literal -
TGMessage:
reply_id
- (optional) send this message as a reply -
TGParseMode:
parse_mode
- (optional) parse the message in specified format before sending -
callback[]
- (optional) - Callback to be called after message is send.
-
TGBot:
-
Example
new TGBot:bot = TGConnect("your_bot_token_here"); new TGChatId:chatid[] = "562896556";//replace with your chatid TGSendMessage( bot, chatid, "`markdown text` ***bold*** _italic_ 123", .parse_mode=MARKDOWN, .callback="SendingMessage" ); forward SendingMessage(TGBot:bot,TGMessage:messageid); public SendingMessage(TGBot:bot,TGMessage:messageid) { //bot is bot instance //messageid is send message' id return 1; }