fromJson static method

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

Creates a object from a json

Implementation

static InlineKeyboardButton fromJson(Map<String, dynamic> json) {
  return InlineKeyboardButton._(
    json['text']!,
    url: json['url'],
    loginUrl: callIfNotNull(LoginUrl.fromJson, json['login_url']),
    callbackData: json['callback_data'],
    webApp: callIfNotNull(WebAppInfo.fromJson, json['web_app']),
    switchInlineQuery: json['switch_inline_query'],
    switchInlineQueryCurrentChat: json['switch_inline_query_current_chat'],
    callbackGame: callIfNotNull(CallbackGame.fromJson, json['callback_game']),
    pay: json['pay'],
  );
}