algoliasearch 5.0.0-alpha.4 → 5.0.0-alpha.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/algoliasearch/builds/browser.d.ts +4 -4
- package/dist/algoliasearch/builds/node.d.ts +4 -4
- package/dist/algoliasearch/lite/src/liteClient.d.ts +1 -1
- package/dist/algoliasearch.cjs.js +17 -17
- package/dist/algoliasearch.esm.browser.js +17 -17
- package/dist/algoliasearch.esm.node.js +17 -17
- package/dist/algoliasearch.umd.js +2 -2
- package/dist/builds/browser.d.ts +4 -4
- package/dist/builds/node.d.ts +4 -4
- package/dist/client-abtesting/src/abtestingClient.d.ts +1 -1
- package/dist/client-analytics/src/analyticsClient.d.ts +1 -1
- package/dist/client-personalization/src/personalizationClient.d.ts +1 -1
- package/dist/client-search/model/clientMethodProps.d.ts +7 -9
- package/dist/client-search/model/clientMethodProps.d.ts.map +1 -1
- package/dist/client-search/src/searchClient.d.ts +8 -8
- package/dist/client-search/src/searchClient.d.ts.map +1 -1
- package/dist/lite/builds/browser.d.ts +4 -4
- package/dist/lite/builds/node.d.ts +4 -4
- package/dist/lite/lite/src/liteClient.d.ts +1 -1
- package/dist/lite/lite.cjs.js +1 -1
- package/dist/lite/lite.esm.browser.js +1 -1
- package/dist/lite/lite.esm.node.js +1 -1
- package/dist/lite/lite.umd.js +2 -2
- package/lite/src/liteClient.ts +1 -1
- package/package.json +8 -8
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/*! algoliasearch.umd.js | 5.0.0-alpha.
|
|
2
|
-
!function(e,r){"object"==typeof exports&&"undefined"!=typeof module?r(exports):"function"==typeof define&&define.amd?define(["exports"],r):r((e="undefined"!=typeof globalThis?globalThis:e||self).algoliasearch={})}(this,(function(e){"use strict";function r(e,r,t){return r in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}function t(e,r){if(null==e)return{};var t,a,n=function(e,r){if(null==e)return{};var t,a,n={},i=Object.keys(e);for(a=0;a<i.length;a++)t=i[a],r.indexOf(t)>=0||(n[t]=e[t]);return n}(e,r);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)t=i[a],r.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(n[t]=e[t])}return n}function a(e,r,t="WithinHeaders"){const a={"x-algolia-api-key":r,"x-algolia-application-id":e};return{headers:()=>"WithinHeaders"===t?a:{},queryParameters:()=>"WithinQueryParameters"===t?a:{}}}function n({func:e,validate:r,aggregator:t,error:a,timeout:n=(()=>0)}){const i=o=>new Promise(((s,c)=>{e(o).then((e=>(t&&t(e),r(e)?s(e):a&&a.validate(e)?c(new Error(a.message(e))):setTimeout((()=>{i(e).then(s).catch(c)}),n())))).catch((e=>{c(e)}))}));return i()}function i(e){let r;const t=`algolia-client-js-${e.key}`;function a(){return void 0===r&&(r=e.localStorage||window.localStorage),r}function n(){return JSON.parse(a().getItem(t)||"{}")}return{get:(e,r,t={miss:()=>Promise.resolve()})=>Promise.resolve().then((()=>{const t=JSON.stringify(e),a=n()[t];return Promise.all([a||r(),void 0!==a])})).then((([e,r])=>Promise.all([e,r||t.miss(e)]))).then((([e])=>e)),set:(e,r)=>Promise.resolve().then((()=>{const i=n();return i[JSON.stringify(e)]=r,a().setItem(t,JSON.stringify(i)),r})),delete:e=>Promise.resolve().then((()=>{const r=n();delete r[JSON.stringify(e)],a().setItem(t,JSON.stringify(r))})),clear:()=>Promise.resolve().then((()=>{a().removeItem(t)}))}}function o(e){const r=[...e.caches],t=r.shift();return void 0===t?{get:(e,r,t={miss:()=>Promise.resolve()})=>r().then((e=>Promise.all([e,t.miss(e)]))).then((([e])=>e)),set:(e,r)=>Promise.resolve(r),delete:e=>Promise.resolve(),clear:()=>Promise.resolve()}:{get:(e,a,n={miss:()=>Promise.resolve()})=>t.get(e,a,n).catch((()=>o({caches:r}).get(e,a,n))),set:(e,a)=>t.set(e,a).catch((()=>o({caches:r}).set(e,a))),delete:e=>t.delete(e).catch((()=>o({caches:r}).delete(e))),clear:()=>t.clear().catch((()=>o({caches:r}).clear()))}}function s(e={serializable:!0}){let r={};return{get(t,a,n={miss:()=>Promise.resolve()}){const i=JSON.stringify(t);if(i in r)return Promise.resolve(e.serializable?JSON.parse(r[i]):r[i]);const o=a();return o.then((e=>n.miss(e))).then((()=>o))},set:(t,a)=>(r[JSON.stringify(t)]=e.serializable?JSON.stringify(a):a,Promise.resolve(a)),delete:e=>(delete r[JSON.stringify(e)],Promise.resolve()),clear:()=>(r={},Promise.resolve())}}const c=12e4;function d(e,r="up"){const t=Date.now();return{...e,status:r,lastUpdate:t,isUp:function(){return"up"===r||Date.now()-t>c},isTimedOut:function(){return"timed out"===r&&Date.now()-t<=c}}}function u(e,r,t){return r in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}class l extends Error{constructor(e,r){super(e),u(this,"name","AlgoliaError"),r&&(this.name=r)}}class h extends l{constructor(e,r,t){super(e,t),u(this,"stackTrace",void 0),this.stackTrace=r}}class m extends h{constructor(e){super("Unreachable hosts - your application id may be incorrect. If the error persists, contact support@algolia.com.",e,"RetryError")}}class p extends h{constructor(e,r,t){super(e,t,"ApiError"),u(this,"status",void 0),this.status=r}}class g extends l{constructor(e,r){super(e,"DeserializationError"),u(this,"response",void 0),this.response=r}}function f(e,r,t){const a=function(e){const r=e=>"[object Object]"===Object.prototype.toString.call(e)||"[object Array]"===Object.prototype.toString.call(e);return Object.keys(e).map((t=>`${t}=${r(e[t])?JSON.stringify(e[t]):e[t]}`)).join("&")}(t);let n=`${e.protocol}://${e.url}/${"/"===r.charAt(0)?r.substr(1):r}`;return a.length&&(n+=`?${a}`),n}function w(e){const r=e.request.headers["x-algolia-api-key"]?{"x-algolia-api-key":"*****"}:{};return{...e,request:{...e.request,headers:{...e.request.headers,...r}}}}function v({hosts:e,hostsCache:r,baseHeaders:t,baseQueryParameters:a,algoliaAgent:n,timeouts:i,requester:o,requestsCache:s,responsesCache:c}){async function u(s,c,u=!0){const l=[],h=function(e,r){if("GET"===e.method||void 0===e.data&&void 0===r.data)return;const t=Array.isArray(e.data)?e.data:{...e.data,...r.data};return JSON.stringify(t)}(s,c),v=function(e,r,t){const a={Accept:"application/json",...e,...r,...t},n={};return Object.keys(a).forEach((e=>{const r=a[e];n[e.toLowerCase()]=r})),n}(t,s.headers,c.headers),y="GET"===s.method?{...s.data,...c.data}:{},P={"x-algolia-agent":n.value,...a,...s.queryParameters,...y};if(c&&c.queryParameters)for(const e of Object.keys(c.queryParameters))c.queryParameters[e]&&"[object Object]"!==Object.prototype.toString.call(c.queryParameters[e])?P[e]=c.queryParameters[e].toString():P[e]=c.queryParameters[e];let q=0;const b=async(e,t)=>{const a=e.pop();if(void 0===a)throw new m(function(e){return e.map((e=>w(e)))}(l));let n=c.timeout;void 0===n&&(n=u?i.read:i.write);const y={data:h,headers:v,method:s.method,url:f(a,s.path,P),connectTimeout:t(q,i.connect),responseTimeout:t(q,n)},E=r=>{const t={request:y,response:r,host:a,triesLeft:e.length};return l.push(t),t},S=await o.send(y);if(function({isTimedOut:e,status:r}){return e||function({isTimedOut:e,status:r}){return!e&&0==~~r}({isTimedOut:e,status:r})||2!=~~(r/100)&&4!=~~(r/100)}(S)){const n=E(S);return S.isTimedOut&&q++,console.log("Retryable failure",w(n)),await r.set(a,d(a,S.isTimedOut?"timed out":"down")),b(e,t)}if(function({status:e}){return 2==~~(e/100)}(S))return function(e){try{return JSON.parse(e.content)}catch(r){throw new g(r.message,e)}}(S);throw E(S),function({content:e,status:r},t){let a=e;try{a=JSON.parse(e).message}catch(e){}return new p(a,r,t)}(S,l)},E=e.filter((e=>"readWrite"===e.accept||(u?"read"===e.accept:"write"===e.accept))),S=await async function(e){const t=await Promise.all(e.map((e=>r.get(e,(()=>Promise.resolve(d(e))))))),a=t.filter((e=>e.isUp())),n=t.filter((e=>e.isTimedOut())),i=[...a,...n];return{hosts:i.length>0?i:e,getTimeout:(e,r)=>(0===n.length&&0===e?1:n.length+3+e)*r}}(E);return b([...S.hosts].reverse(),S.getTimeout)}return{hostsCache:r,requester:o,timeouts:i,algoliaAgent:n,baseHeaders:t,baseQueryParameters:a,hosts:e,request:function(e,r={}){const n=e.useReadTransporter||"GET"===e.method;if(!n)return u(e,r,n);const i=()=>u(e,r);if(!0!==(r.cacheable||e.cacheable))return i();const o={request:e,requestOptions:r,transporter:{queryParameters:a,headers:t}};return c.get(o,(()=>s.get(o,(()=>s.set(o,i()).then((e=>Promise.all([s.delete(o),e])),(e=>Promise.all([s.delete(o),Promise.reject(e)]))).then((([e,r])=>r))))),{miss:e=>c.set(o,e)})},requestsCache:s,responsesCache:c}}function y({algoliaAgents:e,client:r,version:t}){const a=function(e){const r={value:`Algolia for JavaScript (${e})`,add(e){const t=`; ${e.segment}${void 0!==e.version?` (${e.version})`:""}`;return-1===r.value.indexOf(t)&&(r.value=`${r.value}${t}`),r}};return r}(t).add({segment:r,version:t});return e.forEach((e=>a.add(e))),a}var P=["appId","apiKey","authMode","algoliaAgents","region"];function q(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);r&&(a=a.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,a)}return t}function b(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?q(Object(a),!0).forEach((function(t){r(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):q(Object(a)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(a,r))}))}return e}var E=["de","us"];function S(e){var r,n=e.appId,i=e.apiKey,o=e.authMode,s=e.algoliaAgents,c=e.region,d=t(e,P),u=a(n,i,o),l=v(b(b({hosts:(r=c,[{url:r?"analytics.{region}.algolia.com".replace("{region}",r):"analytics.algolia.com",accept:"readWrite",protocol:"https"}])},d),{},{algoliaAgent:y({algoliaAgents:s,client:"Abtesting",version:"5.0.0-alpha.4"}),baseHeaders:b(b({"content-type":"text/plain"},u.headers()),d.baseHeaders),baseQueryParameters:b(b({},u.queryParameters()),d.baseQueryParameters)}));return{transporter:l,appId:n,clearCache:function(){return Promise.all([l.requestsCache.clear(),l.responsesCache.clear()]).then((function(){}))},get _ua(){return l.algoliaAgent.value},addAlgoliaAgent:function(e,r){l.algoliaAgent.add({segment:e,version:r})},addABTests:function(e,r){if(!e)throw new Error("Parameter `addABTestsRequest` is required when calling `addABTests`.");if(!e.name)throw new Error("Parameter `addABTestsRequest.name` is required when calling `addABTests`.");if(!e.variant)throw new Error("Parameter `addABTestsRequest.variant` is required when calling `addABTests`.");if(!e.endAt)throw new Error("Parameter `addABTestsRequest.endAt` is required when calling `addABTests`.");var t={method:"POST",path:"/2/abtests",queryParameters:{},headers:{},data:e};return l.request(t,r)},del:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `del`.");var n={method:"DELETE",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return l.request(n,r)},deleteABTest:function(e,r){var t=e.id;if(!t)throw new Error("Parameter `id` is required when calling `deleteABTest`.");var a={method:"DELETE",path:"/2/abtests/{id}".replace("{id}",encodeURIComponent(t)),queryParameters:{},headers:{}};return l.request(a,r)},get:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `get`.");var n={method:"GET",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return l.request(n,r)},getABTest:function(e,r){var t=e.id;if(!t)throw new Error("Parameter `id` is required when calling `getABTest`.");var a={method:"GET",path:"/2/abtests/{id}".replace("{id}",encodeURIComponent(t)),queryParameters:{},headers:{}};return l.request(a,r)},listABTests:function(e,r){var t=e.offset,a=e.limit,n={};void 0!==t&&(n.offset=t.toString()),void 0!==a&&(n.limit=a.toString());var i={method:"GET",path:"/2/abtests",queryParameters:n,headers:{}};return l.request(i,r)},post:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `post`.");var i={method:"POST",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return l.request(i,r)},put:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `put`.");var i={method:"PUT",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return l.request(i,r)},stopABTest:function(e,r){var t=e.id;if(!t)throw new Error("Parameter `id` is required when calling `stopABTest`.");var a={method:"POST",path:"/2/abtests/{id}/stop".replace("{id}",encodeURIComponent(t)),queryParameters:{},headers:{}};return l.request(a,r)}}}var x=["appId","apiKey","authMode","algoliaAgents","region"];function T(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);r&&(a=a.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,a)}return t}function O(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?T(Object(a),!0).forEach((function(t){r(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):T(Object(a)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(a,r))}))}return e}var D=["de","us"];function I(e){var r,n=e.appId,i=e.apiKey,o=e.authMode,s=e.algoliaAgents,c=e.region,d=t(e,x),u=a(n,i,o),l=v(O(O({hosts:(r=c,[{url:r?"analytics.{region}.algolia.com".replace("{region}",r):"analytics.algolia.com",accept:"readWrite",protocol:"https"}])},d),{},{algoliaAgent:y({algoliaAgents:s,client:"Analytics",version:"5.0.0-alpha.4"}),baseHeaders:O(O({"content-type":"text/plain"},u.headers()),d.baseHeaders),baseQueryParameters:O(O({},u.queryParameters()),d.baseQueryParameters)}));return{transporter:l,appId:n,clearCache:function(){return Promise.all([l.requestsCache.clear(),l.responsesCache.clear()]).then((function(){}))},get _ua(){return l.algoliaAgent.value},addAlgoliaAgent:function(e,r){l.algoliaAgent.add({segment:e,version:r})},del:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `del`.");var n={method:"DELETE",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return l.request(n,r)},get:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `get`.");var n={method:"GET",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return l.request(n,r)},getAverageClickPosition:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getAverageClickPosition`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/clicks/averageClickPosition",queryParameters:o,headers:{}};return l.request(s,r)},getClickPositions:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getClickPositions`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/clicks/positions",queryParameters:o,headers:{}};return l.request(s,r)},getClickThroughRate:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getClickThroughRate`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/clicks/clickThroughRate",queryParameters:o,headers:{}};return l.request(s,r)},getConversationRate:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getConversationRate`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/conversions/conversionRate",queryParameters:o,headers:{}};return l.request(s,r)},getNoClickRate:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getNoClickRate`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/searches/noClickRate",queryParameters:o,headers:{}};return l.request(s,r)},getNoResultsRate:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getNoResultsRate`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/searches/noResultRate",queryParameters:o,headers:{}};return l.request(s,r)},getSearchesCount:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getSearchesCount`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/searches/count",queryParameters:o,headers:{}};return l.request(s,r)},getSearchesNoClicks:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.limit,o=e.offset,s=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getSearchesNoClicks`.");var c={};void 0!==t&&(c.index=t.toString()),void 0!==a&&(c.startDate=a.toString()),void 0!==n&&(c.endDate=n.toString()),void 0!==i&&(c.limit=i.toString()),void 0!==o&&(c.offset=o.toString()),void 0!==s&&(c.tags=s.toString());var d={method:"GET",path:"/2/searches/noClicks",queryParameters:c,headers:{}};return l.request(d,r)},getSearchesNoResults:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.limit,o=e.offset,s=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getSearchesNoResults`.");var c={};void 0!==t&&(c.index=t.toString()),void 0!==a&&(c.startDate=a.toString()),void 0!==n&&(c.endDate=n.toString()),void 0!==i&&(c.limit=i.toString()),void 0!==o&&(c.offset=o.toString()),void 0!==s&&(c.tags=s.toString());var d={method:"GET",path:"/2/searches/noResults",queryParameters:c,headers:{}};return l.request(d,r)},getStatus:function(e,r){var t=e.index;if(!t)throw new Error("Parameter `index` is required when calling `getStatus`.");var a={};void 0!==t&&(a.index=t.toString());var n={method:"GET",path:"/2/status",queryParameters:a,headers:{}};return l.request(n,r)},getTopCountries:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.limit,o=e.offset,s=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getTopCountries`.");var c={};void 0!==t&&(c.index=t.toString()),void 0!==a&&(c.startDate=a.toString()),void 0!==n&&(c.endDate=n.toString()),void 0!==i&&(c.limit=i.toString()),void 0!==o&&(c.offset=o.toString()),void 0!==s&&(c.tags=s.toString());var d={method:"GET",path:"/2/countries",queryParameters:c,headers:{}};return l.request(d,r)},getTopFilterAttributes:function(e,r){var t=e.index,a=e.search,n=e.startDate,i=e.endDate,o=e.limit,s=e.offset,c=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getTopFilterAttributes`.");var d={};void 0!==t&&(d.index=t.toString()),void 0!==a&&(d.search=a.toString()),void 0!==n&&(d.startDate=n.toString()),void 0!==i&&(d.endDate=i.toString()),void 0!==o&&(d.limit=o.toString()),void 0!==s&&(d.offset=s.toString()),void 0!==c&&(d.tags=c.toString());var u={method:"GET",path:"/2/filters",queryParameters:d,headers:{}};return l.request(u,r)},getTopFilterForAttribute:function(e,r){var t=e.attribute,a=e.index,n=e.search,i=e.startDate,o=e.endDate,s=e.limit,c=e.offset,d=e.tags;if(!t)throw new Error("Parameter `attribute` is required when calling `getTopFilterForAttribute`.");if(!a)throw new Error("Parameter `index` is required when calling `getTopFilterForAttribute`.");var u="/2/filters/{attribute}".replace("{attribute}",encodeURIComponent(t)),h={};void 0!==a&&(h.index=a.toString()),void 0!==n&&(h.search=n.toString()),void 0!==i&&(h.startDate=i.toString()),void 0!==o&&(h.endDate=o.toString()),void 0!==s&&(h.limit=s.toString()),void 0!==c&&(h.offset=c.toString()),void 0!==d&&(h.tags=d.toString());var m={method:"GET",path:u,queryParameters:h,headers:{}};return l.request(m,r)},getTopFiltersNoResults:function(e,r){var t=e.index,a=e.search,n=e.startDate,i=e.endDate,o=e.limit,s=e.offset,c=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getTopFiltersNoResults`.");var d={};void 0!==t&&(d.index=t.toString()),void 0!==a&&(d.search=a.toString()),void 0!==n&&(d.startDate=n.toString()),void 0!==i&&(d.endDate=i.toString()),void 0!==o&&(d.limit=o.toString()),void 0!==s&&(d.offset=s.toString()),void 0!==c&&(d.tags=c.toString());var u={method:"GET",path:"/2/filters/noResults",queryParameters:d,headers:{}};return l.request(u,r)},getTopHits:function(e,r){var t=e.index,a=e.search,n=e.clickAnalytics,i=e.startDate,o=e.endDate,s=e.limit,c=e.offset,d=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getTopHits`.");var u={};void 0!==t&&(u.index=t.toString()),void 0!==a&&(u.search=a.toString()),void 0!==n&&(u.clickAnalytics=n.toString()),void 0!==i&&(u.startDate=i.toString()),void 0!==o&&(u.endDate=o.toString()),void 0!==s&&(u.limit=s.toString()),void 0!==c&&(u.offset=c.toString()),void 0!==d&&(u.tags=d.toString());var h={method:"GET",path:"/2/hits",queryParameters:u,headers:{}};return l.request(h,r)},getTopSearches:function(e,r){var t=e.index,a=e.clickAnalytics,n=e.startDate,i=e.endDate,o=e.orderBy,s=e.direction,c=e.limit,d=e.offset,u=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getTopSearches`.");var h={};void 0!==t&&(h.index=t.toString()),void 0!==a&&(h.clickAnalytics=a.toString()),void 0!==n&&(h.startDate=n.toString()),void 0!==i&&(h.endDate=i.toString()),void 0!==o&&(h.orderBy=o.toString()),void 0!==s&&(h.direction=s.toString()),void 0!==c&&(h.limit=c.toString()),void 0!==d&&(h.offset=d.toString()),void 0!==u&&(h.tags=u.toString());var m={method:"GET",path:"/2/searches",queryParameters:h,headers:{}};return l.request(m,r)},getUsersCount:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getUsersCount`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/users/count",queryParameters:o,headers:{}};return l.request(s,r)},post:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `post`.");var i={method:"POST",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return l.request(i,r)},put:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `put`.");var i={method:"PUT",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return l.request(i,r)}}}var N=["appId","apiKey","authMode","algoliaAgents","region"];function j(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);r&&(a=a.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,a)}return t}function R(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?j(Object(a),!0).forEach((function(t){r(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):j(Object(a)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(a,r))}))}return e}var U=["eu","us"];function A(e){return A="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},A(e)}var C=["appId","apiKey","authMode","algoliaAgents"],k=["indexName","browseRequest"],G=["indexName","searchRulesParams"],K=["indexName","validate","aggregator"],B=["params"];function H(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);r&&(a=a.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,a)}return t}function z(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?H(Object(a),!0).forEach((function(t){r(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):H(Object(a)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(a,r))}))}return e}var F="5.0.0-alpha.4";function L(e){return[{url:"".concat(e,"-dsn.algolia.net"),accept:"read",protocol:"https"},{url:"".concat(e,".algolia.net"),accept:"write",protocol:"https"}].concat(function(e){const r=e;for(let t=e.length-1;t>0;t--){const a=Math.floor(Math.random()*(t+1)),n=e[t];r[t]=e[a],r[a]=n}return r}([{url:"".concat(e,"-1.algolianet.com"),accept:"readWrite",protocol:"https"},{url:"".concat(e,"-2.algolianet.com"),accept:"readWrite",protocol:"https"},{url:"".concat(e,"-3.algolianet.com"),accept:"readWrite",protocol:"https"}]))}function M(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);r&&(a=a.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,a)}return t}function J(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?M(Object(a),!0).forEach((function(t){r(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):M(Object(a)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(a,r))}))}return e}var Q=F;e.algoliasearch=function(e,r,c){if(!e||"string"!=typeof e)throw new Error("`appId` is missing.");if(!r||"string"!=typeof r)throw new Error("`apiKey` is missing.");var d=J({apiKey:r,appId:e,timeouts:{connect:1e3,read:2e3,write:3e4},requester:{send:function(e){return new Promise((r=>{const t=new XMLHttpRequest;t.open(e.method,e.url,!0),Object.keys(e.headers).forEach((r=>t.setRequestHeader(r,e.headers[r])));const a=(e,a)=>setTimeout((()=>{t.abort(),r({status:0,content:a,isTimedOut:!0})}),e),n=a(e.connectTimeout,"Connection timeout");let i;t.onreadystatechange=()=>{t.readyState>t.OPENED&&void 0===i&&(clearTimeout(n),i=a(e.responseTimeout,"Socket timeout"))},t.onerror=()=>{0===t.status&&(clearTimeout(n),clearTimeout(i),r({content:t.responseText||"Network request failed",status:t.status,isTimedOut:!1}))},t.onload=()=>{clearTimeout(n),clearTimeout(i),r({content:t.responseText,status:t.status,isTimedOut:!1})},t.send(e.data)}))}},algoliaAgents:[{segment:"Browser"}],authMode:"WithinQueryParameters",responsesCache:s(),requestsCache:s({serializable:!1}),hostsCache:o({caches:[i({key:"".concat(Q,"-").concat(e)}),s()]})},c);return J(J({},function(e){var r=e.appId,i=e.apiKey,o=e.authMode,s=e.algoliaAgents,c=t(e,C),d=a(r,i,o),u=v(z(z({hosts:L(r)},c),{},{algoliaAgent:y({algoliaAgents:s,client:"Search",version:F}),baseHeaders:z(z({"content-type":"text/plain"},d.headers()),c.baseHeaders),baseQueryParameters:z(z({},d.queryParameters()),c.baseQueryParameters)}));return{transporter:u,appId:r,clearCache:function(){return Promise.all([u.requestsCache.clear(),u.responsesCache.clear()]).then((function(){}))},get _ua(){return u.algoliaAgent.value},addAlgoliaAgent:function(e,r){u.algoliaAgent.add({segment:e,version:r})},waitForTask:function(e,r){var t=this,a=e.indexName,i=e.taskID,o=e.maxRetries,s=void 0===o?50:o,c=e.timeout,d=void 0===c?function(e){return Math.min(200*e,5e3)}:c,u=0;return n({func:function(){return t.getTask({indexName:a,taskID:i},r)},validate:function(e){return"published"===e.status},aggregator:function(){return u+=1},error:{validate:function(){return u>=s},message:function(){return"The maximum number of retries exceeded. (".concat(u,"/").concat(s,")")}},timeout:function(){return d(u)}})},waitForApiKey:function(e,r){var t=this,a=e.operation,i=e.key,o=e.apiKey,s=e.maxRetries,c=void 0===s?50:s,d=e.timeout,u=void 0===d?function(e){return Math.min(200*e,5e3)}:d,l=0,h={aggregator:function(){return l+=1},error:{validate:function(){return l>=c},message:function(){return"The maximum number of retries exceeded. (".concat(l,"/").concat(c,")")}},timeout:function(){return u(l)}};if("update"===a){if(!o)throw new Error("`apiKey` is required when waiting for an `update` operation.");return n(z(z({},h),{},{func:function(){return t.getApiKey({key:i},r)},validate:function(e){for(var r=function(){var r=a[t];if(Array.isArray(o[r])){if(o[r].length!==e[r].length||o[r].some((function(t,a){return t!==e[r][a]})))return{v:!1}}else if(e[r]!==o[r])return{v:!1}},t=0,a=Object.keys(o);t<a.length;t++){var n=r();if("object"===A(n))return n.v}return!0}}))}return n(z(z({},h),{},{func:function(){return t.getApiKey({key:i},r).catch((function(e){return e}))},validate:function(e){return"add"===a?404!==e.status:404===e.status}}))},browseObjects:function(e,r){var a=this,i=e.indexName,o=e.browseRequest;return n(z({func:function(e){return a.browse({indexName:i,browseRequest:z({cursor:e?e.cursor:void 0},o)},r)},validate:function(e){return void 0===e.cursor}},t(e,k)))},browseRules:function(e,r){var a=this,i=e.indexName,o=e.searchRulesParams,s=t(e,G),c=z({hitsPerPage:1e3},o);return n(z({func:function(e){return a.searchRules({indexName:i,searchRulesParams:z(z({},c),{},{page:e?e.page+1:c.page||0})},r)},validate:function(e){return e.nbHits<c.hitsPerPage}},s))},browseSynonyms:function(e,r){var a=this,i=e.indexName;e.validate,e.aggregator;var o=t(e,K),s=z({hitsPerPage:1e3},o);return n(z({func:function(e){return a.searchSynonyms(z(z({},s),{},{indexName:i,page:e?e.page+1:o.page||0}),r)},validate:function(e){return e.nbHits<s.hitsPerPage}},o))},addApiKey:function(e,r){if(!e)throw new Error("Parameter `apiKey` is required when calling `addApiKey`.");if(!e.acl)throw new Error("Parameter `apiKey.acl` is required when calling `addApiKey`.");var t={method:"POST",path:"/1/keys",queryParameters:{},headers:{},data:e};return u.request(t,r)},addOrUpdateObject:function(e,r){var t=e.indexName,a=e.objectID,n=e.body;if(!t)throw new Error("Parameter `indexName` is required when calling `addOrUpdateObject`.");if(!a)throw new Error("Parameter `objectID` is required when calling `addOrUpdateObject`.");if(!n)throw new Error("Parameter `body` is required when calling `addOrUpdateObject`.");var i={method:"PUT",path:"/1/indexes/{indexName}/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),queryParameters:{},headers:{},data:n};return u.request(i,r)},appendSource:function(e,r){if(!e)throw new Error("Parameter `source` is required when calling `appendSource`.");var t={method:"POST",path:"/1/security/sources/append",queryParameters:{},headers:{},data:e};return u.request(t,r)},assignUserId:function(e,r){var t=e.xAlgoliaUserID,a=e.assignUserIdParams;if(!t)throw new Error("Parameter `xAlgoliaUserID` is required when calling `assignUserId`.");if(!a)throw new Error("Parameter `assignUserIdParams` is required when calling `assignUserId`.");if(!a.cluster)throw new Error("Parameter `assignUserIdParams.cluster` is required when calling `assignUserId`.");var n={};void 0!==t&&(n["X-Algolia-User-ID"]=t.toString());var i={method:"POST",path:"/1/clusters/mapping",queryParameters:{},headers:n,data:a};return u.request(i,r)},batch:function(e,r){var t=e.indexName,a=e.batchWriteParams;if(!t)throw new Error("Parameter `indexName` is required when calling `batch`.");if(!a)throw new Error("Parameter `batchWriteParams` is required when calling `batch`.");var n={method:"POST",path:"/1/indexes/{indexName}/batch".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a};return u.request(n,r)},batchAssignUserIds:function(e,r){var t=e.xAlgoliaUserID,a=e.batchAssignUserIdsParams;if(!t)throw new Error("Parameter `xAlgoliaUserID` is required when calling `batchAssignUserIds`.");if(!a)throw new Error("Parameter `batchAssignUserIdsParams` is required when calling `batchAssignUserIds`.");if(!a.cluster)throw new Error("Parameter `batchAssignUserIdsParams.cluster` is required when calling `batchAssignUserIds`.");if(!a.users)throw new Error("Parameter `batchAssignUserIdsParams.users` is required when calling `batchAssignUserIds`.");var n={};void 0!==t&&(n["X-Algolia-User-ID"]=t.toString());var i={method:"POST",path:"/1/clusters/mapping/batch",queryParameters:{},headers:n,data:a};return u.request(i,r)},batchDictionaryEntries:function(e,r){var t=e.dictionaryName,a=e.batchDictionaryEntriesParams;if(!t)throw new Error("Parameter `dictionaryName` is required when calling `batchDictionaryEntries`.");if(!a)throw new Error("Parameter `batchDictionaryEntriesParams` is required when calling `batchDictionaryEntries`.");if(!a.requests)throw new Error("Parameter `batchDictionaryEntriesParams.requests` is required when calling `batchDictionaryEntries`.");var n={method:"POST",path:"/1/dictionaries/{dictionaryName}/batch".replace("{dictionaryName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a};return u.request(n,r)},browse:function(e,r){var t=e.indexName,a=e.browseRequest;if(!t)throw new Error("Parameter `indexName` is required when calling `browse`.");var n={method:"POST",path:"/1/indexes/{indexName}/browse".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a||{}};return u.request(n,r)},clearAllSynonyms:function(e,r){var t=e.indexName,a=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `clearAllSynonyms`.");var n="/1/indexes/{indexName}/synonyms/clear".replace("{indexName}",encodeURIComponent(t)),i={};void 0!==a&&(i.forwardToReplicas=a.toString());var o={method:"POST",path:n,queryParameters:i,headers:{}};return u.request(o,r)},clearObjects:function(e,r){var t=e.indexName;if(!t)throw new Error("Parameter `indexName` is required when calling `clearObjects`.");var a={method:"POST",path:"/1/indexes/{indexName}/clear".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},clearRules:function(e,r){var t=e.indexName,a=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `clearRules`.");var n="/1/indexes/{indexName}/rules/clear".replace("{indexName}",encodeURIComponent(t)),i={};void 0!==a&&(i.forwardToReplicas=a.toString());var o={method:"POST",path:n,queryParameters:i,headers:{}};return u.request(o,r)},del:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `del`.");var n={method:"DELETE",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return u.request(n,r)},deleteApiKey:function(e,r){var t=e.key;if(!t)throw new Error("Parameter `key` is required when calling `deleteApiKey`.");var a={method:"DELETE",path:"/1/keys/{key}".replace("{key}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},deleteBy:function(e,r){var t=e.indexName,a=e.searchParams;if(!t)throw new Error("Parameter `indexName` is required when calling `deleteBy`.");if(!a)throw new Error("Parameter `searchParams` is required when calling `deleteBy`.");var n={method:"POST",path:"/1/indexes/{indexName}/deleteByQuery".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a};return u.request(n,r)},deleteIndex:function(e,r){var t=e.indexName;if(!t)throw new Error("Parameter `indexName` is required when calling `deleteIndex`.");var a={method:"DELETE",path:"/1/indexes/{indexName}".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},deleteObject:function(e,r){var t=e.indexName,a=e.objectID;if(!t)throw new Error("Parameter `indexName` is required when calling `deleteObject`.");if(!a)throw new Error("Parameter `objectID` is required when calling `deleteObject`.");var n={method:"DELETE",path:"/1/indexes/{indexName}/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),queryParameters:{},headers:{}};return u.request(n,r)},deleteRule:function(e,r){var t=e.indexName,a=e.objectID,n=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `deleteRule`.");if(!a)throw new Error("Parameter `objectID` is required when calling `deleteRule`.");var i="/1/indexes/{indexName}/rules/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),o={};void 0!==n&&(o.forwardToReplicas=n.toString());var s={method:"DELETE",path:i,queryParameters:o,headers:{}};return u.request(s,r)},deleteSource:function(e,r){var t=e.source;if(!t)throw new Error("Parameter `source` is required when calling `deleteSource`.");var a={method:"DELETE",path:"/1/security/sources/{source}".replace("{source}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},deleteSynonym:function(e,r){var t=e.indexName,a=e.objectID,n=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `deleteSynonym`.");if(!a)throw new Error("Parameter `objectID` is required when calling `deleteSynonym`.");var i="/1/indexes/{indexName}/synonyms/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),o={};void 0!==n&&(o.forwardToReplicas=n.toString());var s={method:"DELETE",path:i,queryParameters:o,headers:{}};return u.request(s,r)},get:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `get`.");var n={method:"GET",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return u.request(n,r)},getApiKey:function(e,r){var t=e.key;if(!t)throw new Error("Parameter `key` is required when calling `getApiKey`.");var a={method:"GET",path:"/1/keys/{key}".replace("{key}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},getDictionaryLanguages:function(e){var r={method:"GET",path:"/1/dictionaries/*/languages",queryParameters:{},headers:{}};return u.request(r,e)},getDictionarySettings:function(e){var r={method:"GET",path:"/1/dictionaries/*/settings",queryParameters:{},headers:{}};return u.request(r,e)},getLogs:function(e,r){var t=e.offset,a=e.length,n=e.indexName,i=e.type,o={};void 0!==t&&(o.offset=t.toString()),void 0!==a&&(o.length=a.toString()),void 0!==n&&(o.indexName=n.toString()),void 0!==i&&(o.type=i.toString());var s={method:"GET",path:"/1/logs",queryParameters:o,headers:{}};return u.request(s,r)},getObject:function(e,r){var t=e.indexName,a=e.objectID,n=e.attributesToRetrieve;if(!t)throw new Error("Parameter `indexName` is required when calling `getObject`.");if(!a)throw new Error("Parameter `objectID` is required when calling `getObject`.");var i="/1/indexes/{indexName}/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),o={};void 0!==n&&(o.attributesToRetrieve=n.toString());var s={method:"GET",path:i,queryParameters:o,headers:{}};return u.request(s,r)},getObjects:function(e,r){if(!e)throw new Error("Parameter `getObjectsParams` is required when calling `getObjects`.");if(!e.requests)throw new Error("Parameter `getObjectsParams.requests` is required when calling `getObjects`.");var t={method:"POST",path:"/1/indexes/*/objects",queryParameters:{},headers:{},data:e,useReadTransporter:!0,cacheable:!0};return u.request(t,r)},getRule:function(e,r){var t=e.indexName,a=e.objectID;if(!t)throw new Error("Parameter `indexName` is required when calling `getRule`.");if(!a)throw new Error("Parameter `objectID` is required when calling `getRule`.");var n={method:"GET",path:"/1/indexes/{indexName}/rules/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),queryParameters:{},headers:{}};return u.request(n,r)},getSettings:function(e,r){var t=e.indexName;if(!t)throw new Error("Parameter `indexName` is required when calling `getSettings`.");var a={method:"GET",path:"/1/indexes/{indexName}/settings".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},getSources:function(e){var r={method:"GET",path:"/1/security/sources",queryParameters:{},headers:{}};return u.request(r,e)},getSynonym:function(e,r){var t=e.indexName,a=e.objectID;if(!t)throw new Error("Parameter `indexName` is required when calling `getSynonym`.");if(!a)throw new Error("Parameter `objectID` is required when calling `getSynonym`.");var n={method:"GET",path:"/1/indexes/{indexName}/synonyms/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),queryParameters:{},headers:{}};return u.request(n,r)},getTask:function(e,r){var t=e.indexName,a=e.taskID;if(!t)throw new Error("Parameter `indexName` is required when calling `getTask`.");if(!a)throw new Error("Parameter `taskID` is required when calling `getTask`.");var n={method:"GET",path:"/1/indexes/{indexName}/task/{taskID}".replace("{indexName}",encodeURIComponent(t)).replace("{taskID}",encodeURIComponent(a)),queryParameters:{},headers:{}};return u.request(n,r)},getTopUserIds:function(e){var r={method:"GET",path:"/1/clusters/mapping/top",queryParameters:{},headers:{}};return u.request(r,e)},getUserId:function(e,r){var t=e.userID;if(!t)throw new Error("Parameter `userID` is required when calling `getUserId`.");var a={method:"GET",path:"/1/clusters/mapping/{userID}".replace("{userID}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},hasPendingMappings:function(e,r){var t=e.getClusters,a={};void 0!==t&&(a.getClusters=t.toString());var n={method:"GET",path:"/1/clusters/mapping/pending",queryParameters:a,headers:{}};return u.request(n,r)},listApiKeys:function(e){var r={method:"GET",path:"/1/keys",queryParameters:{},headers:{}};return u.request(r,e)},listClusters:function(e){var r={method:"GET",path:"/1/clusters",queryParameters:{},headers:{}};return u.request(r,e)},listIndices:function(e,r){var t=e.page,a={};void 0!==t&&(a.page=t.toString());var n={method:"GET",path:"/1/indexes",queryParameters:a,headers:{}};return u.request(n,r)},listUserIds:function(e,r){var t=e.page,a=e.hitsPerPage,n={};void 0!==t&&(n.page=t.toString()),void 0!==a&&(n.hitsPerPage=a.toString());var i={method:"GET",path:"/1/clusters/mapping",queryParameters:n,headers:{}};return u.request(i,r)},multipleBatch:function(e,r){if(!e)throw new Error("Parameter `batchParams` is required when calling `multipleBatch`.");if(!e.requests)throw new Error("Parameter `batchParams.requests` is required when calling `multipleBatch`.");var t={method:"POST",path:"/1/indexes/*/batch",queryParameters:{},headers:{},data:e};return u.request(t,r)},operationIndex:function(e,r){var t=e.indexName,a=e.operationIndexParams;if(!t)throw new Error("Parameter `indexName` is required when calling `operationIndex`.");if(!a)throw new Error("Parameter `operationIndexParams` is required when calling `operationIndex`.");if(!a.operation)throw new Error("Parameter `operationIndexParams.operation` is required when calling `operationIndex`.");if(!a.destination)throw new Error("Parameter `operationIndexParams.destination` is required when calling `operationIndex`.");var n={method:"POST",path:"/1/indexes/{indexName}/operation".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a};return u.request(n,r)},partialUpdateObject:function(e,r){var t=e.indexName,a=e.objectID,n=e.attributeToUpdate,i=e.createIfNotExists;if(!t)throw new Error("Parameter `indexName` is required when calling `partialUpdateObject`.");if(!a)throw new Error("Parameter `objectID` is required when calling `partialUpdateObject`.");if(!n)throw new Error("Parameter `attributeToUpdate` is required when calling `partialUpdateObject`.");var o="/1/indexes/{indexName}/{objectID}/partial".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),s={};void 0!==i&&(s.createIfNotExists=i.toString());var c={method:"POST",path:o,queryParameters:s,headers:{},data:n};return u.request(c,r)},post:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `post`.");var i={method:"POST",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return u.request(i,r)},put:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `put`.");var i={method:"PUT",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return u.request(i,r)},removeUserId:function(e,r){var t=e.userID;if(!t)throw new Error("Parameter `userID` is required when calling `removeUserId`.");var a={method:"DELETE",path:"/1/clusters/mapping/{userID}".replace("{userID}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},replaceSources:function(e,r){var t=e.source;if(!t)throw new Error("Parameter `source` is required when calling `replaceSources`.");var a={method:"PUT",path:"/1/security/sources",queryParameters:{},headers:{},data:t};return u.request(a,r)},restoreApiKey:function(e,r){var t=e.key;if(!t)throw new Error("Parameter `key` is required when calling `restoreApiKey`.");var a={method:"POST",path:"/1/keys/{key}/restore".replace("{key}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},saveObject:function(e,r){var t=e.indexName,a=e.body;if(!t)throw new Error("Parameter `indexName` is required when calling `saveObject`.");if(!a)throw new Error("Parameter `body` is required when calling `saveObject`.");var n={method:"POST",path:"/1/indexes/{indexName}".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a};return u.request(n,r)},saveRule:function(e,r){var t=e.indexName,a=e.objectID,n=e.rule,i=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `saveRule`.");if(!a)throw new Error("Parameter `objectID` is required when calling `saveRule`.");if(!n)throw new Error("Parameter `rule` is required when calling `saveRule`.");if(!n.objectID)throw new Error("Parameter `rule.objectID` is required when calling `saveRule`.");var o="/1/indexes/{indexName}/rules/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),s={};void 0!==i&&(s.forwardToReplicas=i.toString());var c={method:"PUT",path:o,queryParameters:s,headers:{},data:n};return u.request(c,r)},saveRules:function(e,r){var t=e.indexName,a=e.rule,n=e.forwardToReplicas,i=e.clearExistingRules;if(!t)throw new Error("Parameter `indexName` is required when calling `saveRules`.");if(!a)throw new Error("Parameter `rule` is required when calling `saveRules`.");var o="/1/indexes/{indexName}/rules/batch".replace("{indexName}",encodeURIComponent(t)),s={};void 0!==n&&(s.forwardToReplicas=n.toString()),void 0!==i&&(s.clearExistingRules=i.toString());var c={method:"POST",path:o,queryParameters:s,headers:{},data:a};return u.request(c,r)},saveSynonym:function(e,r){var t=e.indexName,a=e.objectID,n=e.synonymHit,i=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `saveSynonym`.");if(!a)throw new Error("Parameter `objectID` is required when calling `saveSynonym`.");if(!n)throw new Error("Parameter `synonymHit` is required when calling `saveSynonym`.");if(!n.objectID)throw new Error("Parameter `synonymHit.objectID` is required when calling `saveSynonym`.");var o="/1/indexes/{indexName}/synonyms/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),s={};void 0!==i&&(s.forwardToReplicas=i.toString());var c={method:"PUT",path:o,queryParameters:s,headers:{},data:n};return u.request(c,r)},saveSynonyms:function(e,r){var t=e.indexName,a=e.synonymHit,n=e.forwardToReplicas,i=e.replaceExistingSynonyms;if(!t)throw new Error("Parameter `indexName` is required when calling `saveSynonyms`.");if(!a)throw new Error("Parameter `synonymHit` is required when calling `saveSynonyms`.");var o="/1/indexes/{indexName}/synonyms/batch".replace("{indexName}",encodeURIComponent(t)),s={};void 0!==n&&(s.forwardToReplicas=n.toString()),void 0!==i&&(s.replaceExistingSynonyms=i.toString());var c={method:"POST",path:o,queryParameters:s,headers:{},data:a};return u.request(c,r)},search:function(e,r){if(e&&Array.isArray(e)){var a={requests:e.map((function(e){var r=e.params,a=t(e,B);return"facet"===a.type?z(z(z({},a),r),{},{type:"facet"}):z(z(z({},a),r),{},{facet:void 0,maxFacetHits:void 0,facetQuery:void 0})}))};e=a}if(!e)throw new Error("Parameter `searchMethodParams` is required when calling `search`.");if(!e.requests)throw new Error("Parameter `searchMethodParams.requests` is required when calling `search`.");var n={method:"POST",path:"/1/indexes/*/queries",queryParameters:{},headers:{},data:e,useReadTransporter:!0,cacheable:!0};return u.request(n,r)},searchDictionaryEntries:function(e,r){var t=e.dictionaryName,a=e.searchDictionaryEntriesParams;if(!t)throw new Error("Parameter `dictionaryName` is required when calling `searchDictionaryEntries`.");if(!a)throw new Error("Parameter `searchDictionaryEntriesParams` is required when calling `searchDictionaryEntries`.");if(!a.query)throw new Error("Parameter `searchDictionaryEntriesParams.query` is required when calling `searchDictionaryEntries`.");var n={method:"POST",path:"/1/dictionaries/{dictionaryName}/search".replace("{dictionaryName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a,useReadTransporter:!0,cacheable:!0};return u.request(n,r)},searchForFacetValues:function(e,r){var t=e.indexName,a=e.facetName,n=e.searchForFacetValuesRequest;if(!t)throw new Error("Parameter `indexName` is required when calling `searchForFacetValues`.");if(!a)throw new Error("Parameter `facetName` is required when calling `searchForFacetValues`.");var i={method:"POST",path:"/1/indexes/{indexName}/facets/{facetName}/query".replace("{indexName}",encodeURIComponent(t)).replace("{facetName}",encodeURIComponent(a)),queryParameters:{},headers:{},data:n||{},useReadTransporter:!0,cacheable:!0};return u.request(i,r)},searchRules:function(e,r){var t=e.indexName,a=e.searchRulesParams;if(!t)throw new Error("Parameter `indexName` is required when calling `searchRules`.");var n={method:"POST",path:"/1/indexes/{indexName}/rules/search".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a||{},useReadTransporter:!0,cacheable:!0};return u.request(n,r)},searchSingleIndex:function(e,r){var t=e.indexName,a=e.searchParams;if(!t)throw new Error("Parameter `indexName` is required when calling `searchSingleIndex`.");var n={method:"POST",path:"/1/indexes/{indexName}/query".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a||{},useReadTransporter:!0,cacheable:!0};return u.request(n,r)},searchSynonyms:function(e,r){var t=e.indexName,a=e.type,n=e.page,i=e.hitsPerPage,o=e.searchSynonymsParams;if(!t)throw new Error("Parameter `indexName` is required when calling `searchSynonyms`.");var s="/1/indexes/{indexName}/synonyms/search".replace("{indexName}",encodeURIComponent(t)),c={};void 0!==a&&(c.type=a.toString()),void 0!==n&&(c.page=n.toString()),void 0!==i&&(c.hitsPerPage=i.toString());var d={method:"POST",path:s,queryParameters:c,headers:{},data:o||{},useReadTransporter:!0,cacheable:!0};return u.request(d,r)},searchUserIds:function(e,r){if(!e)throw new Error("Parameter `searchUserIdsParams` is required when calling `searchUserIds`.");if(!e.query)throw new Error("Parameter `searchUserIdsParams.query` is required when calling `searchUserIds`.");var t={method:"POST",path:"/1/clusters/mapping/search",queryParameters:{},headers:{},data:e,useReadTransporter:!0,cacheable:!0};return u.request(t,r)},setDictionarySettings:function(e,r){if(!e)throw new Error("Parameter `dictionarySettingsParams` is required when calling `setDictionarySettings`.");if(!e.disableStandardEntries)throw new Error("Parameter `dictionarySettingsParams.disableStandardEntries` is required when calling `setDictionarySettings`.");var t={method:"PUT",path:"/1/dictionaries/*/settings",queryParameters:{},headers:{},data:e};return u.request(t,r)},setSettings:function(e,r){var t=e.indexName,a=e.indexSettings,n=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `setSettings`.");if(!a)throw new Error("Parameter `indexSettings` is required when calling `setSettings`.");var i="/1/indexes/{indexName}/settings".replace("{indexName}",encodeURIComponent(t)),o={};void 0!==n&&(o.forwardToReplicas=n.toString());var s={method:"PUT",path:i,queryParameters:o,headers:{},data:a};return u.request(s,r)},updateApiKey:function(e,r){var t=e.key,a=e.apiKey;if(!t)throw new Error("Parameter `key` is required when calling `updateApiKey`.");if(!a)throw new Error("Parameter `apiKey` is required when calling `updateApiKey`.");if(!a.acl)throw new Error("Parameter `apiKey.acl` is required when calling `updateApiKey`.");var n={method:"PUT",path:"/1/keys/{key}".replace("{key}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a};return u.request(n,r)}}}(d)),{},{get _ua(){return this.transporter.algoliaAgent.value},initAnalytics:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(e.region&&("string"!=typeof e.region||!D.includes(e.region)))throw new Error("`region` must be one of the following: ".concat(D.join(", ")));return I(J(J(J({},d),e.options),e))},initPersonalization:function(e){if(!e.region)throw new Error("`region` is missing.");if(e.region&&("string"!=typeof e.region||!U.includes(e.region)))throw new Error("`region` must be one of the following: ".concat(U.join(", ")));return function(e){var r,n=e.appId,i=e.apiKey,o=e.authMode,s=e.algoliaAgents,c=e.region,d=t(e,N),u=a(n,i,o),l=v(R(R({hosts:(r=c,[{url:"personalization.{region}.algolia.com".replace("{region}",r),accept:"readWrite",protocol:"https"}])},d),{},{algoliaAgent:y({algoliaAgents:s,client:"Personalization",version:"5.0.0-alpha.4"}),baseHeaders:R(R({"content-type":"text/plain"},u.headers()),d.baseHeaders),baseQueryParameters:R(R({},u.queryParameters()),d.baseQueryParameters)}));return{transporter:l,appId:n,clearCache:function(){return Promise.all([l.requestsCache.clear(),l.responsesCache.clear()]).then((function(){}))},get _ua(){return l.algoliaAgent.value},addAlgoliaAgent:function(e,r){l.algoliaAgent.add({segment:e,version:r})},del:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `del`.");var n={method:"DELETE",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return l.request(n,r)},deleteUserProfile:function(e,r){var t=e.userToken;if(!t)throw new Error("Parameter `userToken` is required when calling `deleteUserProfile`.");var a={method:"DELETE",path:"/1/profiles/{userToken}".replace("{userToken}",encodeURIComponent(t)),queryParameters:{},headers:{}};return l.request(a,r)},get:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `get`.");var n={method:"GET",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return l.request(n,r)},getPersonalizationStrategy:function(e){var r={method:"GET",path:"/1/strategies/personalization",queryParameters:{},headers:{}};return l.request(r,e)},getUserTokenProfile:function(e,r){var t=e.userToken;if(!t)throw new Error("Parameter `userToken` is required when calling `getUserTokenProfile`.");var a={method:"GET",path:"/1/profiles/personalization/{userToken}".replace("{userToken}",encodeURIComponent(t)),queryParameters:{},headers:{}};return l.request(a,r)},post:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `post`.");var i={method:"POST",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return l.request(i,r)},put:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `put`.");var i={method:"PUT",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return l.request(i,r)},setPersonalizationStrategy:function(e,r){if(!e)throw new Error("Parameter `personalizationStrategyParams` is required when calling `setPersonalizationStrategy`.");if(!e.eventScoring)throw new Error("Parameter `personalizationStrategyParams.eventScoring` is required when calling `setPersonalizationStrategy`.");if(!e.facetScoring)throw new Error("Parameter `personalizationStrategyParams.facetScoring` is required when calling `setPersonalizationStrategy`.");if(!e.personalizationImpact)throw new Error("Parameter `personalizationStrategyParams.personalizationImpact` is required when calling `setPersonalizationStrategy`.");var t={method:"POST",path:"/1/strategies/personalization",queryParameters:{},headers:{},data:e};return l.request(t,r)}}}(J(J(J({},d),e.options),e))},initAbtesting:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(e.region&&("string"!=typeof e.region||!E.includes(e.region)))throw new Error("`region` must be one of the following: ".concat(E.join(", ")));return S(J(J(J({},d),e.options),e))}})},e.apiClientVersion=Q}));
|
|
1
|
+
/*! algoliasearch.umd.js | 5.0.0-alpha.5 | © Algolia, inc. | https://github.com/algolia/algoliasearch-client-javascript */
|
|
2
|
+
!function(e,r){"object"==typeof exports&&"undefined"!=typeof module?r(exports):"function"==typeof define&&define.amd?define(["exports"],r):r((e="undefined"!=typeof globalThis?globalThis:e||self).algoliasearch={})}(this,(function(e){"use strict";function r(e,r,t){return r in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}function t(e,r){if(null==e)return{};var t,a,n=function(e,r){if(null==e)return{};var t,a,n={},i=Object.keys(e);for(a=0;a<i.length;a++)t=i[a],r.indexOf(t)>=0||(n[t]=e[t]);return n}(e,r);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)t=i[a],r.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(n[t]=e[t])}return n}function a(e,r,t="WithinHeaders"){const a={"x-algolia-api-key":r,"x-algolia-application-id":e};return{headers:()=>"WithinHeaders"===t?a:{},queryParameters:()=>"WithinQueryParameters"===t?a:{}}}function n({func:e,validate:r,aggregator:t,error:a,timeout:n=(()=>0)}){const i=o=>new Promise(((s,c)=>{e(o).then((e=>(t&&t(e),r(e)?s(e):a&&a.validate(e)?c(new Error(a.message(e))):setTimeout((()=>{i(e).then(s).catch(c)}),n())))).catch((e=>{c(e)}))}));return i()}function i(e){let r;const t=`algolia-client-js-${e.key}`;function a(){return void 0===r&&(r=e.localStorage||window.localStorage),r}function n(){return JSON.parse(a().getItem(t)||"{}")}return{get:(e,r,t={miss:()=>Promise.resolve()})=>Promise.resolve().then((()=>{const t=JSON.stringify(e),a=n()[t];return Promise.all([a||r(),void 0!==a])})).then((([e,r])=>Promise.all([e,r||t.miss(e)]))).then((([e])=>e)),set:(e,r)=>Promise.resolve().then((()=>{const i=n();return i[JSON.stringify(e)]=r,a().setItem(t,JSON.stringify(i)),r})),delete:e=>Promise.resolve().then((()=>{const r=n();delete r[JSON.stringify(e)],a().setItem(t,JSON.stringify(r))})),clear:()=>Promise.resolve().then((()=>{a().removeItem(t)}))}}function o(e){const r=[...e.caches],t=r.shift();return void 0===t?{get:(e,r,t={miss:()=>Promise.resolve()})=>r().then((e=>Promise.all([e,t.miss(e)]))).then((([e])=>e)),set:(e,r)=>Promise.resolve(r),delete:e=>Promise.resolve(),clear:()=>Promise.resolve()}:{get:(e,a,n={miss:()=>Promise.resolve()})=>t.get(e,a,n).catch((()=>o({caches:r}).get(e,a,n))),set:(e,a)=>t.set(e,a).catch((()=>o({caches:r}).set(e,a))),delete:e=>t.delete(e).catch((()=>o({caches:r}).delete(e))),clear:()=>t.clear().catch((()=>o({caches:r}).clear()))}}function s(e={serializable:!0}){let r={};return{get(t,a,n={miss:()=>Promise.resolve()}){const i=JSON.stringify(t);if(i in r)return Promise.resolve(e.serializable?JSON.parse(r[i]):r[i]);const o=a();return o.then((e=>n.miss(e))).then((()=>o))},set:(t,a)=>(r[JSON.stringify(t)]=e.serializable?JSON.stringify(a):a,Promise.resolve(a)),delete:e=>(delete r[JSON.stringify(e)],Promise.resolve()),clear:()=>(r={},Promise.resolve())}}const c=12e4;function d(e,r="up"){const t=Date.now();return{...e,status:r,lastUpdate:t,isUp:function(){return"up"===r||Date.now()-t>c},isTimedOut:function(){return"timed out"===r&&Date.now()-t<=c}}}function u(e,r,t){return r in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}class l extends Error{constructor(e,r){super(e),u(this,"name","AlgoliaError"),r&&(this.name=r)}}class h extends l{constructor(e,r,t){super(e,t),u(this,"stackTrace",void 0),this.stackTrace=r}}class m extends h{constructor(e){super("Unreachable hosts - your application id may be incorrect. If the error persists, contact support@algolia.com.",e,"RetryError")}}class p extends h{constructor(e,r,t){super(e,t,"ApiError"),u(this,"status",void 0),this.status=r}}class g extends l{constructor(e,r){super(e,"DeserializationError"),u(this,"response",void 0),this.response=r}}function f(e,r,t){const a=function(e){const r=e=>"[object Object]"===Object.prototype.toString.call(e)||"[object Array]"===Object.prototype.toString.call(e);return Object.keys(e).map((t=>`${t}=${r(e[t])?JSON.stringify(e[t]):e[t]}`)).join("&")}(t);let n=`${e.protocol}://${e.url}/${"/"===r.charAt(0)?r.substr(1):r}`;return a.length&&(n+=`?${a}`),n}function w(e){const r=e.request.headers["x-algolia-api-key"]?{"x-algolia-api-key":"*****"}:{};return{...e,request:{...e.request,headers:{...e.request.headers,...r}}}}function v({hosts:e,hostsCache:r,baseHeaders:t,baseQueryParameters:a,algoliaAgent:n,timeouts:i,requester:o,requestsCache:s,responsesCache:c}){async function u(s,c,u=!0){const l=[],h=function(e,r){if("GET"===e.method||void 0===e.data&&void 0===r.data)return;const t=Array.isArray(e.data)?e.data:{...e.data,...r.data};return JSON.stringify(t)}(s,c),v=function(e,r,t){const a={Accept:"application/json",...e,...r,...t},n={};return Object.keys(a).forEach((e=>{const r=a[e];n[e.toLowerCase()]=r})),n}(t,s.headers,c.headers),y="GET"===s.method?{...s.data,...c.data}:{},P={"x-algolia-agent":n.value,...a,...s.queryParameters,...y};if(c&&c.queryParameters)for(const e of Object.keys(c.queryParameters))c.queryParameters[e]&&"[object Object]"!==Object.prototype.toString.call(c.queryParameters[e])?P[e]=c.queryParameters[e].toString():P[e]=c.queryParameters[e];let q=0;const b=async(e,t)=>{const a=e.pop();if(void 0===a)throw new m(function(e){return e.map((e=>w(e)))}(l));let n=c.timeout;void 0===n&&(n=u?i.read:i.write);const y={data:h,headers:v,method:s.method,url:f(a,s.path,P),connectTimeout:t(q,i.connect),responseTimeout:t(q,n)},E=r=>{const t={request:y,response:r,host:a,triesLeft:e.length};return l.push(t),t},S=await o.send(y);if(function({isTimedOut:e,status:r}){return e||function({isTimedOut:e,status:r}){return!e&&0==~~r}({isTimedOut:e,status:r})||2!=~~(r/100)&&4!=~~(r/100)}(S)){const n=E(S);return S.isTimedOut&&q++,console.log("Retryable failure",w(n)),await r.set(a,d(a,S.isTimedOut?"timed out":"down")),b(e,t)}if(function({status:e}){return 2==~~(e/100)}(S))return function(e){try{return JSON.parse(e.content)}catch(r){throw new g(r.message,e)}}(S);throw E(S),function({content:e,status:r},t){let a=e;try{a=JSON.parse(e).message}catch(e){}return new p(a,r,t)}(S,l)},E=e.filter((e=>"readWrite"===e.accept||(u?"read"===e.accept:"write"===e.accept))),S=await async function(e){const t=await Promise.all(e.map((e=>r.get(e,(()=>Promise.resolve(d(e))))))),a=t.filter((e=>e.isUp())),n=t.filter((e=>e.isTimedOut())),i=[...a,...n];return{hosts:i.length>0?i:e,getTimeout:(e,r)=>(0===n.length&&0===e?1:n.length+3+e)*r}}(E);return b([...S.hosts].reverse(),S.getTimeout)}return{hostsCache:r,requester:o,timeouts:i,algoliaAgent:n,baseHeaders:t,baseQueryParameters:a,hosts:e,request:function(e,r={}){const n=e.useReadTransporter||"GET"===e.method;if(!n)return u(e,r,n);const i=()=>u(e,r);if(!0!==(r.cacheable||e.cacheable))return i();const o={request:e,requestOptions:r,transporter:{queryParameters:a,headers:t}};return c.get(o,(()=>s.get(o,(()=>s.set(o,i()).then((e=>Promise.all([s.delete(o),e])),(e=>Promise.all([s.delete(o),Promise.reject(e)]))).then((([e,r])=>r))))),{miss:e=>c.set(o,e)})},requestsCache:s,responsesCache:c}}function y({algoliaAgents:e,client:r,version:t}){const a=function(e){const r={value:`Algolia for JavaScript (${e})`,add(e){const t=`; ${e.segment}${void 0!==e.version?` (${e.version})`:""}`;return-1===r.value.indexOf(t)&&(r.value=`${r.value}${t}`),r}};return r}(t).add({segment:r,version:t});return e.forEach((e=>a.add(e))),a}var P=["appId","apiKey","authMode","algoliaAgents","region"];function q(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);r&&(a=a.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,a)}return t}function b(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?q(Object(a),!0).forEach((function(t){r(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):q(Object(a)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(a,r))}))}return e}var E=["de","us"];function S(e){var r,n=e.appId,i=e.apiKey,o=e.authMode,s=e.algoliaAgents,c=e.region,d=t(e,P),u=a(n,i,o),l=v(b(b({hosts:(r=c,[{url:r?"analytics.{region}.algolia.com".replace("{region}",r):"analytics.algolia.com",accept:"readWrite",protocol:"https"}])},d),{},{algoliaAgent:y({algoliaAgents:s,client:"Abtesting",version:"5.0.0-alpha.5"}),baseHeaders:b(b({"content-type":"text/plain"},u.headers()),d.baseHeaders),baseQueryParameters:b(b({},u.queryParameters()),d.baseQueryParameters)}));return{transporter:l,appId:n,clearCache:function(){return Promise.all([l.requestsCache.clear(),l.responsesCache.clear()]).then((function(){}))},get _ua(){return l.algoliaAgent.value},addAlgoliaAgent:function(e,r){l.algoliaAgent.add({segment:e,version:r})},addABTests:function(e,r){if(!e)throw new Error("Parameter `addABTestsRequest` is required when calling `addABTests`.");if(!e.name)throw new Error("Parameter `addABTestsRequest.name` is required when calling `addABTests`.");if(!e.variant)throw new Error("Parameter `addABTestsRequest.variant` is required when calling `addABTests`.");if(!e.endAt)throw new Error("Parameter `addABTestsRequest.endAt` is required when calling `addABTests`.");var t={method:"POST",path:"/2/abtests",queryParameters:{},headers:{},data:e};return l.request(t,r)},del:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `del`.");var n={method:"DELETE",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return l.request(n,r)},deleteABTest:function(e,r){var t=e.id;if(!t)throw new Error("Parameter `id` is required when calling `deleteABTest`.");var a={method:"DELETE",path:"/2/abtests/{id}".replace("{id}",encodeURIComponent(t)),queryParameters:{},headers:{}};return l.request(a,r)},get:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `get`.");var n={method:"GET",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return l.request(n,r)},getABTest:function(e,r){var t=e.id;if(!t)throw new Error("Parameter `id` is required when calling `getABTest`.");var a={method:"GET",path:"/2/abtests/{id}".replace("{id}",encodeURIComponent(t)),queryParameters:{},headers:{}};return l.request(a,r)},listABTests:function(e,r){var t=e.offset,a=e.limit,n={};void 0!==t&&(n.offset=t.toString()),void 0!==a&&(n.limit=a.toString());var i={method:"GET",path:"/2/abtests",queryParameters:n,headers:{}};return l.request(i,r)},post:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `post`.");var i={method:"POST",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return l.request(i,r)},put:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `put`.");var i={method:"PUT",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return l.request(i,r)},stopABTest:function(e,r){var t=e.id;if(!t)throw new Error("Parameter `id` is required when calling `stopABTest`.");var a={method:"POST",path:"/2/abtests/{id}/stop".replace("{id}",encodeURIComponent(t)),queryParameters:{},headers:{}};return l.request(a,r)}}}var x=["appId","apiKey","authMode","algoliaAgents","region"];function T(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);r&&(a=a.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,a)}return t}function O(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?T(Object(a),!0).forEach((function(t){r(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):T(Object(a)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(a,r))}))}return e}var D=["de","us"];function I(e){var r,n=e.appId,i=e.apiKey,o=e.authMode,s=e.algoliaAgents,c=e.region,d=t(e,x),u=a(n,i,o),l=v(O(O({hosts:(r=c,[{url:r?"analytics.{region}.algolia.com".replace("{region}",r):"analytics.algolia.com",accept:"readWrite",protocol:"https"}])},d),{},{algoliaAgent:y({algoliaAgents:s,client:"Analytics",version:"5.0.0-alpha.5"}),baseHeaders:O(O({"content-type":"text/plain"},u.headers()),d.baseHeaders),baseQueryParameters:O(O({},u.queryParameters()),d.baseQueryParameters)}));return{transporter:l,appId:n,clearCache:function(){return Promise.all([l.requestsCache.clear(),l.responsesCache.clear()]).then((function(){}))},get _ua(){return l.algoliaAgent.value},addAlgoliaAgent:function(e,r){l.algoliaAgent.add({segment:e,version:r})},del:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `del`.");var n={method:"DELETE",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return l.request(n,r)},get:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `get`.");var n={method:"GET",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return l.request(n,r)},getAverageClickPosition:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getAverageClickPosition`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/clicks/averageClickPosition",queryParameters:o,headers:{}};return l.request(s,r)},getClickPositions:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getClickPositions`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/clicks/positions",queryParameters:o,headers:{}};return l.request(s,r)},getClickThroughRate:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getClickThroughRate`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/clicks/clickThroughRate",queryParameters:o,headers:{}};return l.request(s,r)},getConversationRate:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getConversationRate`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/conversions/conversionRate",queryParameters:o,headers:{}};return l.request(s,r)},getNoClickRate:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getNoClickRate`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/searches/noClickRate",queryParameters:o,headers:{}};return l.request(s,r)},getNoResultsRate:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getNoResultsRate`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/searches/noResultRate",queryParameters:o,headers:{}};return l.request(s,r)},getSearchesCount:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getSearchesCount`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/searches/count",queryParameters:o,headers:{}};return l.request(s,r)},getSearchesNoClicks:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.limit,o=e.offset,s=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getSearchesNoClicks`.");var c={};void 0!==t&&(c.index=t.toString()),void 0!==a&&(c.startDate=a.toString()),void 0!==n&&(c.endDate=n.toString()),void 0!==i&&(c.limit=i.toString()),void 0!==o&&(c.offset=o.toString()),void 0!==s&&(c.tags=s.toString());var d={method:"GET",path:"/2/searches/noClicks",queryParameters:c,headers:{}};return l.request(d,r)},getSearchesNoResults:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.limit,o=e.offset,s=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getSearchesNoResults`.");var c={};void 0!==t&&(c.index=t.toString()),void 0!==a&&(c.startDate=a.toString()),void 0!==n&&(c.endDate=n.toString()),void 0!==i&&(c.limit=i.toString()),void 0!==o&&(c.offset=o.toString()),void 0!==s&&(c.tags=s.toString());var d={method:"GET",path:"/2/searches/noResults",queryParameters:c,headers:{}};return l.request(d,r)},getStatus:function(e,r){var t=e.index;if(!t)throw new Error("Parameter `index` is required when calling `getStatus`.");var a={};void 0!==t&&(a.index=t.toString());var n={method:"GET",path:"/2/status",queryParameters:a,headers:{}};return l.request(n,r)},getTopCountries:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.limit,o=e.offset,s=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getTopCountries`.");var c={};void 0!==t&&(c.index=t.toString()),void 0!==a&&(c.startDate=a.toString()),void 0!==n&&(c.endDate=n.toString()),void 0!==i&&(c.limit=i.toString()),void 0!==o&&(c.offset=o.toString()),void 0!==s&&(c.tags=s.toString());var d={method:"GET",path:"/2/countries",queryParameters:c,headers:{}};return l.request(d,r)},getTopFilterAttributes:function(e,r){var t=e.index,a=e.search,n=e.startDate,i=e.endDate,o=e.limit,s=e.offset,c=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getTopFilterAttributes`.");var d={};void 0!==t&&(d.index=t.toString()),void 0!==a&&(d.search=a.toString()),void 0!==n&&(d.startDate=n.toString()),void 0!==i&&(d.endDate=i.toString()),void 0!==o&&(d.limit=o.toString()),void 0!==s&&(d.offset=s.toString()),void 0!==c&&(d.tags=c.toString());var u={method:"GET",path:"/2/filters",queryParameters:d,headers:{}};return l.request(u,r)},getTopFilterForAttribute:function(e,r){var t=e.attribute,a=e.index,n=e.search,i=e.startDate,o=e.endDate,s=e.limit,c=e.offset,d=e.tags;if(!t)throw new Error("Parameter `attribute` is required when calling `getTopFilterForAttribute`.");if(!a)throw new Error("Parameter `index` is required when calling `getTopFilterForAttribute`.");var u="/2/filters/{attribute}".replace("{attribute}",encodeURIComponent(t)),h={};void 0!==a&&(h.index=a.toString()),void 0!==n&&(h.search=n.toString()),void 0!==i&&(h.startDate=i.toString()),void 0!==o&&(h.endDate=o.toString()),void 0!==s&&(h.limit=s.toString()),void 0!==c&&(h.offset=c.toString()),void 0!==d&&(h.tags=d.toString());var m={method:"GET",path:u,queryParameters:h,headers:{}};return l.request(m,r)},getTopFiltersNoResults:function(e,r){var t=e.index,a=e.search,n=e.startDate,i=e.endDate,o=e.limit,s=e.offset,c=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getTopFiltersNoResults`.");var d={};void 0!==t&&(d.index=t.toString()),void 0!==a&&(d.search=a.toString()),void 0!==n&&(d.startDate=n.toString()),void 0!==i&&(d.endDate=i.toString()),void 0!==o&&(d.limit=o.toString()),void 0!==s&&(d.offset=s.toString()),void 0!==c&&(d.tags=c.toString());var u={method:"GET",path:"/2/filters/noResults",queryParameters:d,headers:{}};return l.request(u,r)},getTopHits:function(e,r){var t=e.index,a=e.search,n=e.clickAnalytics,i=e.startDate,o=e.endDate,s=e.limit,c=e.offset,d=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getTopHits`.");var u={};void 0!==t&&(u.index=t.toString()),void 0!==a&&(u.search=a.toString()),void 0!==n&&(u.clickAnalytics=n.toString()),void 0!==i&&(u.startDate=i.toString()),void 0!==o&&(u.endDate=o.toString()),void 0!==s&&(u.limit=s.toString()),void 0!==c&&(u.offset=c.toString()),void 0!==d&&(u.tags=d.toString());var h={method:"GET",path:"/2/hits",queryParameters:u,headers:{}};return l.request(h,r)},getTopSearches:function(e,r){var t=e.index,a=e.clickAnalytics,n=e.startDate,i=e.endDate,o=e.orderBy,s=e.direction,c=e.limit,d=e.offset,u=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getTopSearches`.");var h={};void 0!==t&&(h.index=t.toString()),void 0!==a&&(h.clickAnalytics=a.toString()),void 0!==n&&(h.startDate=n.toString()),void 0!==i&&(h.endDate=i.toString()),void 0!==o&&(h.orderBy=o.toString()),void 0!==s&&(h.direction=s.toString()),void 0!==c&&(h.limit=c.toString()),void 0!==d&&(h.offset=d.toString()),void 0!==u&&(h.tags=u.toString());var m={method:"GET",path:"/2/searches",queryParameters:h,headers:{}};return l.request(m,r)},getUsersCount:function(e,r){var t=e.index,a=e.startDate,n=e.endDate,i=e.tags;if(!t)throw new Error("Parameter `index` is required when calling `getUsersCount`.");var o={};void 0!==t&&(o.index=t.toString()),void 0!==a&&(o.startDate=a.toString()),void 0!==n&&(o.endDate=n.toString()),void 0!==i&&(o.tags=i.toString());var s={method:"GET",path:"/2/users/count",queryParameters:o,headers:{}};return l.request(s,r)},post:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `post`.");var i={method:"POST",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return l.request(i,r)},put:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `put`.");var i={method:"PUT",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return l.request(i,r)}}}var N=["appId","apiKey","authMode","algoliaAgents","region"];function j(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);r&&(a=a.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,a)}return t}function R(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?j(Object(a),!0).forEach((function(t){r(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):j(Object(a)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(a,r))}))}return e}var U=["eu","us"];function A(e){return A="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},A(e)}var C=["appId","apiKey","authMode","algoliaAgents"],k=["indexName","browseRequest"],G=["indexName","searchRulesParams"],K=["indexName","validate","aggregator"],B=["params"];function H(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);r&&(a=a.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,a)}return t}function z(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?H(Object(a),!0).forEach((function(t){r(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):H(Object(a)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(a,r))}))}return e}var F="5.0.0-alpha.5";function L(e){return[{url:"".concat(e,"-dsn.algolia.net"),accept:"read",protocol:"https"},{url:"".concat(e,".algolia.net"),accept:"write",protocol:"https"}].concat(function(e){const r=e;for(let t=e.length-1;t>0;t--){const a=Math.floor(Math.random()*(t+1)),n=e[t];r[t]=e[a],r[a]=n}return r}([{url:"".concat(e,"-1.algolianet.com"),accept:"readWrite",protocol:"https"},{url:"".concat(e,"-2.algolianet.com"),accept:"readWrite",protocol:"https"},{url:"".concat(e,"-3.algolianet.com"),accept:"readWrite",protocol:"https"}]))}function M(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);r&&(a=a.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,a)}return t}function J(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?M(Object(a),!0).forEach((function(t){r(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):M(Object(a)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(a,r))}))}return e}var Q=F;e.algoliasearch=function(e,r,c){if(!e||"string"!=typeof e)throw new Error("`appId` is missing.");if(!r||"string"!=typeof r)throw new Error("`apiKey` is missing.");var d=J({apiKey:r,appId:e,timeouts:{connect:1e3,read:2e3,write:3e4},requester:{send:function(e){return new Promise((r=>{const t=new XMLHttpRequest;t.open(e.method,e.url,!0),Object.keys(e.headers).forEach((r=>t.setRequestHeader(r,e.headers[r])));const a=(e,a)=>setTimeout((()=>{t.abort(),r({status:0,content:a,isTimedOut:!0})}),e),n=a(e.connectTimeout,"Connection timeout");let i;t.onreadystatechange=()=>{t.readyState>t.OPENED&&void 0===i&&(clearTimeout(n),i=a(e.responseTimeout,"Socket timeout"))},t.onerror=()=>{0===t.status&&(clearTimeout(n),clearTimeout(i),r({content:t.responseText||"Network request failed",status:t.status,isTimedOut:!1}))},t.onload=()=>{clearTimeout(n),clearTimeout(i),r({content:t.responseText,status:t.status,isTimedOut:!1})},t.send(e.data)}))}},algoliaAgents:[{segment:"Browser"}],authMode:"WithinQueryParameters",responsesCache:s(),requestsCache:s({serializable:!1}),hostsCache:o({caches:[i({key:"".concat(Q,"-").concat(e)}),s()]})},c);return J(J({},function(e){var r=e.appId,i=e.apiKey,o=e.authMode,s=e.algoliaAgents,c=t(e,C),d=a(r,i,o),u=v(z(z({hosts:L(r)},c),{},{algoliaAgent:y({algoliaAgents:s,client:"Search",version:F}),baseHeaders:z(z({"content-type":"text/plain"},d.headers()),c.baseHeaders),baseQueryParameters:z(z({},d.queryParameters()),c.baseQueryParameters)}));return{transporter:u,appId:r,clearCache:function(){return Promise.all([u.requestsCache.clear(),u.responsesCache.clear()]).then((function(){}))},get _ua(){return u.algoliaAgent.value},addAlgoliaAgent:function(e,r){u.algoliaAgent.add({segment:e,version:r})},waitForTask:function(e,r){var t=this,a=e.indexName,i=e.taskID,o=e.maxRetries,s=void 0===o?50:o,c=e.timeout,d=void 0===c?function(e){return Math.min(200*e,5e3)}:c,u=0;return n({func:function(){return t.getTask({indexName:a,taskID:i},r)},validate:function(e){return"published"===e.status},aggregator:function(){return u+=1},error:{validate:function(){return u>=s},message:function(){return"The maximum number of retries exceeded. (".concat(u,"/").concat(s,")")}},timeout:function(){return d(u)}})},waitForApiKey:function(e,r){var t=this,a=e.operation,i=e.key,o=e.apiKey,s=e.maxRetries,c=void 0===s?50:s,d=e.timeout,u=void 0===d?function(e){return Math.min(200*e,5e3)}:d,l=0,h={aggregator:function(){return l+=1},error:{validate:function(){return l>=c},message:function(){return"The maximum number of retries exceeded. (".concat(l,"/").concat(c,")")}},timeout:function(){return u(l)}};if("update"===a){if(!o)throw new Error("`apiKey` is required when waiting for an `update` operation.");return n(z(z({},h),{},{func:function(){return t.getApiKey({key:i},r)},validate:function(e){for(var r=function(){var r=a[t];if(Array.isArray(o[r])){if(o[r].length!==e[r].length||o[r].some((function(t,a){return t!==e[r][a]})))return{v:!1}}else if(e[r]!==o[r])return{v:!1}},t=0,a=Object.keys(o);t<a.length;t++){var n=r();if("object"===A(n))return n.v}return!0}}))}return n(z(z({},h),{},{func:function(){return t.getApiKey({key:i},r).catch((function(e){return e}))},validate:function(e){return"add"===a?404!==e.status:404===e.status}}))},browseObjects:function(e,r){var a=this,i=e.indexName,o=e.browseRequest;return n(z({func:function(e){return a.browse({indexName:i,browseRequest:z({cursor:e?e.cursor:void 0},o)},r)},validate:function(e){return void 0===e.cursor}},t(e,k)))},browseRules:function(e,r){var a=this,i=e.indexName,o=e.searchRulesParams,s=t(e,G),c=z({hitsPerPage:1e3},o);return n(z({func:function(e){return a.searchRules({indexName:i,searchRulesParams:z(z({},c),{},{page:e?e.page+1:c.page||0})},r)},validate:function(e){return e.nbHits<c.hitsPerPage}},s))},browseSynonyms:function(e,r){var a=this,i=e.indexName;e.validate,e.aggregator;var o=t(e,K),s=z({hitsPerPage:1e3},o);return n(z({func:function(e){return a.searchSynonyms(z(z({},s),{},{indexName:i,page:e?e.page+1:o.page||0}),r)},validate:function(e){return e.nbHits<s.hitsPerPage}},o))},addApiKey:function(e,r){if(!e)throw new Error("Parameter `apiKey` is required when calling `addApiKey`.");if(!e.acl)throw new Error("Parameter `apiKey.acl` is required when calling `addApiKey`.");var t={method:"POST",path:"/1/keys",queryParameters:{},headers:{},data:e};return u.request(t,r)},addOrUpdateObject:function(e,r){var t=e.indexName,a=e.objectID,n=e.body;if(!t)throw new Error("Parameter `indexName` is required when calling `addOrUpdateObject`.");if(!a)throw new Error("Parameter `objectID` is required when calling `addOrUpdateObject`.");if(!n)throw new Error("Parameter `body` is required when calling `addOrUpdateObject`.");var i={method:"PUT",path:"/1/indexes/{indexName}/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),queryParameters:{},headers:{},data:n};return u.request(i,r)},appendSource:function(e,r){if(!e)throw new Error("Parameter `source` is required when calling `appendSource`.");var t={method:"POST",path:"/1/security/sources/append",queryParameters:{},headers:{},data:e};return u.request(t,r)},assignUserId:function(e,r){var t=e.xAlgoliaUserID,a=e.assignUserIdParams;if(!t)throw new Error("Parameter `xAlgoliaUserID` is required when calling `assignUserId`.");if(!a)throw new Error("Parameter `assignUserIdParams` is required when calling `assignUserId`.");if(!a.cluster)throw new Error("Parameter `assignUserIdParams.cluster` is required when calling `assignUserId`.");var n={};void 0!==t&&(n["X-Algolia-User-ID"]=t.toString());var i={method:"POST",path:"/1/clusters/mapping",queryParameters:{},headers:n,data:a};return u.request(i,r)},batch:function(e,r){var t=e.indexName,a=e.batchWriteParams;if(!t)throw new Error("Parameter `indexName` is required when calling `batch`.");if(!a)throw new Error("Parameter `batchWriteParams` is required when calling `batch`.");var n={method:"POST",path:"/1/indexes/{indexName}/batch".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a};return u.request(n,r)},batchAssignUserIds:function(e,r){var t=e.xAlgoliaUserID,a=e.batchAssignUserIdsParams;if(!t)throw new Error("Parameter `xAlgoliaUserID` is required when calling `batchAssignUserIds`.");if(!a)throw new Error("Parameter `batchAssignUserIdsParams` is required when calling `batchAssignUserIds`.");if(!a.cluster)throw new Error("Parameter `batchAssignUserIdsParams.cluster` is required when calling `batchAssignUserIds`.");if(!a.users)throw new Error("Parameter `batchAssignUserIdsParams.users` is required when calling `batchAssignUserIds`.");var n={};void 0!==t&&(n["X-Algolia-User-ID"]=t.toString());var i={method:"POST",path:"/1/clusters/mapping/batch",queryParameters:{},headers:n,data:a};return u.request(i,r)},batchDictionaryEntries:function(e,r){var t=e.dictionaryName,a=e.batchDictionaryEntriesParams;if(!t)throw new Error("Parameter `dictionaryName` is required when calling `batchDictionaryEntries`.");if(!a)throw new Error("Parameter `batchDictionaryEntriesParams` is required when calling `batchDictionaryEntries`.");if(!a.requests)throw new Error("Parameter `batchDictionaryEntriesParams.requests` is required when calling `batchDictionaryEntries`.");var n={method:"POST",path:"/1/dictionaries/{dictionaryName}/batch".replace("{dictionaryName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a};return u.request(n,r)},browse:function(e,r){var t=e.indexName,a=e.browseRequest;if(!t)throw new Error("Parameter `indexName` is required when calling `browse`.");var n={method:"POST",path:"/1/indexes/{indexName}/browse".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a||{}};return u.request(n,r)},clearAllSynonyms:function(e,r){var t=e.indexName,a=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `clearAllSynonyms`.");var n="/1/indexes/{indexName}/synonyms/clear".replace("{indexName}",encodeURIComponent(t)),i={};void 0!==a&&(i.forwardToReplicas=a.toString());var o={method:"POST",path:n,queryParameters:i,headers:{}};return u.request(o,r)},clearObjects:function(e,r){var t=e.indexName;if(!t)throw new Error("Parameter `indexName` is required when calling `clearObjects`.");var a={method:"POST",path:"/1/indexes/{indexName}/clear".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},clearRules:function(e,r){var t=e.indexName,a=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `clearRules`.");var n="/1/indexes/{indexName}/rules/clear".replace("{indexName}",encodeURIComponent(t)),i={};void 0!==a&&(i.forwardToReplicas=a.toString());var o={method:"POST",path:n,queryParameters:i,headers:{}};return u.request(o,r)},del:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `del`.");var n={method:"DELETE",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return u.request(n,r)},deleteApiKey:function(e,r){var t=e.key;if(!t)throw new Error("Parameter `key` is required when calling `deleteApiKey`.");var a={method:"DELETE",path:"/1/keys/{key}".replace("{key}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},deleteBy:function(e,r){var t=e.indexName,a=e.searchParams;if(!t)throw new Error("Parameter `indexName` is required when calling `deleteBy`.");if(!a)throw new Error("Parameter `searchParams` is required when calling `deleteBy`.");var n={method:"POST",path:"/1/indexes/{indexName}/deleteByQuery".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a};return u.request(n,r)},deleteIndex:function(e,r){var t=e.indexName;if(!t)throw new Error("Parameter `indexName` is required when calling `deleteIndex`.");var a={method:"DELETE",path:"/1/indexes/{indexName}".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},deleteObject:function(e,r){var t=e.indexName,a=e.objectID;if(!t)throw new Error("Parameter `indexName` is required when calling `deleteObject`.");if(!a)throw new Error("Parameter `objectID` is required when calling `deleteObject`.");var n={method:"DELETE",path:"/1/indexes/{indexName}/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),queryParameters:{},headers:{}};return u.request(n,r)},deleteRule:function(e,r){var t=e.indexName,a=e.objectID,n=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `deleteRule`.");if(!a)throw new Error("Parameter `objectID` is required when calling `deleteRule`.");var i="/1/indexes/{indexName}/rules/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),o={};void 0!==n&&(o.forwardToReplicas=n.toString());var s={method:"DELETE",path:i,queryParameters:o,headers:{}};return u.request(s,r)},deleteSource:function(e,r){var t=e.source;if(!t)throw new Error("Parameter `source` is required when calling `deleteSource`.");var a={method:"DELETE",path:"/1/security/sources/{source}".replace("{source}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},deleteSynonym:function(e,r){var t=e.indexName,a=e.objectID,n=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `deleteSynonym`.");if(!a)throw new Error("Parameter `objectID` is required when calling `deleteSynonym`.");var i="/1/indexes/{indexName}/synonyms/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),o={};void 0!==n&&(o.forwardToReplicas=n.toString());var s={method:"DELETE",path:i,queryParameters:o,headers:{}};return u.request(s,r)},get:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `get`.");var n={method:"GET",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return u.request(n,r)},getApiKey:function(e,r){var t=e.key;if(!t)throw new Error("Parameter `key` is required when calling `getApiKey`.");var a={method:"GET",path:"/1/keys/{key}".replace("{key}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},getDictionaryLanguages:function(e){var r={method:"GET",path:"/1/dictionaries/*/languages",queryParameters:{},headers:{}};return u.request(r,e)},getDictionarySettings:function(e){var r={method:"GET",path:"/1/dictionaries/*/settings",queryParameters:{},headers:{}};return u.request(r,e)},getLogs:function(e,r){var t=e.offset,a=e.length,n=e.indexName,i=e.type,o={};void 0!==t&&(o.offset=t.toString()),void 0!==a&&(o.length=a.toString()),void 0!==n&&(o.indexName=n.toString()),void 0!==i&&(o.type=i.toString());var s={method:"GET",path:"/1/logs",queryParameters:o,headers:{}};return u.request(s,r)},getObject:function(e,r){var t=e.indexName,a=e.objectID,n=e.attributesToRetrieve;if(!t)throw new Error("Parameter `indexName` is required when calling `getObject`.");if(!a)throw new Error("Parameter `objectID` is required when calling `getObject`.");var i="/1/indexes/{indexName}/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),o={};void 0!==n&&(o.attributesToRetrieve=n.toString());var s={method:"GET",path:i,queryParameters:o,headers:{}};return u.request(s,r)},getObjects:function(e,r){if(!e)throw new Error("Parameter `getObjectsParams` is required when calling `getObjects`.");if(!e.requests)throw new Error("Parameter `getObjectsParams.requests` is required when calling `getObjects`.");var t={method:"POST",path:"/1/indexes/*/objects",queryParameters:{},headers:{},data:e,useReadTransporter:!0,cacheable:!0};return u.request(t,r)},getRule:function(e,r){var t=e.indexName,a=e.objectID;if(!t)throw new Error("Parameter `indexName` is required when calling `getRule`.");if(!a)throw new Error("Parameter `objectID` is required when calling `getRule`.");var n={method:"GET",path:"/1/indexes/{indexName}/rules/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),queryParameters:{},headers:{}};return u.request(n,r)},getSettings:function(e,r){var t=e.indexName;if(!t)throw new Error("Parameter `indexName` is required when calling `getSettings`.");var a={method:"GET",path:"/1/indexes/{indexName}/settings".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},getSources:function(e){var r={method:"GET",path:"/1/security/sources",queryParameters:{},headers:{}};return u.request(r,e)},getSynonym:function(e,r){var t=e.indexName,a=e.objectID;if(!t)throw new Error("Parameter `indexName` is required when calling `getSynonym`.");if(!a)throw new Error("Parameter `objectID` is required when calling `getSynonym`.");var n={method:"GET",path:"/1/indexes/{indexName}/synonyms/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),queryParameters:{},headers:{}};return u.request(n,r)},getTask:function(e,r){var t=e.indexName,a=e.taskID;if(!t)throw new Error("Parameter `indexName` is required when calling `getTask`.");if(!a)throw new Error("Parameter `taskID` is required when calling `getTask`.");var n={method:"GET",path:"/1/indexes/{indexName}/task/{taskID}".replace("{indexName}",encodeURIComponent(t)).replace("{taskID}",encodeURIComponent(a)),queryParameters:{},headers:{}};return u.request(n,r)},getTopUserIds:function(e){var r={method:"GET",path:"/1/clusters/mapping/top",queryParameters:{},headers:{}};return u.request(r,e)},getUserId:function(e,r){var t=e.userID;if(!t)throw new Error("Parameter `userID` is required when calling `getUserId`.");var a={method:"GET",path:"/1/clusters/mapping/{userID}".replace("{userID}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},hasPendingMappings:function(e,r){var t=e.getClusters,a={};void 0!==t&&(a.getClusters=t.toString());var n={method:"GET",path:"/1/clusters/mapping/pending",queryParameters:a,headers:{}};return u.request(n,r)},listApiKeys:function(e){var r={method:"GET",path:"/1/keys",queryParameters:{},headers:{}};return u.request(r,e)},listClusters:function(e){var r={method:"GET",path:"/1/clusters",queryParameters:{},headers:{}};return u.request(r,e)},listIndices:function(e,r){var t=e.page,a={};void 0!==t&&(a.page=t.toString());var n={method:"GET",path:"/1/indexes",queryParameters:a,headers:{}};return u.request(n,r)},listUserIds:function(e,r){var t=e.page,a=e.hitsPerPage,n={};void 0!==t&&(n.page=t.toString()),void 0!==a&&(n.hitsPerPage=a.toString());var i={method:"GET",path:"/1/clusters/mapping",queryParameters:n,headers:{}};return u.request(i,r)},multipleBatch:function(e,r){if(!e)throw new Error("Parameter `batchParams` is required when calling `multipleBatch`.");if(!e.requests)throw new Error("Parameter `batchParams.requests` is required when calling `multipleBatch`.");var t={method:"POST",path:"/1/indexes/*/batch",queryParameters:{},headers:{},data:e};return u.request(t,r)},operationIndex:function(e,r){var t=e.indexName,a=e.operationIndexParams;if(!t)throw new Error("Parameter `indexName` is required when calling `operationIndex`.");if(!a)throw new Error("Parameter `operationIndexParams` is required when calling `operationIndex`.");if(!a.operation)throw new Error("Parameter `operationIndexParams.operation` is required when calling `operationIndex`.");if(!a.destination)throw new Error("Parameter `operationIndexParams.destination` is required when calling `operationIndex`.");var n={method:"POST",path:"/1/indexes/{indexName}/operation".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a};return u.request(n,r)},partialUpdateObject:function(e,r){var t=e.indexName,a=e.objectID,n=e.attributesToUpdate,i=e.createIfNotExists;if(!t)throw new Error("Parameter `indexName` is required when calling `partialUpdateObject`.");if(!a)throw new Error("Parameter `objectID` is required when calling `partialUpdateObject`.");if(!n)throw new Error("Parameter `attributesToUpdate` is required when calling `partialUpdateObject`.");var o="/1/indexes/{indexName}/{objectID}/partial".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),s={};void 0!==i&&(s.createIfNotExists=i.toString());var c={method:"POST",path:o,queryParameters:s,headers:{},data:n};return u.request(c,r)},post:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `post`.");var i={method:"POST",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return u.request(i,r)},put:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `put`.");var i={method:"PUT",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return u.request(i,r)},removeUserId:function(e,r){var t=e.userID;if(!t)throw new Error("Parameter `userID` is required when calling `removeUserId`.");var a={method:"DELETE",path:"/1/clusters/mapping/{userID}".replace("{userID}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},replaceSources:function(e,r){var t=e.source;if(!t)throw new Error("Parameter `source` is required when calling `replaceSources`.");var a={method:"PUT",path:"/1/security/sources",queryParameters:{},headers:{},data:t};return u.request(a,r)},restoreApiKey:function(e,r){var t=e.key;if(!t)throw new Error("Parameter `key` is required when calling `restoreApiKey`.");var a={method:"POST",path:"/1/keys/{key}/restore".replace("{key}",encodeURIComponent(t)),queryParameters:{},headers:{}};return u.request(a,r)},saveObject:function(e,r){var t=e.indexName,a=e.body;if(!t)throw new Error("Parameter `indexName` is required when calling `saveObject`.");if(!a)throw new Error("Parameter `body` is required when calling `saveObject`.");var n={method:"POST",path:"/1/indexes/{indexName}".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a};return u.request(n,r)},saveRule:function(e,r){var t=e.indexName,a=e.objectID,n=e.rule,i=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `saveRule`.");if(!a)throw new Error("Parameter `objectID` is required when calling `saveRule`.");if(!n)throw new Error("Parameter `rule` is required when calling `saveRule`.");if(!n.objectID)throw new Error("Parameter `rule.objectID` is required when calling `saveRule`.");var o="/1/indexes/{indexName}/rules/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),s={};void 0!==i&&(s.forwardToReplicas=i.toString());var c={method:"PUT",path:o,queryParameters:s,headers:{},data:n};return u.request(c,r)},saveRules:function(e,r){var t=e.indexName,a=e.rules,n=e.forwardToReplicas,i=e.clearExistingRules;if(!t)throw new Error("Parameter `indexName` is required when calling `saveRules`.");if(!a)throw new Error("Parameter `rules` is required when calling `saveRules`.");var o="/1/indexes/{indexName}/rules/batch".replace("{indexName}",encodeURIComponent(t)),s={};void 0!==n&&(s.forwardToReplicas=n.toString()),void 0!==i&&(s.clearExistingRules=i.toString());var c={method:"POST",path:o,queryParameters:s,headers:{},data:a};return u.request(c,r)},saveSynonym:function(e,r){var t=e.indexName,a=e.objectID,n=e.synonymHit,i=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `saveSynonym`.");if(!a)throw new Error("Parameter `objectID` is required when calling `saveSynonym`.");if(!n)throw new Error("Parameter `synonymHit` is required when calling `saveSynonym`.");if(!n.objectID)throw new Error("Parameter `synonymHit.objectID` is required when calling `saveSynonym`.");var o="/1/indexes/{indexName}/synonyms/{objectID}".replace("{indexName}",encodeURIComponent(t)).replace("{objectID}",encodeURIComponent(a)),s={};void 0!==i&&(s.forwardToReplicas=i.toString());var c={method:"PUT",path:o,queryParameters:s,headers:{},data:n};return u.request(c,r)},saveSynonyms:function(e,r){var t=e.indexName,a=e.synonymHit,n=e.forwardToReplicas,i=e.replaceExistingSynonyms;if(!t)throw new Error("Parameter `indexName` is required when calling `saveSynonyms`.");if(!a)throw new Error("Parameter `synonymHit` is required when calling `saveSynonyms`.");var o="/1/indexes/{indexName}/synonyms/batch".replace("{indexName}",encodeURIComponent(t)),s={};void 0!==n&&(s.forwardToReplicas=n.toString()),void 0!==i&&(s.replaceExistingSynonyms=i.toString());var c={method:"POST",path:o,queryParameters:s,headers:{},data:a};return u.request(c,r)},search:function(e,r){if(e&&Array.isArray(e)){var a={requests:e.map((function(e){var r=e.params,a=t(e,B);return"facet"===a.type?z(z(z({},a),r),{},{type:"facet"}):z(z(z({},a),r),{},{facet:void 0,maxFacetHits:void 0,facetQuery:void 0})}))};e=a}if(!e)throw new Error("Parameter `searchMethodParams` is required when calling `search`.");if(!e.requests)throw new Error("Parameter `searchMethodParams.requests` is required when calling `search`.");var n={method:"POST",path:"/1/indexes/*/queries",queryParameters:{},headers:{},data:e,useReadTransporter:!0,cacheable:!0};return u.request(n,r)},searchDictionaryEntries:function(e,r){var t=e.dictionaryName,a=e.searchDictionaryEntriesParams;if(!t)throw new Error("Parameter `dictionaryName` is required when calling `searchDictionaryEntries`.");if(!a)throw new Error("Parameter `searchDictionaryEntriesParams` is required when calling `searchDictionaryEntries`.");if(!a.query)throw new Error("Parameter `searchDictionaryEntriesParams.query` is required when calling `searchDictionaryEntries`.");var n={method:"POST",path:"/1/dictionaries/{dictionaryName}/search".replace("{dictionaryName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a,useReadTransporter:!0,cacheable:!0};return u.request(n,r)},searchForFacetValues:function(e,r){var t=e.indexName,a=e.facetName,n=e.searchForFacetValuesRequest;if(!t)throw new Error("Parameter `indexName` is required when calling `searchForFacetValues`.");if(!a)throw new Error("Parameter `facetName` is required when calling `searchForFacetValues`.");var i={method:"POST",path:"/1/indexes/{indexName}/facets/{facetName}/query".replace("{indexName}",encodeURIComponent(t)).replace("{facetName}",encodeURIComponent(a)),queryParameters:{},headers:{},data:n||{},useReadTransporter:!0,cacheable:!0};return u.request(i,r)},searchRules:function(e,r){var t=e.indexName,a=e.searchRulesParams;if(!t)throw new Error("Parameter `indexName` is required when calling `searchRules`.");var n={method:"POST",path:"/1/indexes/{indexName}/rules/search".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a||{},useReadTransporter:!0,cacheable:!0};return u.request(n,r)},searchSingleIndex:function(e,r){var t=e.indexName,a=e.searchParams;if(!t)throw new Error("Parameter `indexName` is required when calling `searchSingleIndex`.");var n={method:"POST",path:"/1/indexes/{indexName}/query".replace("{indexName}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a||{},useReadTransporter:!0,cacheable:!0};return u.request(n,r)},searchSynonyms:function(e,r){var t=e.indexName,a=e.type,n=e.page,i=e.hitsPerPage,o=e.searchSynonymsParams;if(!t)throw new Error("Parameter `indexName` is required when calling `searchSynonyms`.");var s="/1/indexes/{indexName}/synonyms/search".replace("{indexName}",encodeURIComponent(t)),c={};void 0!==a&&(c.type=a.toString()),void 0!==n&&(c.page=n.toString()),void 0!==i&&(c.hitsPerPage=i.toString());var d={method:"POST",path:s,queryParameters:c,headers:{},data:o||{},useReadTransporter:!0,cacheable:!0};return u.request(d,r)},searchUserIds:function(e,r){if(!e)throw new Error("Parameter `searchUserIdsParams` is required when calling `searchUserIds`.");if(!e.query)throw new Error("Parameter `searchUserIdsParams.query` is required when calling `searchUserIds`.");var t={method:"POST",path:"/1/clusters/mapping/search",queryParameters:{},headers:{},data:e,useReadTransporter:!0,cacheable:!0};return u.request(t,r)},setDictionarySettings:function(e,r){if(!e)throw new Error("Parameter `dictionarySettingsParams` is required when calling `setDictionarySettings`.");if(!e.disableStandardEntries)throw new Error("Parameter `dictionarySettingsParams.disableStandardEntries` is required when calling `setDictionarySettings`.");var t={method:"PUT",path:"/1/dictionaries/*/settings",queryParameters:{},headers:{},data:e};return u.request(t,r)},setSettings:function(e,r){var t=e.indexName,a=e.indexSettings,n=e.forwardToReplicas;if(!t)throw new Error("Parameter `indexName` is required when calling `setSettings`.");if(!a)throw new Error("Parameter `indexSettings` is required when calling `setSettings`.");var i="/1/indexes/{indexName}/settings".replace("{indexName}",encodeURIComponent(t)),o={};void 0!==n&&(o.forwardToReplicas=n.toString());var s={method:"PUT",path:i,queryParameters:o,headers:{},data:a};return u.request(s,r)},updateApiKey:function(e,r){var t=e.key,a=e.apiKey;if(!t)throw new Error("Parameter `key` is required when calling `updateApiKey`.");if(!a)throw new Error("Parameter `apiKey` is required when calling `updateApiKey`.");if(!a.acl)throw new Error("Parameter `apiKey.acl` is required when calling `updateApiKey`.");var n={method:"PUT",path:"/1/keys/{key}".replace("{key}",encodeURIComponent(t)),queryParameters:{},headers:{},data:a};return u.request(n,r)}}}(d)),{},{get _ua(){return this.transporter.algoliaAgent.value},initAnalytics:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(e.region&&("string"!=typeof e.region||!D.includes(e.region)))throw new Error("`region` must be one of the following: ".concat(D.join(", ")));return I(J(J(J({},d),e.options),e))},initPersonalization:function(e){if(!e.region)throw new Error("`region` is missing.");if(e.region&&("string"!=typeof e.region||!U.includes(e.region)))throw new Error("`region` must be one of the following: ".concat(U.join(", ")));return function(e){var r,n=e.appId,i=e.apiKey,o=e.authMode,s=e.algoliaAgents,c=e.region,d=t(e,N),u=a(n,i,o),l=v(R(R({hosts:(r=c,[{url:"personalization.{region}.algolia.com".replace("{region}",r),accept:"readWrite",protocol:"https"}])},d),{},{algoliaAgent:y({algoliaAgents:s,client:"Personalization",version:"5.0.0-alpha.5"}),baseHeaders:R(R({"content-type":"text/plain"},u.headers()),d.baseHeaders),baseQueryParameters:R(R({},u.queryParameters()),d.baseQueryParameters)}));return{transporter:l,appId:n,clearCache:function(){return Promise.all([l.requestsCache.clear(),l.responsesCache.clear()]).then((function(){}))},get _ua(){return l.algoliaAgent.value},addAlgoliaAgent:function(e,r){l.algoliaAgent.add({segment:e,version:r})},del:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `del`.");var n={method:"DELETE",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return l.request(n,r)},deleteUserProfile:function(e,r){var t=e.userToken;if(!t)throw new Error("Parameter `userToken` is required when calling `deleteUserProfile`.");var a={method:"DELETE",path:"/1/profiles/{userToken}".replace("{userToken}",encodeURIComponent(t)),queryParameters:{},headers:{}};return l.request(a,r)},get:function(e,r){var t=e.path,a=e.parameters;if(!t)throw new Error("Parameter `path` is required when calling `get`.");var n={method:"GET",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{}};return l.request(n,r)},getPersonalizationStrategy:function(e){var r={method:"GET",path:"/1/strategies/personalization",queryParameters:{},headers:{}};return l.request(r,e)},getUserTokenProfile:function(e,r){var t=e.userToken;if(!t)throw new Error("Parameter `userToken` is required when calling `getUserTokenProfile`.");var a={method:"GET",path:"/1/profiles/personalization/{userToken}".replace("{userToken}",encodeURIComponent(t)),queryParameters:{},headers:{}};return l.request(a,r)},post:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `post`.");var i={method:"POST",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return l.request(i,r)},put:function(e,r){var t=e.path,a=e.parameters,n=e.body;if(!t)throw new Error("Parameter `path` is required when calling `put`.");var i={method:"PUT",path:"/1{path}".replace("{path}",t),queryParameters:a||{},headers:{},data:n||{}};return l.request(i,r)},setPersonalizationStrategy:function(e,r){if(!e)throw new Error("Parameter `personalizationStrategyParams` is required when calling `setPersonalizationStrategy`.");if(!e.eventScoring)throw new Error("Parameter `personalizationStrategyParams.eventScoring` is required when calling `setPersonalizationStrategy`.");if(!e.facetScoring)throw new Error("Parameter `personalizationStrategyParams.facetScoring` is required when calling `setPersonalizationStrategy`.");if(!e.personalizationImpact)throw new Error("Parameter `personalizationStrategyParams.personalizationImpact` is required when calling `setPersonalizationStrategy`.");var t={method:"POST",path:"/1/strategies/personalization",queryParameters:{},headers:{},data:e};return l.request(t,r)}}}(J(J(J({},d),e.options),e))},initAbtesting:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(e.region&&("string"!=typeof e.region||!E.includes(e.region)))throw new Error("`region` must be one of the following: ".concat(E.join(", ")));return S(J(J(J({},d),e.options),e))}})},e.apiClientVersion=Q}));
|
package/dist/builds/browser.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import type { ClientOptions } from '@algolia/client-common';
|
|
|
4
4
|
import type { Region as PersonalizationRegion, PersonalizationClient } from '@algolia/client-personalization/src/personalizationClient';
|
|
5
5
|
import type { InitClientOptions, InitClientRegion } from './models';
|
|
6
6
|
export * from './models';
|
|
7
|
-
export declare const apiClientVersion = "5.0.0-alpha.
|
|
7
|
+
export declare const apiClientVersion = "5.0.0-alpha.5";
|
|
8
8
|
/**
|
|
9
9
|
* The client type.
|
|
10
10
|
*/
|
|
@@ -19,7 +19,7 @@ export declare function algoliasearch(appId: string, apiKey: string, options?: C
|
|
|
19
19
|
clearCache(): Promise<void>;
|
|
20
20
|
addAlgoliaAgent(segment: string, version?: string | undefined): void;
|
|
21
21
|
waitForTask({ indexName, taskID, maxRetries, timeout, }: import("@algolia/client-search/model/clientMethodProps").WaitForTaskOptions, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/getTaskResponse").GetTaskResponse>;
|
|
22
|
-
waitForApiKey({ operation, key, apiKey, maxRetries, timeout, }: import("@algolia/client-search/model/clientMethodProps").WaitForApiKeyOptions, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-
|
|
22
|
+
waitForApiKey({ operation, key, apiKey, maxRetries, timeout, }: import("@algolia/client-search/model/clientMethodProps").WaitForApiKeyOptions, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-common").ApiError | import("@algolia/client-search/model/getApiKeyResponse").GetApiKeyResponse>;
|
|
23
23
|
browseObjects<T>({ indexName, browseRequest, ...browseObjectsOptions }: Partial<Pick<import("@algolia/client-common").CreateIterablePromise<import("@algolia/client-search/model/browseResponse").BrowseResponse<T>>, "validate">> & Required<Pick<import("@algolia/client-common").CreateIterablePromise<import("@algolia/client-search/model/browseResponse").BrowseResponse<T>>, "aggregator">> & import("@algolia/client-search/model/clientMethodProps").BrowseProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/browseResponse").BrowseResponse<T>>;
|
|
24
24
|
browseRules({ indexName, searchRulesParams, ...browseRulesOptions }: Partial<Pick<import("@algolia/client-common").CreateIterablePromise<import("@algolia/client-search/model/searchRulesResponse").SearchRulesResponse>, "validate">> & Required<Pick<import("@algolia/client-common").CreateIterablePromise<import("@algolia/client-search/model/searchRulesResponse").SearchRulesResponse>, "aggregator">> & import("@algolia/client-search/model/clientMethodProps").SearchRulesProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/searchRulesResponse").SearchRulesResponse>;
|
|
25
25
|
browseSynonyms({ indexName, validate, aggregator, ...browseSynonymsOptions }: Partial<Pick<import("@algolia/client-common").CreateIterablePromise<import("@algolia/client-search/model/searchSynonymsResponse").SearchSynonymsResponse>, "validate">> & Required<Pick<import("@algolia/client-common").CreateIterablePromise<import("@algolia/client-search/model/searchSynonymsResponse").SearchSynonymsResponse>, "aggregator">> & import("@algolia/client-search/model/clientMethodProps").SearchSynonymsProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/searchSynonymsResponse").SearchSynonymsResponse>;
|
|
@@ -63,7 +63,7 @@ export declare function algoliasearch(appId: string, apiKey: string, options?: C
|
|
|
63
63
|
listUserIds({ page, hitsPerPage }: import("@algolia/client-search/model/clientMethodProps").ListUserIdsProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/listUserIdsResponse").ListUserIdsResponse>;
|
|
64
64
|
multipleBatch(batchParams: import("@algolia/client-search/model/batchParams").BatchParams, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/multipleBatchResponse").MultipleBatchResponse>;
|
|
65
65
|
operationIndex({ indexName, operationIndexParams }: import("@algolia/client-search/model/clientMethodProps").OperationIndexProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/updatedAtResponse").UpdatedAtResponse>;
|
|
66
|
-
partialUpdateObject({ indexName, objectID,
|
|
66
|
+
partialUpdateObject({ indexName, objectID, attributesToUpdate, createIfNotExists, }: import("@algolia/client-search/model/clientMethodProps").PartialUpdateObjectProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/updatedAtWithObjectIdResponse").UpdatedAtWithObjectIdResponse>;
|
|
67
67
|
post({ path, parameters, body }: import("@algolia/client-search/model/clientMethodProps").PostProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<Record<string, any>>;
|
|
68
68
|
put({ path, parameters, body }: import("@algolia/client-search/model/clientMethodProps").PutProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<Record<string, any>>;
|
|
69
69
|
removeUserId({ userID }: import("@algolia/client-search/model/clientMethodProps").RemoveUserIdProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/removeUserIdResponse").RemoveUserIdResponse>;
|
|
@@ -71,7 +71,7 @@ export declare function algoliasearch(appId: string, apiKey: string, options?: C
|
|
|
71
71
|
restoreApiKey({ key }: import("@algolia/client-search/model/clientMethodProps").RestoreApiKeyProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/addApiKeyResponse").AddApiKeyResponse>;
|
|
72
72
|
saveObject({ indexName, body }: import("@algolia/client-search/model/clientMethodProps").SaveObjectProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/saveObjectResponse").SaveObjectResponse>;
|
|
73
73
|
saveRule({ indexName, objectID, rule, forwardToReplicas }: import("@algolia/client-search/model/clientMethodProps").SaveRuleProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/updatedRuleResponse").UpdatedRuleResponse>;
|
|
74
|
-
saveRules({ indexName,
|
|
74
|
+
saveRules({ indexName, rules, forwardToReplicas, clearExistingRules, }: import("@algolia/client-search/model/clientMethodProps").SaveRulesProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/updatedAtResponse").UpdatedAtResponse>;
|
|
75
75
|
saveSynonym({ indexName, objectID, synonymHit, forwardToReplicas }: import("@algolia/client-search/model/clientMethodProps").SaveSynonymProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/saveSynonymResponse").SaveSynonymResponse>;
|
|
76
76
|
saveSynonyms({ indexName, synonymHit, forwardToReplicas, replaceExistingSynonyms, }: import("@algolia/client-search/model/clientMethodProps").SaveSynonymsProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/updatedAtResponse").UpdatedAtResponse>;
|
|
77
77
|
search<T_3>(searchMethodParams: import("@algolia/client-search/model/clientMethodProps").LegacySearchMethodProps | import("@algolia/client-search/model/searchMethodParams").SearchMethodParams, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/searchResponses").SearchResponses<T_3>>;
|
package/dist/builds/node.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import type { ClientOptions } from '@algolia/client-common';
|
|
|
4
4
|
import type { Region as PersonalizationRegion, PersonalizationClient } from '@algolia/client-personalization/src/personalizationClient';
|
|
5
5
|
import type { InitClientOptions, InitClientRegion } from './models';
|
|
6
6
|
export * from './models';
|
|
7
|
-
export declare const apiClientVersion = "5.0.0-alpha.
|
|
7
|
+
export declare const apiClientVersion = "5.0.0-alpha.5";
|
|
8
8
|
/**
|
|
9
9
|
* The client type.
|
|
10
10
|
*/
|
|
@@ -19,7 +19,7 @@ export declare function algoliasearch(appId: string, apiKey: string, options?: C
|
|
|
19
19
|
clearCache(): Promise<void>;
|
|
20
20
|
addAlgoliaAgent(segment: string, version?: string | undefined): void;
|
|
21
21
|
waitForTask({ indexName, taskID, maxRetries, timeout, }: import("@algolia/client-search/model/clientMethodProps").WaitForTaskOptions, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/getTaskResponse").GetTaskResponse>;
|
|
22
|
-
waitForApiKey({ operation, key, apiKey, maxRetries, timeout, }: import("@algolia/client-search/model/clientMethodProps").WaitForApiKeyOptions, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-
|
|
22
|
+
waitForApiKey({ operation, key, apiKey, maxRetries, timeout, }: import("@algolia/client-search/model/clientMethodProps").WaitForApiKeyOptions, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-common").ApiError | import("@algolia/client-search/model/getApiKeyResponse").GetApiKeyResponse>;
|
|
23
23
|
browseObjects<T>({ indexName, browseRequest, ...browseObjectsOptions }: Partial<Pick<import("@algolia/client-common").CreateIterablePromise<import("@algolia/client-search/model/browseResponse").BrowseResponse<T>>, "validate">> & Required<Pick<import("@algolia/client-common").CreateIterablePromise<import("@algolia/client-search/model/browseResponse").BrowseResponse<T>>, "aggregator">> & import("@algolia/client-search/model/clientMethodProps").BrowseProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/browseResponse").BrowseResponse<T>>;
|
|
24
24
|
browseRules({ indexName, searchRulesParams, ...browseRulesOptions }: Partial<Pick<import("@algolia/client-common").CreateIterablePromise<import("@algolia/client-search/model/searchRulesResponse").SearchRulesResponse>, "validate">> & Required<Pick<import("@algolia/client-common").CreateIterablePromise<import("@algolia/client-search/model/searchRulesResponse").SearchRulesResponse>, "aggregator">> & import("@algolia/client-search/model/clientMethodProps").SearchRulesProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/searchRulesResponse").SearchRulesResponse>;
|
|
25
25
|
browseSynonyms({ indexName, validate, aggregator, ...browseSynonymsOptions }: Partial<Pick<import("@algolia/client-common").CreateIterablePromise<import("@algolia/client-search/model/searchSynonymsResponse").SearchSynonymsResponse>, "validate">> & Required<Pick<import("@algolia/client-common").CreateIterablePromise<import("@algolia/client-search/model/searchSynonymsResponse").SearchSynonymsResponse>, "aggregator">> & import("@algolia/client-search/model/clientMethodProps").SearchSynonymsProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/searchSynonymsResponse").SearchSynonymsResponse>;
|
|
@@ -63,7 +63,7 @@ export declare function algoliasearch(appId: string, apiKey: string, options?: C
|
|
|
63
63
|
listUserIds({ page, hitsPerPage }: import("@algolia/client-search/model/clientMethodProps").ListUserIdsProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/listUserIdsResponse").ListUserIdsResponse>;
|
|
64
64
|
multipleBatch(batchParams: import("@algolia/client-search/model/batchParams").BatchParams, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/multipleBatchResponse").MultipleBatchResponse>;
|
|
65
65
|
operationIndex({ indexName, operationIndexParams }: import("@algolia/client-search/model/clientMethodProps").OperationIndexProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/updatedAtResponse").UpdatedAtResponse>;
|
|
66
|
-
partialUpdateObject({ indexName, objectID,
|
|
66
|
+
partialUpdateObject({ indexName, objectID, attributesToUpdate, createIfNotExists, }: import("@algolia/client-search/model/clientMethodProps").PartialUpdateObjectProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/updatedAtWithObjectIdResponse").UpdatedAtWithObjectIdResponse>;
|
|
67
67
|
post({ path, parameters, body }: import("@algolia/client-search/model/clientMethodProps").PostProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<Record<string, any>>;
|
|
68
68
|
put({ path, parameters, body }: import("@algolia/client-search/model/clientMethodProps").PutProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<Record<string, any>>;
|
|
69
69
|
removeUserId({ userID }: import("@algolia/client-search/model/clientMethodProps").RemoveUserIdProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/removeUserIdResponse").RemoveUserIdResponse>;
|
|
@@ -71,7 +71,7 @@ export declare function algoliasearch(appId: string, apiKey: string, options?: C
|
|
|
71
71
|
restoreApiKey({ key }: import("@algolia/client-search/model/clientMethodProps").RestoreApiKeyProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/addApiKeyResponse").AddApiKeyResponse>;
|
|
72
72
|
saveObject({ indexName, body }: import("@algolia/client-search/model/clientMethodProps").SaveObjectProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/saveObjectResponse").SaveObjectResponse>;
|
|
73
73
|
saveRule({ indexName, objectID, rule, forwardToReplicas }: import("@algolia/client-search/model/clientMethodProps").SaveRuleProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/updatedRuleResponse").UpdatedRuleResponse>;
|
|
74
|
-
saveRules({ indexName,
|
|
74
|
+
saveRules({ indexName, rules, forwardToReplicas, clearExistingRules, }: import("@algolia/client-search/model/clientMethodProps").SaveRulesProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/updatedAtResponse").UpdatedAtResponse>;
|
|
75
75
|
saveSynonym({ indexName, objectID, synonymHit, forwardToReplicas }: import("@algolia/client-search/model/clientMethodProps").SaveSynonymProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/saveSynonymResponse").SaveSynonymResponse>;
|
|
76
76
|
saveSynonyms({ indexName, synonymHit, forwardToReplicas, replaceExistingSynonyms, }: import("@algolia/client-search/model/clientMethodProps").SaveSynonymsProps, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/updatedAtResponse").UpdatedAtResponse>;
|
|
77
77
|
search<T_3>(searchMethodParams: import("@algolia/client-search/model/clientMethodProps").LegacySearchMethodProps | import("@algolia/client-search/model/searchMethodParams").SearchMethodParams, requestOptions?: import("@algolia/client-common").RequestOptions | undefined): Promise<import("@algolia/client-search/model/searchResponses").SearchResponses<T_3>>;
|
|
@@ -4,7 +4,7 @@ import type { ABTestResponse } from '../model/aBTestResponse';
|
|
|
4
4
|
import type { AddABTestsRequest } from '../model/addABTestsRequest';
|
|
5
5
|
import type { DelProps, DeleteABTestProps, GetProps, GetABTestProps, ListABTestsProps, PostProps, PutProps, StopABTestProps } from '../model/clientMethodProps';
|
|
6
6
|
import type { ListABTestsResponse } from '../model/listABTestsResponse';
|
|
7
|
-
export declare const apiClientVersion = "5.0.0-alpha.
|
|
7
|
+
export declare const apiClientVersion = "5.0.0-alpha.5";
|
|
8
8
|
export declare const REGIONS: readonly ["de", "us"];
|
|
9
9
|
export declare type Region = typeof REGIONS[number];
|
|
10
10
|
export declare function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, region: regionOption, ...options }: CreateClientOptions & {
|
|
@@ -17,7 +17,7 @@ import type { GetTopFiltersNoResultsResponse } from '../model/getTopFiltersNoRes
|
|
|
17
17
|
import type { GetTopHitsResponse } from '../model/getTopHitsResponse';
|
|
18
18
|
import type { GetTopSearchesResponse } from '../model/getTopSearchesResponse';
|
|
19
19
|
import type { GetUsersCountResponse } from '../model/getUsersCountResponse';
|
|
20
|
-
export declare const apiClientVersion = "5.0.0-alpha.
|
|
20
|
+
export declare const apiClientVersion = "5.0.0-alpha.5";
|
|
21
21
|
export declare const REGIONS: readonly ["de", "us"];
|
|
22
22
|
export declare type Region = typeof REGIONS[number];
|
|
23
23
|
export declare function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, region: regionOption, ...options }: CreateClientOptions & {
|
|
@@ -4,7 +4,7 @@ import type { DeleteUserProfileResponse } from '../model/deleteUserProfileRespon
|
|
|
4
4
|
import type { GetUserTokenResponse } from '../model/getUserTokenResponse';
|
|
5
5
|
import type { PersonalizationStrategyParams } from '../model/personalizationStrategyParams';
|
|
6
6
|
import type { SetPersonalizationStrategyResponse } from '../model/setPersonalizationStrategyResponse';
|
|
7
|
-
export declare const apiClientVersion = "5.0.0-alpha.
|
|
7
|
+
export declare const apiClientVersion = "5.0.0-alpha.5";
|
|
8
8
|
export declare const REGIONS: readonly ["eu", "us"];
|
|
9
9
|
export declare type Region = typeof REGIONS[number];
|
|
10
10
|
export declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, region: regionOption, ...options }: CreateClientOptions & {
|
|
@@ -7,8 +7,6 @@ import type { BatchDictionaryEntriesParams } from './batchDictionaryEntriesParam
|
|
|
7
7
|
import type { BatchWriteParams } from './batchWriteParams';
|
|
8
8
|
import type { BrowseRequest } from './browseRequest';
|
|
9
9
|
import type { DictionaryType } from './dictionaryType';
|
|
10
|
-
import type { GetApiKeyResponse } from './getApiKeyResponse';
|
|
11
|
-
import type { GetTaskResponse } from './getTaskResponse';
|
|
12
10
|
import type { IndexSettings } from './indexSettings';
|
|
13
11
|
import type { LogType } from './logType';
|
|
14
12
|
import type { OperationIndexParams } from './operationIndexParams';
|
|
@@ -394,9 +392,9 @@ export declare type PartialUpdateObjectProps = {
|
|
|
394
392
|
*/
|
|
395
393
|
objectID: string;
|
|
396
394
|
/**
|
|
397
|
-
*
|
|
395
|
+
* Map of attribute(s) to update.
|
|
398
396
|
*/
|
|
399
|
-
|
|
397
|
+
attributesToUpdate: Record<string, AttributeToUpdate>;
|
|
400
398
|
/**
|
|
401
399
|
* Creates the record if it does not exist yet.
|
|
402
400
|
*/
|
|
@@ -502,7 +500,7 @@ export declare type SaveRulesProps = {
|
|
|
502
500
|
* The index in which to perform the request.
|
|
503
501
|
*/
|
|
504
502
|
indexName: string;
|
|
505
|
-
|
|
503
|
+
rules: Rule[];
|
|
506
504
|
/**
|
|
507
505
|
* When true, changes are also propagated to replicas of the given indexName.
|
|
508
506
|
*/
|
|
@@ -672,7 +670,7 @@ export declare type UpdateApiKeyProps = {
|
|
|
672
670
|
* The `browseObjects`, `browseRules`, `browseSynonyms` options.
|
|
673
671
|
*/
|
|
674
672
|
export declare type BrowseOptions<T> = Partial<Pick<CreateIterablePromise<T>, 'validate'>> & Required<Pick<CreateIterablePromise<T>, 'aggregator'>>;
|
|
675
|
-
declare type WaitForOptions
|
|
673
|
+
declare type WaitForOptions = Partial<{
|
|
676
674
|
/**
|
|
677
675
|
* The maximum number of retries. 50 by default.
|
|
678
676
|
*/
|
|
@@ -681,8 +679,8 @@ declare type WaitForOptions<T> = Omit<CreateIterablePromise<T>, 'func' | 'timeou
|
|
|
681
679
|
* The function to decide how long to wait between retries.
|
|
682
680
|
*/
|
|
683
681
|
timeout: (retryCount: number) => number;
|
|
684
|
-
}
|
|
685
|
-
export declare type WaitForTaskOptions = WaitForOptions
|
|
682
|
+
}>;
|
|
683
|
+
export declare type WaitForTaskOptions = WaitForOptions & {
|
|
686
684
|
/**
|
|
687
685
|
* The `indexName` where the operation was performed.
|
|
688
686
|
*/
|
|
@@ -692,7 +690,7 @@ export declare type WaitForTaskOptions = WaitForOptions<GetTaskResponse> & {
|
|
|
692
690
|
*/
|
|
693
691
|
taskID: number;
|
|
694
692
|
};
|
|
695
|
-
export declare type WaitForApiKeyOptions = WaitForOptions
|
|
693
|
+
export declare type WaitForApiKeyOptions = WaitForOptions & {
|
|
696
694
|
/**
|
|
697
695
|
* The API Key.
|
|
698
696
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"clientMethodProps.d.ts","sourceRoot":"","sources":["../../../../../packages/client-search/model/clientMethodProps.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,wBAAwB,CAAC;AAEpE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC/D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAC7D,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AAC3E,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,gCAAgC,CAAC;AACnF,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AACrD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"clientMethodProps.d.ts","sourceRoot":"","sources":["../../../../../packages/client-search/model/clientMethodProps.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,wBAAwB,CAAC;AAEpE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC/D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAC7D,OAAO,KAAK,EAAE,wBAAwB,EAAE,M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