telegramx.js

SendGiftParams

interface

Declaration

interface SendGiftParams 

Properties

chat_idproperty#
chat_id?: number | string;

Required if user_id is not specified. Unique identifier for the chat or username of the channel (in the format username) that will receive the gift.

gift_idproperty#
gift_id: string;

Identifier of the gift; limited gifts can't be sent to channel chats

pay_for_upgrade?: boolean;

Pass True to pay for the gift upgrade from the bot's balance, thereby making the upgrade free for the receiver

text_entities?: MessageEntity[];

A JSON-serialized list of special entities that appear in the gift text. It can be specified instead of text_parse_mode. Entities other than "bold", "italic", "underline", "strikethrough", "spoiler", "custom_emoji", and "date_time" are ignored.

text_parse_mode?: string;

Mode for parsing entities in the text. See formatting options for more details. Entities other than "bold", "italic", "underline", "strikethrough", "spoiler", "custom_emoji", and "date_time" are ignored.

textproperty#
text?: string;

Text that will be shown along with the gift; 0-128 characters

user_idproperty#
user_id?: number;

Required if chat_id is not specified. Unique identifier of the target user who will receive the gift.