fromJson static method

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

Implementation

static BusinessConnectedBot? fromJson(Map<String, dynamic>? json) {
  if (json == null) {
    return null;
  }

  return BusinessConnectedBot(
    botUserId: (json['bot_user_id'] as int?) ?? 0,
    recipients: BusinessRecipients.fromJson(
      tdMapFromJson(json['recipients']),
    ),
    rights: BusinessBotRights.fromJson(tdMapFromJson(json['rights'])),
  );
}