ChatBoostSourceGiveaway.fromJson constructor

ChatBoostSourceGiveaway.fromJson(
  1. Map<String, dynamic> json
)

Parses a ChatBoostSourceGiveaway from TDLib JSON.

Implementation

factory ChatBoostSourceGiveaway.fromJson(Map<String, dynamic> json) =>
    ChatBoostSourceGiveaway(
      userId: _readInt(json['user_id']),
      giftCode: _readString(json['gift_code']),
      giveawayMessageId: _readInt(json['giveaway_message_id']),
      isUnclaimed: _readBool(json['is_unclaimed']),
    );