Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(recommend): RecommendedForYouQuery userToken should be required #1496

Merged
merged 1 commit into from Dec 12, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
18 changes: 17 additions & 1 deletion packages/recommend/src/types/RecommendedForYouQuery.ts
@@ -1,3 +1,19 @@
import { RecommendationsQuery } from './RecommendationsQuery';
import { RecommendSearchOptions } from './RecommendSearchOptions';

export type RecommendedForYouQuery = Omit<RecommendationsQuery, 'model' | 'objectID'>;
export type RecommendedForYouQuery = Omit<
RecommendationsQuery,
'model' | 'objectID' | 'queryParameters'
> & {
/**
* List of [search parameters](https://www.algolia.com/doc/api-reference/search-api-parameters/) to send.
*/
readonly queryParameters: Omit<RecommendSearchOptions, 'userToken'> & {
/**
* A user identifier.
* Format: alpha numeric string [a-zA-Z0-9_-]
* Length: between 1 and 64 characters.
*/
readonly userToken: string;
};
};