import 'package:json_annotation/json_annotation.dart'; part 'register_request.g.dart'; @JsonSerializable() class RegisterRequest { String name; String phone; String email; String password; RegisterRequest({ required this.name, required this.phone, required this.email, required this.password, }); Map toJson() => _$RegisterRequestToJson(this); factory RegisterRequest.fromJson(Map json) => _$RegisterRequestFromJson(json); }