@coveo/platform-client
Version:
The main goal of this package is to provide an easy to configure and straightforward way of querying Coveo Cloud APIs using JavaScript.
20 lines • 1.07 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
const tslib_1 = require("tslib");
const APICore_js_1 = tslib_1.__importDefault(require("../../APICore.js"));
const Resource_js_1 = tslib_1.__importDefault(require("../Resource.js"));
class SearchAnalysis extends Resource_js_1.default {
static baseUrl = '/rest/search/v3/analysis';
/**
* Replay a query that was already done and get inspection details.
* @param id The SearchUID of the request to replay.
* @param from The inclusive date at which to start looking for the request. Example: 2019-08-24T14:15:22Z
* @param to The inclusive date at which to stop looking for the SearchUID. When omitted searches up until the most recent requests. Example:2019-08-24T14:15:22Z
* @returns
*/
replay(id, from, to) {
return this.api.post(`${SearchAnalysis.baseUrl}/inspect/replay?organizationId=${APICore_js_1.default.orgPlaceholder}`, { id, dateRange: { from, to } });
}
}
exports.default = SearchAnalysis;
//# sourceMappingURL=SearchAnalysis.js.map