Raw.StarsGiveawayOption

Raw.StarsGiveawayOption

Contains info about a telegram star giveaway option.

starsGiveawayOption#94ce852a flags:# extended:flags.0?true default:flags.1?true stars:long yearly_boosts:int store_product:flags.2?string currency:string amount:long winners:Vector<StarsGiveawayWinnersOption> = StarsGiveawayOption;
export namespace Raw {
  export class StarsGiveawayOption {
    constructor(params: {
      extended?: boolean;
      default?: boolean;
      stars: bigint;
      yearlyBoosts: number;
      storeProduct?: string;
      currency: string;
      amount: bigint;
      winners: Array<Raw.TypeStarsGiveawayWinnersOption>;
    }) {}
  }
}
🚫

This is a types constructor, you can’t use it as method when call invoke.

Layer: 198
Constructor ID: 0x94ce852a

Property

  • extended : boolean or undefined

    If set, this option must only be shown in the full list of giveaway options (i.e. they must be added to the list only when the user clicks on the expand button).

  • default : boolean or undefined

    If set, this option must be pre-selected by default in the option list.

  • stars : bigint

    The number of telegram stars that will be distributed among winners

  • yearlyBoosts : number

    Number of times the chat will be boosted for one year if the inputstorepaymentstarsgiveaway.boostPeer flag is populated

  • storeProduct : string or undefined

    Identifier of the store product associated with the option, official apps only.

  • currency : string

    Three-letter iso 4217 currency code

  • amount : bigint

    Total price in the smallest units of the currency (integer, not float/double). for example, for a price of us 1.45 pass amount = 145. see the exp parameter in currencies.json, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).

  • winners : Array of Raw.TypeStarsGiveawayWinnersOption

    Allowed options for the number of giveaway winners.