SendMessageRequest

data class SendMessageRequest(chat_id: String, text: String, parse_mode: ParseMode?, entities: List<MessageEntity>?, disable_web_page_preview: Boolean?, disable_notification: Boolean?, reply_to_message_id: Long?, allow_sending_without_reply: Boolean?, reply_markup: KeyboardOption?) : TelegramRequest

Use this method to send text messages. On success, the sent Message is returned.

Constructors

SendMessageRequest
Link copied to clipboard
fun SendMessageRequest(chat_id: String, text: String, parse_mode: ParseMode? = null, entities: List<MessageEntity>? = null, disable_web_page_preview: Boolean? = null, disable_notification: Boolean? = null, reply_to_message_id: Long? = null, allow_sending_without_reply: Boolean? = null, reply_markup: KeyboardOption? = null)

Properties

allow_sending_without_reply
Link copied to clipboard
val allow_sending_without_reply: Boolean? = null
Pass True, if the message should be sent even if the specified replied-to message is not found
chat_id
Link copied to clipboard
val chat_id: String
Unique identifier for the target chat or username of the target channel (in the format @channelusername)
disable_notification
Link copied to clipboard
val disable_notification: Boolean? = null
Sends the message
disable_web_page_preview
Link copied to clipboard
val disable_web_page_preview: Boolean? = null
Disables link previews for links in this message
entities
Link copied to clipboard
val entities: List<MessageEntity>? = null
List of special entities that appear in message text, which can be specified instead of parse_mode
parse_mode
Link copied to clipboard
val parse_mode: ParseMode? = null
Mode for parsing entities in the message text.
reply_markup
Link copied to clipboard
val reply_markup: KeyboardOption? = null
Additional interface options.
reply_to_message_id
Link copied to clipboard
val reply_to_message_id: Long? = null
If the message is a reply, ID of the original message
text
Link copied to clipboard
val text: String
Text of the message to be sent, 1-4096 characters after entities parsing