ChatBoostSourceGiveaway

Added in version 20.8.

class telegram.ChatBoostSourceGiveaway(giveaway_message_id, user=None, is_unclaimed=None, prize_star_count=None, *, api_kwargs=None)[source]

Bases: telegram.ChatBoostSource

The boost was obtained by the creation of a Telegram Premium giveaway or a Telegram Star. This boosts the chat 4 times for the duration of the corresponding Telegram Premium subscription for Telegram Premium giveaways and prize_star_count / 500 times for one year for Telegram Star giveaways.

Added in version 20.8.

Parameters:
  • giveaway_message_id (int) – Identifier of a message in the chat with the giveaway; the message could have been deleted already. May be 0 if the message isn’t sent yet.

  • user (telegram.User, optional) – User that won the prize in the giveaway if any; for Telegram Premium giveaways only.

  • prize_star_count (int, optional) –

    The number of Telegram Stars to be split between giveaway winners; for Telegram Star giveaways only.

    Added in version 21.6.

  • is_unclaimed (bool, optional) – True, if the giveaway was completed, but there was no user to win the prize.

source[source]

Source of the boost. Always GIVEAWAY.

Type:

str

giveaway_message_id[source]

Identifier of a message in the chat with the giveaway; the message could have been deleted already. May be 0 if the message isn’t sent yet.

Type:

int

user[source]

Optional. User that won the prize in the giveaway if any.

Type:

telegram.User

prize_star_count[source]

Optional. The number of Telegram Stars to be split between giveaway winners; for Telegram Star giveaways only.

Added in version 21.6.

Type:

int

is_unclaimed[source]

Optional. True, if the giveaway was completed, but there was no user to win the prize.

Type:

bool