Interface UserGift

Represents a gift received by a user.

interface UserGift {
    @type: "userGift";
    date: number;
    gift: Gift;
    is_private?: boolean;
    is_saved?: boolean;
    message_id: number;
    sell_star_count: number;
    sender_user_id: number;
    text: FormattedText;
}

Properties

@type: "userGift"
date: number

Point in time (Unix timestamp) when the gift was sent.

gift: Gift

The gift.

is_private?: boolean

True, if the sender and gift text are shown only to the gift receiver; otherwise, everyone are able to see them.

is_saved?: boolean

True, if the gift is displayed on the user's profile page; may be false only for the receiver of the gift.

message_id: number

Identifier of the message with the gift in the chat with the sender of the gift; can be 0 or an identifier of a deleted message; only for the gift receiver.

sell_star_count: number

Number of Telegram Stars that can be claimed by the receiver instead of the gift; 0 if the gift can't be sold by the current user.

sender_user_id: number

Identifier of the user that sent the gift; 0 if unknown.

Message added to the gift.