Socket
Socket
Sign inDemoInstall

@sajari/sdk-node

Package Overview
Dependencies
1
Maintainers
8
Versions
49
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 4.4.1 to 4.5.1

build/src/generated/model/event.d.ts

8

build/src/collections.d.ts
import { Client } from "./client";
import { CollectionsApi, Collection, QueryCollectionRequest } from "./generated/api";
import { CollectionsApi, Collection, QueryCollectionRequest, Event } from "./generated/api";
export { withEndpoint, withKeyCredentials } from "./client";
declare type HeaderOptions = {
headers: {
[name: string]: string;
};
};
export declare class CollectionsClient extends Client {

@@ -31,4 +36,5 @@ client: CollectionsApi;

deleteCollection(id: string): Promise<any>;
trackEvent(accountId: string, collectionId: string, event: Event, options?: HeaderOptions): Promise<object>;
}
export declare const setCollectionDisplayName: (displayName: string) => (c: Collection, updateMask: Record<string, boolean>) => void;
export declare const setCollectionAuthorizedQueryDomains: (domains: string[]) => (c: Collection, updateMask: Record<string, boolean>) => void;

@@ -89,2 +89,11 @@ "use strict";

}
async trackEvent(accountId, collectionId, event, options) {
try {
const res = await this.client.trackEvent(accountId, collectionId, event, options);
return res.body;
}
catch (e) {
throw api_util_1.handleError(e);
}
}
}

@@ -91,0 +100,0 @@ exports.CollectionsClient = CollectionsClient;

@@ -15,2 +15,5 @@ /**

import { Collection } from "../model/collection";
import { Event } from "../model/event";
import { ExperimentRequest } from "../model/experimentRequest";
import { ExperimentResponse } from "../model/experimentResponse";
import { ListCollectionsResponse } from "../model/listCollectionsResponse";

@@ -72,2 +75,16 @@ import { QueryCollectionRequest } from "../model/queryCollectionRequest";

/**
* Run a query on a collection with a hypothetical configuration to see what kinds of results it produces. Saved promotions with a start date in the future are enabled during the experiment, unless they are explicitly disabled. The following example demonstrates how to run a simple experiment for a string, against a pipeline and with a proposed promotion: ```json { \"pipeline\": { \"name\": \"my-pipeline\" }, \"variables\": { \"q\": \"search terms\" }, \"promotions\": [{ \"id\": \"1234\", \"condition\": \"q = \'search terms\'\", \"pins\": [{ \"key\": { \"field\": \"id\", \"value\": \"54hdc7h2334h\" }, \"position\": 1 }] }] } ```
* @summary Experiment
* @param collectionId The collection to query, e.g. &#x60;my-collection&#x60;.
* @param experimentRequest
*/
experiment(collectionId: string, experimentRequest: ExperimentRequest, options?: {
headers: {
[name: string]: string;
};
}): Promise<{
response: http.IncomingMessage;
body: ExperimentResponse;
}>;
/**
* Retrieve the details of a collection.

@@ -89,3 +106,3 @@ * @summary Get collection

* @param pageSize The maximum number of collections to return. The service may return fewer than this value. If unspecified, at most 50 collections are returned. The maximum value is 100; values above 100 are coerced to 100.
* @param pageToken A page token, received from a previous [ListCollections](/api#operation/ListCollections) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListCollections](/api#operation/ListCollections) must match the call that provided the page token.
* @param pageToken A page token, received from a previous [ListCollections](/docs/api#operation/ListCollections) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListCollections](/docs/api#operation/ListCollections) must match the call that provided the page token.
*/

@@ -101,3 +118,3 @@ listCollections(pageSize?: number, pageToken?: string, options?: {

/**
* Query the collection to search for records. The following example demonstrates how to run a simple search for a particular string: ```json { \"variables\": { \"q\": \"search terms\" } } ``` For more information: - See [filtering content](https://docs.search.io/documentation/fundamentals/integrating-search/filters-and-sort-options) - See [tracking in the Go SDK](https://github.com/sajari/sdk-go/blob/v2/session.go) - See [tracking in the JS SDK](https://github.com/sajari/sajari-sdk-js/blob/master/src/session.ts)
* Query the collection to search for records. The following example demonstrates how to run a simple search for a particular string: ```json { \"variables\": { \"q\": \"search terms\" } } ``` For more information: - See [filtering content](https://docs.search.io/documentation/fundamentals/integrating-search/filters-and-sort-options) - See [tracking in the Go SDK](https://github.com/sajari/sdk-go/blob/v2/session.go) - See [tracking in the JS SDK](https://github.com/sajari/sdk-js/blob/554e182e77d3ba99a9c100b208ebf3be414d2067/src/index.ts#L881) Note: Unlike other API calls, the `QueryCollection` call can be called from a browser. When called from a browser, the `Account-Id` header must be set to your account ID.
* @summary Query collection

@@ -116,3 +133,3 @@ * @param collectionId The collection to query, e.g. &#x60;my-collection&#x60;.

/**
* Query the collection to search for records. The following example demonstrates how to run a simple search for a particular string: ```json { \"variables\": { \"q\": \"search terms\" } } ``` For more information: - See [filtering content](https://docs.search.io/documentation/fundamentals/integrating-search/filters-and-sort-options) - See [tracking in the Go SDK](https://github.com/sajari/sdk-go/blob/v2/session.go) - See [tracking in the JS SDK](https://github.com/sajari/sajari-sdk-js/blob/master/src/session.ts)
* Query the collection to search for records. The following example demonstrates how to run a simple search for a particular string: ```json { \"variables\": { \"q\": \"search terms\" } } ``` For more information: - See [filtering content](https://docs.search.io/documentation/fundamentals/integrating-search/filters-and-sort-options) - See [tracking in the Go SDK](https://github.com/sajari/sdk-go/blob/v2/session.go) - See [tracking in the JS SDK](https://github.com/sajari/sdk-js/blob/554e182e77d3ba99a9c100b208ebf3be414d2067/src/index.ts#L881) Note: Unlike other API calls, the `QueryCollection` call can be called from a browser. When called from a browser, the `Account-Id` header must be set to your account ID.
* @summary Query collection

@@ -131,2 +148,17 @@ * @param collectionId The collection to query, e.g. &#x60;my-collection&#x60;.

/**
* Track an analytics event when a user interacts with an object returned by a [QueryCollection](/docs/api/#operation/QueryCollection) request. An analytics event can be tracked for the following objects: - Results - Promotion banners - Redirects Note: You must pass an `Account-Id` header.
* @summary Track event
* @param accountId The account that owns the collection, e.g. &#x60;1618535966441231024&#x60;.
* @param collectionId The collection to track the event against, e.g. &#x60;my-collection&#x60;.
* @param event The details of the event to track.
*/
trackEvent(accountId: string, collectionId: string, event: Event, options?: {
headers: {
[name: string]: string;
};
}): Promise<{
response: http.IncomingMessage;
body: object;
}>;
/**
* Update the details of a collection.

@@ -133,0 +165,0 @@ * @summary Update collection

@@ -235,2 +235,80 @@ "use strict";

/**
* Run a query on a collection with a hypothetical configuration to see what kinds of results it produces. Saved promotions with a start date in the future are enabled during the experiment, unless they are explicitly disabled. The following example demonstrates how to run a simple experiment for a string, against a pipeline and with a proposed promotion: ```json { \"pipeline\": { \"name\": \"my-pipeline\" }, \"variables\": { \"q\": \"search terms\" }, \"promotions\": [{ \"id\": \"1234\", \"condition\": \"q = \'search terms\'\", \"pins\": [{ \"key\": { \"field\": \"id\", \"value\": \"54hdc7h2334h\" }, \"position\": 1 }] }] } ```
* @summary Experiment
* @param collectionId The collection to query, e.g. &#x60;my-collection&#x60;.
* @param experimentRequest
*/
async experiment(collectionId, experimentRequest, options = { headers: {} }) {
const localVarPath = this.basePath +
"/v4/collections/{collection_id}:experiment".replace("{" + "collection_id" + "}", encodeURIComponent(String(collectionId)));
let localVarQueryParameters = {};
let localVarHeaderParams = Object.assign({}, this._defaultHeaders);
const produces = ["application/json"];
// give precedence to 'application/json'
if (produces.indexOf("application/json") >= 0) {
localVarHeaderParams.Accept = "application/json";
}
else {
localVarHeaderParams.Accept = produces.join(",");
}
let localVarFormParams = {};
// verify required parameter 'collectionId' is not null or undefined
if (collectionId === null || collectionId === undefined) {
throw new Error("Required parameter collectionId was null or undefined when calling experiment.");
}
// verify required parameter 'experimentRequest' is not null or undefined
if (experimentRequest === null || experimentRequest === undefined) {
throw new Error("Required parameter experimentRequest was null or undefined when calling experiment.");
}
Object.assign(localVarHeaderParams, options.headers);
let localVarUseFormData = false;
let localVarRequestOptions = {
method: "POST",
qs: localVarQueryParameters,
headers: localVarHeaderParams,
uri: localVarPath,
useQuerystring: this._useQuerystring,
json: true,
body: models_1.ObjectSerializer.serialize(experimentRequest, "ExperimentRequest"),
};
let authenticationPromise = Promise.resolve();
if (this.authentications.BasicAuth.username &&
this.authentications.BasicAuth.password) {
authenticationPromise = authenticationPromise.then(() => this.authentications.BasicAuth.applyToRequest(localVarRequestOptions));
}
authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
let interceptorPromise = authenticationPromise;
for (const interceptor of this.interceptors) {
interceptorPromise = interceptorPromise.then(() => interceptor(localVarRequestOptions));
}
return interceptorPromise.then(() => {
if (Object.keys(localVarFormParams).length) {
if (localVarUseFormData) {
localVarRequestOptions.formData = localVarFormParams;
}
else {
localVarRequestOptions.form = localVarFormParams;
}
}
return new Promise((resolve, reject) => {
request_1.default(localVarRequestOptions, (error, response, body) => {
if (error) {
reject(error);
}
else {
if (response.statusCode &&
response.statusCode >= 200 &&
response.statusCode <= 299) {
body = models_1.ObjectSerializer.deserialize(body, "ExperimentResponse");
resolve({ response: response, body: body });
}
else {
reject(new apis_1.HttpError(response, body, response.statusCode));
}
}
});
});
});
}
/**
* Retrieve the details of a collection.

@@ -311,3 +389,3 @@ * @summary Get collection

* @param pageSize The maximum number of collections to return. The service may return fewer than this value. If unspecified, at most 50 collections are returned. The maximum value is 100; values above 100 are coerced to 100.
* @param pageToken A page token, received from a previous [ListCollections](/api#operation/ListCollections) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListCollections](/api#operation/ListCollections) must match the call that provided the page token.
* @param pageToken A page token, received from a previous [ListCollections](/docs/api#operation/ListCollections) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListCollections](/docs/api#operation/ListCollections) must match the call that provided the page token.
*/

@@ -383,3 +461,3 @@ async listCollections(pageSize, pageToken, options = { headers: {} }) {

/**
* Query the collection to search for records. The following example demonstrates how to run a simple search for a particular string: ```json { \"variables\": { \"q\": \"search terms\" } } ``` For more information: - See [filtering content](https://docs.search.io/documentation/fundamentals/integrating-search/filters-and-sort-options) - See [tracking in the Go SDK](https://github.com/sajari/sdk-go/blob/v2/session.go) - See [tracking in the JS SDK](https://github.com/sajari/sajari-sdk-js/blob/master/src/session.ts)
* Query the collection to search for records. The following example demonstrates how to run a simple search for a particular string: ```json { \"variables\": { \"q\": \"search terms\" } } ``` For more information: - See [filtering content](https://docs.search.io/documentation/fundamentals/integrating-search/filters-and-sort-options) - See [tracking in the Go SDK](https://github.com/sajari/sdk-go/blob/v2/session.go) - See [tracking in the JS SDK](https://github.com/sajari/sdk-js/blob/554e182e77d3ba99a9c100b208ebf3be414d2067/src/index.ts#L881) Note: Unlike other API calls, the `QueryCollection` call can be called from a browser. When called from a browser, the `Account-Id` header must be set to your account ID.
* @summary Query collection

@@ -463,3 +541,3 @@ * @param collectionId The collection to query, e.g. &#x60;my-collection&#x60;.

/**
* Query the collection to search for records. The following example demonstrates how to run a simple search for a particular string: ```json { \"variables\": { \"q\": \"search terms\" } } ``` For more information: - See [filtering content](https://docs.search.io/documentation/fundamentals/integrating-search/filters-and-sort-options) - See [tracking in the Go SDK](https://github.com/sajari/sdk-go/blob/v2/session.go) - See [tracking in the JS SDK](https://github.com/sajari/sajari-sdk-js/blob/master/src/session.ts)
* Query the collection to search for records. The following example demonstrates how to run a simple search for a particular string: ```json { \"variables\": { \"q\": \"search terms\" } } ``` For more information: - See [filtering content](https://docs.search.io/documentation/fundamentals/integrating-search/filters-and-sort-options) - See [tracking in the Go SDK](https://github.com/sajari/sdk-go/blob/v2/session.go) - See [tracking in the JS SDK](https://github.com/sajari/sdk-js/blob/554e182e77d3ba99a9c100b208ebf3be414d2067/src/index.ts#L881) Note: Unlike other API calls, the `QueryCollection` call can be called from a browser. When called from a browser, the `Account-Id` header must be set to your account ID.
* @summary Query collection

@@ -543,2 +621,86 @@ * @param collectionId The collection to query, e.g. &#x60;my-collection&#x60;.

/**
* Track an analytics event when a user interacts with an object returned by a [QueryCollection](/docs/api/#operation/QueryCollection) request. An analytics event can be tracked for the following objects: - Results - Promotion banners - Redirects Note: You must pass an `Account-Id` header.
* @summary Track event
* @param accountId The account that owns the collection, e.g. &#x60;1618535966441231024&#x60;.
* @param collectionId The collection to track the event against, e.g. &#x60;my-collection&#x60;.
* @param event The details of the event to track.
*/
async trackEvent(accountId, collectionId, event, options = { headers: {} }) {
const localVarPath = this.basePath +
"/v4/collections/{collection_id}:trackEvent".replace("{" + "collection_id" + "}", encodeURIComponent(String(collectionId)));
let localVarQueryParameters = {};
let localVarHeaderParams = Object.assign({}, this._defaultHeaders);
const produces = ["application/json"];
// give precedence to 'application/json'
if (produces.indexOf("application/json") >= 0) {
localVarHeaderParams.Accept = "application/json";
}
else {
localVarHeaderParams.Accept = produces.join(",");
}
let localVarFormParams = {};
// verify required parameter 'accountId' is not null or undefined
if (accountId === null || accountId === undefined) {
throw new Error("Required parameter accountId was null or undefined when calling trackEvent.");
}
// verify required parameter 'collectionId' is not null or undefined
if (collectionId === null || collectionId === undefined) {
throw new Error("Required parameter collectionId was null or undefined when calling trackEvent.");
}
// verify required parameter 'event' is not null or undefined
if (event === null || event === undefined) {
throw new Error("Required parameter event was null or undefined when calling trackEvent.");
}
localVarHeaderParams["Account-Id"] = models_1.ObjectSerializer.serialize(accountId, "string");
Object.assign(localVarHeaderParams, options.headers);
let localVarUseFormData = false;
let localVarRequestOptions = {
method: "POST",
qs: localVarQueryParameters,
headers: localVarHeaderParams,
uri: localVarPath,
useQuerystring: this._useQuerystring,
json: true,
body: models_1.ObjectSerializer.serialize(event, "Event"),
};
let authenticationPromise = Promise.resolve();
if (this.authentications.BasicAuth.username &&
this.authentications.BasicAuth.password) {
authenticationPromise = authenticationPromise.then(() => this.authentications.BasicAuth.applyToRequest(localVarRequestOptions));
}
authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
let interceptorPromise = authenticationPromise;
for (const interceptor of this.interceptors) {
interceptorPromise = interceptorPromise.then(() => interceptor(localVarRequestOptions));
}
return interceptorPromise.then(() => {
if (Object.keys(localVarFormParams).length) {
if (localVarUseFormData) {
localVarRequestOptions.formData = localVarFormParams;
}
else {
localVarRequestOptions.form = localVarFormParams;
}
}
return new Promise((resolve, reject) => {
request_1.default(localVarRequestOptions, (error, response, body) => {
if (error) {
reject(error);
}
else {
if (response.statusCode &&
response.statusCode >= 200 &&
response.statusCode <= 299) {
body = models_1.ObjectSerializer.deserialize(body, "object");
resolve({ response: response, body: body });
}
else {
reject(new apis_1.HttpError(response, body, response.statusCode));
}
}
});
});
});
}
/**
* Update the details of a collection.

@@ -545,0 +707,0 @@ * @summary Update collection

8

build/src/generated/api/pipelinesApi.d.ts

@@ -94,3 +94,3 @@ /**

* @param name The name of the pipeline to get the default version of, e.g. &#x60;my-pipeline&#x60;.
* @param view The amount of information to include in the retrieved pipeline. - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;BASIC&#x60; view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/api#operation/ListPipelines) and [GetPipeline](/api#operation/GetPipeline)). - FULL: Include the information from &#x60;BASIC&#x60;, plus full step configuration.
* @param view The amount of information to include in the retrieved pipeline. - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;BASIC&#x60; view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/docs/api#operation/ListPipelines) and [GetPipeline](/docs/api#operation/GetPipeline)). - FULL: Include the information from &#x60;BASIC&#x60;, plus full step configuration.
*/

@@ -112,3 +112,3 @@ getDefaultVersion(collectionId: string, type: "TYPE_UNSPECIFIED" | "RECORD" | "QUERY", name: string, view?: "VIEW_UNSPECIFIED" | "BASIC" | "FULL", options?: {

* @param version The version of the pipeline to retrieve, e.g. &#x60;42&#x60;.
* @param view The amount of information to include in the retrieved pipeline. - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;BASIC&#x60; view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/api#operation/ListPipelines) and [GetPipeline](/api#operation/GetPipeline)). - FULL: Include the information from &#x60;BASIC&#x60;, plus full step configuration.
* @param view The amount of information to include in the retrieved pipeline. - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;BASIC&#x60; view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/docs/api#operation/ListPipelines) and [GetPipeline](/docs/api#operation/GetPipeline)). - FULL: Include the information from &#x60;BASIC&#x60;, plus full step configuration.
*/

@@ -128,4 +128,4 @@ getPipeline(collectionId: string, type: "TYPE_UNSPECIFIED" | "RECORD" | "QUERY", name: string, version: string, view?: "VIEW_UNSPECIFIED" | "BASIC" | "FULL", options?: {

* @param pageSize The maximum number of pipelines to return. The service may return fewer than this value. If unspecified, at most 50 pipelines are returned. The maximum value is 1000; values above 1000 are coerced to 1000.
* @param pageToken A page token, received from a previous [ListPipelines](/api#operation/ListPipelines) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListPipelines](/api#operation/ListPipelines) must match the call that provided the page token.
* @param view The amount of information to include in each retrieved pipeline. - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;BASIC&#x60; view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/api#operation/ListPipelines) and [GetPipeline](/api#operation/GetPipeline)). - FULL: Include the information from &#x60;BASIC&#x60;, plus full step configuration.
* @param pageToken A page token, received from a previous [ListPipelines](/docs/api#operation/ListPipelines) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListPipelines](/docs/api#operation/ListPipelines) must match the call that provided the page token.
* @param view The amount of information to include in each retrieved pipeline. - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;BASIC&#x60; view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/docs/api#operation/ListPipelines) and [GetPipeline](/docs/api#operation/GetPipeline)). - FULL: Include the information from &#x60;BASIC&#x60;, plus full step configuration.
*/

@@ -132,0 +132,0 @@ listPipelines(collectionId: string, pageSize?: number, pageToken?: string, view?: "VIEW_UNSPECIFIED" | "BASIC" | "FULL", options?: {

@@ -325,3 +325,3 @@ "use strict";

* @param name The name of the pipeline to get the default version of, e.g. &#x60;my-pipeline&#x60;.
* @param view The amount of information to include in the retrieved pipeline. - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;BASIC&#x60; view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/api#operation/ListPipelines) and [GetPipeline](/api#operation/GetPipeline)). - FULL: Include the information from &#x60;BASIC&#x60;, plus full step configuration.
* @param view The amount of information to include in the retrieved pipeline. - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;BASIC&#x60; view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/docs/api#operation/ListPipelines) and [GetPipeline](/docs/api#operation/GetPipeline)). - FULL: Include the information from &#x60;BASIC&#x60;, plus full step configuration.
*/

@@ -416,3 +416,3 @@ async getDefaultVersion(collectionId, type, name, view, options = { headers: {} }) {

* @param version The version of the pipeline to retrieve, e.g. &#x60;42&#x60;.
* @param view The amount of information to include in the retrieved pipeline. - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;BASIC&#x60; view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/api#operation/ListPipelines) and [GetPipeline](/api#operation/GetPipeline)). - FULL: Include the information from &#x60;BASIC&#x60;, plus full step configuration.
* @param view The amount of information to include in the retrieved pipeline. - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;BASIC&#x60; view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/docs/api#operation/ListPipelines) and [GetPipeline](/docs/api#operation/GetPipeline)). - FULL: Include the information from &#x60;BASIC&#x60;, plus full step configuration.
*/

@@ -510,4 +510,4 @@ async getPipeline(collectionId, type, name, version, view, options = { headers: {} }) {

* @param pageSize The maximum number of pipelines to return. The service may return fewer than this value. If unspecified, at most 50 pipelines are returned. The maximum value is 1000; values above 1000 are coerced to 1000.
* @param pageToken A page token, received from a previous [ListPipelines](/api#operation/ListPipelines) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListPipelines](/api#operation/ListPipelines) must match the call that provided the page token.
* @param view The amount of information to include in each retrieved pipeline. - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;BASIC&#x60; view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/api#operation/ListPipelines) and [GetPipeline](/api#operation/GetPipeline)). - FULL: Include the information from &#x60;BASIC&#x60;, plus full step configuration.
* @param pageToken A page token, received from a previous [ListPipelines](/docs/api#operation/ListPipelines) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListPipelines](/docs/api#operation/ListPipelines) must match the call that provided the page token.
* @param view The amount of information to include in each retrieved pipeline. - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;BASIC&#x60; view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/docs/api#operation/ListPipelines) and [GetPipeline](/docs/api#operation/GetPipeline)). - FULL: Include the information from &#x60;BASIC&#x60;, plus full step configuration.
*/

@@ -514,0 +514,0 @@ async listPipelines(collectionId, pageSize, pageToken, view, options = { headers: {} }) {

@@ -88,5 +88,6 @@ /**

* @param pageSize The maximum number of promotions to return. The service may return fewer than this value. If unspecified, at most 50 promotions are returned. The maximum value is 1000; values above 1000 are coerced to 1000.
* @param pageToken A page token, received from a previous [ListPromotions](/api#operation/ListPromotions) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListPromotions](/api#operation/ListPromotions) must match the call that provided the page token.
* @param pageToken A page token, received from a previous [ListPromotions](/docs/api#operation/ListPromotions) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListPromotions](/docs/api#operation/ListPromotions) must match the call that provided the page token.
* @param view The amount of information to include in each retrieved promotion. - PROMOTION_VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;FULL&#x60; view. - BASIC: Include basic information including name, start time and end time, but not detailed information about the promotion effects. - FULL: Returns all information about a promotion. This is the default value.
*/
listPromotions(collectionId: string, pageSize?: number, pageToken?: string, options?: {
listPromotions(collectionId: string, pageSize?: number, pageToken?: string, view?: "PROMOTION_VIEW_UNSPECIFIED" | "BASIC" | "FULL", options?: {
headers: {

@@ -93,0 +94,0 @@ [name: string]: string;

@@ -323,5 +323,6 @@ "use strict";

* @param pageSize The maximum number of promotions to return. The service may return fewer than this value. If unspecified, at most 50 promotions are returned. The maximum value is 1000; values above 1000 are coerced to 1000.
* @param pageToken A page token, received from a previous [ListPromotions](/api#operation/ListPromotions) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListPromotions](/api#operation/ListPromotions) must match the call that provided the page token.
* @param pageToken A page token, received from a previous [ListPromotions](/docs/api#operation/ListPromotions) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListPromotions](/docs/api#operation/ListPromotions) must match the call that provided the page token.
* @param view The amount of information to include in each retrieved promotion. - PROMOTION_VIEW_UNSPECIFIED: The default / unset value. The API defaults to the &#x60;FULL&#x60; view. - BASIC: Include basic information including name, start time and end time, but not detailed information about the promotion effects. - FULL: Returns all information about a promotion. This is the default value.
*/
async listPromotions(collectionId, pageSize, pageToken, options = { headers: {} }) {
async listPromotions(collectionId, pageSize, pageToken, view, options = { headers: {} }) {
const localVarPath = this.basePath +

@@ -350,2 +351,5 @@ "/v4/collections/{collection_id}/promotions".replace("{" + "collection_id" + "}", encodeURIComponent(String(collectionId)));

}
if (view !== undefined) {
localVarQueryParameters["view"] = models_1.ObjectSerializer.serialize(view, "'PROMOTION_VIEW_UNSPECIFIED' | 'BASIC' | 'FULL'");
}
Object.assign(localVarHeaderParams, options.headers);

@@ -352,0 +356,0 @@ let localVarUseFormData = false;

@@ -49,3 +49,3 @@ /**

/**
* The batch version of the [UpdateRecord](/api#operation/UpdateRecord) call.
* The batch version of the [UpdateRecord](/docs/api#operation/UpdateRecord) call.
* @summary Batch update records

@@ -64,3 +64,3 @@ * @param collectionId The collection that contains the records to update, e.g. &#x60;my-collection&#x60;.

/**
* The batch version of the [UpsertRecord](/api#operation/UpsertRecord) call.
* The batch version of the [UpsertRecord](/docs/api#operation/UpsertRecord) call.
* @summary Batch upsert records

@@ -107,3 +107,3 @@ * @param collectionId The collection to upsert the records in, e.g. &#x60;my-collection&#x60;.

/**
* Add or update specific fields within a record with the given values. The updated record is returned in the response. To replace all fields in a record, you should use the [UpsertRecord](/api#operation/UpsertRecord) call. Note that the update record call cannot be used to add or update indexed or unique fields. For this case use the [UpsertRecord](/api#operation/UpsertRecord) call.
* Add or update specific fields within a record with the given values. The updated record is returned in the response. To replace all fields in a record, you should use the [UpsertRecord](/docs/api#operation/UpsertRecord) call. Note that the update record call cannot be used to add or update indexed or unique fields. For this case use the [UpsertRecord](/docs/api#operation/UpsertRecord) call.
* @summary Update record

@@ -110,0 +110,0 @@ * @param collectionId The collection that contains the record to update, e.g. &#x60;my-collection&#x60;.

@@ -83,3 +83,3 @@ "use strict";

/**
* The batch version of the [UpdateRecord](/api#operation/UpdateRecord) call.
* The batch version of the [UpdateRecord](/docs/api#operation/UpdateRecord) call.
* @summary Batch update records

@@ -163,3 +163,3 @@ * @param collectionId The collection that contains the records to update, e.g. &#x60;my-collection&#x60;.

/**
* The batch version of the [UpsertRecord](/api#operation/UpsertRecord) call.
* The batch version of the [UpsertRecord](/docs/api#operation/UpsertRecord) call.
* @summary Batch upsert records

@@ -399,3 +399,3 @@ * @param collectionId The collection to upsert the records in, e.g. &#x60;my-collection&#x60;.

/**
* Add or update specific fields within a record with the given values. The updated record is returned in the response. To replace all fields in a record, you should use the [UpsertRecord](/api#operation/UpsertRecord) call. Note that the update record call cannot be used to add or update indexed or unique fields. For this case use the [UpsertRecord](/api#operation/UpsertRecord) call.
* Add or update specific fields within a record with the given values. The updated record is returned in the response. To replace all fields in a record, you should use the [UpsertRecord](/docs/api#operation/UpsertRecord) call. Note that the update record call cannot be used to add or update indexed or unique fields. For this case use the [UpsertRecord](/docs/api#operation/UpsertRecord) call.
* @summary Update record

@@ -402,0 +402,0 @@ * @param collectionId The collection that contains the record to update, e.g. &#x60;my-collection&#x60;.

@@ -88,3 +88,3 @@ /**

* @param pageSize The maximum number of redirects to return. The service may return fewer than this value. If unspecified, at most 50 redirects are returned. The maximum value is 1000; values above 1000 are coerced to 1000.
* @param pageToken A page token, received from a previous [ListRedirects](/api#operation/ListRedirects) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListRedirects](/api#operation/ListRedirects) must match the call that provided the page token.
* @param pageToken A page token, received from a previous [ListRedirects](/docs/api#operation/ListRedirects) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListRedirects](/docs/api#operation/ListRedirects) must match the call that provided the page token.
*/

@@ -91,0 +91,0 @@ listRedirects(collectionId: string, pageSize?: number, pageToken?: string, options?: {

@@ -323,3 +323,3 @@ "use strict";

* @param pageSize The maximum number of redirects to return. The service may return fewer than this value. If unspecified, at most 50 redirects are returned. The maximum value is 1000; values above 1000 are coerced to 1000.
* @param pageToken A page token, received from a previous [ListRedirects](/api#operation/ListRedirects) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListRedirects](/api#operation/ListRedirects) must match the call that provided the page token.
* @param pageToken A page token, received from a previous [ListRedirects](/docs/api#operation/ListRedirects) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListRedirects](/docs/api#operation/ListRedirects) must match the call that provided the page token.
*/

@@ -326,0 +326,0 @@ async listRedirects(collectionId, pageSize, pageToken, options = { headers: {} }) {

@@ -44,3 +44,3 @@ /**

/**
* The batch version of the [CreateSchemaField](/api#operation/CreateSchemaField) call.
* The batch version of the [CreateSchemaField](/docs/api#operation/CreateSchemaField) call.
* @summary Batch create schema fields

@@ -77,3 +77,3 @@ * @param collectionId The collection to create the schema fields in, e.g. &#x60;my-collection&#x60;.

* @param pageSize The maximum number of schema fields to return. The service may return fewer than this value. If unspecified, at most 50 schema fields are returned. The maximum value is 1000; values above 1000 are coerced to 1000.
* @param pageToken A page token, received from a previous [ListSchemaFields](/api#operation/ListSchemaFields) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListSchemaFields](/api#operation/ListSchemaFields) must match the call that provided the page token.
* @param pageToken A page token, received from a previous [ListSchemaFields](/docs/api#operation/ListSchemaFields) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListSchemaFields](/docs/api#operation/ListSchemaFields) must match the call that provided the page token.
*/

@@ -80,0 +80,0 @@ listSchemaFields(collectionId: string, pageSize?: number, pageToken?: string, options?: {

@@ -83,3 +83,3 @@ "use strict";

/**
* The batch version of the [CreateSchemaField](/api#operation/CreateSchemaField) call.
* The batch version of the [CreateSchemaField](/docs/api#operation/CreateSchemaField) call.
* @summary Batch create schema fields

@@ -245,3 +245,3 @@ * @param collectionId The collection to create the schema fields in, e.g. &#x60;my-collection&#x60;.

* @param pageSize The maximum number of schema fields to return. The service may return fewer than this value. If unspecified, at most 50 schema fields are returned. The maximum value is 1000; values above 1000 are coerced to 1000.
* @param pageToken A page token, received from a previous [ListSchemaFields](/api#operation/ListSchemaFields) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListSchemaFields](/api#operation/ListSchemaFields) must match the call that provided the page token.
* @param pageToken A page token, received from a previous [ListSchemaFields](/docs/api#operation/ListSchemaFields) call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to [ListSchemaFields](/docs/api#operation/ListSchemaFields) must match the call that provided the page token.
*/

@@ -248,0 +248,0 @@ async listSchemaFields(collectionId, pageSize, pageToken, options = { headers: {} }) {

@@ -12,2 +12,3 @@ /**

*/
import { TextPosition } from "./textPosition";
/**

@@ -18,4 +19,8 @@ * A synthetic search result that renders as an image. It takes a user to a pre-determined location when clicked.

/**
* the height the banner occupies in grid cells.
* The description of the banner, displayed in sub-head font.
*/
"description"?: string;
/**
* The height the banner occupies in grid cells.
*/
"height"?: number;

@@ -39,2 +44,11 @@ /**

/**
* The color of the text as a hex code with a # prefix, e.g. #FFCC00 or #FC0.
*/
"textColor"?: string;
"textPosition"?: TextPosition;
/**
* The title of the banner, displayed in header font.
*/
"title"?: string;
/**
* The width the banner occupies in grid cells.

@@ -41,0 +55,0 @@ */

@@ -27,2 +27,7 @@ "use strict";

{
name: "description",
baseName: "description",
type: "string",
},
{
name: "height",

@@ -53,2 +58,17 @@ baseName: "height",

{
name: "textColor",
baseName: "text_color",
type: "string",
},
{
name: "textPosition",
baseName: "text_position",
type: "TextPosition",
},
{
name: "title",
baseName: "title",
type: "string",
},
{
name: "width",

@@ -55,0 +75,0 @@ baseName: "width",

@@ -18,3 +18,3 @@ /**

/**
* The list of authorized query domains for the collection. Client-side / browser requests to the [QueryCollection](/api#operation/QueryCollection) call can be made by any authorized query domain or any of its subdomains. This allows your interface to make search requests without having to provide an API key in the client-side request.
* The list of authorized query domains for the collection. Client-side / browser requests to the [QueryCollection](/docs/api#operation/QueryCollection) call can be made by any authorized query domain or any of its subdomains. This allows your interface to make search requests without having to provide an API key in the client-side request.
*/

@@ -21,0 +21,0 @@ "authorizedQueryDomains"?: Array<string>;

@@ -13,3 +13,3 @@ /**

/**
* - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the `BASIC` view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/api#operation/ListPipelines) and [GetPipeline](/api#operation/GetPipeline)). - FULL: Include the information from `BASIC`, plus full step configuration.
* - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the `BASIC` view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/docs/api#operation/ListPipelines) and [GetPipeline](/docs/api#operation/GetPipeline)). - FULL: Include the information from `BASIC`, plus full step configuration.
*/

@@ -16,0 +16,0 @@ export declare enum GetDefaultVersionRequestView {

@@ -16,3 +16,3 @@ "use strict";

/**
* - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the `BASIC` view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/api#operation/ListPipelines) and [GetPipeline](/api#operation/GetPipeline)). - FULL: Include the information from `BASIC`, plus full step configuration.
* - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the `BASIC` view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/docs/api#operation/ListPipelines) and [GetPipeline](/docs/api#operation/GetPipeline)). - FULL: Include the information from `BASIC`, plus full step configuration.
*/

@@ -19,0 +19,0 @@ var GetDefaultVersionRequestView;

@@ -13,3 +13,3 @@ /**

/**
* - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the `BASIC` view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/api#operation/ListPipelines) and [GetPipeline](/api#operation/GetPipeline)). - FULL: Include the information from `BASIC`, plus full step configuration.
* - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the `BASIC` view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/docs/api#operation/ListPipelines) and [GetPipeline](/docs/api#operation/GetPipeline)). - FULL: Include the information from `BASIC`, plus full step configuration.
*/

@@ -16,0 +16,0 @@ export declare enum GetPipelineRequestView {

@@ -16,3 +16,3 @@ "use strict";

/**
* - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the `BASIC` view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/api#operation/ListPipelines) and [GetPipeline](/api#operation/GetPipeline)). - FULL: Include the information from `BASIC`, plus full step configuration.
* - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the `BASIC` view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/docs/api#operation/ListPipelines) and [GetPipeline](/docs/api#operation/GetPipeline)). - FULL: Include the information from `BASIC`, plus full step configuration.
*/

@@ -19,0 +19,0 @@ var GetPipelineRequestView;

@@ -13,3 +13,3 @@ /**

/**
* - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the `BASIC` view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/api#operation/ListPipelines) and [GetPipeline](/api#operation/GetPipeline)). - FULL: Include the information from `BASIC`, plus full step configuration.
* - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the `BASIC` view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/docs/api#operation/ListPipelines) and [GetPipeline](/docs/api#operation/GetPipeline)). - FULL: Include the information from `BASIC`, plus full step configuration.
*/

@@ -16,0 +16,0 @@ export declare enum ListPipelinesRequestView {

@@ -16,3 +16,3 @@ "use strict";

/**
* - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the `BASIC` view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/api#operation/ListPipelines) and [GetPipeline](/api#operation/GetPipeline)). - FULL: Include the information from `BASIC`, plus full step configuration.
* - VIEW_UNSPECIFIED: The default / unset value. The API defaults to the `BASIC` view. - BASIC: Include basic information including type, name, version and description but not the full step configuration. This is the default value (for both [ListPipelines](/docs/api#operation/ListPipelines) and [GetPipeline](/docs/api#operation/GetPipeline)). - FULL: Include the information from `BASIC`, plus full step configuration.
*/

@@ -19,0 +19,0 @@ var ListPipelinesRequestView;

@@ -20,2 +20,6 @@ /// <reference types="node" />

export * from "./deleteRecordRequest";
export * from "./event";
export * from "./experimentRequest";
export * from "./experimentRequestPipeline";
export * from "./experimentResponse";
export * from "./generatePipelinesRequest";

@@ -30,2 +34,3 @@ export * from "./generatePipelinesResponse";

export * from "./listPipelinesResponse";
export * from "./listPromotionsRequestPromotionView";
export * from "./listPromotionsResponse";

@@ -46,2 +51,3 @@ export * from "./listRedirectsResponse";

export * from "./promotionPin";
export * from "./promotionPinMode";
export * from "./promotionRangeBoost";

@@ -79,2 +85,3 @@ export * from "./protobufAny";

export * from "./status";
export * from "./textPosition";
export * from "./updateRecordRequest";

@@ -81,0 +88,0 @@ export * from "./upsertRecordRequest";

@@ -31,2 +31,6 @@ "use strict";

__exportStar(require("./deleteRecordRequest"), exports);
__exportStar(require("./event"), exports);
__exportStar(require("./experimentRequest"), exports);
__exportStar(require("./experimentRequestPipeline"), exports);
__exportStar(require("./experimentResponse"), exports);
__exportStar(require("./generatePipelinesRequest"), exports);

@@ -41,2 +45,3 @@ __exportStar(require("./generatePipelinesResponse"), exports);

__exportStar(require("./listPipelinesResponse"), exports);
__exportStar(require("./listPromotionsRequestPromotionView"), exports);
__exportStar(require("./listPromotionsResponse"), exports);

@@ -57,2 +62,3 @@ __exportStar(require("./listRedirectsResponse"), exports);

__exportStar(require("./promotionPin"), exports);
__exportStar(require("./promotionPinMode"), exports);
__exportStar(require("./promotionRangeBoost"), exports);

@@ -90,2 +96,3 @@ __exportStar(require("./protobufAny"), exports);

__exportStar(require("./status"), exports);
__exportStar(require("./textPosition"), exports);
__exportStar(require("./updateRecordRequest"), exports);

@@ -112,2 +119,6 @@ __exportStar(require("./upsertRecordRequest"), exports);

const deleteRecordRequest_1 = require("./deleteRecordRequest");
const event_1 = require("./event");
const experimentRequest_1 = require("./experimentRequest");
const experimentRequestPipeline_1 = require("./experimentRequestPipeline");
const experimentResponse_1 = require("./experimentResponse");
const generatePipelinesRequest_1 = require("./generatePipelinesRequest");

@@ -122,2 +133,3 @@ const generatePipelinesResponse_1 = require("./generatePipelinesResponse");

const listPipelinesResponse_1 = require("./listPipelinesResponse");
const listPromotionsRequestPromotionView_1 = require("./listPromotionsRequestPromotionView");
const listPromotionsResponse_1 = require("./listPromotionsResponse");

@@ -138,2 +150,3 @@ const listRedirectsResponse_1 = require("./listRedirectsResponse");

const promotionPin_1 = require("./promotionPin");
const promotionPinMode_1 = require("./promotionPinMode");
const promotionRangeBoost_1 = require("./promotionRangeBoost");

@@ -171,2 +184,3 @@ const protobufAny_1 = require("./protobufAny");

const status_1 = require("./status");
const textPosition_1 = require("./textPosition");
const updateRecordRequest_1 = require("./updateRecordRequest");

@@ -191,3 +205,5 @@ const upsertRecordRequest_1 = require("./upsertRecordRequest");

ListPipelinesRequestView: listPipelinesRequestView_1.ListPipelinesRequestView,
ListPromotionsRequestPromotionView: listPromotionsRequestPromotionView_1.ListPromotionsRequestPromotionView,
PipelineType: pipelineType_1.PipelineType,
PromotionPinMode: promotionPinMode_1.PromotionPinMode,
ProtobufNullValue: protobufNullValue_1.ProtobufNullValue,

@@ -197,2 +213,3 @@ QueryCollectionRequestTrackingType: queryCollectionRequestTrackingType_1.QueryCollectionRequestTrackingType,

SchemaFieldType: schemaFieldType_1.SchemaFieldType,
TextPosition: textPosition_1.TextPosition,
};

@@ -217,2 +234,6 @@ let typeMap = {

DeleteRecordRequest: deleteRecordRequest_1.DeleteRecordRequest,
Event: event_1.Event,
ExperimentRequest: experimentRequest_1.ExperimentRequest,
ExperimentRequestPipeline: experimentRequestPipeline_1.ExperimentRequestPipeline,
ExperimentResponse: experimentResponse_1.ExperimentResponse,
GeneratePipelinesRequest: generatePipelinesRequest_1.GeneratePipelinesRequest,

@@ -219,0 +240,0 @@ GeneratePipelinesResponse: generatePipelinesResponse_1.GeneratePipelinesResponse,

@@ -12,5 +12,7 @@ /**

*/
import { PromotionPinMode } from "./promotionPinMode";
import { RecordKey } from "./recordKey";
export declare class PromotionPin {
"key"?: RecordKey;
"mode"?: PromotionPinMode;
/**

@@ -17,0 +19,0 @@ * Position the record should occupy in search results. The top position is position 1. Doesn\'t need to be contiguous with other pins, i.e. there can be gaps in the pinned set that are filled with organic results. In the case where there are insufficient search results pinned items are collapsed.

@@ -29,2 +29,7 @@ "use strict";

{
name: "mode",
baseName: "mode",
type: "PromotionPinMode",
},
{
name: "position",

@@ -31,0 +36,0 @@ baseName: "position",

@@ -13,3 +13,3 @@ /**

/**
* - TYPE_UNSPECIFIED: The default / unset value. The API defaults to `NONE` tracking. - NONE: No tracking. - CLICK: Click tracking. A click token is be generated for each result. Results which do not receive clicks fall down the rankings, and similarly low-ranked records which receive clicks are moved up the rankings. - POS_NEG: Pos/neg tracking. Pos/neg tokens are generated for each result. Each record in the result set can be marked with pos/neg value for the search. This is then fed back into the ranking algorithm to improve future results. Unlike `CLICK`, if no tokens are reported for records then no action is taken.
* - TYPE_UNSPECIFIED: The default / unset value. The API defaults to `NONE` tracking. - NONE: No tracking. - CLICK: Click tracking. A click token is be generated for each result. Results which do not receive clicks fall down the rankings, and similarly low-ranked records which receive clicks are moved up the rankings. - POS_NEG: Pos/neg tracking. Pos/neg tokens are generated for each result. Each record in the result set can be marked with pos/neg value for the search. This is then fed back into the ranking algorithm to improve future results. Unlike `CLICK`, if no tokens are reported for records then no action is taken. - EVENT: Event tracking. A query identifier is returned in the [QueryResponse][sajari.v4.QueryResponse] that can be used to link a user interaction to a specific query.
*/

@@ -20,3 +20,4 @@ export declare enum QueryCollectionRequestTrackingType {

Click,
PosNeg
PosNeg,
Event
}

@@ -16,3 +16,3 @@ "use strict";

/**
* - TYPE_UNSPECIFIED: The default / unset value. The API defaults to `NONE` tracking. - NONE: No tracking. - CLICK: Click tracking. A click token is be generated for each result. Results which do not receive clicks fall down the rankings, and similarly low-ranked records which receive clicks are moved up the rankings. - POS_NEG: Pos/neg tracking. Pos/neg tokens are generated for each result. Each record in the result set can be marked with pos/neg value for the search. This is then fed back into the ranking algorithm to improve future results. Unlike `CLICK`, if no tokens are reported for records then no action is taken.
* - TYPE_UNSPECIFIED: The default / unset value. The API defaults to `NONE` tracking. - NONE: No tracking. - CLICK: Click tracking. A click token is be generated for each result. Results which do not receive clicks fall down the rankings, and similarly low-ranked records which receive clicks are moved up the rankings. - POS_NEG: Pos/neg tracking. Pos/neg tokens are generated for each result. Each record in the result set can be marked with pos/neg value for the search. This is then fed back into the ranking algorithm to improve future results. Unlike `CLICK`, if no tokens are reported for records then no action is taken. - EVENT: Event tracking. A query identifier is returned in the [QueryResponse][sajari.v4.QueryResponse] that can be used to link a user interaction to a specific query.
*/

@@ -25,3 +25,4 @@ var QueryCollectionRequestTrackingType;

QueryCollectionRequestTrackingType[QueryCollectionRequestTrackingType["PosNeg"] = "POS_NEG"] = "PosNeg";
QueryCollectionRequestTrackingType[QueryCollectionRequestTrackingType["Event"] = "EVENT"] = "Event";
})(QueryCollectionRequestTrackingType = exports.QueryCollectionRequestTrackingType || (exports.QueryCollectionRequestTrackingType = {}));
//# sourceMappingURL=queryCollectionRequestTrackingType.js.map

@@ -13,2 +13,3 @@ /**

import { ActivePromotion } from "./activePromotion";
import { Banner } from "./banner";
import { QueryAggregateResult } from "./queryAggregateResult";

@@ -36,2 +37,6 @@ import { QueryCollectionResponsePipeline } from "./queryCollectionResponsePipeline";

/**
* Banners associated with this query.
*/
"banners"?: Array<Banner>;
/**
* The weight applied to the features in the query, used for analyzing the index, neural and feature components for results. For each result: ``` score = max(index_score, neural_score) * (1 - feature_score_weight) + feature_score * feature_score_weight ```

@@ -46,2 +51,6 @@ */

/**
* The query identifier. This uniqely identifies the specific query it was returned on. This is used to link user interactions with a query.
*/
"queryId"?: string;
/**
* A mapping of redirects triggered for all possible variations of the query.

@@ -48,0 +57,0 @@ */

@@ -39,2 +39,7 @@ "use strict";

{
name: "banners",
baseName: "banners",
type: "Array<Banner>",
},
{
name: "featureScoreWeight",

@@ -55,2 +60,7 @@ baseName: "feature_score_weight",

{
name: "queryId",
baseName: "query_id",
type: "string",
},
{
name: "redirects",

@@ -57,0 +67,0 @@ baseName: "redirects",

@@ -12,4 +12,6 @@ /**

*/
import { Banner } from "./banner";
import { QueryResultToken } from "./queryResultToken";
export declare class QueryResult {
"banner"?: Banner;
/**

@@ -32,2 +34,6 @@ * The feature score of the result. This is a value between 0 and 1 representing the business-specific ranking of the result as determined by the ranking adjustments. See [Ranking adjustments](https://docs.search.io/documentation/fundamentals/search-settings/ranking-adjustments) for more information.

/**
* The relevance score of the result. This is the best of `index_score` and `neural_score` with any index boosts applied on top.
*/
"relevanceScore"?: number;
/**
* The overall relevance of the result. This is a value between 0 and 1 that combines the index, neural and feature scores. The higher the score the more relevant the result is.

@@ -34,0 +40,0 @@ */

@@ -24,2 +24,7 @@ "use strict";

{
name: "banner",
baseName: "banner",
type: "Banner",
},
{
name: "featureScore",

@@ -45,2 +50,7 @@ baseName: "feature_score",

{
name: "relevanceScore",
baseName: "relevance_score",
type: "number",
},
{
name: "score",

@@ -47,0 +57,0 @@ baseName: "score",

@@ -1,1 +0,1 @@

export declare const version = "4.4.1";
export declare const version = "4.5.1";

@@ -5,3 +5,3 @@ "use strict";

exports.version = void 0;
exports.version = "4.4.1";
exports.version = "4.5.1";
//# sourceMappingURL=version.js.map
{
"name": "@sajari/sdk-node",
"version": "4.4.1",
"version": "4.5.1",
"repository": "git@github.com:github.com/sajari/sdk-node.git",

@@ -5,0 +5,0 @@ "author": "Search.io",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc