messageMediaGiveaway
Contains info about a giveaway, see here » for more info.
type tg.MessageMediaGiveaway struct { /* ... */ }
Implements MessageMedia.
Fields
| Name | Type | Required | Description |
|---|---|---|---|
OnlyNewSubscribers | bool | — | If set, only new subscribers starting from the giveaway creation date will be able to participate to the giveaway. |
WinnersAreVisible | bool | — | If set, giveaway winners are public and will be listed in a messageMediaGiveawayResults message that will be automatically sent to the channel once the giveaway ends. |
Channels | []int64 | yes | The channels that the user must join to participate in the giveaway. |
CountriesISO2 | []string | — | If set, only users residing in these countries can participate in the giveaway, (specified as a list of two-letter ISO 3166-1 alpha-2 country codes); otherwise there are no country-based limitations. |
PrizeDescription | string | — | Can contain a textual description of additional giveaway prizes. |
Quantity | int | yes | Number of Telegram Premium subscriptions given away. |
Months | int | — | Duration in months of each Telegram Premium subscription in the giveaway. |
Stars | int64 | — | For Telegram Star giveaways, the total number of Telegram Stars being given away. |
UntilDate | int | yes | The end date of the giveaway. |
References
- Official documentation
- Generated Go reference
- TL definition:
messageMediaGiveaway#aa073beb