factory ErrorResponse.fromJson(Map<String, dynamic> json) { return ErrorResponse( error: ErrorDetails.fromJson(json['error']), ); }