// ignore_for_file: invalid_annotation_target import 'package:freezed_annotation/freezed_annotation.dart'; import '../error/error_model.dart'; import '../recommendation_item/recommendation_item.dart'; part 'recommend_response.freezed.dart'; part 'recommend_response.g.dart'; /// Standard API envelope for `POST /api/v1/recommend`. /// /// [data] holds the ranked recommendations and may be empty (or null) until /// the AI service finishes indexing the company. @freezed abstract class RecommendResponse with _$RecommendResponse { @JsonSerializable(explicitToJson: true) const factory RecommendResponse({ @JsonKey(name: 'data') required List? data, @JsonKey(name: 'error') required ErrorModel? error, required String? message, required bool? success, }) = _RecommendResponse; factory RecommendResponse.fromJson(Map json) => _$RecommendResponseFromJson(json); }