import 'package:freezed_annotation/freezed_annotation.dart'; part 'account.g.dart'; @JsonSerializable() class Account { int id; DateTime createdAt; DateTime updatedAt; DateTime? deletedAt; DateTime? confirmedAt; DateTime? suspendedAt; String name; String nick; dynamic avatar; dynamic banner; String description; List? badges; String? emailAddress; int? externalId; Account({ required this.id, required this.createdAt, required this.updatedAt, required this.deletedAt, required this.confirmedAt, required this.suspendedAt, required this.name, required this.nick, required this.avatar, required this.banner, required this.description, required this.badges, required this.emailAddress, this.externalId, }); factory Account.fromJson(Map json) => _$AccountFromJson(json); Map toJson() => _$AccountToJson(this); } @JsonSerializable() class AccountBadge { int id; DateTime createdAt; DateTime updatedAt; DateTime? deletedAt; Map? metadata; String type; int accountId; AccountBadge({ required this.id, required this.accountId, required this.createdAt, required this.updatedAt, required this.deletedAt, required this.metadata, required this.type, }); factory AccountBadge.fromJson(Map json) => _$AccountBadgeFromJson(json); Map toJson() => _$AccountBadgeToJson(this); }