From 61a0077761df09afc5793f9c52eb361024ccb0c9 Mon Sep 17 00:00:00 2001
From: algolia-bot
Date: Wed, 6 Nov 2024 16:37:44 +0000
Subject: [PATCH] feat(specs): add composition API (generated)
https://github.com/algolia/api-clients-automation/pull/4056
Co-authored-by: algolia-bot
Co-authored-by: Emmanuel Krebs
Co-authored-by: shortcuts
Co-authored-by: Pierre Millot
---
bundlesize.config.json | 4 +
package.json | 2 +-
packages/client-composition/LICENSE | 21 +
packages/client-composition/README.md | 77 +++
packages/client-composition/builds/browser.ts | 53 ++
packages/client-composition/builds/fetch.ts | 50 ++
packages/client-composition/builds/node.ts | 51 ++
packages/client-composition/index.d.ts | 1 +
packages/client-composition/index.js | 1 +
packages/client-composition/model/action.ts | 6 +
.../model/advancedSyntaxFeatures.ts | 3 +
.../model/alternativesAsExact.ts | 3 +
.../client-composition/model/anchoring.ts | 6 +
.../model/aroundPrecision.ts | 8 +
.../client-composition/model/aroundRadius.ts | 8 +
.../model/aroundRadiusAll.ts | 6 +
packages/client-composition/model/banner.ts | 13 +
.../client-composition/model/bannerImage.ts | 12 +
.../model/bannerImageUrl.ts | 8 +
.../client-composition/model/bannerLink.ts | 8 +
.../model/baseSearchParams.ts | 6 +
.../model/baseSearchParamsWithoutQuery.ts | 148 ++++
.../model/baseSearchResponse.ts | 129 ++++
.../model/batchCompositionAction.ts | 7 +
.../client-composition/model/batchParams.ts | 10 +
.../client-composition/model/booleanString.ts | 3 +
.../model/clientMethodProps.ts | 195 ++++++
.../model/composedRankingInfo.ts | 7 +
.../client-composition/model/composition.ts | 17 +
.../model/compositionBehavior.ts | 7 +
.../model/compositionInset.ts | 16 +
.../model/compositionInsetSource.ts | 7 +
.../model/compositionInsetSourceSearch.ts | 12 +
.../model/compositionRankingInfo.ts | 7 +
.../model/compositionRule.ts | 34 +
.../model/compositionRuleConsequence.ts | 10 +
.../model/compositionRulesBatchParams.ts | 10 +
.../model/compositionSource.ts | 7 +
.../model/compositionSourceSearch.ts | 12 +
.../client-composition/model/condition.ts | 27 +
.../model/deleteCompositionAction.ts | 11 +
.../model/deleteCompositionRuleAction.ts | 11 +
packages/client-composition/model/distinct.ts | 6 +
.../client-composition/model/errorBase.ts | 8 +
.../model/exactOnSingleWordQuery.ts | 6 +
.../client-composition/model/exhaustive.ts | 31 +
.../client-composition/model/facetFilters.ts | 6 +
.../client-composition/model/facetHits.ts | 18 +
.../client-composition/model/facetOrdering.ts | 16 +
.../client-composition/model/facetStats.ts | 23 +
packages/client-composition/model/facets.ts | 11 +
.../model/getTaskResponse.ts | 7 +
.../model/highlightResult.ts | 5 +
.../model/highlightResultOption.ts | 25 +
packages/client-composition/model/hit.ts | 29 +
.../model/hitRankingInfo.ts | 6 +
.../client-composition/model/ignorePlurals.ts | 9 +
packages/client-composition/model/index.ts | 106 +++
.../model/indexSettingsAsSearchParams.ts | 205 ++++++
.../client-composition/model/injection.ts | 13 +
.../model/insetsQueryParameters.ts | 227 +++++++
.../model/listCompositionsResponse.ts | 15 +
packages/client-composition/model/main.ts | 7 +
.../model/mainInjectionQueryParameters.ts | 262 +++++++
.../client-composition/model/matchLevel.ts | 6 +
.../model/matchedGeoLocation.ts | 18 +
packages/client-composition/model/mode.ts | 6 +
.../model/multipleBatchRequest.ts | 10 +
.../model/multipleBatchResponse.ts | 8 +
.../model/numericFilters.ts | 6 +
.../model/optionalFilters.ts | 6 +
.../model/personalization.ts | 18 +
.../client-composition/model/queryType.ts | 6 +
packages/client-composition/model/range.ts | 16 +
.../client-composition/model/rankingInfo.ts | 68 ++
.../model/reRankingApplyFilter.ts | 6 +
packages/client-composition/model/redirect.ts | 10 +
.../model/redirectRuleIndexData.ts | 8 +
.../model/redirectRuleIndexMetadata.ts | 27 +
.../client-composition/model/redirectURL.ts | 8 +
.../model/removeStopWords.ts | 8 +
.../model/removeWordsIfNoResults.ts | 6 +
.../model/renderingContent.ts | 16 +
.../model/rulesBatchCompositionAction.ts | 7 +
.../model/rulesMultipleBatchRequest.ts | 10 +
.../model/rulesMultipleBatchResponse.ts | 8 +
.../model/searchCompositionRulesParams.ts | 35 +
.../model/searchCompositionRulesResponse.ts | 25 +
.../model/searchForFacetValuesParams.ts | 17 +
.../model/searchForFacetValuesRequest.ts | 7 +
.../model/searchForFacetValuesResponse.ts | 10 +
.../model/searchForFacetValuesResults.ts | 22 +
.../client-composition/model/searchHits.ts | 10 +
.../model/searchPagination.ts | 23 +
.../client-composition/model/searchParams.ts | 6 +
.../model/searchParamsObject.ts | 9 +
.../model/searchParamsQuery.ts | 8 +
.../model/searchParamsSearchParams.ts | 122 ++++
.../model/searchParamsString.ts | 11 +
.../model/searchResponse.ts | 6 +
.../client-composition/model/searchResults.ts | 10 +
.../model/searchResultsItem.ts | 6 +
.../model/semanticSearch.ts | 11 +
.../client-composition/model/snippetResult.ts | 5 +
.../model/snippetResultOption.ts | 15 +
.../model/sortRemainingBy.ts | 6 +
.../model/supportedLanguage.ts | 74 ++
.../client-composition/model/tagFilters.ts | 6 +
.../client-composition/model/taskStatus.ts | 6 +
.../client-composition/model/timeRange.ts | 13 +
.../client-composition/model/typoTolerance.ts | 8 +
.../model/typoToleranceEnum.ts | 6 +
packages/client-composition/model/value.ts | 17 +
packages/client-composition/model/widgets.ts | 13 +
packages/client-composition/package.json | 67 ++
packages/client-composition/rollup.config.js | 16 +
.../src/compositionClient.ts | 638 ++++++++++++++++++
packages/client-composition/tsconfig.json | 8 +
packages/client-composition/tsup.config.ts | 59 ++
yarn.lock | 17 +
120 files changed, 3668 insertions(+), 1 deletion(-)
create mode 100644 packages/client-composition/LICENSE
create mode 100644 packages/client-composition/README.md
create mode 100644 packages/client-composition/builds/browser.ts
create mode 100644 packages/client-composition/builds/fetch.ts
create mode 100644 packages/client-composition/builds/node.ts
create mode 100644 packages/client-composition/index.d.ts
create mode 100644 packages/client-composition/index.js
create mode 100644 packages/client-composition/model/action.ts
create mode 100644 packages/client-composition/model/advancedSyntaxFeatures.ts
create mode 100644 packages/client-composition/model/alternativesAsExact.ts
create mode 100644 packages/client-composition/model/anchoring.ts
create mode 100644 packages/client-composition/model/aroundPrecision.ts
create mode 100644 packages/client-composition/model/aroundRadius.ts
create mode 100644 packages/client-composition/model/aroundRadiusAll.ts
create mode 100644 packages/client-composition/model/banner.ts
create mode 100644 packages/client-composition/model/bannerImage.ts
create mode 100644 packages/client-composition/model/bannerImageUrl.ts
create mode 100644 packages/client-composition/model/bannerLink.ts
create mode 100644 packages/client-composition/model/baseSearchParams.ts
create mode 100644 packages/client-composition/model/baseSearchParamsWithoutQuery.ts
create mode 100644 packages/client-composition/model/baseSearchResponse.ts
create mode 100644 packages/client-composition/model/batchCompositionAction.ts
create mode 100644 packages/client-composition/model/batchParams.ts
create mode 100644 packages/client-composition/model/booleanString.ts
create mode 100644 packages/client-composition/model/clientMethodProps.ts
create mode 100644 packages/client-composition/model/composedRankingInfo.ts
create mode 100644 packages/client-composition/model/composition.ts
create mode 100644 packages/client-composition/model/compositionBehavior.ts
create mode 100644 packages/client-composition/model/compositionInset.ts
create mode 100644 packages/client-composition/model/compositionInsetSource.ts
create mode 100644 packages/client-composition/model/compositionInsetSourceSearch.ts
create mode 100644 packages/client-composition/model/compositionRankingInfo.ts
create mode 100644 packages/client-composition/model/compositionRule.ts
create mode 100644 packages/client-composition/model/compositionRuleConsequence.ts
create mode 100644 packages/client-composition/model/compositionRulesBatchParams.ts
create mode 100644 packages/client-composition/model/compositionSource.ts
create mode 100644 packages/client-composition/model/compositionSourceSearch.ts
create mode 100644 packages/client-composition/model/condition.ts
create mode 100644 packages/client-composition/model/deleteCompositionAction.ts
create mode 100644 packages/client-composition/model/deleteCompositionRuleAction.ts
create mode 100644 packages/client-composition/model/distinct.ts
create mode 100644 packages/client-composition/model/errorBase.ts
create mode 100644 packages/client-composition/model/exactOnSingleWordQuery.ts
create mode 100644 packages/client-composition/model/exhaustive.ts
create mode 100644 packages/client-composition/model/facetFilters.ts
create mode 100644 packages/client-composition/model/facetHits.ts
create mode 100644 packages/client-composition/model/facetOrdering.ts
create mode 100644 packages/client-composition/model/facetStats.ts
create mode 100644 packages/client-composition/model/facets.ts
create mode 100644 packages/client-composition/model/getTaskResponse.ts
create mode 100644 packages/client-composition/model/highlightResult.ts
create mode 100644 packages/client-composition/model/highlightResultOption.ts
create mode 100644 packages/client-composition/model/hit.ts
create mode 100644 packages/client-composition/model/hitRankingInfo.ts
create mode 100644 packages/client-composition/model/ignorePlurals.ts
create mode 100644 packages/client-composition/model/index.ts
create mode 100644 packages/client-composition/model/indexSettingsAsSearchParams.ts
create mode 100644 packages/client-composition/model/injection.ts
create mode 100644 packages/client-composition/model/insetsQueryParameters.ts
create mode 100644 packages/client-composition/model/listCompositionsResponse.ts
create mode 100644 packages/client-composition/model/main.ts
create mode 100644 packages/client-composition/model/mainInjectionQueryParameters.ts
create mode 100644 packages/client-composition/model/matchLevel.ts
create mode 100644 packages/client-composition/model/matchedGeoLocation.ts
create mode 100644 packages/client-composition/model/mode.ts
create mode 100644 packages/client-composition/model/multipleBatchRequest.ts
create mode 100644 packages/client-composition/model/multipleBatchResponse.ts
create mode 100644 packages/client-composition/model/numericFilters.ts
create mode 100644 packages/client-composition/model/optionalFilters.ts
create mode 100644 packages/client-composition/model/personalization.ts
create mode 100644 packages/client-composition/model/queryType.ts
create mode 100644 packages/client-composition/model/range.ts
create mode 100644 packages/client-composition/model/rankingInfo.ts
create mode 100644 packages/client-composition/model/reRankingApplyFilter.ts
create mode 100644 packages/client-composition/model/redirect.ts
create mode 100644 packages/client-composition/model/redirectRuleIndexData.ts
create mode 100644 packages/client-composition/model/redirectRuleIndexMetadata.ts
create mode 100644 packages/client-composition/model/redirectURL.ts
create mode 100644 packages/client-composition/model/removeStopWords.ts
create mode 100644 packages/client-composition/model/removeWordsIfNoResults.ts
create mode 100644 packages/client-composition/model/renderingContent.ts
create mode 100644 packages/client-composition/model/rulesBatchCompositionAction.ts
create mode 100644 packages/client-composition/model/rulesMultipleBatchRequest.ts
create mode 100644 packages/client-composition/model/rulesMultipleBatchResponse.ts
create mode 100644 packages/client-composition/model/searchCompositionRulesParams.ts
create mode 100644 packages/client-composition/model/searchCompositionRulesResponse.ts
create mode 100644 packages/client-composition/model/searchForFacetValuesParams.ts
create mode 100644 packages/client-composition/model/searchForFacetValuesRequest.ts
create mode 100644 packages/client-composition/model/searchForFacetValuesResponse.ts
create mode 100644 packages/client-composition/model/searchForFacetValuesResults.ts
create mode 100644 packages/client-composition/model/searchHits.ts
create mode 100644 packages/client-composition/model/searchPagination.ts
create mode 100644 packages/client-composition/model/searchParams.ts
create mode 100644 packages/client-composition/model/searchParamsObject.ts
create mode 100644 packages/client-composition/model/searchParamsQuery.ts
create mode 100644 packages/client-composition/model/searchParamsSearchParams.ts
create mode 100644 packages/client-composition/model/searchParamsString.ts
create mode 100644 packages/client-composition/model/searchResponse.ts
create mode 100644 packages/client-composition/model/searchResults.ts
create mode 100644 packages/client-composition/model/searchResultsItem.ts
create mode 100644 packages/client-composition/model/semanticSearch.ts
create mode 100644 packages/client-composition/model/snippetResult.ts
create mode 100644 packages/client-composition/model/snippetResultOption.ts
create mode 100644 packages/client-composition/model/sortRemainingBy.ts
create mode 100644 packages/client-composition/model/supportedLanguage.ts
create mode 100644 packages/client-composition/model/tagFilters.ts
create mode 100644 packages/client-composition/model/taskStatus.ts
create mode 100644 packages/client-composition/model/timeRange.ts
create mode 100644 packages/client-composition/model/typoTolerance.ts
create mode 100644 packages/client-composition/model/typoToleranceEnum.ts
create mode 100644 packages/client-composition/model/value.ts
create mode 100644 packages/client-composition/model/widgets.ts
create mode 100644 packages/client-composition/package.json
create mode 100644 packages/client-composition/rollup.config.js
create mode 100644 packages/client-composition/src/compositionClient.ts
create mode 100644 packages/client-composition/tsconfig.json
create mode 100644 packages/client-composition/tsup.config.ts
diff --git a/bundlesize.config.json b/bundlesize.config.json
index d88e2da74..f327011db 100644
--- a/bundlesize.config.json
+++ b/bundlesize.config.json
@@ -16,6 +16,10 @@
"path": "packages/client-analytics/dist/builds/browser.umd.js",
"maxSize": "4.85KB"
},
+ {
+ "path": "packages/client-composition/dist/builds/browser.umd.js",
+ "maxSize": "4.05KB"
+ },
{
"path": "packages/client-insights/dist/builds/browser.umd.js",
"maxSize": "3.90KB"
diff --git a/package.json b/package.json
index bc699a718..1236d7e99 100644
--- a/package.json
+++ b/package.json
@@ -6,7 +6,7 @@
"packages/*"
],
"scripts": {
- "build": "lerna run build --scope '@algolia/requester-testing' --scope '@algolia/logger-console' --scope 'algoliasearch' --include-dependencies",
+ "build": "lerna run build --scope '@algolia/requester-testing' --scope '@algolia/logger-console' --scope 'algoliasearch' --scope '@algolia/client-composition' --include-dependencies",
"clean": "lerna run clean",
"release:bump": "lerna version ${0:-patch} --no-changelog --no-git-tag-version --no-push --exact --force-publish --yes",
"release:publish": "tsc --project scripts/tsconfig.json && node scripts/dist/scripts/publish.js",
diff --git a/packages/client-composition/LICENSE b/packages/client-composition/LICENSE
new file mode 100644
index 000000000..fddf416f9
--- /dev/null
+++ b/packages/client-composition/LICENSE
@@ -0,0 +1,21 @@
+MIT License
+
+Copyright (c) 2013-Present Algolia
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/packages/client-composition/README.md b/packages/client-composition/README.md
new file mode 100644
index 000000000..09e665321
--- /dev/null
+++ b/packages/client-composition/README.md
@@ -0,0 +1,77 @@
+
+
+
+
+
+
The perfect starting point to integrate Algolia within your JavaScript project
+
+
+
+
+
+
+
+
+
+
+ Documentation •
+ InstantSearch •
+ Community Forum •
+ Stack Overflow •
+ Report a bug •
+ FAQ •
+ Support
+
+
+## ✨ Features
+
+- Thin & **minimal low-level HTTP client** to interact with Algolia's API
+- Works both on the **browser** and **node.js**
+- **UMD and ESM compatible**, you can use it with any module loader
+- Built with TypeScript
+
+## 💡 Getting Started
+
+> [!TIP]
+> This API client is already a dependency of [the algoliasearch client](https://www.npmjs.com/package/algoliasearch), you don't need to manually install `@algolia/client-composition` if you already have `algoliasearch` installed.
+
+To get started, you first need to install @algolia/client-composition (or any other available API client package).
+All of our clients comes with type definition, and are available for both browser and node environments.
+
+### With a package manager
+
+```bash
+yarn add @algolia/client-composition@0.0.1-alpha.0
+# or
+npm install @algolia/client-composition@0.0.1-alpha.0
+# or
+pnpm add @algolia/client-composition@0.0.1-alpha.0
+```
+
+### Without a package manager
+
+Add the following JavaScript snippet to the of your website:
+
+```html
+
+```
+
+### Usage
+
+You can now import the Algolia API client in your project and play with it.
+
+```js
+import { compositionClient } from '@algolia/client-composition';
+
+const client = compositionClient('YOUR_APP_ID', 'YOUR_API_KEY');
+```
+
+For full documentation, visit the **[Algolia JavaScript API Client](https://www.algolia.com/doc/libraries/javascript/v5/methods/composition/)**.
+
+## ❓ Troubleshooting
+
+Encountering an issue? Before reaching out to support, we recommend heading to our [FAQ](https://www.algolia.com/doc/libraries/javascript/v5/) where you will find answers for the most common issues and gotchas with the client. You can also open [a GitHub issue](https://github.com/algolia/api-clients-automation/issues/new?assignees=&labels=&projects=&template=Bug_report.md)
+
+## 📄 License
+
+The Algolia JavaScript API Client is an open-sourced software licensed under the [MIT license](LICENSE).
diff --git a/packages/client-composition/builds/browser.ts b/packages/client-composition/builds/browser.ts
new file mode 100644
index 000000000..4d60997ca
--- /dev/null
+++ b/packages/client-composition/builds/browser.ts
@@ -0,0 +1,53 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import { createXhrRequester } from '@algolia/requester-browser-xhr';
+
+import {
+ createBrowserLocalStorageCache,
+ createFallbackableCache,
+ createMemoryCache,
+ createNullLogger,
+ DEFAULT_CONNECT_TIMEOUT_BROWSER,
+ DEFAULT_READ_TIMEOUT_BROWSER,
+ DEFAULT_WRITE_TIMEOUT_BROWSER,
+} from '@algolia/client-common';
+
+import type { ClientOptions } from '@algolia/client-common';
+
+import { apiClientVersion, createCompositionClient } from '../src/compositionClient';
+
+export { apiClientVersion } from '../src/compositionClient';
+
+export * from '../model';
+
+export function compositionClient(appId: string, apiKey: string, options?: ClientOptions): CompositionClient {
+ if (!appId || typeof appId !== 'string') {
+ throw new Error('`appId` is missing.');
+ }
+
+ if (!apiKey || typeof apiKey !== 'string') {
+ throw new Error('`apiKey` is missing.');
+ }
+
+ return createCompositionClient({
+ appId,
+ apiKey,
+ timeouts: {
+ connect: DEFAULT_CONNECT_TIMEOUT_BROWSER,
+ read: DEFAULT_READ_TIMEOUT_BROWSER,
+ write: DEFAULT_WRITE_TIMEOUT_BROWSER,
+ },
+ logger: createNullLogger(),
+ requester: createXhrRequester(),
+ algoliaAgents: [{ segment: 'Browser' }],
+ authMode: 'WithinQueryParameters',
+ responsesCache: createMemoryCache(),
+ requestsCache: createMemoryCache({ serializable: false }),
+ hostsCache: createFallbackableCache({
+ caches: [createBrowserLocalStorageCache({ key: `${apiClientVersion}-${appId}` }), createMemoryCache()],
+ }),
+ ...options,
+ });
+}
+
+export type CompositionClient = ReturnType;
diff --git a/packages/client-composition/builds/fetch.ts b/packages/client-composition/builds/fetch.ts
new file mode 100644
index 000000000..232378048
--- /dev/null
+++ b/packages/client-composition/builds/fetch.ts
@@ -0,0 +1,50 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type CompositionClient = ReturnType;
+
+import {
+ createMemoryCache,
+ createNullCache,
+ createNullLogger,
+ DEFAULT_CONNECT_TIMEOUT_NODE,
+ DEFAULT_READ_TIMEOUT_NODE,
+ DEFAULT_WRITE_TIMEOUT_NODE,
+} from '@algolia/client-common';
+import { createFetchRequester } from '@algolia/requester-fetch';
+
+import type { ClientOptions } from '@algolia/client-common';
+
+import { createCompositionClient } from '../src/compositionClient';
+
+export { apiClientVersion } from '../src/compositionClient';
+
+export * from '../model';
+
+export function compositionClient(appId: string, apiKey: string, options?: ClientOptions): CompositionClient {
+ if (!appId || typeof appId !== 'string') {
+ throw new Error('`appId` is missing.');
+ }
+
+ if (!apiKey || typeof apiKey !== 'string') {
+ throw new Error('`apiKey` is missing.');
+ }
+
+ return {
+ ...createCompositionClient({
+ appId,
+ apiKey,
+ timeouts: {
+ connect: DEFAULT_CONNECT_TIMEOUT_NODE,
+ read: DEFAULT_READ_TIMEOUT_NODE,
+ write: DEFAULT_WRITE_TIMEOUT_NODE,
+ },
+ logger: createNullLogger(),
+ algoliaAgents: [{ segment: 'Fetch' }],
+ requester: createFetchRequester(),
+ responsesCache: createNullCache(),
+ requestsCache: createNullCache(),
+ hostsCache: createMemoryCache(),
+ ...options,
+ }),
+ };
+}
diff --git a/packages/client-composition/builds/node.ts b/packages/client-composition/builds/node.ts
new file mode 100644
index 000000000..55e3cf770
--- /dev/null
+++ b/packages/client-composition/builds/node.ts
@@ -0,0 +1,51 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type CompositionClient = ReturnType;
+
+import { createHttpRequester } from '@algolia/requester-node-http';
+
+import {
+ createMemoryCache,
+ createNullCache,
+ createNullLogger,
+ DEFAULT_CONNECT_TIMEOUT_NODE,
+ DEFAULT_READ_TIMEOUT_NODE,
+ DEFAULT_WRITE_TIMEOUT_NODE,
+} from '@algolia/client-common';
+
+import type { ClientOptions } from '@algolia/client-common';
+
+import { createCompositionClient } from '../src/compositionClient';
+
+export { apiClientVersion } from '../src/compositionClient';
+
+export * from '../model';
+
+export function compositionClient(appId: string, apiKey: string, options?: ClientOptions): CompositionClient {
+ if (!appId || typeof appId !== 'string') {
+ throw new Error('`appId` is missing.');
+ }
+
+ if (!apiKey || typeof apiKey !== 'string') {
+ throw new Error('`apiKey` is missing.');
+ }
+
+ return {
+ ...createCompositionClient({
+ appId,
+ apiKey,
+ timeouts: {
+ connect: DEFAULT_CONNECT_TIMEOUT_NODE,
+ read: DEFAULT_READ_TIMEOUT_NODE,
+ write: DEFAULT_WRITE_TIMEOUT_NODE,
+ },
+ logger: createNullLogger(),
+ requester: createHttpRequester(),
+ algoliaAgents: [{ segment: 'Node.js', version: process.versions.node }],
+ responsesCache: createNullCache(),
+ requestsCache: createNullCache(),
+ hostsCache: createMemoryCache(),
+ ...options,
+ }),
+ };
+}
diff --git a/packages/client-composition/index.d.ts b/packages/client-composition/index.d.ts
new file mode 100644
index 000000000..e81a1cd3e
--- /dev/null
+++ b/packages/client-composition/index.d.ts
@@ -0,0 +1 @@
+export * from './dist/node';
diff --git a/packages/client-composition/index.js b/packages/client-composition/index.js
new file mode 100644
index 000000000..21e26aad3
--- /dev/null
+++ b/packages/client-composition/index.js
@@ -0,0 +1 @@
+module.exports = require('./dist/builds/node.cjs');
diff --git a/packages/client-composition/model/action.ts b/packages/client-composition/model/action.ts
new file mode 100644
index 000000000..f00b21c4b
--- /dev/null
+++ b/packages/client-composition/model/action.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Type of Composition Batch operation.
+ */
+export type Action = 'upsert' | 'delete';
diff --git a/packages/client-composition/model/advancedSyntaxFeatures.ts b/packages/client-composition/model/advancedSyntaxFeatures.ts
new file mode 100644
index 000000000..61e577d48
--- /dev/null
+++ b/packages/client-composition/model/advancedSyntaxFeatures.ts
@@ -0,0 +1,3 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type AdvancedSyntaxFeatures = 'exactPhrase' | 'excludeWords';
diff --git a/packages/client-composition/model/alternativesAsExact.ts b/packages/client-composition/model/alternativesAsExact.ts
new file mode 100644
index 000000000..dd6871e7f
--- /dev/null
+++ b/packages/client-composition/model/alternativesAsExact.ts
@@ -0,0 +1,3 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type AlternativesAsExact = 'ignorePlurals' | 'singleWordSynonym' | 'multiWordsSynonym';
diff --git a/packages/client-composition/model/anchoring.ts b/packages/client-composition/model/anchoring.ts
new file mode 100644
index 000000000..9effad076
--- /dev/null
+++ b/packages/client-composition/model/anchoring.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Which part of the search query the pattern should match: - `startsWith`. The pattern must match the beginning of the query. - `endsWith`. The pattern must match the end of the query. - `is`. The pattern must match the query exactly. - `contains`. The pattern must match anywhere in the query. Empty queries are only allowed as patterns with `anchoring: is`.
+ */
+export type Anchoring = 'is' | 'startsWith' | 'endsWith' | 'contains';
diff --git a/packages/client-composition/model/aroundPrecision.ts b/packages/client-composition/model/aroundPrecision.ts
new file mode 100644
index 000000000..79ff0cd59
--- /dev/null
+++ b/packages/client-composition/model/aroundPrecision.ts
@@ -0,0 +1,8 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { Range } from './range';
+
+/**
+ * Precision of a coordinate-based search in meters to group results with similar distances. The Geo ranking criterion considers all matches within the same range of distances to be equal.
+ */
+export type AroundPrecision = number | Array;
diff --git a/packages/client-composition/model/aroundRadius.ts b/packages/client-composition/model/aroundRadius.ts
new file mode 100644
index 000000000..8198f1e75
--- /dev/null
+++ b/packages/client-composition/model/aroundRadius.ts
@@ -0,0 +1,8 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { AroundRadiusAll } from './aroundRadiusAll';
+
+/**
+ * Maximum radius for a search around a central location. This parameter works in combination with the `aroundLatLng` and `aroundLatLngViaIP` parameters. By default, the search radius is determined automatically from the density of hits around the central location. The search radius is small if there are many hits close to the central coordinates.
+ */
+export type AroundRadius = number | AroundRadiusAll;
diff --git a/packages/client-composition/model/aroundRadiusAll.ts b/packages/client-composition/model/aroundRadiusAll.ts
new file mode 100644
index 000000000..e5f107060
--- /dev/null
+++ b/packages/client-composition/model/aroundRadiusAll.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Return all records with a valid `_geoloc` attribute. Don\'t filter by distance.
+ */
+export type AroundRadiusAll = 'all';
diff --git a/packages/client-composition/model/banner.ts b/packages/client-composition/model/banner.ts
new file mode 100644
index 000000000..c82d29db8
--- /dev/null
+++ b/packages/client-composition/model/banner.ts
@@ -0,0 +1,13 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { BannerImage } from './bannerImage';
+import type { BannerLink } from './bannerLink';
+
+/**
+ * a search banner with image and url.
+ */
+export type Banner = {
+ image?: BannerImage;
+
+ link?: BannerLink;
+};
diff --git a/packages/client-composition/model/bannerImage.ts b/packages/client-composition/model/bannerImage.ts
new file mode 100644
index 000000000..9be9f3878
--- /dev/null
+++ b/packages/client-composition/model/bannerImage.ts
@@ -0,0 +1,12 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { BannerImageUrl } from './bannerImageUrl';
+
+/**
+ * image of a search banner.
+ */
+export type BannerImage = {
+ urls?: Array;
+
+ title?: string;
+};
diff --git a/packages/client-composition/model/bannerImageUrl.ts b/packages/client-composition/model/bannerImageUrl.ts
new file mode 100644
index 000000000..eafbfaffb
--- /dev/null
+++ b/packages/client-composition/model/bannerImageUrl.ts
@@ -0,0 +1,8 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * url for a search banner image.
+ */
+export type BannerImageUrl = {
+ url?: string;
+};
diff --git a/packages/client-composition/model/bannerLink.ts b/packages/client-composition/model/bannerLink.ts
new file mode 100644
index 000000000..27cac4baa
--- /dev/null
+++ b/packages/client-composition/model/bannerLink.ts
@@ -0,0 +1,8 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * link for a banner defined in merchandising studio.
+ */
+export type BannerLink = {
+ url?: string;
+};
diff --git a/packages/client-composition/model/baseSearchParams.ts b/packages/client-composition/model/baseSearchParams.ts
new file mode 100644
index 000000000..030809e05
--- /dev/null
+++ b/packages/client-composition/model/baseSearchParams.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { BaseSearchParamsWithoutQuery } from './baseSearchParamsWithoutQuery';
+import type { SearchParamsQuery } from './searchParamsQuery';
+
+export type BaseSearchParams = SearchParamsQuery & BaseSearchParamsWithoutQuery;
diff --git a/packages/client-composition/model/baseSearchParamsWithoutQuery.ts b/packages/client-composition/model/baseSearchParamsWithoutQuery.ts
new file mode 100644
index 000000000..577120301
--- /dev/null
+++ b/packages/client-composition/model/baseSearchParamsWithoutQuery.ts
@@ -0,0 +1,148 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { AroundPrecision } from './aroundPrecision';
+import type { AroundRadius } from './aroundRadius';
+import type { FacetFilters } from './facetFilters';
+import type { NumericFilters } from './numericFilters';
+import type { OptionalFilters } from './optionalFilters';
+import type { SupportedLanguage } from './supportedLanguage';
+import type { TagFilters } from './tagFilters';
+
+export type BaseSearchParamsWithoutQuery = {
+ /**
+ * Keywords to be used instead of the search query to conduct a more broader search. Using the `similarQuery` parameter changes other settings: - `queryType` is set to `prefixNone`. - `removeStopWords` is set to true. - `words` is set as the first ranking criterion. - All remaining words are treated as `optionalWords`. Since the `similarQuery` is supposed to do a broad search, they usually return many results. Combine it with `filters` to narrow down the list of results.
+ */
+ similarQuery?: string;
+
+ /**
+ * Filter expression to only include items that match the filter criteria in the response. You can use these filter expressions: - **Numeric filters.** ` `, where `` is one of `<`, `<=`, `=`, `!=`, `>`, `>=`. - **Ranges.** `: TO ` where `` and `` are the lower and upper limits of the range (inclusive). - **Facet filters.** `:` where `` is a facet attribute (case-sensitive) and `` a facet value. - **Tag filters.** `_tags:` or just `` (case-sensitive). - **Boolean filters.** `: true | false`. You can combine filters with `AND`, `OR`, and `NOT` operators with the following restrictions: - You can only combine filters of the same type with `OR`. **Not supported:** `facet:value OR num > 3`. - You can\'t use `NOT` with combinations of filters. **Not supported:** `NOT(facet:value OR facet:value)` - You can\'t combine conjunctions (`AND`) with `OR`. **Not supported:** `facet:value OR (facet:value AND facet:value)` Use quotes around your filters, if the facet attribute name or facet value has spaces, keywords (`OR`, `AND`, `NOT`), or quotes. If a facet attribute is an array, the filter matches if it matches at least one element of the array. For more information, see [Filters](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/).
+ */
+ filters?: string;
+
+ facetFilters?: FacetFilters;
+
+ optionalFilters?: OptionalFilters;
+
+ numericFilters?: NumericFilters;
+
+ tagFilters?: TagFilters;
+
+ /**
+ * Whether to sum all filter scores. If true, all filter scores are summed. Otherwise, the maximum filter score is kept. For more information, see [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).
+ */
+ sumOrFiltersScores?: boolean;
+
+ /**
+ * Restricts a search to a subset of your searchable attributes. Attribute names are case-sensitive.
+ */
+ restrictSearchableAttributes?: Array;
+
+ /**
+ * Facets for which to retrieve facet values that match the search criteria and the number of matching facet values. To retrieve all facets, use the wildcard character `*`. For more information, see [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts).
+ */
+ facets?: Array;
+
+ /**
+ * Whether faceting should be applied after deduplication with `distinct`. This leads to accurate facet counts when using faceting in combination with `distinct`. It\'s usually better to use `afterDistinct` modifiers in the `attributesForFaceting` setting, as `facetingAfterDistinct` only computes correct facet counts if all records have the same facet values for the `attributeForDistinct`.
+ */
+ facetingAfterDistinct?: boolean;
+
+ /**
+ * Page of search results to retrieve.
+ */
+ page?: number;
+
+ /**
+ * Position of the first hit to retrieve.
+ */
+ offset?: number;
+
+ /**
+ * Number of hits to retrieve (used in combination with `offset`).
+ */
+ length?: number;
+
+ /**
+ * Coordinates for the center of a circle, expressed as a comma-separated string of latitude and longitude. Only records included within a circle around this central location are included in the results. The radius of the circle is determined by the `aroundRadius` and `minimumAroundRadius` settings. This parameter is ignored if you also specify `insidePolygon` or `insideBoundingBox`.
+ */
+ aroundLatLng?: string;
+
+ /**
+ * Whether to obtain the coordinates from the request\'s IP address.
+ */
+ aroundLatLngViaIP?: boolean;
+
+ aroundRadius?: AroundRadius;
+
+ aroundPrecision?: AroundPrecision;
+
+ /**
+ * Minimum radius (in meters) for a search around a location when `aroundRadius` isn\'t set.
+ */
+ minimumAroundRadius?: number;
+
+ /**
+ * Coordinates for a rectangular area in which to search. Each bounding box is defined by the two opposite points of its diagonal, and expressed as latitude and longitude pair: `[p1 lat, p1 long, p2 lat, p2 long]`. Provide multiple bounding boxes as nested arrays. For more information, see [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas).
+ */
+ insideBoundingBox?: Array>;
+
+ /**
+ * Coordinates of a polygon in which to search. Polygons are defined by 3 to 10,000 points. Each point is represented by its latitude and longitude. Provide multiple polygons as nested arrays. For more information, see [filtering inside polygons](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas). This parameter is ignored if you also specify `insideBoundingBox`.
+ */
+ insidePolygon?: Array>;
+
+ /**
+ * ISO language codes that adjust settings that are useful for processing natural language queries (as opposed to keyword searches): - Sets `removeStopWords` and `ignorePlurals` to the list of provided languages. - Sets `removeWordsIfNoResults` to `allOptional`. - Adds a `natural_language` attribute to `ruleContexts` and `analyticsTags`.
+ */
+ naturalLanguages?: Array;
+
+ /**
+ * Assigns a rule context to the search query. [Rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) are strings that you can use to trigger matching rules.
+ */
+ ruleContexts?: Array;
+
+ /**
+ * Impact that Personalization should have on this search. The higher this value is, the more Personalization determines the ranking compared to other factors. For more information, see [Understanding Personalization impact](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).
+ */
+ personalizationImpact?: number;
+
+ /**
+ * Unique pseudonymous or anonymous user identifier. This helps with analytics and click and conversion events. For more information, see [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/).
+ */
+ userToken?: string;
+
+ /**
+ * Whether the search response should include detailed ranking information.
+ */
+ getRankingInfo?: boolean;
+
+ /**
+ * Whether to take into account an index\'s synonyms for this search.
+ */
+ synonyms?: boolean;
+
+ /**
+ * Whether to include a `queryID` attribute in the response. The query ID is a unique identifier for a search query and is required for tracking [click and conversion events](https://www.algolia.com/guides/sending-events/getting-started/).
+ */
+ clickAnalytics?: boolean;
+
+ /**
+ * Whether this search will be included in Analytics.
+ */
+ analytics?: boolean;
+
+ /**
+ * Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
+ */
+ analyticsTags?: Array;
+
+ /**
+ * Whether to include this search when calculating processing-time percentiles.
+ */
+ percentileComputation?: boolean;
+
+ /**
+ * Whether to enable A/B testing for this search.
+ */
+ enableABTest?: boolean;
+};
diff --git a/packages/client-composition/model/baseSearchResponse.ts b/packages/client-composition/model/baseSearchResponse.ts
new file mode 100644
index 000000000..2c0cffc54
--- /dev/null
+++ b/packages/client-composition/model/baseSearchResponse.ts
@@ -0,0 +1,129 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { Exhaustive } from './exhaustive';
+import type { FacetStats } from './facetStats';
+import type { Redirect } from './redirect';
+import type { RenderingContent } from './renderingContent';
+
+export type BaseSearchResponse = Record & {
+ /**
+ * A/B test ID. This is only included in the response for indices that are part of an A/B test.
+ */
+ abTestID?: number;
+
+ /**
+ * Variant ID. This is only included in the response for indices that are part of an A/B test.
+ */
+ abTestVariantID?: number;
+
+ /**
+ * Computed geographical location.
+ */
+ aroundLatLng?: string;
+
+ /**
+ * Distance from a central coordinate provided by `aroundLatLng`.
+ */
+ automaticRadius?: string;
+
+ exhaustive?: Exhaustive;
+
+ /**
+ * Rules applied to the query.
+ */
+ appliedRules?: Array>;
+
+ /**
+ * See the `facetsCount` field of the `exhaustive` object in the response.
+ */
+ exhaustiveFacetsCount?: boolean;
+
+ /**
+ * See the `nbHits` field of the `exhaustive` object in the response.
+ */
+ exhaustiveNbHits?: boolean;
+
+ /**
+ * See the `typo` field of the `exhaustive` object in the response.
+ */
+ exhaustiveTypo?: boolean;
+
+ /**
+ * Facet counts.
+ */
+ facets?: { [key: string]: { [key: string]: number } };
+
+ /**
+ * Statistics for numerical facets.
+ */
+ facets_stats?: { [key: string]: FacetStats };
+
+ /**
+ * Index name used for the query.
+ */
+ index?: string;
+
+ /**
+ * Index name used for the query. During A/B testing, the targeted index isn\'t always the index used by the query.
+ */
+ indexUsed?: string;
+
+ /**
+ * Warnings about the query.
+ */
+ message?: string;
+
+ /**
+ * Number of hits selected and sorted by the relevant sort algorithm.
+ */
+ nbSortedHits?: number;
+
+ /**
+ * Post-[normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/#what-does-normalization-mean) query string that will be searched.
+ */
+ parsedQuery?: string;
+
+ /**
+ * Time the server took to process the request, in milliseconds.
+ */
+ processingTimeMS: number;
+
+ /**
+ * Experimental. List of processing steps and their times, in milliseconds. You can use this list to investigate performance issues.
+ */
+ processingTimingsMS?: Record;
+
+ /**
+ * Markup text indicating which parts of the original query have been removed to retrieve a non-empty result set.
+ */
+ queryAfterRemoval?: string;
+
+ redirect?: Redirect;
+
+ renderingContent?: RenderingContent;
+
+ /**
+ * Time the server took to process the request, in milliseconds.
+ */
+ serverTimeMS?: number;
+
+ /**
+ * Host name of the server that processed the request.
+ */
+ serverUsed?: string;
+
+ /**
+ * An object with custom data. You can store up to 32kB as custom data.
+ */
+ userData?: Record;
+
+ /**
+ * Unique identifier for the query. This is used for [click analytics](https://www.algolia.com/doc/guides/analytics/click-analytics/).
+ */
+ queryID?: string;
+
+ /**
+ * Whether automatic events collection is enabled for the application.
+ */
+ _automaticInsights?: boolean;
+};
diff --git a/packages/client-composition/model/batchCompositionAction.ts b/packages/client-composition/model/batchCompositionAction.ts
new file mode 100644
index 000000000..7b9fd6979
--- /dev/null
+++ b/packages/client-composition/model/batchCompositionAction.ts
@@ -0,0 +1,7 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { Composition } from './composition';
+
+import type { DeleteCompositionAction } from './deleteCompositionAction';
+
+export type BatchCompositionAction = Composition | DeleteCompositionAction;
diff --git a/packages/client-composition/model/batchParams.ts b/packages/client-composition/model/batchParams.ts
new file mode 100644
index 000000000..9ab9e4a92
--- /dev/null
+++ b/packages/client-composition/model/batchParams.ts
@@ -0,0 +1,10 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { MultipleBatchRequest } from './multipleBatchRequest';
+
+/**
+ * Batch parameters.
+ */
+export type BatchParams = {
+ requests: Array;
+};
diff --git a/packages/client-composition/model/booleanString.ts b/packages/client-composition/model/booleanString.ts
new file mode 100644
index 000000000..4cf1fb196
--- /dev/null
+++ b/packages/client-composition/model/booleanString.ts
@@ -0,0 +1,3 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type BooleanString = 'true' | 'false';
diff --git a/packages/client-composition/model/clientMethodProps.ts b/packages/client-composition/model/clientMethodProps.ts
new file mode 100644
index 000000000..0be6e2177
--- /dev/null
+++ b/packages/client-composition/model/clientMethodProps.ts
@@ -0,0 +1,195 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { CompositionRulesBatchParams } from '../model/compositionRulesBatchParams';
+
+import type { SearchCompositionRulesParams } from '../model/searchCompositionRulesParams';
+
+import type { SearchForFacetValuesRequest } from '../model/searchForFacetValuesRequest';
+
+import type { SearchParams } from '../model/searchParams';
+
+/**
+ * Properties for the `customDelete` method.
+ */
+export type CustomDeleteProps = {
+ /**
+ * Path of the endpoint, anything after \"/1\" must be specified.
+ */
+ path: string;
+ /**
+ * Query parameters to apply to the current query.
+ */
+ parameters?: { [key: string]: any };
+};
+
+/**
+ * Properties for the `customGet` method.
+ */
+export type CustomGetProps = {
+ /**
+ * Path of the endpoint, anything after \"/1\" must be specified.
+ */
+ path: string;
+ /**
+ * Query parameters to apply to the current query.
+ */
+ parameters?: { [key: string]: any };
+};
+
+/**
+ * Properties for the `customPost` method.
+ */
+export type CustomPostProps = {
+ /**
+ * Path of the endpoint, anything after \"/1\" must be specified.
+ */
+ path: string;
+ /**
+ * Query parameters to apply to the current query.
+ */
+ parameters?: { [key: string]: any };
+ /**
+ * Parameters to send with the custom request.
+ */
+ body?: Record;
+};
+
+/**
+ * Properties for the `customPut` method.
+ */
+export type CustomPutProps = {
+ /**
+ * Path of the endpoint, anything after \"/1\" must be specified.
+ */
+ path: string;
+ /**
+ * Query parameters to apply to the current query.
+ */
+ parameters?: { [key: string]: any };
+ /**
+ * Parameters to send with the custom request.
+ */
+ body?: Record;
+};
+
+/**
+ * Properties for the `getComposition` method.
+ */
+export type GetCompositionProps = {
+ /**
+ * Unique Composition ObjectID.
+ */
+ compositionID: string;
+};
+
+/**
+ * Properties for the `getRule` method.
+ */
+export type GetRuleProps = {
+ /**
+ * Unique Composition ObjectID.
+ */
+ compositionID: string;
+ /**
+ * Unique identifier of a rule object.
+ */
+ objectID: string;
+};
+
+/**
+ * Properties for the `getTask` method.
+ */
+export type GetTaskProps = {
+ /**
+ * Unique Composition ObjectID.
+ */
+ compositionID: string;
+ /**
+ * Unique task identifier.
+ */
+ taskID: number;
+};
+
+/**
+ * Properties for the `listCompositions` method.
+ */
+export type ListCompositionsProps = {
+ /**
+ * Requested page of the API response. If `null`, the API response is not paginated.
+ */
+ page?: number;
+ /**
+ * Number of hits per page.
+ */
+ hitsPerPage?: number;
+};
+
+/**
+ * Properties for the `runSingleComposition` method.
+ */
+export type RunSingleCompositionProps = {
+ /**
+ * Unique Composition ObjectID.
+ */
+ compositionID: string;
+ searchParams?: SearchParams;
+};
+
+/**
+ * Properties for the `saveRules` method.
+ */
+export type SaveRulesProps = {
+ /**
+ * Unique Composition ObjectID.
+ */
+ compositionID: string;
+ rules: CompositionRulesBatchParams;
+};
+
+/**
+ * Properties for the `searchCompositionRules` method.
+ */
+export type SearchCompositionRulesProps = {
+ /**
+ * Unique Composition ObjectID.
+ */
+ compositionID: string;
+ searchCompositionRulesParams?: SearchCompositionRulesParams;
+};
+
+/**
+ * Properties for the `searchForFacetValues` method.
+ */
+export type SearchForFacetValuesProps = {
+ /**
+ * Unique Composition ObjectID.
+ */
+ compositionID: string;
+ /**
+ * Facet attribute in which to search for values. This attribute must be included in the `attributesForFaceting` index setting with the `searchable()` modifier.
+ */
+ facetName: string;
+ searchForFacetValuesRequest?: SearchForFacetValuesRequest;
+};
+
+export type WaitForCompositionTaskOptions = {
+ /**
+ * The maximum number of retries. 50 by default.
+ */
+ maxRetries?: number;
+
+ /**
+ * The function to decide how long to wait between retries.
+ */
+ timeout?: (retryCount: number) => number;
+
+ /**
+ * The `taskID` returned by the method response.
+ */
+
+ taskID: number;
+ /**
+ * The `compositionID` where the operation was performed.
+ */
+ compositionID: string;
+};
diff --git a/packages/client-composition/model/composedRankingInfo.ts b/packages/client-composition/model/composedRankingInfo.ts
new file mode 100644
index 000000000..9a46788f3
--- /dev/null
+++ b/packages/client-composition/model/composedRankingInfo.ts
@@ -0,0 +1,7 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type ComposedRankingInfo = {
+ index: string;
+
+ inset: string;
+};
diff --git a/packages/client-composition/model/composition.ts b/packages/client-composition/model/composition.ts
new file mode 100644
index 000000000..e74db7527
--- /dev/null
+++ b/packages/client-composition/model/composition.ts
@@ -0,0 +1,17 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { CompositionBehavior } from './compositionBehavior';
+
+export type Composition = {
+ /**
+ * Unique record identifier.
+ */
+ objectID: string;
+
+ /**
+ * Composition name.
+ */
+ description?: string;
+
+ behavior: CompositionBehavior;
+};
diff --git a/packages/client-composition/model/compositionBehavior.ts b/packages/client-composition/model/compositionBehavior.ts
new file mode 100644
index 000000000..a858153a2
--- /dev/null
+++ b/packages/client-composition/model/compositionBehavior.ts
@@ -0,0 +1,7 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { Injection } from './injection';
+
+export type CompositionBehavior = {
+ injection: Injection;
+};
diff --git a/packages/client-composition/model/compositionInset.ts b/packages/client-composition/model/compositionInset.ts
new file mode 100644
index 000000000..d68f658c9
--- /dev/null
+++ b/packages/client-composition/model/compositionInset.ts
@@ -0,0 +1,16 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { CompositionInsetSource } from './compositionInsetSource';
+
+export type CompositionInset = {
+ /**
+ * Inset name.
+ */
+ name: string;
+
+ source: CompositionInsetSource;
+
+ position: number;
+
+ length: number;
+};
diff --git a/packages/client-composition/model/compositionInsetSource.ts b/packages/client-composition/model/compositionInsetSource.ts
new file mode 100644
index 000000000..775ad61f4
--- /dev/null
+++ b/packages/client-composition/model/compositionInsetSource.ts
@@ -0,0 +1,7 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { CompositionInsetSourceSearch } from './compositionInsetSourceSearch';
+
+export type CompositionInsetSource = {
+ search: CompositionInsetSourceSearch;
+};
diff --git a/packages/client-composition/model/compositionInsetSourceSearch.ts b/packages/client-composition/model/compositionInsetSourceSearch.ts
new file mode 100644
index 000000000..9a8a3c533
--- /dev/null
+++ b/packages/client-composition/model/compositionInsetSourceSearch.ts
@@ -0,0 +1,12 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { InsetsQueryParameters } from './insetsQueryParameters';
+
+export type CompositionInsetSourceSearch = {
+ /**
+ * Composition Main Index name.
+ */
+ index: string;
+
+ params?: InsetsQueryParameters;
+};
diff --git a/packages/client-composition/model/compositionRankingInfo.ts b/packages/client-composition/model/compositionRankingInfo.ts
new file mode 100644
index 000000000..5d2773bd3
--- /dev/null
+++ b/packages/client-composition/model/compositionRankingInfo.ts
@@ -0,0 +1,7 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { ComposedRankingInfo } from './composedRankingInfo';
+
+export type CompositionRankingInfo = {
+ composed?: ComposedRankingInfo;
+};
diff --git a/packages/client-composition/model/compositionRule.ts b/packages/client-composition/model/compositionRule.ts
new file mode 100644
index 000000000..b3fb3b2d0
--- /dev/null
+++ b/packages/client-composition/model/compositionRule.ts
@@ -0,0 +1,34 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { CompositionRuleConsequence } from './compositionRuleConsequence';
+import type { Condition } from './condition';
+import type { TimeRange } from './timeRange';
+
+export type CompositionRule = {
+ /**
+ * Unique record identifier.
+ */
+ objectID: string;
+
+ /**
+ * Conditions that trigger a composition rule.
+ */
+ conditions: Array;
+
+ consequence: CompositionRuleConsequence;
+
+ /**
+ * Description of the rule\'s purpose to help you distinguish between different rules.
+ */
+ description?: string;
+
+ /**
+ * Whether the rule is active.
+ */
+ enabled?: boolean;
+
+ /**
+ * Time periods when the rule is active.
+ */
+ validity?: Array;
+};
diff --git a/packages/client-composition/model/compositionRuleConsequence.ts b/packages/client-composition/model/compositionRuleConsequence.ts
new file mode 100644
index 000000000..51e26567b
--- /dev/null
+++ b/packages/client-composition/model/compositionRuleConsequence.ts
@@ -0,0 +1,10 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { CompositionBehavior } from './compositionBehavior';
+
+/**
+ * Effect of the rule.
+ */
+export type CompositionRuleConsequence = {
+ behavior: CompositionBehavior;
+};
diff --git a/packages/client-composition/model/compositionRulesBatchParams.ts b/packages/client-composition/model/compositionRulesBatchParams.ts
new file mode 100644
index 000000000..55ed11cab
--- /dev/null
+++ b/packages/client-composition/model/compositionRulesBatchParams.ts
@@ -0,0 +1,10 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { RulesMultipleBatchRequest } from './rulesMultipleBatchRequest';
+
+/**
+ * Composition rules batch parameters.
+ */
+export type CompositionRulesBatchParams = {
+ requests?: Array;
+};
diff --git a/packages/client-composition/model/compositionSource.ts b/packages/client-composition/model/compositionSource.ts
new file mode 100644
index 000000000..5ecc29688
--- /dev/null
+++ b/packages/client-composition/model/compositionSource.ts
@@ -0,0 +1,7 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { CompositionSourceSearch } from './compositionSourceSearch';
+
+export type CompositionSource = {
+ search: CompositionSourceSearch;
+};
diff --git a/packages/client-composition/model/compositionSourceSearch.ts b/packages/client-composition/model/compositionSourceSearch.ts
new file mode 100644
index 000000000..0731661e8
--- /dev/null
+++ b/packages/client-composition/model/compositionSourceSearch.ts
@@ -0,0 +1,12 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { MainInjectionQueryParameters } from './mainInjectionQueryParameters';
+
+export type CompositionSourceSearch = {
+ /**
+ * Composition Main Index name.
+ */
+ index: string;
+
+ params?: MainInjectionQueryParameters;
+};
diff --git a/packages/client-composition/model/condition.ts b/packages/client-composition/model/condition.ts
new file mode 100644
index 000000000..fea1e6776
--- /dev/null
+++ b/packages/client-composition/model/condition.ts
@@ -0,0 +1,27 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { Anchoring } from './anchoring';
+
+export type Condition = {
+ /**
+ * Query pattern that triggers the rule. You can use either a literal string, or a special pattern `{facet:ATTRIBUTE}`, where `ATTRIBUTE` is a facet name. The rule is triggered if the query matches the literal string or a value of the specified facet. For example, with `pattern: {facet:genre}`, the rule is triggered when users search for a genre, such as \"comedy\".
+ */
+ pattern?: string;
+
+ anchoring?: Anchoring;
+
+ /**
+ * Whether the pattern should match plurals, synonyms, and typos.
+ */
+ alternatives?: boolean;
+
+ /**
+ * An additional restriction that only triggers the rule, when the search has the same value as `ruleContexts` parameter. For example, if `context: mobile`, the rule is only triggered when the search request has a matching `ruleContexts: mobile`. A rule context must only contain alphanumeric characters.
+ */
+ context?: string;
+
+ /**
+ * Filters that trigger the rule. You can add add filters using the syntax `facet:value` so that the rule is triggered, when the specific filter is selected. You can use `filters` on its own or combine it with the `pattern` parameter.
+ */
+ filters?: string;
+};
diff --git a/packages/client-composition/model/deleteCompositionAction.ts b/packages/client-composition/model/deleteCompositionAction.ts
new file mode 100644
index 000000000..a1b76df20
--- /dev/null
+++ b/packages/client-composition/model/deleteCompositionAction.ts
@@ -0,0 +1,11 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Operation arguments when deleting.
+ */
+export type DeleteCompositionAction = {
+ /**
+ * Unique record identifier.
+ */
+ objectID: string;
+};
diff --git a/packages/client-composition/model/deleteCompositionRuleAction.ts b/packages/client-composition/model/deleteCompositionRuleAction.ts
new file mode 100644
index 000000000..6d1defcd5
--- /dev/null
+++ b/packages/client-composition/model/deleteCompositionRuleAction.ts
@@ -0,0 +1,11 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Operation arguments when deleting.
+ */
+export type DeleteCompositionRuleAction = {
+ /**
+ * Unique record identifier.
+ */
+ objectID: string;
+};
diff --git a/packages/client-composition/model/distinct.ts b/packages/client-composition/model/distinct.ts
new file mode 100644
index 000000000..dc87dfb00
--- /dev/null
+++ b/packages/client-composition/model/distinct.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Determines how many records of a group are included in the search results. Records with the same value for the `attributeForDistinct` attribute are considered a group. The `distinct` setting controls how many members of the group are returned. This is useful for [deduplication and grouping](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature). The `distinct` setting is ignored if `attributeForDistinct` is not set.
+ */
+export type Distinct = boolean | number;
diff --git a/packages/client-composition/model/errorBase.ts b/packages/client-composition/model/errorBase.ts
new file mode 100644
index 000000000..960e509cb
--- /dev/null
+++ b/packages/client-composition/model/errorBase.ts
@@ -0,0 +1,8 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Error.
+ */
+export type ErrorBase = Record & {
+ message?: string;
+};
diff --git a/packages/client-composition/model/exactOnSingleWordQuery.ts b/packages/client-composition/model/exactOnSingleWordQuery.ts
new file mode 100644
index 000000000..d01b358f6
--- /dev/null
+++ b/packages/client-composition/model/exactOnSingleWordQuery.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Determines how the [Exact ranking criterion](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/adjust-exact-settings/#turn-off-exact-for-some-attributes) is computed when the search query has only one word. - `attribute`. The Exact ranking criterion is 1 if the query word and attribute value are the same. For example, a search for \"road\" will match the value \"road\", but not \"road trip\". - `none`. The Exact ranking criterion is ignored on single-word searches. - `word`. The Exact ranking criterion is 1 if the query word is found in the attribute value. The query word must have at least 3 characters and must not be a stop word. Only exact matches will be highlighted, partial and prefix matches won\'t.
+ */
+export type ExactOnSingleWordQuery = 'attribute' | 'none' | 'word';
diff --git a/packages/client-composition/model/exhaustive.ts b/packages/client-composition/model/exhaustive.ts
new file mode 100644
index 000000000..6e578adf1
--- /dev/null
+++ b/packages/client-composition/model/exhaustive.ts
@@ -0,0 +1,31 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Whether certain properties of the search response are calculated exhaustive (exact) or approximated.
+ */
+export type Exhaustive = {
+ /**
+ * Whether the facet count is exhaustive (`true`) or approximate (`false`). See the [related discussion](https://support.algolia.com/hc/en-us/articles/4406975248145-Why-are-my-facet-and-hit-counts-not-accurate-).
+ */
+ facetsCount?: boolean;
+
+ /**
+ * The value is `false` if not all facet values are retrieved.
+ */
+ facetValues?: boolean;
+
+ /**
+ * Whether the `nbHits` is exhaustive (`true`) or approximate (`false`). When the query takes more than 50ms to be processed, the engine makes an approximation. This can happen when using complex filters on millions of records, when typo-tolerance was not exhaustive, or when enough hits have been retrieved (for example, after the engine finds 10,000 exact matches). `nbHits` is reported as non-exhaustive whenever an approximation is made, even if the approximation didn’t, in the end, impact the exhaustivity of the query.
+ */
+ nbHits?: boolean;
+
+ /**
+ * Rules matching exhaustivity. The value is `false` if rules were enable for this query, and could not be fully processed due a timeout. This is generally caused by the number of alternatives (such as typos) which is too large.
+ */
+ rulesMatch?: boolean;
+
+ /**
+ * Whether the typo search was exhaustive (`true`) or approximate (`false`). An approximation is done when the typo search query part takes more than 10% of the query budget (ie. 5ms by default) to be processed (this can happen when a lot of typo alternatives exist for the query). This field will not be included when typo-tolerance is entirely disabled.
+ */
+ typo?: boolean;
+};
diff --git a/packages/client-composition/model/facetFilters.ts b/packages/client-composition/model/facetFilters.ts
new file mode 100644
index 000000000..0dc5e336e
--- /dev/null
+++ b/packages/client-composition/model/facetFilters.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Filter the search by facet values, so that only records with the same facet values are retrieved. **Prefer using the `filters` parameter, which supports all filter types and combinations with boolean operators.** - `[filter1, filter2]` is interpreted as `filter1 AND filter2`. - `[[filter1, filter2], filter3]` is interpreted as `filter1 OR filter2 AND filter3`. - `facet:-value` is interpreted as `NOT facet:value`. While it\'s best to avoid attributes that start with a `-`, you can still filter them by escaping with a backslash: `facet:\\-value`.
+ */
+export type FacetFilters = Array | string;
diff --git a/packages/client-composition/model/facetHits.ts b/packages/client-composition/model/facetHits.ts
new file mode 100644
index 000000000..bd205a61e
--- /dev/null
+++ b/packages/client-composition/model/facetHits.ts
@@ -0,0 +1,18 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type FacetHits = {
+ /**
+ * Facet value.
+ */
+ value: string;
+
+ /**
+ * Highlighted attribute value, including HTML tags.
+ */
+ highlighted: string;
+
+ /**
+ * Number of records with this facet value. [The count may be approximated](https://support.algolia.com/hc/en-us/articles/4406975248145-Why-are-my-facet-and-hit-counts-not-accurate-).
+ */
+ count: number;
+};
diff --git a/packages/client-composition/model/facetOrdering.ts b/packages/client-composition/model/facetOrdering.ts
new file mode 100644
index 000000000..18b84be27
--- /dev/null
+++ b/packages/client-composition/model/facetOrdering.ts
@@ -0,0 +1,16 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { Facets } from './facets';
+import type { Value } from './value';
+
+/**
+ * Order of facet names and facet values in your UI.
+ */
+export type FacetOrdering = {
+ facets?: Facets;
+
+ /**
+ * Order of facet values. One object for each facet.
+ */
+ values?: { [key: string]: Value };
+};
diff --git a/packages/client-composition/model/facetStats.ts b/packages/client-composition/model/facetStats.ts
new file mode 100644
index 000000000..f8bb276a8
--- /dev/null
+++ b/packages/client-composition/model/facetStats.ts
@@ -0,0 +1,23 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type FacetStats = {
+ /**
+ * Minimum value in the results.
+ */
+ min?: number;
+
+ /**
+ * Maximum value in the results.
+ */
+ max?: number;
+
+ /**
+ * Average facet value in the results.
+ */
+ avg?: number;
+
+ /**
+ * Sum of all values in the results.
+ */
+ sum?: number;
+};
diff --git a/packages/client-composition/model/facets.ts b/packages/client-composition/model/facets.ts
new file mode 100644
index 000000000..d99f83ff2
--- /dev/null
+++ b/packages/client-composition/model/facets.ts
@@ -0,0 +1,11 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Order of facet names.
+ */
+export type Facets = {
+ /**
+ * Explicit order of facets or facet values. This setting lets you always show specific facets or facet values at the top of the list.
+ */
+ order?: Array;
+};
diff --git a/packages/client-composition/model/getTaskResponse.ts b/packages/client-composition/model/getTaskResponse.ts
new file mode 100644
index 000000000..b8a4c6b85
--- /dev/null
+++ b/packages/client-composition/model/getTaskResponse.ts
@@ -0,0 +1,7 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { TaskStatus } from './taskStatus';
+
+export type GetTaskResponse = {
+ status: TaskStatus;
+};
diff --git a/packages/client-composition/model/highlightResult.ts b/packages/client-composition/model/highlightResult.ts
new file mode 100644
index 000000000..102271a17
--- /dev/null
+++ b/packages/client-composition/model/highlightResult.ts
@@ -0,0 +1,5 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { HighlightResultOption } from './highlightResultOption';
+
+export type HighlightResult = HighlightResultOption | { [key: string]: HighlightResult } | Array;
diff --git a/packages/client-composition/model/highlightResultOption.ts b/packages/client-composition/model/highlightResultOption.ts
new file mode 100644
index 000000000..47ab0b748
--- /dev/null
+++ b/packages/client-composition/model/highlightResultOption.ts
@@ -0,0 +1,25 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { MatchLevel } from './matchLevel';
+
+/**
+ * Surround words that match the query with HTML tags for highlighting.
+ */
+export type HighlightResultOption = {
+ /**
+ * Highlighted attribute value, including HTML tags.
+ */
+ value: string;
+
+ matchLevel: MatchLevel;
+
+ /**
+ * List of matched words from the search query.
+ */
+ matchedWords: Array;
+
+ /**
+ * Whether the entire attribute value is highlighted.
+ */
+ fullyHighlighted?: boolean;
+};
diff --git a/packages/client-composition/model/hit.ts b/packages/client-composition/model/hit.ts
new file mode 100644
index 000000000..a7d56b6c2
--- /dev/null
+++ b/packages/client-composition/model/hit.ts
@@ -0,0 +1,29 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { HighlightResult } from './highlightResult';
+import type { HitRankingInfo } from './hitRankingInfo';
+import type { SnippetResult } from './snippetResult';
+
+/**
+ * Search result. A hit is a record from your index, augmented with special attributes for highlighting, snippeting, and ranking.
+ */
+export type Hit> = T & {
+ /**
+ * Unique record identifier.
+ */
+ objectID: string;
+
+ /**
+ * Surround words that match the query with HTML tags for highlighting.
+ */
+ _highlightResult?: { [key: string]: HighlightResult };
+
+ /**
+ * Snippets that show the context around a matching search query.
+ */
+ _snippetResult?: { [key: string]: SnippetResult };
+
+ _rankingInfo?: HitRankingInfo;
+
+ _distinctSeqID?: number;
+};
diff --git a/packages/client-composition/model/hitRankingInfo.ts b/packages/client-composition/model/hitRankingInfo.ts
new file mode 100644
index 000000000..7f1379c9a
--- /dev/null
+++ b/packages/client-composition/model/hitRankingInfo.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { CompositionRankingInfo } from './compositionRankingInfo';
+import type { RankingInfo } from './rankingInfo';
+
+export type HitRankingInfo = RankingInfo & CompositionRankingInfo;
diff --git a/packages/client-composition/model/ignorePlurals.ts b/packages/client-composition/model/ignorePlurals.ts
new file mode 100644
index 000000000..5e4ac00cb
--- /dev/null
+++ b/packages/client-composition/model/ignorePlurals.ts
@@ -0,0 +1,9 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { BooleanString } from './booleanString';
+import type { SupportedLanguage } from './supportedLanguage';
+
+/**
+ * Treat singular, plurals, and other forms of declensions as equivalent. You should only use this feature for the languages used in your index.
+ */
+export type IgnorePlurals = Array | BooleanString | boolean;
diff --git a/packages/client-composition/model/index.ts b/packages/client-composition/model/index.ts
new file mode 100644
index 000000000..e04185aa8
--- /dev/null
+++ b/packages/client-composition/model/index.ts
@@ -0,0 +1,106 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export * from './action';
+export * from './advancedSyntaxFeatures';
+export * from './alternativesAsExact';
+export * from './anchoring';
+export * from './aroundPrecision';
+export * from './aroundRadius';
+export * from './aroundRadiusAll';
+export * from './banner';
+export * from './bannerImage';
+export * from './bannerImageUrl';
+export * from './bannerLink';
+export * from './baseSearchParams';
+export * from './baseSearchParamsWithoutQuery';
+export * from './baseSearchResponse';
+export * from './batchCompositionAction';
+export * from './batchParams';
+export * from './booleanString';
+export * from './clientMethodProps';
+export * from './composedRankingInfo';
+export * from './composition';
+export * from './compositionBehavior';
+export * from './compositionInset';
+export * from './compositionInsetSource';
+export * from './compositionInsetSourceSearch';
+export * from './compositionRankingInfo';
+export * from './compositionRule';
+export * from './compositionRuleConsequence';
+export * from './compositionRulesBatchParams';
+export * from './compositionSource';
+export * from './compositionSourceSearch';
+export * from './condition';
+export * from './deleteCompositionAction';
+export * from './deleteCompositionRuleAction';
+export * from './distinct';
+export * from './errorBase';
+export * from './exactOnSingleWordQuery';
+export * from './exhaustive';
+export * from './facetFilters';
+export * from './facetHits';
+export * from './facetOrdering';
+export * from './facets';
+export * from './facetStats';
+export * from './getTaskResponse';
+export * from './highlightResult';
+export * from './highlightResultOption';
+export * from './hit';
+export * from './hitRankingInfo';
+export * from './ignorePlurals';
+export * from './indexSettingsAsSearchParams';
+export * from './injection';
+export * from './insetsQueryParameters';
+export * from './listCompositionsResponse';
+export * from './main';
+export * from './mainInjectionQueryParameters';
+export * from './matchedGeoLocation';
+export * from './matchLevel';
+export * from './mode';
+export * from './multipleBatchRequest';
+export * from './multipleBatchResponse';
+export * from './numericFilters';
+export * from './optionalFilters';
+export * from './personalization';
+export * from './queryType';
+export * from './range';
+export * from './rankingInfo';
+export * from './redirect';
+export * from './redirectRuleIndexData';
+export * from './redirectRuleIndexMetadata';
+export * from './redirectURL';
+export * from './removeStopWords';
+export * from './removeWordsIfNoResults';
+export * from './renderingContent';
+export * from './reRankingApplyFilter';
+export * from './rulesBatchCompositionAction';
+export * from './rulesMultipleBatchRequest';
+export * from './rulesMultipleBatchResponse';
+export * from './searchCompositionRulesParams';
+export * from './searchCompositionRulesResponse';
+export * from './searchForFacetValuesParams';
+export * from './searchForFacetValuesRequest';
+export * from './searchForFacetValuesResponse';
+export * from './searchForFacetValuesResults';
+export * from './searchHits';
+export * from './searchPagination';
+export * from './searchParams';
+export * from './searchParamsObject';
+export * from './searchParamsQuery';
+export * from './searchParamsSearchParams';
+export * from './searchParamsString';
+export * from './searchResponse';
+export * from './searchResults';
+export * from './searchResultsItem';
+export * from './semanticSearch';
+export * from './snippetResult';
+export * from './snippetResultOption';
+export * from './sortRemainingBy';
+export * from './supportedLanguage';
+export * from './tagFilters';
+export * from './taskStatus';
+export * from './timeRange';
+export * from './typoTolerance';
+export * from './typoToleranceEnum';
+export * from './value';
+export * from './widgets';
diff --git a/packages/client-composition/model/indexSettingsAsSearchParams.ts b/packages/client-composition/model/indexSettingsAsSearchParams.ts
new file mode 100644
index 000000000..99d1ddd57
--- /dev/null
+++ b/packages/client-composition/model/indexSettingsAsSearchParams.ts
@@ -0,0 +1,205 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { AdvancedSyntaxFeatures } from './advancedSyntaxFeatures';
+import type { AlternativesAsExact } from './alternativesAsExact';
+import type { Distinct } from './distinct';
+import type { ExactOnSingleWordQuery } from './exactOnSingleWordQuery';
+import type { IgnorePlurals } from './ignorePlurals';
+import type { Mode } from './mode';
+import type { QueryType } from './queryType';
+import type { ReRankingApplyFilter } from './reRankingApplyFilter';
+import type { RemoveStopWords } from './removeStopWords';
+import type { RemoveWordsIfNoResults } from './removeWordsIfNoResults';
+import type { RenderingContent } from './renderingContent';
+import type { SemanticSearch } from './semanticSearch';
+import type { SupportedLanguage } from './supportedLanguage';
+import type { TypoTolerance } from './typoTolerance';
+
+export type IndexSettingsAsSearchParams = {
+ /**
+ * Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. Attribute names are case-sensitive. - `*` retrieves all attributes, except attributes included in the `customRanking` and `unretrievableAttributes` settings. - To retrieve all attributes except a specific one, prefix the attribute with a dash and combine it with the `*`: `[\"*\", \"-ATTRIBUTE\"]`. - The `objectID` attribute is always included.
+ */
+ attributesToRetrieve?: Array;
+
+ /**
+ * Determines the order in which Algolia returns your results. By default, each entry corresponds to a [ranking criteria](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/). The tie-breaking algorithm sequentially applies each criterion in the order they\'re specified. If you configure a replica index for [sorting by an attribute](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/how-to/sort-by-attribute/), you put the sorting attribute at the top of the list. **Modifiers** - `asc(\"ATTRIBUTE\")`. Sort the index by the values of an attribute, in ascending order. - `desc(\"ATTRIBUTE\")`. Sort the index by the values of an attribute, in descending order. Before you modify the default setting, you should test your changes in the dashboard, and by [A/B testing](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/).
+ */
+ ranking?: Array;
+
+ /**
+ * Attributes to use as [custom ranking](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Attribute names are case-sensitive. The custom ranking attributes decide which items are shown first if the other ranking criteria are equal. Records with missing values for your selected custom ranking attributes are always sorted last. Boolean attributes are sorted based on their alphabetical order. **Modifiers** - `asc(\"ATTRIBUTE\")`. Sort the index by the values of an attribute, in ascending order. - `desc(\"ATTRIBUTE\")`. Sort the index by the values of an attribute, in descending order. If you use two or more custom ranking attributes, [reduce the precision](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/how-to/controlling-custom-ranking-metrics-precision/) of your first attributes, or the other attributes will never be applied.
+ */
+ customRanking?: Array;
+
+ /**
+ * Relevancy threshold below which less relevant results aren\'t included in the results. You can only set `relevancyStrictness` on [virtual replica indices](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/in-depth/replicas/#what-are-virtual-replicas). Use this setting to strike a balance between the relevance and number of returned results.
+ */
+ relevancyStrictness?: number;
+
+ /**
+ * Attributes to highlight. By default, all searchable attributes are highlighted. Use `*` to highlight all attributes or use an empty array `[]` to turn off highlighting. Attribute names are case-sensitive. With highlighting, strings that match the search query are surrounded by HTML tags defined by `highlightPreTag` and `highlightPostTag`. You can use this to visually highlight matching parts of a search query in your UI. For more information, see [Highlighting and snippeting](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/highlighting-snippeting/js/).
+ */
+ attributesToHighlight?: Array;
+
+ /**
+ * Attributes for which to enable snippets. Attribute names are case-sensitive. Snippets provide additional context to matched words. If you enable snippets, they include 10 words, including the matched word. The matched word will also be wrapped by HTML tags for highlighting. You can adjust the number of words with the following notation: `ATTRIBUTE:NUMBER`, where `NUMBER` is the number of words to be extracted.
+ */
+ attributesToSnippet?: Array;
+
+ /**
+ * HTML tag to insert before the highlighted parts in all highlighted results and snippets.
+ */
+ highlightPreTag?: string;
+
+ /**
+ * HTML tag to insert after the highlighted parts in all highlighted results and snippets.
+ */
+ highlightPostTag?: string;
+
+ /**
+ * String used as an ellipsis indicator when a snippet is truncated.
+ */
+ snippetEllipsisText?: string;
+
+ /**
+ * Whether to restrict highlighting and snippeting to items that at least partially matched the search query. By default, all items are highlighted and snippeted.
+ */
+ restrictHighlightAndSnippetArrays?: boolean;
+
+ /**
+ * Number of hits per page.
+ */
+ hitsPerPage?: number;
+
+ /**
+ * Minimum number of characters a word in the search query must contain to accept matches with [one typo](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#configuring-word-length-for-typos).
+ */
+ minWordSizefor1Typo?: number;
+
+ /**
+ * Minimum number of characters a word in the search query must contain to accept matches with [two typos](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#configuring-word-length-for-typos).
+ */
+ minWordSizefor2Typos?: number;
+
+ typoTolerance?: TypoTolerance;
+
+ /**
+ * Whether to allow typos on numbers in the search query. Turn off this setting to reduce the number of irrelevant matches when searching in large sets of similar numbers.
+ */
+ allowTyposOnNumericTokens?: boolean;
+
+ /**
+ * Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/). Attribute names are case-sensitive. Returning only exact matches can help when: - [Searching in hyphenated attributes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/how-to/how-to-search-in-hyphenated-attributes/). - Reducing the number of matches when you have too many. This can happen with attributes that are long blocks of text, such as product descriptions. Consider alternatives such as `disableTypoToleranceOnWords` or adding synonyms if your attributes have intentional unusual spellings that might look like typos.
+ */
+ disableTypoToleranceOnAttributes?: Array;
+
+ ignorePlurals?: IgnorePlurals;
+
+ removeStopWords?: RemoveStopWords;
+
+ /**
+ * Characters for which diacritics should be preserved. By default, Algolia removes diacritics from letters. For example, `é` becomes `e`. If this causes issues in your search, you can specify characters that should keep their diacritics.
+ */
+ keepDiacriticsOnCharacters?: string;
+
+ /**
+ * Languages for language-specific query processing steps such as plurals, stop-word removal, and word-detection dictionaries. This setting sets a default list of languages used by the `removeStopWords` and `ignorePlurals` settings. This setting also sets a dictionary for word detection in the logogram-based [CJK](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/#normalization-for-logogram-based-languages-cjk) languages. To support this, you must place the CJK language **first**. **You should always specify a query language.** If you don\'t specify an indexing language, the search engine uses all [supported languages](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/), or the languages you specified with the `ignorePlurals` or `removeStopWords` parameters. This can lead to unexpected search results. For more information, see [Language-specific configuration](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/).
+ */
+ queryLanguages?: Array;
+
+ /**
+ * Whether to split compound words in the query into their building blocks. For more information, see [Word segmentation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words). Word segmentation is supported for these languages: German, Dutch, Finnish, Swedish, and Norwegian. Decompounding doesn\'t work for words with [non-spacing mark Unicode characters](https://www.charactercodes.net/category/non-spacing_mark). For example, `Gartenstühle` won\'t be decompounded if the `ü` consists of `u` (U+0075) and `◌̈` (U+0308).
+ */
+ decompoundQuery?: boolean;
+
+ /**
+ * Whether to enable rules.
+ */
+ enableRules?: boolean;
+
+ /**
+ * Whether to enable Personalization.
+ */
+ enablePersonalization?: boolean;
+
+ queryType?: QueryType;
+
+ removeWordsIfNoResults?: RemoveWordsIfNoResults;
+
+ mode?: Mode;
+
+ semanticSearch?: SemanticSearch;
+
+ /**
+ * Whether to support phrase matching and excluding words from search queries. Use the `advancedSyntaxFeatures` parameter to control which feature is supported.
+ */
+ advancedSyntax?: boolean;
+
+ /**
+ * Words that should be considered optional when found in the query. By default, records must match all words in the search query to be included in the search results. Adding optional words can help to increase the number of search results by running an additional search query that doesn\'t include the optional words. For example, if the search query is \"action video\" and \"video\" is an optional word, the search engine runs two queries. One for \"action video\" and one for \"action\". Records that match all words are ranked higher. For a search query with 4 or more words **and** all its words are optional, the number of matched words required for a record to be included in the search results increases for every 1,000 records: - If `optionalWords` has less than 10 words, the required number of matched words increases by 1: results 1 to 1,000 require 1 matched word, results 1,001 to 2000 need 2 matched words. - If `optionalWords` has 10 or more words, the number of required matched words increases by the number of optional words divided by 5 (rounded down). For example, with 18 optional words: results 1 to 1,000 require 1 matched word, results 1,001 to 2000 need 4 matched words. For more information, see [Optional words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words).
+ */
+ optionalWords?: Array;
+
+ /**
+ * Searchable attributes for which you want to [turn off the Exact ranking criterion](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/adjust-exact-settings/#turn-off-exact-for-some-attributes). Attribute names are case-sensitive. This can be useful for attributes with long values, where the likelihood of an exact match is high, such as product descriptions. Turning off the Exact ranking criterion for these attributes favors exact matching on other attributes. This reduces the impact of individual attributes with a lot of content on ranking.
+ */
+ disableExactOnAttributes?: Array;
+
+ exactOnSingleWordQuery?: ExactOnSingleWordQuery;
+
+ /**
+ * Determine which plurals and synonyms should be considered an exact matches. By default, Algolia treats singular and plural forms of a word, and single-word synonyms, as [exact](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#exact) matches when searching. For example: - \"swimsuit\" and \"swimsuits\" are treated the same - \"swimsuit\" and \"swimwear\" are treated the same (if they are [synonyms](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/#regular-synonyms)). - `ignorePlurals`. Plurals and similar declensions added by the `ignorePlurals` setting are considered exact matches. - `singleWordSynonym`. Single-word synonyms, such as \"NY\" = \"NYC\", are considered exact matches. - `multiWordsSynonym`. Multi-word synonyms, such as \"NY\" = \"New York\", are considered exact matches.
+ */
+ alternativesAsExact?: Array;
+
+ /**
+ * Advanced search syntax features you want to support. - `exactPhrase`. Phrases in quotes must match exactly. For example, `sparkly blue \"iPhone case\"` only returns records with the exact string \"iPhone case\". - `excludeWords`. Query words prefixed with a `-` must not occur in a record. For example, `search -engine` matches records that contain \"search\" but not \"engine\". This setting only has an effect if `advancedSyntax` is true.
+ */
+ advancedSyntaxFeatures?: Array;
+
+ distinct?: Distinct;
+
+ /**
+ * Whether to replace a highlighted word with the matched synonym. By default, the original words are highlighted even if a synonym matches. For example, with `home` as a synonym for `house` and a search for `home`, records matching either \"home\" or \"house\" are included in the search results, and either \"home\" or \"house\" are highlighted. With `replaceSynonymsInHighlight` set to `true`, a search for `home` still matches the same records, but all occurrences of \"house\" are replaced by \"home\" in the highlighted response.
+ */
+ replaceSynonymsInHighlight?: boolean;
+
+ /**
+ * Minimum proximity score for two matching words. This adjusts the [Proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity) by equally scoring matches that are farther apart. For example, if `minProximity` is 2, neighboring matches and matches with one word between them would have the same score.
+ */
+ minProximity?: number;
+
+ /**
+ * Properties to include in the API response of `search` and `browse` requests. By default, all response properties are included. To reduce the response size, you can select, which attributes should be included. You can\'t exclude these properties: `message`, `warning`, `cursor`, `serverUsed`, `indexUsed`, `abTestVariantID`, `parsedQuery`, or any property triggered by the `getRankingInfo` parameter. Don\'t exclude properties that you might need in your search UI.
+ */
+ responseFields?: Array;
+
+ /**
+ * Maximum number of facet values to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).
+ */
+ maxFacetHits?: number;
+
+ /**
+ * Maximum number of facet values to return for each facet.
+ */
+ maxValuesPerFacet?: number;
+
+ /**
+ * Order in which to retrieve facet values. - `count`. Facet values are retrieved by decreasing count. The count is the number of matching records containing this facet value. - `alpha`. Retrieve facet values alphabetically. This setting doesn\'t influence how facet values are displayed in your UI (see `renderingContent`). For more information, see [facet value display](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/facet-display/js/).
+ */
+ sortFacetValuesBy?: string;
+
+ /**
+ * Whether the best matching attribute should be determined by minimum proximity. This setting only affects ranking if the Attribute ranking criterion comes before Proximity in the `ranking` setting. If true, the best matching attribute is selected based on the minimum proximity of multiple matches. Otherwise, the best matching attribute is determined by the order in the `searchableAttributes` setting.
+ */
+ attributeCriteriaComputedByMinProximity?: boolean;
+
+ renderingContent?: RenderingContent;
+
+ /**
+ * Whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/). This setting only has an effect if you activated Dynamic Re-Ranking for this index in the Algolia dashboard.
+ */
+ enableReRanking?: boolean;
+
+ reRankingApplyFilter?: ReRankingApplyFilter | null;
+};
diff --git a/packages/client-composition/model/injection.ts b/packages/client-composition/model/injection.ts
new file mode 100644
index 000000000..9b5833451
--- /dev/null
+++ b/packages/client-composition/model/injection.ts
@@ -0,0 +1,13 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { CompositionInset } from './compositionInset';
+import type { Main } from './main';
+
+export type Injection = {
+ main: Main;
+
+ /**
+ * list of insets of the current Composition.
+ */
+ insets?: Array;
+};
diff --git a/packages/client-composition/model/insetsQueryParameters.ts b/packages/client-composition/model/insetsQueryParameters.ts
new file mode 100644
index 000000000..0e8de9666
--- /dev/null
+++ b/packages/client-composition/model/insetsQueryParameters.ts
@@ -0,0 +1,227 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { AdvancedSyntaxFeatures } from './advancedSyntaxFeatures';
+import type { AlternativesAsExact } from './alternativesAsExact';
+import type { Distinct } from './distinct';
+import type { ExactOnSingleWordQuery } from './exactOnSingleWordQuery';
+import type { FacetFilters } from './facetFilters';
+import type { IgnorePlurals } from './ignorePlurals';
+import type { NumericFilters } from './numericFilters';
+import type { OptionalFilters } from './optionalFilters';
+import type { QueryType } from './queryType';
+import type { RemoveStopWords } from './removeStopWords';
+import type { RemoveWordsIfNoResults } from './removeWordsIfNoResults';
+import type { SupportedLanguage } from './supportedLanguage';
+import type { TypoTolerance } from './typoTolerance';
+
+export type InsetsQueryParameters = {
+ /**
+ * Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. Attribute names are case-sensitive. - `*` retrieves all attributes, except attributes included in the `customRanking` and `unretrievableAttributes` settings. - To retrieve all attributes except a specific one, prefix the attribute with a dash and combine it with the `*`: `[\"*\", \"-ATTRIBUTE\"]`. - The `objectID` attribute is always included.
+ */
+ attributesToRetrieve?: Array;
+
+ /**
+ * Restricts a search to a subset of your searchable attributes. Attribute names are case-sensitive.
+ */
+ restrictSearchableAttributes?: Array;
+
+ /**
+ * Filter expression to only include items that match the filter criteria in the response. You can use these filter expressions: - **Numeric filters.** ` `, where `` is one of `<`, `<=`, `=`, `!=`, `>`, `>=`. - **Ranges.** `: TO ` where `` and `` are the lower and upper limits of the range (inclusive). - **Facet filters.** `:` where `` is a facet attribute (case-sensitive) and `` a facet value. - **Tag filters.** `_tags:` or just `` (case-sensitive). - **Boolean filters.** `: true | false`. You can combine filters with `AND`, `OR`, and `NOT` operators with the following restrictions: - You can only combine filters of the same type with `OR`. **Not supported:** `facet:value OR num > 3`. - You can\'t use `NOT` with combinations of filters. **Not supported:** `NOT(facet:value OR facet:value)` - You can\'t combine conjunctions (`AND`) with `OR`. **Not supported:** `facet:value OR (facet:value AND facet:value)` Use quotes around your filters, if the facet attribute name or facet value has spaces, keywords (`OR`, `AND`, `NOT`), or quotes. If a facet attribute is an array, the filter matches if it matches at least one element of the array. For more information, see [Filters](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/).
+ */
+ filters?: string;
+
+ facetFilters?: FacetFilters;
+
+ optionalFilters?: OptionalFilters;
+
+ numericFilters?: NumericFilters;
+
+ /**
+ * Attributes to highlight. By default, all searchable attributes are highlighted. Use `*` to highlight all attributes or use an empty array `[]` to turn off highlighting. Attribute names are case-sensitive. With highlighting, strings that match the search query are surrounded by HTML tags defined by `highlightPreTag` and `highlightPostTag`. You can use this to visually highlight matching parts of a search query in your UI. For more information, see [Highlighting and snippeting](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/highlighting-snippeting/js/).
+ */
+ attributesToHighlight?: Array;
+
+ /**
+ * Attributes for which to enable snippets. Attribute names are case-sensitive. Snippets provide additional context to matched words. If you enable snippets, they include 10 words, including the matched word. The matched word will also be wrapped by HTML tags for highlighting. You can adjust the number of words with the following notation: `ATTRIBUTE:NUMBER`, where `NUMBER` is the number of words to be extracted.
+ */
+ attributesToSnippet?: Array;
+
+ /**
+ * HTML tag to insert before the highlighted parts in all highlighted results and snippets.
+ */
+ highlightPreTag?: string;
+
+ /**
+ * HTML tag to insert after the highlighted parts in all highlighted results and snippets.
+ */
+ highlightPostTag?: string;
+
+ /**
+ * String used as an ellipsis indicator when a snippet is truncated.
+ */
+ snippetEllipsisText?: string;
+
+ /**
+ * Whether to restrict highlighting and snippeting to items that at least partially matched the search query. By default, all items are highlighted and snippeted.
+ */
+ restrictHighlightAndSnippetArrays?: boolean;
+
+ /**
+ * Minimum number of characters a word in the search query must contain to accept matches with [one typo](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#configuring-word-length-for-typos).
+ */
+ minWordSizefor1Typo?: number;
+
+ /**
+ * Minimum number of characters a word in the search query must contain to accept matches with [two typos](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#configuring-word-length-for-typos).
+ */
+ minWordSizefor2Typos?: number;
+
+ typoTolerance?: TypoTolerance;
+
+ /**
+ * Whether to allow typos on numbers in the search query. Turn off this setting to reduce the number of irrelevant matches when searching in large sets of similar numbers.
+ */
+ allowTyposOnNumericTokens?: boolean;
+
+ /**
+ * Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/). Attribute names are case-sensitive. Returning only exact matches can help when: - [Searching in hyphenated attributes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/how-to/how-to-search-in-hyphenated-attributes/). - Reducing the number of matches when you have too many. This can happen with attributes that are long blocks of text, such as product descriptions. Consider alternatives such as `disableTypoToleranceOnWords` or adding synonyms if your attributes have intentional unusual spellings that might look like typos.
+ */
+ disableTypoToleranceOnAttributes?: Array;
+
+ ignorePlurals?: IgnorePlurals;
+
+ removeStopWords?: RemoveStopWords;
+
+ /**
+ * Languages for language-specific query processing steps such as plurals, stop-word removal, and word-detection dictionaries. This setting sets a default list of languages used by the `removeStopWords` and `ignorePlurals` settings. This setting also sets a dictionary for word detection in the logogram-based [CJK](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/#normalization-for-logogram-based-languages-cjk) languages. To support this, you must place the CJK language **first**. **You should always specify a query language.** If you don\'t specify an indexing language, the search engine uses all [supported languages](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/), or the languages you specified with the `ignorePlurals` or `removeStopWords` parameters. This can lead to unexpected search results. For more information, see [Language-specific configuration](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/).
+ */
+ queryLanguages?: Array;
+
+ /**
+ * ISO language codes that adjust settings that are useful for processing natural language queries (as opposed to keyword searches): - Sets `removeStopWords` and `ignorePlurals` to the list of provided languages. - Sets `removeWordsIfNoResults` to `allOptional`. - Adds a `natural_language` attribute to `ruleContexts` and `analyticsTags`.
+ */
+ naturalLanguages?: Array;
+
+ /**
+ * Whether to split compound words in the query into their building blocks. For more information, see [Word segmentation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words). Word segmentation is supported for these languages: German, Dutch, Finnish, Swedish, and Norwegian. Decompounding doesn\'t work for words with [non-spacing mark Unicode characters](https://www.charactercodes.net/category/non-spacing_mark). For example, `Gartenstühle` won\'t be decompounded if the `ü` consists of `u` (U+0075) and `◌̈` (U+0308).
+ */
+ decompoundQuery?: boolean;
+
+ /**
+ * Whether to enable rules.
+ */
+ enableRules?: boolean;
+
+ /**
+ * Assigns a rule context to the search query. [Rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) are strings that you can use to trigger matching rules.
+ */
+ ruleContexts?: Array;
+
+ /**
+ * Whether to enable Personalization.
+ */
+ enablePersonalization?: boolean;
+
+ /**
+ * Impact that Personalization should have on this search. The higher this value is, the more Personalization determines the ranking compared to other factors. For more information, see [Understanding Personalization impact](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).
+ */
+ personalizationImpact?: number;
+
+ queryType?: QueryType;
+
+ removeWordsIfNoResults?: RemoveWordsIfNoResults;
+
+ /**
+ * Whether to support phrase matching and excluding words from search queries. Use the `advancedSyntaxFeatures` parameter to control which feature is supported.
+ */
+ advancedSyntax?: boolean;
+
+ /**
+ * Words that should be considered optional when found in the query. By default, records must match all words in the search query to be included in the search results. Adding optional words can help to increase the number of search results by running an additional search query that doesn\'t include the optional words. For example, if the search query is \"action video\" and \"video\" is an optional word, the search engine runs two queries. One for \"action video\" and one for \"action\". Records that match all words are ranked higher. For a search query with 4 or more words **and** all its words are optional, the number of matched words required for a record to be included in the search results increases for every 1,000 records: - If `optionalWords` has less than 10 words, the required number of matched words increases by 1: results 1 to 1,000 require 1 matched word, results 1,001 to 2000 need 2 matched words. - If `optionalWords` has 10 or more words, the number of required matched words increases by the number of optional words divided by 5 (rounded down). For example, with 18 optional words: results 1 to 1,000 require 1 matched word, results 1,001 to 2000 need 4 matched words. For more information, see [Optional words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words).
+ */
+ optionalWords?: Array;
+
+ /**
+ * Searchable attributes for which you want to [turn off the Exact ranking criterion](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/adjust-exact-settings/#turn-off-exact-for-some-attributes). Attribute names are case-sensitive. This can be useful for attributes with long values, where the likelihood of an exact match is high, such as product descriptions. Turning off the Exact ranking criterion for these attributes favors exact matching on other attributes. This reduces the impact of individual attributes with a lot of content on ranking.
+ */
+ disableExactOnAttributes?: Array;
+
+ exactOnSingleWordQuery?: ExactOnSingleWordQuery;
+
+ /**
+ * Determine which plurals and synonyms should be considered an exact matches. By default, Algolia treats singular and plural forms of a word, and single-word synonyms, as [exact](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#exact) matches when searching. For example: - \"swimsuit\" and \"swimsuits\" are treated the same - \"swimsuit\" and \"swimwear\" are treated the same (if they are [synonyms](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/#regular-synonyms)). - `ignorePlurals`. Plurals and similar declensions added by the `ignorePlurals` setting are considered exact matches. - `singleWordSynonym`. Single-word synonyms, such as \"NY\" = \"NYC\", are considered exact matches. - `multiWordsSynonym`. Multi-word synonyms, such as \"NY\" = \"New York\", are considered exact matches.
+ */
+ alternativesAsExact?: Array;
+
+ /**
+ * Advanced search syntax features you want to support. - `exactPhrase`. Phrases in quotes must match exactly. For example, `sparkly blue \"iPhone case\"` only returns records with the exact string \"iPhone case\". - `excludeWords`. Query words prefixed with a `-` must not occur in a record. For example, `search -engine` matches records that contain \"search\" but not \"engine\". This setting only has an effect if `advancedSyntax` is true.
+ */
+ advancedSyntaxFeatures?: Array;
+
+ distinct?: Distinct;
+
+ /**
+ * Whether the search response should include detailed ranking information.
+ */
+ getRankingInfo?: boolean;
+
+ /**
+ * Whether to include a `queryID` attribute in the response. The query ID is a unique identifier for a search query and is required for tracking [click and conversion events](https://www.algolia.com/guides/sending-events/getting-started/).
+ */
+ clickAnalytics?: boolean;
+
+ /**
+ * Whether this search will be included in Analytics.
+ */
+ analytics?: boolean;
+
+ /**
+ * Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
+ */
+ analyticsTags?: Array;
+
+ /**
+ * Whether to take into account an index\'s synonyms for this search.
+ */
+ synonyms?: boolean;
+
+ /**
+ * Whether to replace a highlighted word with the matched synonym. By default, the original words are highlighted even if a synonym matches. For example, with `home` as a synonym for `house` and a search for `home`, records matching either \"home\" or \"house\" are included in the search results, and either \"home\" or \"house\" are highlighted. With `replaceSynonymsInHighlight` set to `true`, a search for `home` still matches the same records, but all occurrences of \"house\" are replaced by \"home\" in the highlighted response.
+ */
+ replaceSynonymsInHighlight?: boolean;
+
+ /**
+ * Minimum proximity score for two matching words. This adjusts the [Proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity) by equally scoring matches that are farther apart. For example, if `minProximity` is 2, neighboring matches and matches with one word between them would have the same score.
+ */
+ minProximity?: number;
+
+ /**
+ * Properties to include in the API response of `search` and `browse` requests. By default, all response properties are included. To reduce the response size, you can select, which attributes should be included. You can\'t exclude these properties: `message`, `warning`, `cursor`, `serverUsed`, `indexUsed`, `abTestVariantID`, `parsedQuery`, or any property triggered by the `getRankingInfo` parameter. Don\'t exclude properties that you might need in your search UI.
+ */
+ responseFields?: Array;
+
+ /**
+ * Maximum number of facet values to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).
+ */
+ maxFacetHits?: number;
+
+ /**
+ * Whether to include this search when calculating processing-time percentiles.
+ */
+ percentileComputation?: boolean;
+
+ /**
+ * Whether the best matching attribute should be determined by minimum proximity. This setting only affects ranking if the Attribute ranking criterion comes before Proximity in the `ranking` setting. If true, the best matching attribute is selected based on the minimum proximity of multiple matches. Otherwise, the best matching attribute is determined by the order in the `searchableAttributes` setting.
+ */
+ attributeCriteriaComputedByMinProximity?: boolean;
+
+ /**
+ * Whether to enable A/B testing for this search.
+ */
+ enableABTest?: boolean;
+
+ /**
+ * Whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/). This setting only has an effect if you activated Dynamic Re-Ranking for this index in the Algolia dashboard.
+ */
+ enableReRanking?: boolean;
+};
diff --git a/packages/client-composition/model/listCompositionsResponse.ts b/packages/client-composition/model/listCompositionsResponse.ts
new file mode 100644
index 000000000..1261a5d37
--- /dev/null
+++ b/packages/client-composition/model/listCompositionsResponse.ts
@@ -0,0 +1,15 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { Composition } from './composition';
+
+export type ListCompositionsResponse = {
+ /**
+ * All compositions in your Algolia application.
+ */
+ items: Array;
+
+ /**
+ * Number of pages.
+ */
+ nbPages: number;
+};
diff --git a/packages/client-composition/model/main.ts b/packages/client-composition/model/main.ts
new file mode 100644
index 000000000..ce0445af6
--- /dev/null
+++ b/packages/client-composition/model/main.ts
@@ -0,0 +1,7 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { CompositionSource } from './compositionSource';
+
+export type Main = {
+ source: CompositionSource;
+};
diff --git a/packages/client-composition/model/mainInjectionQueryParameters.ts b/packages/client-composition/model/mainInjectionQueryParameters.ts
new file mode 100644
index 000000000..97a8179b7
--- /dev/null
+++ b/packages/client-composition/model/mainInjectionQueryParameters.ts
@@ -0,0 +1,262 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { AdvancedSyntaxFeatures } from './advancedSyntaxFeatures';
+import type { AlternativesAsExact } from './alternativesAsExact';
+import type { Distinct } from './distinct';
+import type { ExactOnSingleWordQuery } from './exactOnSingleWordQuery';
+import type { FacetFilters } from './facetFilters';
+import type { IgnorePlurals } from './ignorePlurals';
+import type { NumericFilters } from './numericFilters';
+import type { OptionalFilters } from './optionalFilters';
+import type { QueryType } from './queryType';
+import type { RemoveStopWords } from './removeStopWords';
+import type { RemoveWordsIfNoResults } from './removeWordsIfNoResults';
+import type { SupportedLanguage } from './supportedLanguage';
+import type { TypoTolerance } from './typoTolerance';
+
+export type MainInjectionQueryParameters = {
+ /**
+ * Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. Attribute names are case-sensitive. - `*` retrieves all attributes, except attributes included in the `customRanking` and `unretrievableAttributes` settings. - To retrieve all attributes except a specific one, prefix the attribute with a dash and combine it with the `*`: `[\"*\", \"-ATTRIBUTE\"]`. - The `objectID` attribute is always included.
+ */
+ attributesToRetrieve?: Array;
+
+ /**
+ * Restricts a search to a subset of your searchable attributes. Attribute names are case-sensitive.
+ */
+ restrictSearchableAttributes?: Array;
+
+ /**
+ * Filter expression to only include items that match the filter criteria in the response. You can use these filter expressions: - **Numeric filters.** ` `, where `` is one of `<`, `<=`, `=`, `!=`, `>`, `>=`. - **Ranges.** `: TO ` where `` and `` are the lower and upper limits of the range (inclusive). - **Facet filters.** `:` where `` is a facet attribute (case-sensitive) and `` a facet value. - **Tag filters.** `_tags:` or just `` (case-sensitive). - **Boolean filters.** `: true | false`. You can combine filters with `AND`, `OR`, and `NOT` operators with the following restrictions: - You can only combine filters of the same type with `OR`. **Not supported:** `facet:value OR num > 3`. - You can\'t use `NOT` with combinations of filters. **Not supported:** `NOT(facet:value OR facet:value)` - You can\'t combine conjunctions (`AND`) with `OR`. **Not supported:** `facet:value OR (facet:value AND facet:value)` Use quotes around your filters, if the facet attribute name or facet value has spaces, keywords (`OR`, `AND`, `NOT`), or quotes. If a facet attribute is an array, the filter matches if it matches at least one element of the array. For more information, see [Filters](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/).
+ */
+ filters?: string;
+
+ facetFilters?: FacetFilters;
+
+ optionalFilters?: OptionalFilters;
+
+ numericFilters?: NumericFilters;
+
+ /**
+ * Whether to sum all filter scores. If true, all filter scores are summed. Otherwise, the maximum filter score is kept. For more information, see [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).
+ */
+ sumOrFiltersScores?: boolean;
+
+ /**
+ * Facets for which to retrieve facet values that match the search criteria and the number of matching facet values. To retrieve all facets, use the wildcard character `*`. For more information, see [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts).
+ */
+ facets?: Array;
+
+ /**
+ * Maximum number of facet values to return for each facet.
+ */
+ maxValuesPerFacet?: number;
+
+ /**
+ * Whether faceting should be applied after deduplication with `distinct`. This leads to accurate facet counts when using faceting in combination with `distinct`. It\'s usually better to use `afterDistinct` modifiers in the `attributesForFaceting` setting, as `facetingAfterDistinct` only computes correct facet counts if all records have the same facet values for the `attributeForDistinct`.
+ */
+ facetingAfterDistinct?: boolean;
+
+ /**
+ * Order in which to retrieve facet values. - `count`. Facet values are retrieved by decreasing count. The count is the number of matching records containing this facet value. - `alpha`. Retrieve facet values alphabetically. This setting doesn\'t influence how facet values are displayed in your UI (see `renderingContent`). For more information, see [facet value display](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/facet-display/js/).
+ */
+ sortFacetValuesBy?: string;
+
+ /**
+ * Attributes to highlight. By default, all searchable attributes are highlighted. Use `*` to highlight all attributes or use an empty array `[]` to turn off highlighting. Attribute names are case-sensitive. With highlighting, strings that match the search query are surrounded by HTML tags defined by `highlightPreTag` and `highlightPostTag`. You can use this to visually highlight matching parts of a search query in your UI. For more information, see [Highlighting and snippeting](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/highlighting-snippeting/js/).
+ */
+ attributesToHighlight?: Array;
+
+ /**
+ * Attributes for which to enable snippets. Attribute names are case-sensitive. Snippets provide additional context to matched words. If you enable snippets, they include 10 words, including the matched word. The matched word will also be wrapped by HTML tags for highlighting. You can adjust the number of words with the following notation: `ATTRIBUTE:NUMBER`, where `NUMBER` is the number of words to be extracted.
+ */
+ attributesToSnippet?: Array;
+
+ /**
+ * HTML tag to insert before the highlighted parts in all highlighted results and snippets.
+ */
+ highlightPreTag?: string;
+
+ /**
+ * HTML tag to insert after the highlighted parts in all highlighted results and snippets.
+ */
+ highlightPostTag?: string;
+
+ /**
+ * String used as an ellipsis indicator when a snippet is truncated.
+ */
+ snippetEllipsisText?: string;
+
+ /**
+ * Whether to restrict highlighting and snippeting to items that at least partially matched the search query. By default, all items are highlighted and snippeted.
+ */
+ restrictHighlightAndSnippetArrays?: boolean;
+
+ /**
+ * Number of hits per page.
+ */
+ hitsPerPage?: number;
+
+ /**
+ * Number of hits to retrieve (used in combination with `offset`).
+ */
+ length?: number;
+
+ /**
+ * Minimum number of characters a word in the search query must contain to accept matches with [one typo](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#configuring-word-length-for-typos).
+ */
+ minWordSizefor1Typo?: number;
+
+ /**
+ * Minimum number of characters a word in the search query must contain to accept matches with [two typos](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#configuring-word-length-for-typos).
+ */
+ minWordSizefor2Typos?: number;
+
+ typoTolerance?: TypoTolerance;
+
+ /**
+ * Whether to allow typos on numbers in the search query. Turn off this setting to reduce the number of irrelevant matches when searching in large sets of similar numbers.
+ */
+ allowTyposOnNumericTokens?: boolean;
+
+ /**
+ * Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/). Attribute names are case-sensitive. Returning only exact matches can help when: - [Searching in hyphenated attributes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/how-to/how-to-search-in-hyphenated-attributes/). - Reducing the number of matches when you have too many. This can happen with attributes that are long blocks of text, such as product descriptions. Consider alternatives such as `disableTypoToleranceOnWords` or adding synonyms if your attributes have intentional unusual spellings that might look like typos.
+ */
+ disableTypoToleranceOnAttributes?: Array;
+
+ ignorePlurals?: IgnorePlurals;
+
+ removeStopWords?: RemoveStopWords;
+
+ /**
+ * Languages for language-specific query processing steps such as plurals, stop-word removal, and word-detection dictionaries. This setting sets a default list of languages used by the `removeStopWords` and `ignorePlurals` settings. This setting also sets a dictionary for word detection in the logogram-based [CJK](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/#normalization-for-logogram-based-languages-cjk) languages. To support this, you must place the CJK language **first**. **You should always specify a query language.** If you don\'t specify an indexing language, the search engine uses all [supported languages](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/), or the languages you specified with the `ignorePlurals` or `removeStopWords` parameters. This can lead to unexpected search results. For more information, see [Language-specific configuration](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/).
+ */
+ queryLanguages?: Array;
+
+ /**
+ * ISO language codes that adjust settings that are useful for processing natural language queries (as opposed to keyword searches): - Sets `removeStopWords` and `ignorePlurals` to the list of provided languages. - Sets `removeWordsIfNoResults` to `allOptional`. - Adds a `natural_language` attribute to `ruleContexts` and `analyticsTags`.
+ */
+ naturalLanguages?: Array;
+
+ /**
+ * Whether to split compound words in the query into their building blocks. For more information, see [Word segmentation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words). Word segmentation is supported for these languages: German, Dutch, Finnish, Swedish, and Norwegian. Decompounding doesn\'t work for words with [non-spacing mark Unicode characters](https://www.charactercodes.net/category/non-spacing_mark). For example, `Gartenstühle` won\'t be decompounded if the `ü` consists of `u` (U+0075) and `◌̈` (U+0308).
+ */
+ decompoundQuery?: boolean;
+
+ /**
+ * Whether to enable rules.
+ */
+ enableRules?: boolean;
+
+ /**
+ * Assigns a rule context to the search query. [Rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) are strings that you can use to trigger matching rules.
+ */
+ ruleContexts?: Array;
+
+ /**
+ * Whether to enable Personalization.
+ */
+ enablePersonalization?: boolean;
+
+ /**
+ * Impact that Personalization should have on this search. The higher this value is, the more Personalization determines the ranking compared to other factors. For more information, see [Understanding Personalization impact](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).
+ */
+ personalizationImpact?: number;
+
+ queryType?: QueryType;
+
+ removeWordsIfNoResults?: RemoveWordsIfNoResults;
+
+ /**
+ * Whether to support phrase matching and excluding words from search queries. Use the `advancedSyntaxFeatures` parameter to control which feature is supported.
+ */
+ advancedSyntax?: boolean;
+
+ /**
+ * Words that should be considered optional when found in the query. By default, records must match all words in the search query to be included in the search results. Adding optional words can help to increase the number of search results by running an additional search query that doesn\'t include the optional words. For example, if the search query is \"action video\" and \"video\" is an optional word, the search engine runs two queries. One for \"action video\" and one for \"action\". Records that match all words are ranked higher. For a search query with 4 or more words **and** all its words are optional, the number of matched words required for a record to be included in the search results increases for every 1,000 records: - If `optionalWords` has less than 10 words, the required number of matched words increases by 1: results 1 to 1,000 require 1 matched word, results 1,001 to 2000 need 2 matched words. - If `optionalWords` has 10 or more words, the number of required matched words increases by the number of optional words divided by 5 (rounded down). For example, with 18 optional words: results 1 to 1,000 require 1 matched word, results 1,001 to 2000 need 4 matched words. For more information, see [Optional words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words).
+ */
+ optionalWords?: Array;
+
+ /**
+ * Searchable attributes for which you want to [turn off the Exact ranking criterion](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/adjust-exact-settings/#turn-off-exact-for-some-attributes). Attribute names are case-sensitive. This can be useful for attributes with long values, where the likelihood of an exact match is high, such as product descriptions. Turning off the Exact ranking criterion for these attributes favors exact matching on other attributes. This reduces the impact of individual attributes with a lot of content on ranking.
+ */
+ disableExactOnAttributes?: Array;
+
+ exactOnSingleWordQuery?: ExactOnSingleWordQuery;
+
+ /**
+ * Determine which plurals and synonyms should be considered an exact matches. By default, Algolia treats singular and plural forms of a word, and single-word synonyms, as [exact](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#exact) matches when searching. For example: - \"swimsuit\" and \"swimsuits\" are treated the same - \"swimsuit\" and \"swimwear\" are treated the same (if they are [synonyms](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/#regular-synonyms)). - `ignorePlurals`. Plurals and similar declensions added by the `ignorePlurals` setting are considered exact matches. - `singleWordSynonym`. Single-word synonyms, such as \"NY\" = \"NYC\", are considered exact matches. - `multiWordsSynonym`. Multi-word synonyms, such as \"NY\" = \"New York\", are considered exact matches.
+ */
+ alternativesAsExact?: Array;
+
+ /**
+ * Advanced search syntax features you want to support. - `exactPhrase`. Phrases in quotes must match exactly. For example, `sparkly blue \"iPhone case\"` only returns records with the exact string \"iPhone case\". - `excludeWords`. Query words prefixed with a `-` must not occur in a record. For example, `search -engine` matches records that contain \"search\" but not \"engine\". This setting only has an effect if `advancedSyntax` is true.
+ */
+ advancedSyntaxFeatures?: Array;
+
+ distinct?: Distinct;
+
+ /**
+ * Whether the search response should include detailed ranking information.
+ */
+ getRankingInfo?: boolean;
+
+ /**
+ * Whether to include a `queryID` attribute in the response. The query ID is a unique identifier for a search query and is required for tracking [click and conversion events](https://www.algolia.com/guides/sending-events/getting-started/).
+ */
+ clickAnalytics?: boolean;
+
+ /**
+ * Whether this search will be included in Analytics.
+ */
+ analytics?: boolean;
+
+ /**
+ * Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
+ */
+ analyticsTags?: Array;
+
+ /**
+ * Whether to take into account an index\'s synonyms for this search.
+ */
+ synonyms?: boolean;
+
+ /**
+ * Whether to replace a highlighted word with the matched synonym. By default, the original words are highlighted even if a synonym matches. For example, with `home` as a synonym for `house` and a search for `home`, records matching either \"home\" or \"house\" are included in the search results, and either \"home\" or \"house\" are highlighted. With `replaceSynonymsInHighlight` set to `true`, a search for `home` still matches the same records, but all occurrences of \"house\" are replaced by \"home\" in the highlighted response.
+ */
+ replaceSynonymsInHighlight?: boolean;
+
+ /**
+ * Minimum proximity score for two matching words. This adjusts the [Proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity) by equally scoring matches that are farther apart. For example, if `minProximity` is 2, neighboring matches and matches with one word between them would have the same score.
+ */
+ minProximity?: number;
+
+ /**
+ * Properties to include in the API response of `search` and `browse` requests. By default, all response properties are included. To reduce the response size, you can select, which attributes should be included. You can\'t exclude these properties: `message`, `warning`, `cursor`, `serverUsed`, `indexUsed`, `abTestVariantID`, `parsedQuery`, or any property triggered by the `getRankingInfo` parameter. Don\'t exclude properties that you might need in your search UI.
+ */
+ responseFields?: Array;
+
+ /**
+ * Maximum number of facet values to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).
+ */
+ maxFacetHits?: number;
+
+ /**
+ * Whether to include this search when calculating processing-time percentiles.
+ */
+ percentileComputation?: boolean;
+
+ /**
+ * Whether the best matching attribute should be determined by minimum proximity. This setting only affects ranking if the Attribute ranking criterion comes before Proximity in the `ranking` setting. If true, the best matching attribute is selected based on the minimum proximity of multiple matches. Otherwise, the best matching attribute is determined by the order in the `searchableAttributes` setting.
+ */
+ attributeCriteriaComputedByMinProximity?: boolean;
+
+ /**
+ * Whether to enable A/B testing for this search.
+ */
+ enableABTest?: boolean;
+
+ /**
+ * Whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/). This setting only has an effect if you activated Dynamic Re-Ranking for this index in the Algolia dashboard.
+ */
+ enableReRanking?: boolean;
+};
diff --git a/packages/client-composition/model/matchLevel.ts b/packages/client-composition/model/matchLevel.ts
new file mode 100644
index 000000000..2cb9f4d21
--- /dev/null
+++ b/packages/client-composition/model/matchLevel.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Whether the whole query string matches or only a part.
+ */
+export type MatchLevel = 'none' | 'partial' | 'full';
diff --git a/packages/client-composition/model/matchedGeoLocation.ts b/packages/client-composition/model/matchedGeoLocation.ts
new file mode 100644
index 000000000..018634191
--- /dev/null
+++ b/packages/client-composition/model/matchedGeoLocation.ts
@@ -0,0 +1,18 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type MatchedGeoLocation = {
+ /**
+ * Latitude of the matched location.
+ */
+ lat?: number;
+
+ /**
+ * Longitude of the matched location.
+ */
+ lng?: number;
+
+ /**
+ * Distance between the matched location and the search location (in meters).
+ */
+ distance?: number;
+};
diff --git a/packages/client-composition/model/mode.ts b/packages/client-composition/model/mode.ts
new file mode 100644
index 000000000..36561b89e
--- /dev/null
+++ b/packages/client-composition/model/mode.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Search mode the index will use to query for results. This setting only applies to indices, for which Algolia enabled NeuralSearch for you.
+ */
+export type Mode = 'neuralSearch' | 'keywordSearch';
diff --git a/packages/client-composition/model/multipleBatchRequest.ts b/packages/client-composition/model/multipleBatchRequest.ts
new file mode 100644
index 000000000..857bdca1e
--- /dev/null
+++ b/packages/client-composition/model/multipleBatchRequest.ts
@@ -0,0 +1,10 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { Action } from './action';
+import type { BatchCompositionAction } from './batchCompositionAction';
+
+export type MultipleBatchRequest = {
+ action: Action;
+
+ body: BatchCompositionAction;
+};
diff --git a/packages/client-composition/model/multipleBatchResponse.ts b/packages/client-composition/model/multipleBatchResponse.ts
new file mode 100644
index 000000000..a5fa74e64
--- /dev/null
+++ b/packages/client-composition/model/multipleBatchResponse.ts
@@ -0,0 +1,8 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type MultipleBatchResponse = {
+ /**
+ * Task IDs. One for each index.
+ */
+ taskID: { [key: string]: number };
+};
diff --git a/packages/client-composition/model/numericFilters.ts b/packages/client-composition/model/numericFilters.ts
new file mode 100644
index 000000000..6129dc5d3
--- /dev/null
+++ b/packages/client-composition/model/numericFilters.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Filter by numeric facets. **Prefer using the `filters` parameter, which supports all filter types and combinations with boolean operators.** You can use numeric comparison operators: `<`, `<=`, `=`, `!=`, `>`, `>=`. Comparisons are precise up to 3 decimals. You can also provide ranges: `facet: TO `. The range includes the lower and upper boundaries. The same combination rules apply as for `facetFilters`.
+ */
+export type NumericFilters = Array | string;
diff --git a/packages/client-composition/model/optionalFilters.ts b/packages/client-composition/model/optionalFilters.ts
new file mode 100644
index 000000000..35275edcc
--- /dev/null
+++ b/packages/client-composition/model/optionalFilters.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Filters to promote or demote records in the search results. Optional filters work like facet filters, but they don\'t exclude records from the search results. Records that match the optional filter rank before records that don\'t match. If you\'re using a negative filter `facet:-value`, matching records rank after records that don\'t match. - Optional filters don\'t work on virtual replicas. - Optional filters are applied _after_ sort-by attributes. - Optional filters don\'t work with numeric attributes.
+ */
+export type OptionalFilters = Array | string;
diff --git a/packages/client-composition/model/personalization.ts b/packages/client-composition/model/personalization.ts
new file mode 100644
index 000000000..c8efd58b1
--- /dev/null
+++ b/packages/client-composition/model/personalization.ts
@@ -0,0 +1,18 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type Personalization = {
+ /**
+ * The score of the filters.
+ */
+ filtersScore?: number;
+
+ /**
+ * The score of the ranking.
+ */
+ rankingScore?: number;
+
+ /**
+ * The score of the event.
+ */
+ score?: number;
+};
diff --git a/packages/client-composition/model/queryType.ts b/packages/client-composition/model/queryType.ts
new file mode 100644
index 000000000..b16a40de3
--- /dev/null
+++ b/packages/client-composition/model/queryType.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Determines if and how query words are interpreted as prefixes. By default, only the last query word is treated as a prefix (`prefixLast`). To turn off prefix search, use `prefixNone`. Avoid `prefixAll`, which treats all query words as prefixes. This might lead to counterintuitive results and makes your search slower. For more information, see [Prefix searching](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).
+ */
+export type QueryType = 'prefixLast' | 'prefixAll' | 'prefixNone';
diff --git a/packages/client-composition/model/range.ts b/packages/client-composition/model/range.ts
new file mode 100644
index 000000000..780b75be7
--- /dev/null
+++ b/packages/client-composition/model/range.ts
@@ -0,0 +1,16 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Range object with lower and upper values in meters to define custom ranges.
+ */
+export type Range = {
+ /**
+ * Lower boundary of a range in meters. The Geo ranking criterion considers all records within the range to be equal.
+ */
+ from?: number;
+
+ /**
+ * Upper boundary of a range in meters. The Geo ranking criterion considers all records within the range to be equal.
+ */
+ value?: number;
+};
diff --git a/packages/client-composition/model/rankingInfo.ts b/packages/client-composition/model/rankingInfo.ts
new file mode 100644
index 000000000..50c5a3058
--- /dev/null
+++ b/packages/client-composition/model/rankingInfo.ts
@@ -0,0 +1,68 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { MatchedGeoLocation } from './matchedGeoLocation';
+import type { Personalization } from './personalization';
+
+/**
+ * Object with detailed information about the record\'s ranking.
+ */
+export type RankingInfo = {
+ /**
+ * Whether a filter matched the query.
+ */
+ filters?: number;
+
+ /**
+ * Position of the first matched word in the best matching attribute of the record.
+ */
+ firstMatchedWord: number;
+
+ /**
+ * Distance between the geo location in the search query and the best matching geo location in the record, divided by the geo precision (in meters).
+ */
+ geoDistance: number;
+
+ /**
+ * Precision used when computing the geo distance, in meters.
+ */
+ geoPrecision?: number;
+
+ matchedGeoLocation?: MatchedGeoLocation;
+
+ personalization?: Personalization;
+
+ /**
+ * Number of exactly matched words.
+ */
+ nbExactWords: number;
+
+ /**
+ * Number of typos encountered when matching the record.
+ */
+ nbTypos: number;
+
+ /**
+ * Whether the record was promoted by a rule.
+ */
+ promoted?: boolean;
+
+ /**
+ * Number of words between multiple matches in the query plus 1. For single word queries, `proximityDistance` is 0.
+ */
+ proximityDistance?: number;
+
+ /**
+ * Overall ranking of the record, expressed as a single integer. This attribute is internal.
+ */
+ userScore: number;
+
+ /**
+ * Number of matched words.
+ */
+ words?: number;
+
+ /**
+ * Whether the record is re-ranked.
+ */
+ promotedByReRanking?: boolean;
+};
diff --git a/packages/client-composition/model/reRankingApplyFilter.ts b/packages/client-composition/model/reRankingApplyFilter.ts
new file mode 100644
index 000000000..6d4bd8b9f
--- /dev/null
+++ b/packages/client-composition/model/reRankingApplyFilter.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Restrict [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) to records that match these filters.
+ */
+export type ReRankingApplyFilter = Array | string;
diff --git a/packages/client-composition/model/redirect.ts b/packages/client-composition/model/redirect.ts
new file mode 100644
index 000000000..fa3ea30ff
--- /dev/null
+++ b/packages/client-composition/model/redirect.ts
@@ -0,0 +1,10 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { RedirectRuleIndexMetadata } from './redirectRuleIndexMetadata';
+
+/**
+ * [Redirect results to a URL](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/redirects/), this this parameter is for internal use only.
+ */
+export type Redirect = {
+ index?: Array;
+};
diff --git a/packages/client-composition/model/redirectRuleIndexData.ts b/packages/client-composition/model/redirectRuleIndexData.ts
new file mode 100644
index 000000000..fbb7ea140
--- /dev/null
+++ b/packages/client-composition/model/redirectRuleIndexData.ts
@@ -0,0 +1,8 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Redirect rule data.
+ */
+export type RedirectRuleIndexData = {
+ ruleObjectID: string;
+};
diff --git a/packages/client-composition/model/redirectRuleIndexMetadata.ts b/packages/client-composition/model/redirectRuleIndexMetadata.ts
new file mode 100644
index 000000000..33802fc69
--- /dev/null
+++ b/packages/client-composition/model/redirectRuleIndexMetadata.ts
@@ -0,0 +1,27 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { RedirectRuleIndexData } from './redirectRuleIndexData';
+
+export type RedirectRuleIndexMetadata = {
+ /**
+ * Source index for the redirect rule.
+ */
+ source: string;
+
+ /**
+ * Destination index for the redirect rule.
+ */
+ dest: string;
+
+ /**
+ * Reason for the redirect rule.
+ */
+ reason: string;
+
+ /**
+ * Redirect rule status.
+ */
+ succeed: boolean;
+
+ data: RedirectRuleIndexData;
+};
diff --git a/packages/client-composition/model/redirectURL.ts b/packages/client-composition/model/redirectURL.ts
new file mode 100644
index 000000000..8f66f7ee2
--- /dev/null
+++ b/packages/client-composition/model/redirectURL.ts
@@ -0,0 +1,8 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * The redirect rule container.
+ */
+export type RedirectURL = {
+ url?: string;
+};
diff --git a/packages/client-composition/model/removeStopWords.ts b/packages/client-composition/model/removeStopWords.ts
new file mode 100644
index 000000000..263ad1184
--- /dev/null
+++ b/packages/client-composition/model/removeStopWords.ts
@@ -0,0 +1,8 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { SupportedLanguage } from './supportedLanguage';
+
+/**
+ * Removes stop words from the search query. Stop words are common words like articles, conjunctions, prepositions, or pronouns that have little or no meaning on their own. In English, \"the\", \"a\", or \"and\" are stop words. You should only use this feature for the languages used in your index.
+ */
+export type RemoveStopWords = Array | boolean;
diff --git a/packages/client-composition/model/removeWordsIfNoResults.ts b/packages/client-composition/model/removeWordsIfNoResults.ts
new file mode 100644
index 000000000..3b61da6d8
--- /dev/null
+++ b/packages/client-composition/model/removeWordsIfNoResults.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Strategy for removing words from the query when it doesn\'t return any results. This helps to avoid returning empty search results. - `none`. No words are removed when a query doesn\'t return results. - `lastWords`. Treat the last (then second to last, then third to last) word as optional, until there are results or at most 5 words have been removed. - `firstWords`. Treat the first (then second, then third) word as optional, until there are results or at most 5 words have been removed. - `allOptional`. Treat all words as optional. For more information, see [Remove words to improve results](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/).
+ */
+export type RemoveWordsIfNoResults = 'none' | 'lastWords' | 'firstWords' | 'allOptional';
diff --git a/packages/client-composition/model/renderingContent.ts b/packages/client-composition/model/renderingContent.ts
new file mode 100644
index 000000000..ddb01bde8
--- /dev/null
+++ b/packages/client-composition/model/renderingContent.ts
@@ -0,0 +1,16 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { FacetOrdering } from './facetOrdering';
+import type { RedirectURL } from './redirectURL';
+import type { Widgets } from './widgets';
+
+/**
+ * Extra data that can be used in the search UI. You can use this to control aspects of your search UI, such as the order of facet names and values without changing your frontend code.
+ */
+export type RenderingContent = {
+ facetOrdering?: FacetOrdering;
+
+ redirect?: RedirectURL;
+
+ widgets?: Widgets;
+};
diff --git a/packages/client-composition/model/rulesBatchCompositionAction.ts b/packages/client-composition/model/rulesBatchCompositionAction.ts
new file mode 100644
index 000000000..98d4f7b2d
--- /dev/null
+++ b/packages/client-composition/model/rulesBatchCompositionAction.ts
@@ -0,0 +1,7 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { CompositionRule } from './compositionRule';
+
+import type { DeleteCompositionRuleAction } from './deleteCompositionRuleAction';
+
+export type RulesBatchCompositionAction = CompositionRule | DeleteCompositionRuleAction;
diff --git a/packages/client-composition/model/rulesMultipleBatchRequest.ts b/packages/client-composition/model/rulesMultipleBatchRequest.ts
new file mode 100644
index 000000000..3bbbe20be
--- /dev/null
+++ b/packages/client-composition/model/rulesMultipleBatchRequest.ts
@@ -0,0 +1,10 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { Action } from './action';
+import type { RulesBatchCompositionAction } from './rulesBatchCompositionAction';
+
+export type RulesMultipleBatchRequest = {
+ action: Action;
+
+ body: RulesBatchCompositionAction;
+};
diff --git a/packages/client-composition/model/rulesMultipleBatchResponse.ts b/packages/client-composition/model/rulesMultipleBatchResponse.ts
new file mode 100644
index 000000000..26b97ef67
--- /dev/null
+++ b/packages/client-composition/model/rulesMultipleBatchResponse.ts
@@ -0,0 +1,8 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type RulesMultipleBatchResponse = {
+ /**
+ * Unique identifier of a task. A successful API response means that a task was added to a queue. It might not run immediately. You can check the task\'s progress with the [`task` operation](#tag/Indices/operation/getTask) and this `taskID`.
+ */
+ taskID: number;
+};
diff --git a/packages/client-composition/model/searchCompositionRulesParams.ts b/packages/client-composition/model/searchCompositionRulesParams.ts
new file mode 100644
index 000000000..51fbc9805
--- /dev/null
+++ b/packages/client-composition/model/searchCompositionRulesParams.ts
@@ -0,0 +1,35 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { Anchoring } from './anchoring';
+
+/**
+ * Composition Rules search parameters.
+ */
+export type SearchCompositionRulesParams = {
+ /**
+ * Search query for rules.
+ */
+ query?: string;
+
+ anchoring?: Anchoring;
+
+ /**
+ * Only return composition rules that match the context (exact match).
+ */
+ context?: string;
+
+ /**
+ * Requested page of the API response. Algolia uses `page` and `hitsPerPage` to control how search results are displayed ([paginated](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/)). - `hitsPerPage`: sets the number of search results (_hits_) displayed per page. - `page`: specifies the page number of the search results you want to retrieve. Page numbering starts at 0, so the first page is `page=0`, the second is `page=1`, and so on. For example, to display 10 results per page starting from the third page, set `hitsPerPage` to 10 and `page` to 2.
+ */
+ page?: number;
+
+ /**
+ * Maximum number of hits per page. Algolia uses `page` and `hitsPerPage` to control how search results are displayed ([paginated](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/)). - `hitsPerPage`: sets the number of search results (_hits_) displayed per page. - `page`: specifies the page number of the search results you want to retrieve. Page numbering starts at 0, so the first page is `page=0`, the second is `page=1`, and so on. For example, to display 10 results per page starting from the third page, set `hitsPerPage` to 10 and `page` to 2.
+ */
+ hitsPerPage?: number;
+
+ /**
+ * If `true`, return only enabled composition rules. If `false`, return only inactive composition rules. By default, _all_ composition rules are returned.
+ */
+ enabled?: boolean | null;
+};
diff --git a/packages/client-composition/model/searchCompositionRulesResponse.ts b/packages/client-composition/model/searchCompositionRulesResponse.ts
new file mode 100644
index 000000000..414928cbd
--- /dev/null
+++ b/packages/client-composition/model/searchCompositionRulesResponse.ts
@@ -0,0 +1,25 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { CompositionRule } from './compositionRule';
+
+export type SearchCompositionRulesResponse = {
+ /**
+ * Composition rules that matched the search criteria.
+ */
+ hits: Array;
+
+ /**
+ * Number of composition rules that matched the search criteria.
+ */
+ nbHits: number;
+
+ /**
+ * Current page.
+ */
+ page: number;
+
+ /**
+ * Number of pages.
+ */
+ nbPages: number;
+};
diff --git a/packages/client-composition/model/searchForFacetValuesParams.ts b/packages/client-composition/model/searchForFacetValuesParams.ts
new file mode 100644
index 000000000..9d398717f
--- /dev/null
+++ b/packages/client-composition/model/searchForFacetValuesParams.ts
@@ -0,0 +1,17 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { SearchParamsSearchParams } from './searchParamsSearchParams';
+
+export type SearchForFacetValuesParams = {
+ /**
+ * Search query.
+ */
+ query?: string;
+
+ /**
+ * Maximum number of facet values to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).
+ */
+ maxFacetHits?: number;
+
+ searchQuery?: SearchParamsSearchParams;
+};
diff --git a/packages/client-composition/model/searchForFacetValuesRequest.ts b/packages/client-composition/model/searchForFacetValuesRequest.ts
new file mode 100644
index 000000000..62ac3a2dd
--- /dev/null
+++ b/packages/client-composition/model/searchForFacetValuesRequest.ts
@@ -0,0 +1,7 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { SearchForFacetValuesParams } from './searchForFacetValuesParams';
+
+export type SearchForFacetValuesRequest = {
+ params?: SearchForFacetValuesParams;
+};
diff --git a/packages/client-composition/model/searchForFacetValuesResponse.ts b/packages/client-composition/model/searchForFacetValuesResponse.ts
new file mode 100644
index 000000000..cbe8e92f7
--- /dev/null
+++ b/packages/client-composition/model/searchForFacetValuesResponse.ts
@@ -0,0 +1,10 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { SearchForFacetValuesResults } from './searchForFacetValuesResults';
+
+export type SearchForFacetValuesResponse = {
+ /**
+ * Search for facet values results.
+ */
+ results?: Array;
+};
diff --git a/packages/client-composition/model/searchForFacetValuesResults.ts b/packages/client-composition/model/searchForFacetValuesResults.ts
new file mode 100644
index 000000000..94960fdee
--- /dev/null
+++ b/packages/client-composition/model/searchForFacetValuesResults.ts
@@ -0,0 +1,22 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { FacetHits } from './facetHits';
+
+export type SearchForFacetValuesResults = {
+ indexName: string;
+
+ /**
+ * Matching facet values.
+ */
+ facetHits: Array;
+
+ /**
+ * Whether the facet count is exhaustive (true) or approximate (false). For more information, see [Why are my facet and hit counts not accurate](https://support.algolia.com/hc/en-us/articles/4406975248145-Why-are-my-facet-and-hit-counts-not-accurate-).
+ */
+ exhaustiveFacetsCount: boolean;
+
+ /**
+ * Time the server took to process the request, in milliseconds.
+ */
+ processingTimeMS?: number;
+};
diff --git a/packages/client-composition/model/searchHits.ts b/packages/client-composition/model/searchHits.ts
new file mode 100644
index 000000000..1c40dc031
--- /dev/null
+++ b/packages/client-composition/model/searchHits.ts
@@ -0,0 +1,10 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { Hit } from './hit';
+
+export type SearchHits> = Record & {
+ /**
+ * Search results (hits). Hits are records from your index that match the search criteria, augmented with additional attributes, such as, for highlighting.
+ */
+ hits: Hit[];
+};
diff --git a/packages/client-composition/model/searchPagination.ts b/packages/client-composition/model/searchPagination.ts
new file mode 100644
index 000000000..284961b8f
--- /dev/null
+++ b/packages/client-composition/model/searchPagination.ts
@@ -0,0 +1,23 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type SearchPagination = {
+ /**
+ * Page of search results to retrieve.
+ */
+ page?: number;
+
+ /**
+ * Number of results (hits).
+ */
+ nbHits?: number;
+
+ /**
+ * Number of pages of results.
+ */
+ nbPages?: number;
+
+ /**
+ * Number of hits per page.
+ */
+ hitsPerPage?: number;
+};
diff --git a/packages/client-composition/model/searchParams.ts b/packages/client-composition/model/searchParams.ts
new file mode 100644
index 000000000..38bf1b3bd
--- /dev/null
+++ b/packages/client-composition/model/searchParams.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { SearchParamsObject } from './searchParamsObject';
+import type { SearchParamsString } from './searchParamsString';
+
+export type SearchParams = SearchParamsString | SearchParamsObject;
diff --git a/packages/client-composition/model/searchParamsObject.ts b/packages/client-composition/model/searchParamsObject.ts
new file mode 100644
index 000000000..b79d4f8f3
--- /dev/null
+++ b/packages/client-composition/model/searchParamsObject.ts
@@ -0,0 +1,9 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { BaseSearchParams } from './baseSearchParams';
+import type { IndexSettingsAsSearchParams } from './indexSettingsAsSearchParams';
+
+/**
+ * Each parameter value, including the `query` must not be larger than 512 bytes.
+ */
+export type SearchParamsObject = BaseSearchParams & IndexSettingsAsSearchParams;
diff --git a/packages/client-composition/model/searchParamsQuery.ts b/packages/client-composition/model/searchParamsQuery.ts
new file mode 100644
index 000000000..9f1926f6c
--- /dev/null
+++ b/packages/client-composition/model/searchParamsQuery.ts
@@ -0,0 +1,8 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type SearchParamsQuery = {
+ /**
+ * Search query.
+ */
+ query?: string;
+};
diff --git a/packages/client-composition/model/searchParamsSearchParams.ts b/packages/client-composition/model/searchParamsSearchParams.ts
new file mode 100644
index 000000000..5029ff478
--- /dev/null
+++ b/packages/client-composition/model/searchParamsSearchParams.ts
@@ -0,0 +1,122 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { AroundPrecision } from './aroundPrecision';
+import type { AroundRadius } from './aroundRadius';
+import type { FacetFilters } from './facetFilters';
+import type { NumericFilters } from './numericFilters';
+import type { OptionalFilters } from './optionalFilters';
+import type { SupportedLanguage } from './supportedLanguage';
+
+export type SearchParamsSearchParams = {
+ /**
+ * Search query.
+ */
+ query?: string;
+
+ /**
+ * Filter expression to only include items that match the filter criteria in the response. You can use these filter expressions: - **Numeric filters.** ` `, where `` is one of `<`, `<=`, `=`, `!=`, `>`, `>=`. - **Ranges.** `: TO ` where `` and `` are the lower and upper limits of the range (inclusive). - **Facet filters.** `:` where `` is a facet attribute (case-sensitive) and `` a facet value. - **Tag filters.** `_tags:` or just `` (case-sensitive). - **Boolean filters.** `: true | false`. You can combine filters with `AND`, `OR`, and `NOT` operators with the following restrictions: - You can only combine filters of the same type with `OR`. **Not supported:** `facet:value OR num > 3`. - You can\'t use `NOT` with combinations of filters. **Not supported:** `NOT(facet:value OR facet:value)` - You can\'t combine conjunctions (`AND`) with `OR`. **Not supported:** `facet:value OR (facet:value AND facet:value)` Use quotes around your filters, if the facet attribute name or facet value has spaces, keywords (`OR`, `AND`, `NOT`), or quotes. If a facet attribute is an array, the filter matches if it matches at least one element of the array. For more information, see [Filters](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/).
+ */
+ filters?: string;
+
+ /**
+ * Page of search results to retrieve.
+ */
+ page?: number;
+
+ /**
+ * Whether the search response should include detailed ranking information.
+ */
+ getRankingInfo?: boolean;
+
+ relevancyStrictness?: number;
+
+ facetFilters?: FacetFilters;
+
+ optionalFilters?: OptionalFilters;
+
+ numericFilters?: NumericFilters;
+
+ /**
+ * Number of hits per page.
+ */
+ hitsPerPage?: number;
+
+ /**
+ * Coordinates for the center of a circle, expressed as a comma-separated string of latitude and longitude. Only records included within a circle around this central location are included in the results. The radius of the circle is determined by the `aroundRadius` and `minimumAroundRadius` settings. This parameter is ignored if you also specify `insidePolygon` or `insideBoundingBox`.
+ */
+ aroundLatLng?: string;
+
+ /**
+ * Whether to obtain the coordinates from the request\'s IP address.
+ */
+ aroundLatLngViaIP?: boolean;
+
+ aroundRadius?: AroundRadius;
+
+ aroundPrecision?: AroundPrecision;
+
+ /**
+ * Minimum radius (in meters) for a search around a location when `aroundRadius` isn\'t set.
+ */
+ minimumAroundRadius?: number;
+
+ /**
+ * Coordinates for a rectangular area in which to search. Each bounding box is defined by the two opposite points of its diagonal, and expressed as latitude and longitude pair: `[p1 lat, p1 long, p2 lat, p2 long]`. Provide multiple bounding boxes as nested arrays. For more information, see [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas).
+ */
+ insideBoundingBox?: Array>;
+
+ /**
+ * Coordinates of a polygon in which to search. Polygons are defined by 3 to 10,000 points. Each point is represented by its latitude and longitude. Provide multiple polygons as nested arrays. For more information, see [filtering inside polygons](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas). This parameter is ignored if you also specify `insideBoundingBox`.
+ */
+ insidePolygon?: Array>;
+
+ /**
+ * Languages for language-specific query processing steps such as plurals, stop-word removal, and word-detection dictionaries. This setting sets a default list of languages used by the `removeStopWords` and `ignorePlurals` settings. This setting also sets a dictionary for word detection in the logogram-based [CJK](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/#normalization-for-logogram-based-languages-cjk) languages. To support this, you must place the CJK language **first**. **You should always specify a query language.** If you don\'t specify an indexing language, the search engine uses all [supported languages](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/), or the languages you specified with the `ignorePlurals` or `removeStopWords` parameters. This can lead to unexpected search results. For more information, see [Language-specific configuration](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/).
+ */
+ queryLanguages?: Array;
+
+ /**
+ * ISO language codes that adjust settings that are useful for processing natural language queries (as opposed to keyword searches): - Sets `removeStopWords` and `ignorePlurals` to the list of provided languages. - Sets `removeWordsIfNoResults` to `allOptional`. - Adds a `natural_language` attribute to `ruleContexts` and `analyticsTags`.
+ */
+ naturalLanguages?: Array;
+
+ /**
+ * Whether to enable rules.
+ */
+ enableRules?: boolean;
+
+ /**
+ * Assigns a rule context to the search query. [Rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) are strings that you can use to trigger matching rules.
+ */
+ ruleContexts?: Array;
+
+ /**
+ * Unique pseudonymous or anonymous user identifier. This helps with analytics and click and conversion events. For more information, see [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/).
+ */
+ userToken?: string;
+
+ /**
+ * Whether to include a `queryID` attribute in the response. The query ID is a unique identifier for a search query and is required for tracking [click and conversion events](https://www.algolia.com/guides/sending-events/getting-started/).
+ */
+ clickAnalytics?: boolean;
+
+ /**
+ * Whether this search will be included in Analytics.
+ */
+ analytics?: boolean;
+
+ /**
+ * Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
+ */
+ analyticsTags?: Array;
+
+ /**
+ * Whether to enable A/B testing for this search.
+ */
+ enableABTest?: boolean;
+
+ /**
+ * Whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/). This setting only has an effect if you activated Dynamic Re-Ranking for this index in the Algolia dashboard.
+ */
+ enableReRanking?: boolean;
+};
diff --git a/packages/client-composition/model/searchParamsString.ts b/packages/client-composition/model/searchParamsString.ts
new file mode 100644
index 000000000..78e0b5950
--- /dev/null
+++ b/packages/client-composition/model/searchParamsString.ts
@@ -0,0 +1,11 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Search parameters as query string.
+ */
+export type SearchParamsString = {
+ /**
+ * Search parameters as a URL-encoded query string.
+ */
+ params?: string;
+};
diff --git a/packages/client-composition/model/searchResponse.ts b/packages/client-composition/model/searchResponse.ts
new file mode 100644
index 000000000..1883cde16
--- /dev/null
+++ b/packages/client-composition/model/searchResponse.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { BaseSearchResponse } from './baseSearchResponse';
+import type { SearchResults } from './searchResults';
+
+export type SearchResponse> = BaseSearchResponse & SearchResults;
diff --git a/packages/client-composition/model/searchResults.ts b/packages/client-composition/model/searchResults.ts
new file mode 100644
index 000000000..f1846efb9
--- /dev/null
+++ b/packages/client-composition/model/searchResults.ts
@@ -0,0 +1,10 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { SearchResultsItem } from './searchResultsItem';
+
+export type SearchResults> = {
+ /**
+ * Search results.
+ */
+ results?: SearchResultsItem[];
+};
diff --git a/packages/client-composition/model/searchResultsItem.ts b/packages/client-composition/model/searchResultsItem.ts
new file mode 100644
index 000000000..a7c5c336b
--- /dev/null
+++ b/packages/client-composition/model/searchResultsItem.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { SearchHits } from './searchHits';
+import type { SearchPagination } from './searchPagination';
+
+export type SearchResultsItem> = SearchHits & SearchPagination;
diff --git a/packages/client-composition/model/semanticSearch.ts b/packages/client-composition/model/semanticSearch.ts
new file mode 100644
index 000000000..851ce7838
--- /dev/null
+++ b/packages/client-composition/model/semanticSearch.ts
@@ -0,0 +1,11 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Settings for the semantic search part of NeuralSearch. Only used when `mode` is `neuralSearch`.
+ */
+export type SemanticSearch = {
+ /**
+ * Indices from which to collect click and conversion events. If null, the current index and all its replicas are used.
+ */
+ eventSources?: Array | null;
+};
diff --git a/packages/client-composition/model/snippetResult.ts b/packages/client-composition/model/snippetResult.ts
new file mode 100644
index 000000000..0d9abff48
--- /dev/null
+++ b/packages/client-composition/model/snippetResult.ts
@@ -0,0 +1,5 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { SnippetResultOption } from './snippetResultOption';
+
+export type SnippetResult = SnippetResultOption | { [key: string]: SnippetResult } | Array;
diff --git a/packages/client-composition/model/snippetResultOption.ts b/packages/client-composition/model/snippetResultOption.ts
new file mode 100644
index 000000000..daab65f2d
--- /dev/null
+++ b/packages/client-composition/model/snippetResultOption.ts
@@ -0,0 +1,15 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { MatchLevel } from './matchLevel';
+
+/**
+ * Snippets that show the context around a matching search query.
+ */
+export type SnippetResultOption = {
+ /**
+ * Highlighted attribute value, including HTML tags.
+ */
+ value: string;
+
+ matchLevel: MatchLevel;
+};
diff --git a/packages/client-composition/model/sortRemainingBy.ts b/packages/client-composition/model/sortRemainingBy.ts
new file mode 100644
index 000000000..85fc5bd88
--- /dev/null
+++ b/packages/client-composition/model/sortRemainingBy.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Order of facet values that aren\'t explicitly positioned with the `order` setting. - `count`. Order remaining facet values by decreasing count. The count is the number of matching records containing this facet value. - `alpha`. Sort facet values alphabetically. - `hidden`. Don\'t show facet values that aren\'t explicitly positioned.
+ */
+export type SortRemainingBy = 'count' | 'alpha' | 'hidden';
diff --git a/packages/client-composition/model/supportedLanguage.ts b/packages/client-composition/model/supportedLanguage.ts
new file mode 100644
index 000000000..85f2111cc
--- /dev/null
+++ b/packages/client-composition/model/supportedLanguage.ts
@@ -0,0 +1,74 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * ISO code for a supported language.
+ */
+export type SupportedLanguage =
+ | 'af'
+ | 'ar'
+ | 'az'
+ | 'bg'
+ | 'bn'
+ | 'ca'
+ | 'cs'
+ | 'cy'
+ | 'da'
+ | 'de'
+ | 'el'
+ | 'en'
+ | 'eo'
+ | 'es'
+ | 'et'
+ | 'eu'
+ | 'fa'
+ | 'fi'
+ | 'fo'
+ | 'fr'
+ | 'ga'
+ | 'gl'
+ | 'he'
+ | 'hi'
+ | 'hu'
+ | 'hy'
+ | 'id'
+ | 'is'
+ | 'it'
+ | 'ja'
+ | 'ka'
+ | 'kk'
+ | 'ko'
+ | 'ku'
+ | 'ky'
+ | 'lt'
+ | 'lv'
+ | 'mi'
+ | 'mn'
+ | 'mr'
+ | 'ms'
+ | 'mt'
+ | 'nb'
+ | 'nl'
+ | 'no'
+ | 'ns'
+ | 'pl'
+ | 'ps'
+ | 'pt'
+ | 'pt-br'
+ | 'qu'
+ | 'ro'
+ | 'ru'
+ | 'sk'
+ | 'sq'
+ | 'sv'
+ | 'sw'
+ | 'ta'
+ | 'te'
+ | 'th'
+ | 'tl'
+ | 'tn'
+ | 'tr'
+ | 'tt'
+ | 'uk'
+ | 'ur'
+ | 'uz'
+ | 'zh';
diff --git a/packages/client-composition/model/tagFilters.ts b/packages/client-composition/model/tagFilters.ts
new file mode 100644
index 000000000..b13f801cf
--- /dev/null
+++ b/packages/client-composition/model/tagFilters.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Filter the search by values of the special `_tags` attribute. **Prefer using the `filters` parameter, which supports all filter types and combinations with boolean operators.** Different from regular facets, `_tags` can only be used for filtering (including or excluding records). You won\'t get a facet count. The same combination and escaping rules apply as for `facetFilters`.
+ */
+export type TagFilters = Array | string;
diff --git a/packages/client-composition/model/taskStatus.ts b/packages/client-composition/model/taskStatus.ts
new file mode 100644
index 000000000..5b312a99c
--- /dev/null
+++ b/packages/client-composition/model/taskStatus.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * Task status, `published` if the task is completed, `notPublished` otherwise.
+ */
+export type TaskStatus = 'published' | 'notPublished';
diff --git a/packages/client-composition/model/timeRange.ts b/packages/client-composition/model/timeRange.ts
new file mode 100644
index 000000000..dee6043c9
--- /dev/null
+++ b/packages/client-composition/model/timeRange.ts
@@ -0,0 +1,13 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+export type TimeRange = {
+ /**
+ * When the rule should start to be active, in Unix epoch time.
+ */
+ from: number;
+
+ /**
+ * When the rule should stop to be active, in Unix epoch time.
+ */
+ until: number;
+};
diff --git a/packages/client-composition/model/typoTolerance.ts b/packages/client-composition/model/typoTolerance.ts
new file mode 100644
index 000000000..767e63229
--- /dev/null
+++ b/packages/client-composition/model/typoTolerance.ts
@@ -0,0 +1,8 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { TypoToleranceEnum } from './typoToleranceEnum';
+
+/**
+ * Whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied. If typo tolerance is true, `min`, or `strict`, [word splitting and concatenation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/splitting-and-concatenation/) are also active.
+ */
+export type TypoTolerance = boolean | TypoToleranceEnum;
diff --git a/packages/client-composition/model/typoToleranceEnum.ts b/packages/client-composition/model/typoToleranceEnum.ts
new file mode 100644
index 000000000..a33877b0d
--- /dev/null
+++ b/packages/client-composition/model/typoToleranceEnum.ts
@@ -0,0 +1,6 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+/**
+ * - `min`. Return matches with the lowest number of typos. For example, if you have matches without typos, only include those. But if there are no matches without typos (with 1 typo), include matches with 1 typo (2 typos). - `strict`. Return matches with the two lowest numbers of typos. With `strict`, the Typo ranking criterion is applied first in the `ranking` setting.
+ */
+export type TypoToleranceEnum = 'min' | 'strict';
diff --git a/packages/client-composition/model/value.ts b/packages/client-composition/model/value.ts
new file mode 100644
index 000000000..72cd05add
--- /dev/null
+++ b/packages/client-composition/model/value.ts
@@ -0,0 +1,17 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { SortRemainingBy } from './sortRemainingBy';
+
+export type Value = {
+ /**
+ * Explicit order of facets or facet values. This setting lets you always show specific facets or facet values at the top of the list.
+ */
+ order?: Array;
+
+ sortRemainingBy?: SortRemainingBy;
+
+ /**
+ * Hide facet values.
+ */
+ hide?: Array;
+};
diff --git a/packages/client-composition/model/widgets.ts b/packages/client-composition/model/widgets.ts
new file mode 100644
index 000000000..0f50c381b
--- /dev/null
+++ b/packages/client-composition/model/widgets.ts
@@ -0,0 +1,13 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type { Banner } from './banner';
+
+/**
+ * widgets returned from any rules that are applied to the current search.
+ */
+export type Widgets = {
+ /**
+ * banners defined in the merchandising studio for the given search.
+ */
+ banners?: Array;
+};
diff --git a/packages/client-composition/package.json b/packages/client-composition/package.json
new file mode 100644
index 000000000..dddab97d1
--- /dev/null
+++ b/packages/client-composition/package.json
@@ -0,0 +1,67 @@
+{
+ "version": "0.0.1-alpha.0",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/algolia/algoliasearch-client-javascript.git"
+ },
+ "type": "module",
+ "license": "MIT",
+ "author": "Algolia",
+ "scripts": {
+ "build": "yarn clean && yarn tsup && yarn rollup -c rollup.config.js",
+ "clean": "rm -rf ./dist || true",
+ "test:bundle": "publint . && attw --pack ."
+ },
+ "name": "@algolia/client-composition",
+ "description": "JavaScript client for client-composition",
+ "exports": {
+ ".": {
+ "node": {
+ "types": {
+ "import": "./dist/node.d.ts",
+ "module": "./dist/node.d.ts",
+ "require": "./dist/node.d.cts"
+ },
+ "import": "./dist/builds/node.js",
+ "module": "./dist/builds/node.js",
+ "require": "./dist/builds/node.cjs"
+ },
+ "worker": {
+ "types": "./dist/fetch.d.ts",
+ "default": "./dist/builds/fetch.js"
+ },
+ "default": {
+ "types": "./dist/browser.d.ts",
+ "module": "./dist/builds/browser.js",
+ "import": "./dist/builds/browser.js",
+ "default": "./dist/builds/browser.umd.js"
+ }
+ },
+ "./dist/builds/*": "./dist/builds/*.js"
+ },
+ "jsdelivr": "./dist/builds/browser.umd.js",
+ "unpkg": "./dist/builds/browser.umd.js",
+ "react-native": "./dist/builds/browser.js",
+ "files": [
+ "dist",
+ "index.js",
+ "index.d.ts"
+ ],
+ "dependencies": {
+ "@algolia/client-common": "5.12.0",
+ "@algolia/requester-browser-xhr": "5.12.0",
+ "@algolia/requester-fetch": "5.12.0",
+ "@algolia/requester-node-http": "5.12.0"
+ },
+ "devDependencies": {
+ "@arethetypeswrong/cli": "0.16.4",
+ "@types/node": "22.8.7",
+ "publint": "0.2.12",
+ "rollup": "4.24.3",
+ "tsup": "8.3.5",
+ "typescript": "5.6.3"
+ },
+ "engines": {
+ "node": ">= 14.0.0"
+ }
+}
diff --git a/packages/client-composition/rollup.config.js b/packages/client-composition/rollup.config.js
new file mode 100644
index 000000000..d3d56acde
--- /dev/null
+++ b/packages/client-composition/rollup.config.js
@@ -0,0 +1,16 @@
+export default [
+ {
+ input: 'dist/builds/browser.min.js',
+ external: ['dom'],
+ output: {
+ esModule: false,
+ file: 'dist/builds/browser.umd.js',
+ name: '@algolia/client-composition',
+ format: 'umd',
+ sourcemap: false,
+ globals: {
+ ['compositionClient']: 'compositionClient',
+ },
+ },
+ },
+];
diff --git a/packages/client-composition/src/compositionClient.ts b/packages/client-composition/src/compositionClient.ts
new file mode 100644
index 000000000..dc300a9e9
--- /dev/null
+++ b/packages/client-composition/src/compositionClient.ts
@@ -0,0 +1,638 @@
+// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
+
+import type {
+ CreateClientOptions,
+ Headers,
+ Host,
+ QueryParameters,
+ Request,
+ RequestOptions,
+} from '@algolia/client-common';
+import { createAuth, createIterablePromise, createTransporter, getAlgoliaAgent, shuffle } from '@algolia/client-common';
+
+import type { BatchParams } from '../model/batchParams';
+import type { Composition } from '../model/composition';
+import type { CompositionRule } from '../model/compositionRule';
+
+import type { GetTaskResponse } from '../model/getTaskResponse';
+import type { ListCompositionsResponse } from '../model/listCompositionsResponse';
+import type { MultipleBatchResponse } from '../model/multipleBatchResponse';
+import type { RulesMultipleBatchResponse } from '../model/rulesMultipleBatchResponse';
+
+import type { SearchCompositionRulesResponse } from '../model/searchCompositionRulesResponse';
+
+import type { SearchForFacetValuesResponse } from '../model/searchForFacetValuesResponse';
+
+import type { SearchResponse } from '../model/searchResponse';
+
+import type {
+ CustomDeleteProps,
+ CustomGetProps,
+ CustomPostProps,
+ CustomPutProps,
+ GetCompositionProps,
+ GetRuleProps,
+ GetTaskProps,
+ ListCompositionsProps,
+ RunSingleCompositionProps,
+ SaveRulesProps,
+ SearchCompositionRulesProps,
+ SearchForFacetValuesProps,
+ WaitForCompositionTaskOptions,
+} from '../model/clientMethodProps';
+
+export const apiClientVersion = '0.0.1-alpha.0';
+
+function getDefaultHosts(appId: string): Host[] {
+ return (
+ [
+ {
+ url: `${appId}-dsn.algolia.net`,
+ accept: 'read',
+ protocol: 'https',
+ },
+ {
+ url: `${appId}.algolia.net`,
+ accept: 'write',
+ protocol: 'https',
+ },
+ ] as Host[]
+ ).concat(
+ shuffle([
+ {
+ url: `${appId}-1.algolianet.com`,
+ accept: 'readWrite',
+ protocol: 'https',
+ },
+ {
+ url: `${appId}-2.algolianet.com`,
+ accept: 'readWrite',
+ protocol: 'https',
+ },
+ {
+ url: `${appId}-3.algolianet.com`,
+ accept: 'readWrite',
+ protocol: 'https',
+ },
+ ]),
+ );
+}
+
+export function createCompositionClient({
+ appId: appIdOption,
+ apiKey: apiKeyOption,
+ authMode,
+ algoliaAgents,
+ ...options
+}: CreateClientOptions) {
+ const auth = createAuth(appIdOption, apiKeyOption, authMode);
+ const transporter = createTransporter({
+ hosts: getDefaultHosts(appIdOption),
+ ...options,
+ algoliaAgent: getAlgoliaAgent({
+ algoliaAgents,
+ client: 'Composition',
+ version: apiClientVersion,
+ }),
+ baseHeaders: {
+ 'content-type': 'text/plain',
+ ...auth.headers(),
+ ...options.baseHeaders,
+ },
+ baseQueryParameters: {
+ ...auth.queryParameters(),
+ ...options.baseQueryParameters,
+ },
+ });
+
+ return {
+ transporter,
+
+ /**
+ * The `appId` currently in use.
+ */
+ appId: appIdOption,
+
+ /**
+ * Clears the cache of the transporter for the `requestsCache` and `responsesCache` properties.
+ */
+ clearCache(): Promise {
+ return Promise.all([transporter.requestsCache.clear(), transporter.responsesCache.clear()]).then(() => undefined);
+ },
+
+ /**
+ * Get the value of the `algoliaAgent`, used by our libraries internally and telemetry system.
+ */
+ get _ua(): string {
+ return transporter.algoliaAgent.value;
+ },
+
+ /**
+ * Adds a `segment` to the `x-algolia-agent` sent with every requests.
+ *
+ * @param segment - The algolia agent (user-agent) segment to add.
+ * @param version - The version of the agent.
+ */
+ addAlgoliaAgent(segment: string, version?: string): void {
+ transporter.algoliaAgent.add({ segment, version });
+ },
+
+ /**
+ * Helper method to switch the API key used to authenticate the requests.
+ *
+ * @param params - Method params.
+ * @param params.apiKey - The new API Key to use.
+ */
+ setClientApiKey({ apiKey }: { apiKey: string }): void {
+ if (!authMode || authMode === 'WithinHeaders') {
+ transporter.baseHeaders['x-algolia-api-key'] = apiKey;
+ } else {
+ transporter.baseQueryParameters['x-algolia-api-key'] = apiKey;
+ }
+ },
+
+ /**
+ * Helper: Wait for a composition-level task to be published (completed) for a given `compositionID` and `taskID`.
+ *
+ * @summary Helper method that waits for a task to be published (completed).
+ * @param WaitForCompositionTaskOptions - The `WaitForCompositionTaskOptions` object.
+ * @param WaitForCompositionTaskOptions.compositionID - The `compositionID` where the operation was performed.
+ * @param WaitForCompositionTaskOptions.taskID - The `taskID` returned in the method response.
+ * @param WaitForCompositionTaskOptions.maxRetries - The maximum number of retries. 50 by default.
+ * @param WaitForCompositionTaskOptions.timeout - The function to decide how long to wait between retries.
+ * @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `getTask` method and merged with the transporter requestOptions.
+ */
+ waitForCompositionTask(
+ {
+ compositionID,
+ taskID,
+ maxRetries = 50,
+ timeout = (retryCount: number): number => Math.min(retryCount * 200, 5000),
+ }: WaitForCompositionTaskOptions,
+ requestOptions?: RequestOptions,
+ ): Promise {
+ let retryCount = 0;
+
+ return createIterablePromise({
+ func: () => this.getTask({ compositionID, taskID }, requestOptions),
+ validate: (response) => response.status === 'published',
+ aggregator: () => (retryCount += 1),
+ error: {
+ validate: () => retryCount >= maxRetries,
+ message: () => `The maximum number of retries exceeded. (${retryCount}/${maxRetries})`,
+ },
+ timeout: () => timeout(retryCount),
+ });
+ },
+
+ /**
+ * This method allow you to send requests to the Algolia REST API.
+ * @param customDelete - The customDelete object.
+ * @param customDelete.path - Path of the endpoint, anything after \"/1\" must be specified.
+ * @param customDelete.parameters - Query parameters to apply to the current query.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ customDelete(
+ { path, parameters }: CustomDeleteProps,
+ requestOptions?: RequestOptions,
+ ): Promise> {
+ if (!path) {
+ throw new Error('Parameter `path` is required when calling `customDelete`.');
+ }
+
+ const requestPath = '/{path}'.replace('{path}', path);
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = parameters ? parameters : {};
+
+ const request: Request = {
+ method: 'DELETE',
+ path: requestPath,
+ queryParameters,
+ headers,
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+
+ /**
+ * This method allow you to send requests to the Algolia REST API.
+ * @param customGet - The customGet object.
+ * @param customGet.path - Path of the endpoint, anything after \"/1\" must be specified.
+ * @param customGet.parameters - Query parameters to apply to the current query.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ customGet({ path, parameters }: CustomGetProps, requestOptions?: RequestOptions): Promise> {
+ if (!path) {
+ throw new Error('Parameter `path` is required when calling `customGet`.');
+ }
+
+ const requestPath = '/{path}'.replace('{path}', path);
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = parameters ? parameters : {};
+
+ const request: Request = {
+ method: 'GET',
+ path: requestPath,
+ queryParameters,
+ headers,
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+
+ /**
+ * This method allow you to send requests to the Algolia REST API.
+ * @param customPost - The customPost object.
+ * @param customPost.path - Path of the endpoint, anything after \"/1\" must be specified.
+ * @param customPost.parameters - Query parameters to apply to the current query.
+ * @param customPost.body - Parameters to send with the custom request.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ customPost(
+ { path, parameters, body }: CustomPostProps,
+ requestOptions?: RequestOptions,
+ ): Promise> {
+ if (!path) {
+ throw new Error('Parameter `path` is required when calling `customPost`.');
+ }
+
+ const requestPath = '/{path}'.replace('{path}', path);
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = parameters ? parameters : {};
+
+ const request: Request = {
+ method: 'POST',
+ path: requestPath,
+ queryParameters,
+ headers,
+ data: body ? body : {},
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+
+ /**
+ * This method allow you to send requests to the Algolia REST API.
+ * @param customPut - The customPut object.
+ * @param customPut.path - Path of the endpoint, anything after \"/1\" must be specified.
+ * @param customPut.parameters - Query parameters to apply to the current query.
+ * @param customPut.body - Parameters to send with the custom request.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ customPut(
+ { path, parameters, body }: CustomPutProps,
+ requestOptions?: RequestOptions,
+ ): Promise> {
+ if (!path) {
+ throw new Error('Parameter `path` is required when calling `customPut`.');
+ }
+
+ const requestPath = '/{path}'.replace('{path}', path);
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = parameters ? parameters : {};
+
+ const request: Request = {
+ method: 'PUT',
+ path: requestPath,
+ queryParameters,
+ headers,
+ data: body ? body : {},
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+
+ /**
+ * Retrieve a single composition in the current Algolia application.
+ *
+ * Required API Key ACLs:
+ * - editSettings
+ * - settings
+ * @param getComposition - The getComposition object.
+ * @param getComposition.compositionID - Unique Composition ObjectID.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ getComposition({ compositionID }: GetCompositionProps, requestOptions?: RequestOptions): Promise {
+ if (!compositionID) {
+ throw new Error('Parameter `compositionID` is required when calling `getComposition`.');
+ }
+
+ const requestPath = '/1/compositions/{compositionID}'.replace(
+ '{compositionID}',
+ encodeURIComponent(compositionID),
+ );
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = {};
+
+ const request: Request = {
+ method: 'GET',
+ path: requestPath,
+ queryParameters,
+ headers,
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+
+ /**
+ * Retrieves a rule by its ID. To find the object ID of rules, use the [`search` operation](#tag/Rules/operation/searchRules).
+ *
+ * Required API Key ACLs:
+ * - settings
+ * @param getRule - The getRule object.
+ * @param getRule.compositionID - Unique Composition ObjectID.
+ * @param getRule.objectID - Unique identifier of a rule object.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ getRule({ compositionID, objectID }: GetRuleProps, requestOptions?: RequestOptions): Promise {
+ if (!compositionID) {
+ throw new Error('Parameter `compositionID` is required when calling `getRule`.');
+ }
+
+ if (!objectID) {
+ throw new Error('Parameter `objectID` is required when calling `getRule`.');
+ }
+
+ const requestPath = '/1/compositions/{compositionID}/rules/{objectID}'
+ .replace('{compositionID}', encodeURIComponent(compositionID))
+ .replace('{objectID}', encodeURIComponent(objectID));
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = {};
+
+ const request: Request = {
+ method: 'GET',
+ path: requestPath,
+ queryParameters,
+ headers,
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+
+ /**
+ * Checks the status of a given task.
+ *
+ * Required API Key ACLs:
+ * - editSettings
+ * - settings
+ * - addObject
+ * - deleteObject
+ * - deleteIndex
+ * @param getTask - The getTask object.
+ * @param getTask.compositionID - Unique Composition ObjectID.
+ * @param getTask.taskID - Unique task identifier.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ getTask({ compositionID, taskID }: GetTaskProps, requestOptions?: RequestOptions): Promise {
+ if (!compositionID) {
+ throw new Error('Parameter `compositionID` is required when calling `getTask`.');
+ }
+
+ if (!taskID) {
+ throw new Error('Parameter `taskID` is required when calling `getTask`.');
+ }
+
+ const requestPath = '/1/compositions/{compositionID}/task/{taskID}'
+ .replace('{compositionID}', encodeURIComponent(compositionID))
+ .replace('{taskID}', encodeURIComponent(taskID));
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = {};
+
+ const request: Request = {
+ method: 'GET',
+ path: requestPath,
+ queryParameters,
+ headers,
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+
+ /**
+ * Lists all compositions in the current Algolia application.
+ *
+ * Required API Key ACLs:
+ * - editSettings
+ * - settings
+ * @param listCompositions - The listCompositions object.
+ * @param listCompositions.page - Requested page of the API response. If `null`, the API response is not paginated.
+ * @param listCompositions.hitsPerPage - Number of hits per page.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ listCompositions(
+ { page, hitsPerPage }: ListCompositionsProps = {},
+ requestOptions: RequestOptions | undefined = undefined,
+ ): Promise {
+ const requestPath = '/1/compositions';
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = {};
+
+ if (page !== undefined) {
+ queryParameters['page'] = page.toString();
+ }
+
+ if (hitsPerPage !== undefined) {
+ queryParameters['hitsPerPage'] = hitsPerPage.toString();
+ }
+
+ const request: Request = {
+ method: 'GET',
+ path: requestPath,
+ queryParameters,
+ headers,
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+
+ /**
+ * Adds, updates, or deletes compositions with a single API request.
+ *
+ * Required API Key ACLs:
+ * - editSettings
+ * @param batchParams - The batchParams object.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ multipleBatch(batchParams: BatchParams, requestOptions?: RequestOptions): Promise {
+ if (!batchParams) {
+ throw new Error('Parameter `batchParams` is required when calling `multipleBatch`.');
+ }
+
+ if (!batchParams.requests) {
+ throw new Error('Parameter `batchParams.requests` is required when calling `multipleBatch`.');
+ }
+
+ const requestPath = '/1/compositions/*/batch';
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = {};
+
+ const request: Request = {
+ method: 'POST',
+ path: requestPath,
+ queryParameters,
+ headers,
+ data: batchParams,
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+
+ /**
+ * Runs a query on a single composition and returns matching results.
+ *
+ * Required API Key ACLs:
+ * - search
+ * @param runSingleComposition - The runSingleComposition object.
+ * @param runSingleComposition.compositionID - Unique Composition ObjectID.
+ * @param runSingleComposition.searchParams - The searchParams object.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ runSingleComposition(
+ { compositionID, searchParams }: RunSingleCompositionProps,
+ requestOptions?: RequestOptions,
+ ): Promise> {
+ if (!compositionID) {
+ throw new Error('Parameter `compositionID` is required when calling `runSingleComposition`.');
+ }
+
+ const requestPath = '/1/compositions/{compositionID}/run'.replace(
+ '{compositionID}',
+ encodeURIComponent(compositionID),
+ );
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = {};
+
+ const request: Request = {
+ method: 'POST',
+ path: requestPath,
+ queryParameters,
+ headers,
+ data: searchParams ? searchParams : {},
+ useReadTransporter: true,
+ cacheable: true,
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+
+ /**
+ * Create or update or delete multiple composition rules.
+ *
+ * Required API Key ACLs:
+ * - editSettings
+ * @param saveRules - The saveRules object.
+ * @param saveRules.compositionID - Unique Composition ObjectID.
+ * @param saveRules.rules - The rules object.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ saveRules(
+ { compositionID, rules }: SaveRulesProps,
+ requestOptions?: RequestOptions,
+ ): Promise {
+ if (!compositionID) {
+ throw new Error('Parameter `compositionID` is required when calling `saveRules`.');
+ }
+
+ if (!rules) {
+ throw new Error('Parameter `rules` is required when calling `saveRules`.');
+ }
+
+ const requestPath = '/1/compositions/{compositionID}/rules/batch'.replace(
+ '{compositionID}',
+ encodeURIComponent(compositionID),
+ );
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = {};
+
+ const request: Request = {
+ method: 'POST',
+ path: requestPath,
+ queryParameters,
+ headers,
+ data: rules,
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+
+ /**
+ * Searches for composition rules in your index.
+ *
+ * Required API Key ACLs:
+ * - settings
+ * @param searchCompositionRules - The searchCompositionRules object.
+ * @param searchCompositionRules.compositionID - Unique Composition ObjectID.
+ * @param searchCompositionRules.searchCompositionRulesParams - The searchCompositionRulesParams object.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ searchCompositionRules(
+ { compositionID, searchCompositionRulesParams }: SearchCompositionRulesProps,
+ requestOptions?: RequestOptions,
+ ): Promise {
+ if (!compositionID) {
+ throw new Error('Parameter `compositionID` is required when calling `searchCompositionRules`.');
+ }
+
+ const requestPath = '/1/compositions/{compositionID}/rules/search'.replace(
+ '{compositionID}',
+ encodeURIComponent(compositionID),
+ );
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = {};
+
+ const request: Request = {
+ method: 'POST',
+ path: requestPath,
+ queryParameters,
+ headers,
+ data: searchCompositionRulesParams ? searchCompositionRulesParams : {},
+ useReadTransporter: true,
+ cacheable: true,
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+
+ /**
+ * Searches for values of a specified facet attribute on the composition\'s main source\'s index. - By default, facet values are sorted by decreasing count. You can adjust this with the `sortFacetValueBy` parameter. - Searching for facet values doesn\'t work if you have **more than 65 searchable facets and searchable attributes combined**.
+ *
+ * Required API Key ACLs:
+ * - search
+ * @param searchForFacetValues - The searchForFacetValues object.
+ * @param searchForFacetValues.compositionID - Unique Composition ObjectID.
+ * @param searchForFacetValues.facetName - Facet attribute in which to search for values. This attribute must be included in the `attributesForFaceting` index setting with the `searchable()` modifier.
+ * @param searchForFacetValues.searchForFacetValuesRequest - The searchForFacetValuesRequest object.
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
+ */
+ searchForFacetValues(
+ { compositionID, facetName, searchForFacetValuesRequest }: SearchForFacetValuesProps,
+ requestOptions?: RequestOptions,
+ ): Promise {
+ if (!compositionID) {
+ throw new Error('Parameter `compositionID` is required when calling `searchForFacetValues`.');
+ }
+
+ if (!facetName) {
+ throw new Error('Parameter `facetName` is required when calling `searchForFacetValues`.');
+ }
+
+ const requestPath = '/1/compositions/{compositionID}/facets/{facetName}/query'
+ .replace('{compositionID}', encodeURIComponent(compositionID))
+ .replace('{facetName}', encodeURIComponent(facetName));
+ const headers: Headers = {};
+ const queryParameters: QueryParameters = {};
+
+ const request: Request = {
+ method: 'POST',
+ path: requestPath,
+ queryParameters,
+ headers,
+ data: searchForFacetValuesRequest ? searchForFacetValuesRequest : {},
+ useReadTransporter: true,
+ cacheable: true,
+ };
+
+ return transporter.request(request, requestOptions);
+ },
+ };
+}
diff --git a/packages/client-composition/tsconfig.json b/packages/client-composition/tsconfig.json
new file mode 100644
index 000000000..444e8bb64
--- /dev/null
+++ b/packages/client-composition/tsconfig.json
@@ -0,0 +1,8 @@
+{
+ "extends": "../../tsconfig.json",
+ "compilerOptions": {
+ "outDir": "dist"
+ },
+ "include": ["src", "model", "builds"],
+ "exclude": ["dist", "node_modules"]
+}
diff --git a/packages/client-composition/tsup.config.ts b/packages/client-composition/tsup.config.ts
new file mode 100644
index 000000000..40b03bc89
--- /dev/null
+++ b/packages/client-composition/tsup.config.ts
@@ -0,0 +1,59 @@
+import type { Options } from 'tsup';
+import { defineConfig } from 'tsup';
+
+import { getBaseBrowserOptions, getBaseNodeOptions, getDependencies } from '../../base.tsup.config';
+
+import pkg from './package.json' with { type: 'json' };
+
+const nodeOptions: Options = {
+ ...getBaseNodeOptions(pkg, __dirname),
+ dts: { entry: { node: 'builds/node.ts' } },
+ entry: ['builds/node.ts', 'src/*.ts'],
+};
+
+const nodeConfigs: Options[] = [
+ {
+ ...nodeOptions,
+ format: 'cjs',
+ name: `node ${pkg.name} cjs`,
+ },
+ {
+ ...nodeOptions,
+ format: 'esm',
+ name: `node ${pkg.name} esm`,
+ },
+ {
+ ...nodeOptions,
+ format: 'esm',
+ name: `fetch ${pkg.name} esm`,
+ dts: { entry: { fetch: 'builds/fetch.ts' } },
+ external: getDependencies(pkg, 'fetch'),
+ entry: ['builds/fetch.ts', 'src/*.ts'],
+ },
+];
+
+const browserOptions: Options = {
+ ...getBaseBrowserOptions(pkg, __dirname),
+ globalName: 'compositionClient',
+};
+
+const browserConfigs: Options[] = [
+ {
+ ...browserOptions,
+ minify: false,
+ name: `browser ${pkg.name} esm`,
+ dts: { entry: { browser: 'builds/browser.ts' } },
+ entry: ['builds/browser.ts', 'src/*.ts'],
+ },
+ {
+ ...browserOptions,
+ dts: false,
+ minify: true,
+ name: `browser ${pkg.name} min esm`,
+ entry: { 'builds/browser.min': 'builds/browser.ts' },
+ external: [],
+ noExternal: getDependencies(pkg, 'xhr'),
+ },
+];
+
+export default defineConfig([...nodeConfigs, ...browserConfigs]);
diff --git a/yarn.lock b/yarn.lock
index d6cb9ccc1..43cdba6d8 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -54,6 +54,23 @@ __metadata:
languageName: unknown
linkType: soft
+"@algolia/client-composition@workspace:packages/client-composition":
+ version: 0.0.0-use.local
+ resolution: "@algolia/client-composition@workspace:packages/client-composition"
+ dependencies:
+ "@algolia/client-common": "npm:5.12.0"
+ "@algolia/requester-browser-xhr": "npm:5.12.0"
+ "@algolia/requester-fetch": "npm:5.12.0"
+ "@algolia/requester-node-http": "npm:5.12.0"
+ "@arethetypeswrong/cli": "npm:0.16.4"
+ "@types/node": "npm:22.8.7"
+ publint: "npm:0.2.12"
+ rollup: "npm:4.24.3"
+ tsup: "npm:8.3.5"
+ typescript: "npm:5.6.3"
+ languageName: unknown
+ linkType: soft
+
"@algolia/client-insights@npm:5.12.0, @algolia/client-insights@workspace:packages/client-insights":
version: 0.0.0-use.local
resolution: "@algolia/client-insights@workspace:packages/client-insights"