Link Search Menu Expand Document

Constructor: inputInvoicePremiumGiftStars

Back to constructors index

Used to gift a Telegram Premium subscription to another user, paying with Telegram Stars.

Attributes:

NameTypeRequiredDescription
user_idUsername, chat ID, Update, Message or InputUserOptionalWho will receive the gifted subscription.
monthsintYesDuration of the subscription in months, must be one of the options with currency == "XTR" returned by payments.getPremiumGiftCodeOptions.
messageTextWithEntitiesOptionalMessage attached with the gift.

Type: InputInvoice

Example:

$inputInvoicePremiumGiftStars = ['_' => 'inputInvoicePremiumGiftStars', 'user_id' => InputUser, 'months' => int, 'message' => TextWithEntities];