import 'package:json_annotation/json_annotation.dart'; part 'bread_dto.g.dart'; @JsonSerializable(createToJson: false) class BreadsDto { final List? data; const BreadsDto({this.data}); factory BreadsDto.fromJson(Map json) => _$BreadsDtoFromJson(json); } @JsonSerializable(createToJson: false) class BreadDataDto { final String? id; final String? type; final BreadAttributesDataDto? attributes; const BreadDataDto({this.id, this.type, this.attributes}); factory BreadDataDto.fromJson(Map json) => _$BreadDataDtoFromJson(json); } @JsonSerializable(createToJson: false) class BreadAttributesDataDto { final String? name; final String? info; final String? image; const BreadAttributesDataDto({this.name, this.info, this.image}); factory BreadAttributesDataDto.fromJson(Map json) => _$BreadAttributesDataDtoFromJson(json); }