diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index db77932eab..13641dec7a 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -440,12 +440,6 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.ALGOLIA_BOT_TOKEN }} - - name: Push specs to new worlds documentation - if: github.ref == 'refs/heads/main' - run: yarn workspace scripts pushSpecsToNewWorldDocs - env: - GITHUB_TOKEN: ${{ secrets.ALGOLIA_BOT_TOKEN }} - - name: Set output id: setoutput run: echo "success=true" >> "$GITHUB_OUTPUT" diff --git a/scripts/buildSpecs.ts b/scripts/buildSpecs.ts index 148417430a..4a716fd540 100644 --- a/scripts/buildSpecs.ts +++ b/scripts/buildSpecs.ts @@ -218,9 +218,6 @@ async function buildSpec(spec: string, outputFormat: string, useCache: boolean): if (!isAlgoliasearch) { spinner.text = `linting '${spec}' doc spec`; await run(`yarn specs:fix bundled/${spec}.doc.yml`); - await run( - `yarn openapi bundle specs/bundled/${spec}.doc.yml --output specs/bundled/${spec}.json --format json --ext json --dereferenced`, - ); } if (useCache) { diff --git a/scripts/ci/codegen/pushSpecsToNewWorldDocs.ts b/scripts/ci/codegen/pushSpecsToNewWorldDocs.ts deleted file mode 100644 index 3aa8bcf1c3..0000000000 --- a/scripts/ci/codegen/pushSpecsToNewWorldDocs.ts +++ /dev/null @@ -1,86 +0,0 @@ -/* eslint-disable no-console */ -import fsp from 'fs/promises'; -import { resolve } from 'path'; - -import { - emptyDirExceptForDotGit, - gitCommit, - run, - toAbsolutePath, - ensureGitHubToken, - OWNER, - configureGitHubAuthor, - getOctokit, - setVerbose, -} from '../../common.js'; -import { getNbGitDiff } from '../utils.js'; - -import { commitStartRelease } from './text.js'; - -async function pushToNewWorld(): Promise { - const githubToken = ensureGitHubToken(); - - const repository = 'new-world-docs'; - const lastCommitMessage = await run('git log -1 --format="%s"'); - const author = (await run('git log -1 --format="Co-authored-by: %an <%ae>"')).trim(); - const coAuthors = (await run('git log -1 --format="%(trailers:key=Co-authored-by)"')) - .split('\n') - .map((coAuthor) => coAuthor.trim()) - .filter(Boolean); - - if (!lastCommitMessage.startsWith(commitStartRelease)) { - return; - } - - console.log(`Pushing generated specs to ${OWNER}/${repository}`); - - const targetBranch = 'feat/automated-update-from-api-clients-automation-repository'; - const githubURL = `https://${githubToken}:${githubToken}@github.com/${OWNER}/${repository}`; - const tempGitDir = resolve(process.env.RUNNER_TEMP!, repository); - await fsp.rm(tempGitDir, { force: true, recursive: true }); - await run(`git clone --depth 1 ${githubURL} ${tempGitDir}`); - await run(`git checkout -B ${targetBranch}`, { cwd: tempGitDir }); - - const dest = toAbsolutePath(`${tempGitDir}/apps/docs/public/specs`); - await emptyDirExceptForDotGit(dest); - await run(`cp ${toAbsolutePath('specs/bundled/*.json')} ${dest}`); - - if ((await getNbGitDiff({ head: null, cwd: tempGitDir })) === 0) { - console.log(`❎ Skipping specs push because there is no change.`); - - return; - } - - await configureGitHubAuthor(tempGitDir); - - const message = 'feat(specs): automatic update from api-clients-automation repository'; - await run('git add .', { cwd: tempGitDir }); - await gitCommit({ - message, - coAuthors: [author, ...coAuthors], - cwd: tempGitDir, - }); - await run(`git push -f -u origin ${targetBranch}`, { cwd: tempGitDir }); - - console.log(`Creating pull request on ${OWNER}/${repository}...`); - const octokit = getOctokit(); - const { data } = await octokit.pulls.create({ - owner: OWNER, - repo: repository, - title: message, - body: [ - 'This PR is automatically created by https://github.com/algolia/api-clients-automation', - 'It contains the most up-to-date OpenAPI for the Algolia API clients.', - ].join('\n\n'), - base: 'main', - head: targetBranch, - }); - - console.log(`Pull request created on ${OWNER}/${repository}`); - console.log(` > ${data.url}`); -} - -if (import.meta.url.endsWith(process.argv[1])) { - setVerbose(false); - pushToNewWorld(); -} diff --git a/scripts/package.json b/scripts/package.json index e6900dffa5..352055e1b2 100644 --- a/scripts/package.json +++ b/scripts/package.json @@ -13,7 +13,6 @@ "lint:deadcode": "knip", "pre-commit": "node ./ci/husky/pre-commit.mjs", "pushGeneratedCode": "NODE_NO_WARNINGS=1 node dist/scripts/ci/codegen/pushGeneratedCode.js", - "pushSpecsToNewWorldDocs": "NODE_NO_WARNINGS=1 node dist/scripts/ci/codegen/pushSpecsToNewWorldDocs.js", "setRunVariables": "NODE_NO_WARNINGS=1 node dist/scripts/ci/githubActions/setRunVariables.js", "spreadGeneration": "NODE_NO_WARNINGS=1 node dist/scripts/ci/codegen/spreadGeneration.js", "start": "NODE_NO_WARNINGS=1 node dist/scripts/cli/index.js", diff --git a/specs/bundled/abtesting.json b/specs/bundled/abtesting.json deleted file mode 100644 index 9c0b5d11ba..0000000000 --- a/specs/bundled/abtesting.json +++ /dev/null @@ -1,3467 +0,0 @@ -{ - "openapi": "3.0.2", - "info": { - "title": "A/B Testing API", - "description": "API powering the A/B Testing feature of Algolia.", - "version": "1.0.0" - }, - "components": { - "securitySchemes": { - "appId": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-Application-Id" - }, - "apiKey": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-API-Key" - } - }, - "parameters": { - "PathInPath": { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - "Parameters": { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - }, - "Offset": { - "in": "query", - "name": "offset", - "description": "Position of the starting record. Used for paging. 0 is the first record.", - "schema": { - "type": "integer", - "default": 0 - } - }, - "Limit": { - "in": "query", - "name": "limit", - "description": "Number of records to return (page size).", - "schema": { - "type": "integer", - "default": 10 - } - }, - "ID": { - "in": "path", - "name": "id", - "description": "Unique A/B test ID.", - "required": true, - "schema": { - "type": "integer", - "example": 390 - } - } - }, - "schemas": { - "ErrorBase": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - }, - "abTestID": { - "type": "integer", - "description": "Unique A/B test ID.", - "example": 224 - }, - "updatedAt": { - "type": "string", - "description": "Update date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-15T15:06:44.400601Z" - }, - "createdAt": { - "type": "string", - "description": "Creation date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-15T15:06:04.249906Z" - }, - "endAt": { - "type": "string", - "description": "End date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-17T00:00:00Z" - }, - "name": { - "type": "string", - "description": "A/B test name.", - "example": "Custom ranking sales rank test" - }, - "currencies": { - "type": "object", - "description": "A/B test currencies.", - "example": { - "USD": { - "currency": "USD", - "revenue": 120, - "mean": 53.7, - "standardDeviation": 12.3 - }, - "EUR": { - "currency": "EUR", - "revenue": 100, - "mean": 43.7, - "standardDeviation": 10.3 - } - }, - "additionalProperties": { - "type": "object", - "properties": { - "currency": { - "type": "string", - "description": "Currency code.", - "example": "USD" - }, - "revenue": { - "type": "number", - "format": "double", - "description": "Revenue for this currency.", - "example": 120 - }, - "mean": { - "type": "number", - "format": "double", - "description": "Mean for this currency.", - "example": 53.7 - }, - "standardDeviation": { - "type": "number", - "format": "double", - "description": "Standard deviation for this currency.", - "example": 12.3 - } - } - } - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - }, - "filterEffects": { - "type": "object", - "description": "A/B test filter effects resulting from configuration settings.", - "properties": { - "outliers": { - "type": "object", - "description": "Outliers removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - }, - "emptySearch": { - "type": "object", - "description": "Empty searches removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - } - } - }, - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "variant": { - "type": "object", - "additionalProperties": false, - "properties": { - "addToCartCount": { - "type": "integer", - "description": "Number of add-to-cart events for this variant.", - "example": 0 - }, - "addToCartRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [add-to-cart rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#add-to-cart-rate).", - "example": 0 - }, - "averageClickPosition": { - "type": "integer", - "nullable": true, - "description": "Variant's [average click position](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-position).", - "example": 0 - }, - "clickCount": { - "type": "integer", - "description": "Number of click events for this variant.", - "example": 65131 - }, - "clickThroughRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [click-through rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).", - "example": 0.22219857724813036 - }, - "conversionCount": { - "type": "integer", - "description": "Number of click events for this variant.", - "example": 4785 - }, - "conversionRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [conversion rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).", - "example": 0.14546725846658964 - }, - "currencies": { - "type": "object", - "description": "A/B test currencies.", - "example": { - "USD": { - "currency": "USD", - "revenue": 120, - "mean": 53.7, - "standardDeviation": 12.3 - }, - "EUR": { - "currency": "EUR", - "revenue": 100, - "mean": 43.7, - "standardDeviation": 10.3 - } - }, - "additionalProperties": { - "type": "object", - "properties": { - "currency": { - "type": "string", - "description": "Currency code.", - "example": "USD" - }, - "revenue": { - "type": "number", - "format": "double", - "description": "Revenue for this currency.", - "example": 120 - }, - "mean": { - "type": "number", - "format": "double", - "description": "Mean for this currency.", - "example": 53.7 - }, - "standardDeviation": { - "type": "number", - "format": "double", - "description": "Standard deviation for this currency.", - "example": 12.3 - } - } - } - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - }, - "estimatedSampleSize": { - "type": "integer", - "description": "The estimated number of searches that will need to be run to achieve the desired confidence level and statistical power. A `minimumDetectableEffect` must be set in the `configuration` object for this to be used.", - "example": 0 - }, - "filterEffects": { - "type": "object", - "description": "A/B test filter effects resulting from configuration settings.", - "properties": { - "outliers": { - "type": "object", - "description": "Outliers removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - }, - "emptySearch": { - "type": "object", - "description": "Empty searches removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - } - } - }, - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "noResultCount": { - "type": "integer", - "nullable": true, - "description": "Number of [searches without results](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#searches-without-results) for that variant.", - "example": 0 - }, - "purchaseCount": { - "type": "integer", - "description": "Number of purchase events for this variant.", - "example": 0 - }, - "purchaseRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [purchase rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#purchase-rate).", - "example": 0 - }, - "searchCount": { - "type": "integer", - "nullable": true, - "description": "Number of searches carried out during the A/B test.", - "example": 86269 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "userCount": { - "type": "integer", - "nullable": true, - "description": "Number of users during the A/B test.", - "example": 55501 - }, - "trackedUserCount": { - "type": "integer", - "nullable": true, - "description": "Number of users that performed a tracked search during the A/B test.", - "example": 55501 - } - }, - "required": [ - "userCount", - "trackedUserCount", - "trafficPercentage", - "trackedSearchCount", - "searchCount", - "noResultCount", - "index", - "description", - "conversionRate", - "conversionCount", - "clickThroughRate", - "clickCount", - "averageClickPosition", - "addToCartRate", - "addToCartCount", - "purchaseRate", - "purchaseCount" - ] - }, - "variants": { - "type": "array", - "description": "A/B test variants.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "addToCartCount": { - "type": "integer", - "description": "Number of add-to-cart events for this variant.", - "example": 0 - }, - "addToCartRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [add-to-cart rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#add-to-cart-rate).", - "example": 0 - }, - "averageClickPosition": { - "type": "integer", - "nullable": true, - "description": "Variant's [average click position](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-position).", - "example": 0 - }, - "clickCount": { - "type": "integer", - "description": "Number of click events for this variant.", - "example": 65131 - }, - "clickThroughRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [click-through rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).", - "example": 0.22219857724813036 - }, - "conversionCount": { - "type": "integer", - "description": "Number of click events for this variant.", - "example": 4785 - }, - "conversionRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [conversion rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).", - "example": 0.14546725846658964 - }, - "currencies": { - "type": "object", - "description": "A/B test currencies.", - "example": { - "USD": { - "currency": "USD", - "revenue": 120, - "mean": 53.7, - "standardDeviation": 12.3 - }, - "EUR": { - "currency": "EUR", - "revenue": 100, - "mean": 43.7, - "standardDeviation": 10.3 - } - }, - "additionalProperties": { - "type": "object", - "properties": { - "currency": { - "type": "string", - "description": "Currency code.", - "example": "USD" - }, - "revenue": { - "type": "number", - "format": "double", - "description": "Revenue for this currency.", - "example": 120 - }, - "mean": { - "type": "number", - "format": "double", - "description": "Mean for this currency.", - "example": 53.7 - }, - "standardDeviation": { - "type": "number", - "format": "double", - "description": "Standard deviation for this currency.", - "example": 12.3 - } - } - } - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - }, - "estimatedSampleSize": { - "type": "integer", - "description": "The estimated number of searches that will need to be run to achieve the desired confidence level and statistical power. A `minimumDetectableEffect` must be set in the `configuration` object for this to be used.", - "example": 0 - }, - "filterEffects": { - "type": "object", - "description": "A/B test filter effects resulting from configuration settings.", - "properties": { - "outliers": { - "type": "object", - "description": "Outliers removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - }, - "emptySearch": { - "type": "object", - "description": "Empty searches removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - } - } - }, - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "noResultCount": { - "type": "integer", - "nullable": true, - "description": "Number of [searches without results](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#searches-without-results) for that variant.", - "example": 0 - }, - "purchaseCount": { - "type": "integer", - "description": "Number of purchase events for this variant.", - "example": 0 - }, - "purchaseRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [purchase rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#purchase-rate).", - "example": 0 - }, - "searchCount": { - "type": "integer", - "nullable": true, - "description": "Number of searches carried out during the A/B test.", - "example": 86269 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "userCount": { - "type": "integer", - "nullable": true, - "description": "Number of users during the A/B test.", - "example": 55501 - }, - "trackedUserCount": { - "type": "integer", - "nullable": true, - "description": "Number of users that performed a tracked search during the A/B test.", - "example": 55501 - } - }, - "required": [ - "userCount", - "trackedUserCount", - "trafficPercentage", - "trackedSearchCount", - "searchCount", - "noResultCount", - "index", - "description", - "conversionRate", - "conversionCount", - "clickThroughRate", - "clickCount", - "averageClickPosition", - "addToCartRate", - "addToCartCount", - "purchaseRate", - "purchaseCount" - ] - } - }, - "ABTest": { - "type": "object", - "additionalProperties": false, - "properties": { - "abTestID": { - "type": "integer", - "description": "Unique A/B test ID.", - "example": 224 - }, - "clickSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on click data. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "conversionSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on conversion. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "addToCartSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on add-to-cart data. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "purchaseSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on purchase data. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "revenueSignificance": { - "type": "object", - "additionalProperties": { - "type": "number", - "format": "double" - }, - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on revenue data. A value of 0.95 or over is considered to be _significant_.\n", - "example": { - "USD": 1, - "EUR": 0.87 - } - }, - "updatedAt": { - "type": "string", - "description": "Update date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-15T15:06:44.400601Z" - }, - "createdAt": { - "type": "string", - "description": "Creation date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-15T15:06:04.249906Z" - }, - "endAt": { - "type": "string", - "description": "End date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-17T00:00:00Z" - }, - "name": { - "type": "string", - "description": "A/B test name.", - "example": "Custom ranking sales rank test" - }, - "status": { - "type": "string", - "description": "A/B test status.", - "example": "running" - }, - "variants": { - "type": "array", - "description": "A/B test variants.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "addToCartCount": { - "type": "integer", - "description": "Number of add-to-cart events for this variant.", - "example": 0 - }, - "addToCartRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [add-to-cart rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#add-to-cart-rate).", - "example": 0 - }, - "averageClickPosition": { - "type": "integer", - "nullable": true, - "description": "Variant's [average click position](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-position).", - "example": 0 - }, - "clickCount": { - "type": "integer", - "description": "Number of click events for this variant.", - "example": 65131 - }, - "clickThroughRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [click-through rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).", - "example": 0.22219857724813036 - }, - "conversionCount": { - "type": "integer", - "description": "Number of click events for this variant.", - "example": 4785 - }, - "conversionRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [conversion rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).", - "example": 0.14546725846658964 - }, - "currencies": { - "type": "object", - "description": "A/B test currencies.", - "example": { - "USD": { - "currency": "USD", - "revenue": 120, - "mean": 53.7, - "standardDeviation": 12.3 - }, - "EUR": { - "currency": "EUR", - "revenue": 100, - "mean": 43.7, - "standardDeviation": 10.3 - } - }, - "additionalProperties": { - "type": "object", - "properties": { - "currency": { - "type": "string", - "description": "Currency code.", - "example": "USD" - }, - "revenue": { - "type": "number", - "format": "double", - "description": "Revenue for this currency.", - "example": 120 - }, - "mean": { - "type": "number", - "format": "double", - "description": "Mean for this currency.", - "example": 53.7 - }, - "standardDeviation": { - "type": "number", - "format": "double", - "description": "Standard deviation for this currency.", - "example": 12.3 - } - } - } - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - }, - "estimatedSampleSize": { - "type": "integer", - "description": "The estimated number of searches that will need to be run to achieve the desired confidence level and statistical power. A `minimumDetectableEffect` must be set in the `configuration` object for this to be used.", - "example": 0 - }, - "filterEffects": { - "type": "object", - "description": "A/B test filter effects resulting from configuration settings.", - "properties": { - "outliers": { - "type": "object", - "description": "Outliers removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - }, - "emptySearch": { - "type": "object", - "description": "Empty searches removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - } - } - }, - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "noResultCount": { - "type": "integer", - "nullable": true, - "description": "Number of [searches without results](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#searches-without-results) for that variant.", - "example": 0 - }, - "purchaseCount": { - "type": "integer", - "description": "Number of purchase events for this variant.", - "example": 0 - }, - "purchaseRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [purchase rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#purchase-rate).", - "example": 0 - }, - "searchCount": { - "type": "integer", - "nullable": true, - "description": "Number of searches carried out during the A/B test.", - "example": 86269 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "userCount": { - "type": "integer", - "nullable": true, - "description": "Number of users during the A/B test.", - "example": 55501 - }, - "trackedUserCount": { - "type": "integer", - "nullable": true, - "description": "Number of users that performed a tracked search during the A/B test.", - "example": 55501 - } - }, - "required": [ - "userCount", - "trackedUserCount", - "trafficPercentage", - "trackedSearchCount", - "searchCount", - "noResultCount", - "index", - "description", - "conversionRate", - "conversionCount", - "clickThroughRate", - "clickCount", - "averageClickPosition", - "addToCartRate", - "addToCartCount", - "purchaseRate", - "purchaseCount" - ] - } - } - }, - "required": [ - "status", - "name", - "createdAt", - "endAt", - "updatedAt", - "conversionSignificance", - "clickSignificance", - "purchaseSignificance", - "addToCartSignificance", - "revenueSignificance", - "abTestID", - "variants" - ] - }, - "ABTests": { - "nullable": true, - "type": "array", - "description": "A/B tests.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "abTestID": { - "type": "integer", - "description": "Unique A/B test ID.", - "example": 224 - }, - "clickSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on click data. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "conversionSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on conversion. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "addToCartSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on add-to-cart data. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "purchaseSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on purchase data. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "revenueSignificance": { - "type": "object", - "additionalProperties": { - "type": "number", - "format": "double" - }, - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on revenue data. A value of 0.95 or over is considered to be _significant_.\n", - "example": { - "USD": 1, - "EUR": 0.87 - } - }, - "updatedAt": { - "type": "string", - "description": "Update date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-15T15:06:44.400601Z" - }, - "createdAt": { - "type": "string", - "description": "Creation date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-15T15:06:04.249906Z" - }, - "endAt": { - "type": "string", - "description": "End date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-17T00:00:00Z" - }, - "name": { - "type": "string", - "description": "A/B test name.", - "example": "Custom ranking sales rank test" - }, - "status": { - "type": "string", - "description": "A/B test status.", - "example": "running" - }, - "variants": { - "type": "array", - "description": "A/B test variants.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "addToCartCount": { - "type": "integer", - "description": "Number of add-to-cart events for this variant.", - "example": 0 - }, - "addToCartRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [add-to-cart rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#add-to-cart-rate).", - "example": 0 - }, - "averageClickPosition": { - "type": "integer", - "nullable": true, - "description": "Variant's [average click position](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-position).", - "example": 0 - }, - "clickCount": { - "type": "integer", - "description": "Number of click events for this variant.", - "example": 65131 - }, - "clickThroughRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [click-through rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).", - "example": 0.22219857724813036 - }, - "conversionCount": { - "type": "integer", - "description": "Number of click events for this variant.", - "example": 4785 - }, - "conversionRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [conversion rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).", - "example": 0.14546725846658964 - }, - "currencies": { - "type": "object", - "description": "A/B test currencies.", - "example": { - "USD": { - "currency": "USD", - "revenue": 120, - "mean": 53.7, - "standardDeviation": 12.3 - }, - "EUR": { - "currency": "EUR", - "revenue": 100, - "mean": 43.7, - "standardDeviation": 10.3 - } - }, - "additionalProperties": { - "type": "object", - "properties": { - "currency": { - "type": "string", - "description": "Currency code.", - "example": "USD" - }, - "revenue": { - "type": "number", - "format": "double", - "description": "Revenue for this currency.", - "example": 120 - }, - "mean": { - "type": "number", - "format": "double", - "description": "Mean for this currency.", - "example": 53.7 - }, - "standardDeviation": { - "type": "number", - "format": "double", - "description": "Standard deviation for this currency.", - "example": 12.3 - } - } - } - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - }, - "estimatedSampleSize": { - "type": "integer", - "description": "The estimated number of searches that will need to be run to achieve the desired confidence level and statistical power. A `minimumDetectableEffect` must be set in the `configuration` object for this to be used.", - "example": 0 - }, - "filterEffects": { - "type": "object", - "description": "A/B test filter effects resulting from configuration settings.", - "properties": { - "outliers": { - "type": "object", - "description": "Outliers removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - }, - "emptySearch": { - "type": "object", - "description": "Empty searches removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - } - } - }, - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "noResultCount": { - "type": "integer", - "nullable": true, - "description": "Number of [searches without results](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#searches-without-results) for that variant.", - "example": 0 - }, - "purchaseCount": { - "type": "integer", - "description": "Number of purchase events for this variant.", - "example": 0 - }, - "purchaseRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [purchase rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#purchase-rate).", - "example": 0 - }, - "searchCount": { - "type": "integer", - "nullable": true, - "description": "Number of searches carried out during the A/B test.", - "example": 86269 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "userCount": { - "type": "integer", - "nullable": true, - "description": "Number of users during the A/B test.", - "example": 55501 - }, - "trackedUserCount": { - "type": "integer", - "nullable": true, - "description": "Number of users that performed a tracked search during the A/B test.", - "example": 55501 - } - }, - "required": [ - "userCount", - "trackedUserCount", - "trafficPercentage", - "trackedSearchCount", - "searchCount", - "noResultCount", - "index", - "description", - "conversionRate", - "conversionCount", - "clickThroughRate", - "clickCount", - "averageClickPosition", - "addToCartRate", - "addToCartCount", - "purchaseRate", - "purchaseCount" - ] - } - } - }, - "required": [ - "status", - "name", - "createdAt", - "endAt", - "updatedAt", - "conversionSignificance", - "clickSignificance", - "purchaseSignificance", - "addToCartSignificance", - "revenueSignificance", - "abTestID", - "variants" - ] - } - }, - "abTestsVariant": { - "type": "object", - "additionalProperties": false, - "properties": { - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - } - }, - "required": [ - "index", - "trafficPercentage" - ] - }, - "customSearchParams": { - "type": "object", - "description": "Applies search parameters from [a restricted set of options](https://www.algolia.com/doc/api-reference/api-methods/add-ab-test/#method-param-customsearchparameters). Only use this parameter if the two variants use the same index.", - "example": { - "typoTolerance": false, - "synonyms": false - }, - "additionalProperties": false, - "properties": { - "customSearchParameters": { - "type": "object" - } - }, - "required": [ - "customSearchParameters" - ] - }, - "abTestsVariantSearchParams": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - } - }, - "required": [ - "index", - "trafficPercentage" - ] - }, - { - "type": "object", - "description": "Applies search parameters from [a restricted set of options](https://www.algolia.com/doc/api-reference/api-methods/add-ab-test/#method-param-customsearchparameters). Only use this parameter if the two variants use the same index.", - "example": { - "typoTolerance": false, - "synonyms": false - }, - "additionalProperties": false, - "properties": { - "customSearchParameters": { - "type": "object" - } - }, - "required": [ - "customSearchParameters" - ] - } - ] - }, - "AddABTestsVariant": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - } - }, - "required": [ - "index", - "trafficPercentage" - ] - }, - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - } - }, - "required": [ - "index", - "trafficPercentage" - ] - }, - { - "type": "object", - "description": "Applies search parameters from [a restricted set of options](https://www.algolia.com/doc/api-reference/api-methods/add-ab-test/#method-param-customsearchparameters). Only use this parameter if the two variants use the same index.", - "example": { - "typoTolerance": false, - "synonyms": false - }, - "additionalProperties": false, - "properties": { - "customSearchParameters": { - "type": "object" - } - }, - "required": [ - "customSearchParameters" - ] - } - ] - } - ] - }, - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "ABTestResponse": { - "type": "object", - "additionalProperties": false, - "properties": { - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "abTestID": { - "type": "integer", - "description": "Unique A/B test ID.", - "example": 224 - }, - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - } - }, - "required": [ - "abTestID", - "index", - "taskID" - ] - } - }, - "responses": { - "BadRequest": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "FeatureNotEnabled": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "MethodNotAllowed": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "IndexNotFound": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "servers": [ - { - "url": "https://analytics.{region}.algolia.com", - "variables": { - "region": { - "enum": [ - "us", - "de" - ], - "default": "us" - } - } - }, - { - "url": "https://analytics.algolia.com" - } - ], - "security": [ - { - "appId": [], - "apiKey": [] - } - ], - "tags": [ - { - "name": "abtest", - "x-displayName": "A/B testing", - "description": "Manage A/B tests." - } - ], - "x-tagGroups": [ - { - "name": "General", - "tags": [ - "abtest" - ] - } - ], - "paths": { - "/1{path}": { - "get": { - "operationId": "customGet", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "operationId": "customPost", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "operationId": "customPut", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "operationId": "customDelete", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/abtests": { - "post": { - "tags": [ - "abtest" - ], - "operationId": "addABTests", - "x-acl": [ - "editSettings" - ], - "summary": "Create an A/B test.", - "description": "Creates an A/B test.", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "title": "addABTestsRequest", - "type": "object", - "additionalProperties": false, - "properties": { - "name": { - "type": "string", - "description": "A/B test name.", - "example": "Custom ranking sales rank test" - }, - "variants": { - "type": "array", - "description": "A/B test variants.", - "minItems": 2, - "maxItems": 2, - "items": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - } - }, - "required": [ - "index", - "trafficPercentage" - ] - }, - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - } - }, - "required": [ - "index", - "trafficPercentage" - ] - }, - { - "type": "object", - "description": "Applies search parameters from [a restricted set of options](https://www.algolia.com/doc/api-reference/api-methods/add-ab-test/#method-param-customsearchparameters). Only use this parameter if the two variants use the same index.", - "example": { - "typoTolerance": false, - "synonyms": false - }, - "additionalProperties": false, - "properties": { - "customSearchParameters": { - "type": "object" - } - }, - "required": [ - "customSearchParameters" - ] - } - ] - } - ] - } - }, - "endAt": { - "type": "string", - "description": "End date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-17T00:00:00Z" - } - }, - "required": [ - "name", - "variants", - "endAt" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "abTestID": { - "type": "integer", - "description": "Unique A/B test ID.", - "example": 224 - }, - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - } - }, - "required": [ - "abTestID", - "index", - "taskID" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "get": { - "tags": [ - "abtest" - ], - "operationId": "listABTests", - "x-acl": [ - "analytics" - ], - "summary": "List all A/B tests.", - "description": "List all A/B tests.", - "parameters": [ - { - "in": "query", - "name": "offset", - "description": "Position of the starting record. Used for paging. 0 is the first record.", - "schema": { - "type": "integer", - "default": 0 - } - }, - { - "in": "query", - "name": "limit", - "description": "Number of records to return (page size).", - "schema": { - "type": "integer", - "default": 10 - } - }, - { - "name": "indexPrefix", - "in": "query", - "description": "Only return A/B tests for indices starting with this prefix.", - "example": "dev_", - "schema": { - "type": "string" - } - }, - { - "name": "indexSuffix", - "in": "query", - "description": "Only return A/B tests for indices ending with this suffix.", - "example": "_development", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "listABTestsResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "abtests": { - "nullable": true, - "type": "array", - "description": "A/B tests.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "abTestID": { - "type": "integer", - "description": "Unique A/B test ID.", - "example": 224 - }, - "clickSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on click data. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "conversionSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on conversion. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "addToCartSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on add-to-cart data. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "purchaseSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on purchase data. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "revenueSignificance": { - "type": "object", - "additionalProperties": { - "type": "number", - "format": "double" - }, - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on revenue data. A value of 0.95 or over is considered to be _significant_.\n", - "example": { - "USD": 1, - "EUR": 0.87 - } - }, - "updatedAt": { - "type": "string", - "description": "Update date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-15T15:06:44.400601Z" - }, - "createdAt": { - "type": "string", - "description": "Creation date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-15T15:06:04.249906Z" - }, - "endAt": { - "type": "string", - "description": "End date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-17T00:00:00Z" - }, - "name": { - "type": "string", - "description": "A/B test name.", - "example": "Custom ranking sales rank test" - }, - "status": { - "type": "string", - "description": "A/B test status.", - "example": "running" - }, - "variants": { - "type": "array", - "description": "A/B test variants.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "addToCartCount": { - "type": "integer", - "description": "Number of add-to-cart events for this variant.", - "example": 0 - }, - "addToCartRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [add-to-cart rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#add-to-cart-rate).", - "example": 0 - }, - "averageClickPosition": { - "type": "integer", - "nullable": true, - "description": "Variant's [average click position](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-position).", - "example": 0 - }, - "clickCount": { - "type": "integer", - "description": "Number of click events for this variant.", - "example": 65131 - }, - "clickThroughRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [click-through rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).", - "example": 0.22219857724813036 - }, - "conversionCount": { - "type": "integer", - "description": "Number of click events for this variant.", - "example": 4785 - }, - "conversionRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [conversion rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).", - "example": 0.14546725846658964 - }, - "currencies": { - "type": "object", - "description": "A/B test currencies.", - "example": { - "USD": { - "currency": "USD", - "revenue": 120, - "mean": 53.7, - "standardDeviation": 12.3 - }, - "EUR": { - "currency": "EUR", - "revenue": 100, - "mean": 43.7, - "standardDeviation": 10.3 - } - }, - "additionalProperties": { - "type": "object", - "properties": { - "currency": { - "type": "string", - "description": "Currency code.", - "example": "USD" - }, - "revenue": { - "type": "number", - "format": "double", - "description": "Revenue for this currency.", - "example": 120 - }, - "mean": { - "type": "number", - "format": "double", - "description": "Mean for this currency.", - "example": 53.7 - }, - "standardDeviation": { - "type": "number", - "format": "double", - "description": "Standard deviation for this currency.", - "example": 12.3 - } - } - } - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - }, - "estimatedSampleSize": { - "type": "integer", - "description": "The estimated number of searches that will need to be run to achieve the desired confidence level and statistical power. A `minimumDetectableEffect` must be set in the `configuration` object for this to be used.", - "example": 0 - }, - "filterEffects": { - "type": "object", - "description": "A/B test filter effects resulting from configuration settings.", - "properties": { - "outliers": { - "type": "object", - "description": "Outliers removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - }, - "emptySearch": { - "type": "object", - "description": "Empty searches removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - } - } - }, - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "noResultCount": { - "type": "integer", - "nullable": true, - "description": "Number of [searches without results](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#searches-without-results) for that variant.", - "example": 0 - }, - "purchaseCount": { - "type": "integer", - "description": "Number of purchase events for this variant.", - "example": 0 - }, - "purchaseRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [purchase rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#purchase-rate).", - "example": 0 - }, - "searchCount": { - "type": "integer", - "nullable": true, - "description": "Number of searches carried out during the A/B test.", - "example": 86269 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "userCount": { - "type": "integer", - "nullable": true, - "description": "Number of users during the A/B test.", - "example": 55501 - }, - "trackedUserCount": { - "type": "integer", - "nullable": true, - "description": "Number of users that performed a tracked search during the A/B test.", - "example": 55501 - } - }, - "required": [ - "userCount", - "trackedUserCount", - "trafficPercentage", - "trackedSearchCount", - "searchCount", - "noResultCount", - "index", - "description", - "conversionRate", - "conversionCount", - "clickThroughRate", - "clickCount", - "averageClickPosition", - "addToCartRate", - "addToCartCount", - "purchaseRate", - "purchaseCount" - ] - } - } - }, - "required": [ - "status", - "name", - "createdAt", - "endAt", - "updatedAt", - "conversionSignificance", - "clickSignificance", - "purchaseSignificance", - "addToCartSignificance", - "revenueSignificance", - "abTestID", - "variants" - ] - } - }, - "count": { - "type": "integer", - "description": "Number of A/B tests implemented.", - "example": 10 - }, - "total": { - "type": "integer", - "description": "Number of retrievable A/B tests.", - "example": 12 - } - }, - "required": [ - "abtests", - "count", - "total" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/abtests/{id}": { - "get": { - "tags": [ - "abtest" - ], - "operationId": "getABTest", - "x-acl": [ - "analytics" - ], - "summary": "Get A/B test details.", - "description": "Get specific details for an A/B test.\nTo determine the `id` for an A/B test, use the [`listABTests` operation](#tag/abtest/operation/listABTests).\n", - "parameters": [ - { - "in": "path", - "name": "id", - "description": "Unique A/B test ID.", - "required": true, - "schema": { - "type": "integer", - "example": 390 - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "abTestID": { - "type": "integer", - "description": "Unique A/B test ID.", - "example": 224 - }, - "clickSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on click data. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "conversionSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on conversion. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "addToCartSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on add-to-cart data. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "purchaseSignificance": { - "type": "number", - "format": "double", - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on purchase data. A value of 0.95 or over is considered to be _significant_.\n", - "example": 1 - }, - "revenueSignificance": { - "type": "object", - "additionalProperties": { - "type": "number", - "format": "double" - }, - "nullable": true, - "description": "[A/B test significance](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing/in-depth/how-ab-test-scores-are-calculated/#statistical-significance-or-chance) based on revenue data. A value of 0.95 or over is considered to be _significant_.\n", - "example": { - "USD": 1, - "EUR": 0.87 - } - }, - "updatedAt": { - "type": "string", - "description": "Update date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-15T15:06:44.400601Z" - }, - "createdAt": { - "type": "string", - "description": "Creation date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-15T15:06:04.249906Z" - }, - "endAt": { - "type": "string", - "description": "End date timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-06-17T00:00:00Z" - }, - "name": { - "type": "string", - "description": "A/B test name.", - "example": "Custom ranking sales rank test" - }, - "status": { - "type": "string", - "description": "A/B test status.", - "example": "running" - }, - "variants": { - "type": "array", - "description": "A/B test variants.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "addToCartCount": { - "type": "integer", - "description": "Number of add-to-cart events for this variant.", - "example": 0 - }, - "addToCartRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [add-to-cart rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#add-to-cart-rate).", - "example": 0 - }, - "averageClickPosition": { - "type": "integer", - "nullable": true, - "description": "Variant's [average click position](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-position).", - "example": 0 - }, - "clickCount": { - "type": "integer", - "description": "Number of click events for this variant.", - "example": 65131 - }, - "clickThroughRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [click-through rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).", - "example": 0.22219857724813036 - }, - "conversionCount": { - "type": "integer", - "description": "Number of click events for this variant.", - "example": 4785 - }, - "conversionRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [conversion rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).", - "example": 0.14546725846658964 - }, - "currencies": { - "type": "object", - "description": "A/B test currencies.", - "example": { - "USD": { - "currency": "USD", - "revenue": 120, - "mean": 53.7, - "standardDeviation": 12.3 - }, - "EUR": { - "currency": "EUR", - "revenue": 100, - "mean": 43.7, - "standardDeviation": 10.3 - } - }, - "additionalProperties": { - "type": "object", - "properties": { - "currency": { - "type": "string", - "description": "Currency code.", - "example": "USD" - }, - "revenue": { - "type": "number", - "format": "double", - "description": "Revenue for this currency.", - "example": 120 - }, - "mean": { - "type": "number", - "format": "double", - "description": "Mean for this currency.", - "example": 53.7 - }, - "standardDeviation": { - "type": "number", - "format": "double", - "description": "Standard deviation for this currency.", - "example": 12.3 - } - } - } - }, - "description": { - "type": "string", - "description": "A/B test description.", - "example": "Current production index" - }, - "estimatedSampleSize": { - "type": "integer", - "description": "The estimated number of searches that will need to be run to achieve the desired confidence level and statistical power. A `minimumDetectableEffect` must be set in the `configuration` object for this to be used.", - "example": 0 - }, - "filterEffects": { - "type": "object", - "description": "A/B test filter effects resulting from configuration settings.", - "properties": { - "outliers": { - "type": "object", - "description": "Outliers removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - }, - "emptySearch": { - "type": "object", - "description": "Empty searches removed from the A/B test as a result of configuration settings.", - "example": { - "usersCount": 1, - "trackedSearchesCount": 237 - }, - "properties": { - "usersCount": { - "type": "integer", - "description": "Number of users removed from the A/B test.", - "example": 1 - }, - "trackedSearchesCount": { - "type": "integer", - "description": "Number of tracked searches removed from the A/B test.", - "example": 237 - } - } - } - } - }, - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "noResultCount": { - "type": "integer", - "nullable": true, - "description": "Number of [searches without results](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#searches-without-results) for that variant.", - "example": 0 - }, - "purchaseCount": { - "type": "integer", - "description": "Number of purchase events for this variant.", - "example": 0 - }, - "purchaseRate": { - "type": "number", - "format": "double", - "nullable": true, - "description": "Variant's [purchase rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#purchase-rate).", - "example": 0 - }, - "searchCount": { - "type": "integer", - "nullable": true, - "description": "Number of searches carried out during the A/B test.", - "example": 86269 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "trafficPercentage": { - "type": "integer", - "description": "A/B test traffic percentage.", - "example": 60 - }, - "userCount": { - "type": "integer", - "nullable": true, - "description": "Number of users during the A/B test.", - "example": 55501 - }, - "trackedUserCount": { - "type": "integer", - "nullable": true, - "description": "Number of users that performed a tracked search during the A/B test.", - "example": 55501 - } - }, - "required": [ - "userCount", - "trackedUserCount", - "trafficPercentage", - "trackedSearchCount", - "searchCount", - "noResultCount", - "index", - "description", - "conversionRate", - "conversionCount", - "clickThroughRate", - "clickCount", - "averageClickPosition", - "addToCartRate", - "addToCartCount", - "purchaseRate", - "purchaseCount" - ] - } - } - }, - "required": [ - "status", - "name", - "createdAt", - "endAt", - "updatedAt", - "conversionSignificance", - "clickSignificance", - "purchaseSignificance", - "addToCartSignificance", - "revenueSignificance", - "abTestID", - "variants" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "abtest" - ], - "operationId": "deleteABTest", - "x-acl": [ - "editSettings" - ], - "summary": "Delete an A/B test.", - "description": "Delete an A/B test.\nTo determine the `id` for an A/B test, use the [`listABTests` operation](#tag/abtest/operation/listABTests).\n", - "parameters": [ - { - "in": "path", - "name": "id", - "description": "Unique A/B test ID.", - "required": true, - "schema": { - "type": "integer", - "example": 390 - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "abTestID": { - "type": "integer", - "description": "Unique A/B test ID.", - "example": 224 - }, - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - } - }, - "required": [ - "abTestID", - "index", - "taskID" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/abtests/{id}/stop": { - "post": { - "tags": [ - "abtest" - ], - "operationId": "stopABTest", - "x-acl": [ - "editSettings" - ], - "summary": "Stop an A/B test.", - "description": "If stopped, the test is over and can't be restarted. There is now only one index, receiving 100% of all search requests.\nThe data gathered for stopped A/B tests is retained.\nTo determine the `id` for an A/B test, use the [`listABTests` operation](#tag/abtest/operation/listABTests).\n", - "parameters": [ - { - "in": "path", - "name": "id", - "description": "Unique A/B test ID.", - "required": true, - "schema": { - "type": "integer", - "example": 390 - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "index": { - "type": "string", - "description": "A/B test index.", - "example": "delcourt_production" - }, - "abTestID": { - "type": "integer", - "description": "Unique A/B test ID.", - "example": 224 - }, - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - } - }, - "required": [ - "abTestID", - "index", - "taskID" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - } - } -} \ No newline at end of file diff --git a/specs/bundled/analytics.json b/specs/bundled/analytics.json deleted file mode 100644 index 5f51ab91a4..0000000000 --- a/specs/bundled/analytics.json +++ /dev/null @@ -1,5064 +0,0 @@ -{ - "openapi": "3.0.2", - "info": { - "title": "Analytics API", - "description": "The Analytics API lets you review your search, and click and conversion analytics.\n> **Note**: The API key in the `X-Algolia-API-Key` header requires the [`analytics` ACL](https://www.algolia.com/doc/guides/security/api-keys/#access-control-list-acl).\n", - "version": "1.0.0" - }, - "components": { - "securitySchemes": { - "appId": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-Application-Id" - }, - "apiKey": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-API-Key" - } - }, - "parameters": { - "PathInPath": { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - "Parameters": { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - }, - "Index": { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - "ClickAnalytics": { - "in": "query", - "name": "clickAnalytics", - "description": "Whether to include [click and conversion](https://www.algolia.com/doc/guides/sending-events/getting-started/) rates for a search.", - "schema": { - "type": "boolean", - "default": false - } - }, - "StartDate": { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - "EndDate": { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - "OrderBy": { - "in": "query", - "name": "orderBy", - "description": "Reorder the results.", - "schema": { - "type": "string", - "description": "Method for ordering results.\n`clickThroughRate`, `conversionRate` and `averageClickPosition` are only available if the `clickAnalytics` parameter is `true`.\n", - "enum": [ - "searchCount", - "clickThroughRate", - "conversionRate", - "averageClickPosition" - ], - "default": "searchCount" - } - }, - "Direction": { - "in": "query", - "name": "direction", - "description": "Sorting direction of the results: ascending or descending.\n", - "schema": { - "type": "string", - "enum": [ - "asc", - "desc" - ], - "default": "asc" - } - }, - "Limit": { - "in": "query", - "name": "limit", - "description": "Number of records to return (page size).", - "schema": { - "type": "integer", - "default": 10 - } - }, - "Offset": { - "in": "query", - "name": "offset", - "description": "Position of the starting record. Used for paging. 0 is the first record.", - "schema": { - "type": "integer", - "default": 0 - } - }, - "Tags": { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - }, - "Search": { - "in": "query", - "name": "search", - "description": "User query.", - "example": "enable ab test", - "schema": { - "type": "string" - } - }, - "Attribute": { - "in": "path", - "name": "attribute", - "description": "Attribute name.", - "required": true, - "schema": { - "type": "string", - "example": "brand" - } - } - }, - "schemas": { - "ErrorBase": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - }, - "orderBy": { - "type": "string", - "description": "Method for ordering results.\n`clickThroughRate`, `conversionRate` and `averageClickPosition` are only available if the `clickAnalytics` parameter is `true`.\n", - "enum": [ - "searchCount", - "clickThroughRate", - "conversionRate", - "averageClickPosition" - ], - "default": "searchCount" - }, - "direction": { - "type": "string", - "enum": [ - "asc", - "desc" - ], - "default": "asc" - }, - "search": { - "description": "User query.", - "example": "separator", - "type": "string" - }, - "count": { - "description": "Number of tracked _and_ untracked searches (where the `clickAnalytics` parameter isn't `true`).", - "type": "integer", - "example": 504 - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "topSearchesResponse": { - "type": "object", - "additionalProperties": false, - "required": [ - "searches" - ], - "properties": { - "searches": { - "type": "array", - "description": "Top searches with their hits count.", - "items": { - "type": "object", - "title": "topSearch", - "additionalProperties": false, - "required": [ - "search", - "count", - "nbHits" - ], - "properties": { - "search": { - "description": "User query.", - "example": "separator", - "type": "string" - }, - "count": { - "description": "Number of tracked _and_ untracked searches (where the `clickAnalytics` parameter isn't `true`).", - "type": "integer", - "example": 504 - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - } - } - } - } - } - }, - "rate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "averageClickPosition": { - "type": "integer", - "description": "Average [position](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-position) of clicked search result.", - "example": 1 - }, - "conversionRate": { - "type": "number", - "format": "double", - "description": "[Conversion rate (CR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).\n", - "example": 0 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "clickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "conversionCount": { - "type": "integer", - "description": "Number of converted clicks.", - "example": 0 - }, - "topSearchesResponseWithAnalytics": { - "type": "object", - "additionalProperties": false, - "required": [ - "searches" - ], - "properties": { - "searches": { - "type": "array", - "description": "Top searches with their hits count and analytics.", - "items": { - "type": "object", - "title": "topSearchWithAnalytics", - "additionalProperties": false, - "required": [ - "search", - "count", - "nbHits", - "clickThroughRate", - "averageClickPosition", - "conversionRate", - "trackedSearchCount", - "clickCount", - "conversionCount" - ], - "properties": { - "search": { - "description": "User query.", - "example": "separator", - "type": "string" - }, - "count": { - "description": "Number of tracked _and_ untracked searches (where the `clickAnalytics` parameter isn't `true`).", - "type": "integer", - "example": 504 - }, - "clickThroughRate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "averageClickPosition": { - "type": "integer", - "description": "Average [position](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-position) of clicked search result.", - "example": 1 - }, - "conversionRate": { - "type": "number", - "format": "double", - "description": "[Conversion rate (CR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).\n", - "example": 0 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "clickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "conversionCount": { - "type": "integer", - "description": "Number of converted clicks.", - "example": 0 - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - } - } - } - } - } - }, - "getTopSearchesResponse": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "required": [ - "searches" - ], - "properties": { - "searches": { - "type": "array", - "description": "Top searches with their hits count.", - "items": { - "type": "object", - "title": "topSearch", - "additionalProperties": false, - "required": [ - "search", - "count", - "nbHits" - ], - "properties": { - "search": { - "description": "User query.", - "example": "separator", - "type": "string" - }, - "count": { - "description": "Number of tracked _and_ untracked searches (where the `clickAnalytics` parameter isn't `true`).", - "type": "integer", - "example": 504 - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - } - } - } - } - } - }, - { - "type": "object", - "additionalProperties": false, - "required": [ - "searches" - ], - "properties": { - "searches": { - "type": "array", - "description": "Top searches with their hits count and analytics.", - "items": { - "type": "object", - "title": "topSearchWithAnalytics", - "additionalProperties": false, - "required": [ - "search", - "count", - "nbHits", - "clickThroughRate", - "averageClickPosition", - "conversionRate", - "trackedSearchCount", - "clickCount", - "conversionCount" - ], - "properties": { - "search": { - "description": "User query.", - "example": "separator", - "type": "string" - }, - "count": { - "description": "Number of tracked _and_ untracked searches (where the `clickAnalytics` parameter isn't `true`).", - "type": "integer", - "example": 504 - }, - "clickThroughRate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "averageClickPosition": { - "type": "integer", - "description": "Average [position](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-position) of clicked search result.", - "example": 1 - }, - "conversionRate": { - "type": "number", - "format": "double", - "description": "[Conversion rate (CR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).\n", - "example": 0 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "clickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "conversionCount": { - "type": "integer", - "description": "Number of converted clicks.", - "example": 0 - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - } - } - } - } - } - } - ] - }, - "parameters_count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "date": { - "type": "string", - "description": "Date of the event in the format YYYY-MM-DD.", - "example": "2023-06-14" - }, - "noResultCount": { - "description": "Number of occurences.", - "type": "integer", - "example": 54 - }, - "hit": { - "description": "Hit.", - "type": "string", - "example": "method-export-rules-php" - }, - "topHitsResponse": { - "type": "object", - "additionalProperties": false, - "required": [ - "hits" - ], - "properties": { - "hits": { - "type": "array", - "description": "Top hits.", - "items": { - "type": "object", - "title": "topHit", - "additionalProperties": false, - "required": [ - "hit", - "count" - ], - "properties": { - "hit": { - "description": "Hit.", - "type": "string", - "example": "method-export-rules-php" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - } - } - } - }, - "topHitsResponseWithAnalytics": { - "type": "object", - "additionalProperties": false, - "required": [ - "hits" - ], - "properties": { - "hits": { - "type": "array", - "description": "Top hits.", - "items": { - "type": "object", - "title": "topHitWithAnalytics", - "additionalProperties": false, - "required": [ - "hit", - "count", - "clickThroughRate", - "conversionRate", - "trackedSearchCount", - "clickCount", - "conversionCount" - ], - "properties": { - "hit": { - "description": "Hit.", - "type": "string", - "example": "method-export-rules-php" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "clickThroughRate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "conversionRate": { - "type": "number", - "format": "double", - "description": "[Conversion rate (CR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).\n", - "example": 0 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "clickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "conversionCount": { - "type": "integer", - "description": "Number of converted clicks.", - "example": 0 - } - } - } - } - } - }, - "getTopHitsResponse": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "required": [ - "hits" - ], - "properties": { - "hits": { - "type": "array", - "description": "Top hits.", - "items": { - "type": "object", - "title": "topHit", - "additionalProperties": false, - "required": [ - "hit", - "count" - ], - "properties": { - "hit": { - "description": "Hit.", - "type": "string", - "example": "method-export-rules-php" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - } - } - } - }, - { - "type": "object", - "additionalProperties": false, - "required": [ - "hits" - ], - "properties": { - "hits": { - "type": "array", - "description": "Top hits.", - "items": { - "type": "object", - "title": "topHitWithAnalytics", - "additionalProperties": false, - "required": [ - "hit", - "count", - "clickThroughRate", - "conversionRate", - "trackedSearchCount", - "clickCount", - "conversionCount" - ], - "properties": { - "hit": { - "description": "Hit.", - "type": "string", - "example": "method-export-rules-php" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "clickThroughRate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "conversionRate": { - "type": "number", - "format": "double", - "description": "[Conversion rate (CR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).\n", - "example": 0 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "clickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "conversionCount": { - "type": "integer", - "description": "Number of converted clicks.", - "example": 0 - } - } - } - } - } - } - ] - }, - "attribute": { - "description": "Attribute name.", - "type": "string", - "example": "url" - }, - "getTopFilterAttribute": { - "type": "object", - "additionalProperties": false, - "required": [ - "attribute", - "count" - ], - "properties": { - "attribute": { - "description": "Attribute name.", - "type": "string", - "example": "url" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - }, - "getTopFilterAttributesResponse": { - "type": "object", - "additionalProperties": false, - "required": [ - "attributes" - ], - "properties": { - "attributes": { - "type": "array", - "description": "Filterable attributes.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "attribute", - "count" - ], - "properties": { - "attribute": { - "description": "Attribute name.", - "type": "string", - "example": "url" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - } - } - } - }, - "operator": { - "description": "Operator.", - "type": "string", - "example": ":" - }, - "value": { - "description": "Attribute value.", - "type": "string", - "example": "integration" - }, - "getTopFilterForAttribute": { - "type": "object", - "additionalProperties": false, - "required": [ - "operator", - "attribute", - "value", - "count" - ], - "properties": { - "attribute": { - "description": "Attribute name.", - "type": "string", - "example": "url" - }, - "operator": { - "description": "Operator.", - "type": "string", - "example": ":" - }, - "value": { - "description": "Attribute value.", - "type": "string", - "example": "integration" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - }, - "getTopFilterForAttributeResponse": { - "type": "object", - "additionalProperties": false, - "required": [ - "values" - ], - "properties": { - "values": { - "type": "array", - "description": "Filter values for an attribute.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "operator", - "attribute", - "value", - "count" - ], - "properties": { - "attribute": { - "description": "Attribute name.", - "type": "string", - "example": "url" - }, - "operator": { - "description": "Operator.", - "type": "string", - "example": ":" - }, - "value": { - "description": "Attribute value.", - "type": "string", - "example": "integration" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - } - } - } - }, - "getTopFiltersNoResultsValue": { - "type": "object", - "additionalProperties": false, - "required": [ - "attribute", - "operator", - "value" - ], - "properties": { - "attribute": { - "description": "Attribute name.", - "type": "string", - "example": "url" - }, - "operator": { - "description": "Operator.", - "type": "string", - "example": ":" - }, - "value": { - "description": "Attribute value.", - "type": "string", - "example": "integration" - } - } - }, - "getTopFiltersNoResultsValues": { - "type": "object", - "additionalProperties": false, - "required": [ - "values", - "count" - ], - "properties": { - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "values": { - "type": "array", - "description": "Filters with no results.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "attribute", - "operator", - "value" - ], - "properties": { - "attribute": { - "description": "Attribute name.", - "type": "string", - "example": "url" - }, - "operator": { - "description": "Operator.", - "type": "string", - "example": ":" - }, - "value": { - "description": "Attribute value.", - "type": "string", - "example": "integration" - } - } - } - } - } - }, - "getTopFiltersNoResultsResponse": { - "type": "object", - "additionalProperties": false, - "required": [ - "values" - ], - "properties": { - "values": { - "type": "array", - "description": "Filters with no results.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "values", - "count" - ], - "properties": { - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "values": { - "type": "array", - "description": "Filters with no results.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "attribute", - "operator", - "value" - ], - "properties": { - "attribute": { - "description": "Attribute name.", - "type": "string", - "example": "url" - }, - "operator": { - "description": "Operator.", - "type": "string", - "example": ":" - }, - "value": { - "description": "Attribute value.", - "type": "string", - "example": "integration" - } - } - } - } - } - } - } - } - }, - "average": { - "type": "number", - "format": "double", - "description": "Average count of all click events.", - "example": 2.3344634550185286 - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - }, - "responses": { - "BadRequest": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "FeatureNotEnabled": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "MethodNotAllowed": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "IndexNotFound": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "servers": [ - { - "url": "https://analytics.{region}.algolia.com", - "variables": { - "region": { - "enum": [ - "us", - "de" - ], - "default": "us" - } - } - }, - { - "url": "https://analytics.algolia.com" - } - ], - "security": [ - { - "appId": [], - "apiKey": [] - } - ], - "tags": [ - { - "name": "advanced", - "x-displayName": "Advanced", - "description": "Advanced operations." - }, - { - "name": "click", - "x-displayName": "Click Analytics", - "description": "Get all click analytics." - }, - { - "name": "search", - "x-displayName": "Search Analytics", - "description": "Get all search analytics." - } - ], - "x-tagGroups": [ - { - "name": "General", - "tags": [ - "search", - "click" - ] - }, - { - "name": "Others", - "tags": [ - "advanced" - ] - } - ], - "paths": { - "/1{path}": { - "get": { - "operationId": "customGet", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "operationId": "customPost", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "operationId": "customPut", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "operationId": "customDelete", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/searches": { - "get": { - "tags": [ - "search" - ], - "operationId": "getTopSearches", - "x-acl": [ - "analytics" - ], - "summary": "Get top searches.", - "description": "Returns the most popular of the latest 1,000 searches. For each search, also returns the number of hits.", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "clickAnalytics", - "description": "Whether to include [click and conversion](https://www.algolia.com/doc/guides/sending-events/getting-started/) rates for a search.", - "schema": { - "type": "boolean", - "default": false - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "orderBy", - "description": "Reorder the results.", - "schema": { - "type": "string", - "description": "Method for ordering results.\n`clickThroughRate`, `conversionRate` and `averageClickPosition` are only available if the `clickAnalytics` parameter is `true`.\n", - "enum": [ - "searchCount", - "clickThroughRate", - "conversionRate", - "averageClickPosition" - ], - "default": "searchCount" - } - }, - { - "in": "query", - "name": "direction", - "description": "Sorting direction of the results: ascending or descending.\n", - "schema": { - "type": "string", - "enum": [ - "asc", - "desc" - ], - "default": "asc" - } - }, - { - "in": "query", - "name": "limit", - "description": "Number of records to return (page size).", - "schema": { - "type": "integer", - "default": 10 - } - }, - { - "in": "query", - "name": "offset", - "description": "Position of the starting record. Used for paging. 0 is the first record.", - "schema": { - "type": "integer", - "default": 0 - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "required": [ - "searches" - ], - "properties": { - "searches": { - "type": "array", - "description": "Top searches with their hits count.", - "items": { - "type": "object", - "title": "topSearch", - "additionalProperties": false, - "required": [ - "search", - "count", - "nbHits" - ], - "properties": { - "search": { - "description": "User query.", - "example": "separator", - "type": "string" - }, - "count": { - "description": "Number of tracked _and_ untracked searches (where the `clickAnalytics` parameter isn't `true`).", - "type": "integer", - "example": 504 - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - } - } - } - } - } - }, - { - "type": "object", - "additionalProperties": false, - "required": [ - "searches" - ], - "properties": { - "searches": { - "type": "array", - "description": "Top searches with their hits count and analytics.", - "items": { - "type": "object", - "title": "topSearchWithAnalytics", - "additionalProperties": false, - "required": [ - "search", - "count", - "nbHits", - "clickThroughRate", - "averageClickPosition", - "conversionRate", - "trackedSearchCount", - "clickCount", - "conversionCount" - ], - "properties": { - "search": { - "description": "User query.", - "example": "separator", - "type": "string" - }, - "count": { - "description": "Number of tracked _and_ untracked searches (where the `clickAnalytics` parameter isn't `true`).", - "type": "integer", - "example": 504 - }, - "clickThroughRate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "averageClickPosition": { - "type": "integer", - "description": "Average [position](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-position) of clicked search result.", - "example": 1 - }, - "conversionRate": { - "type": "number", - "format": "double", - "description": "[Conversion rate (CR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).\n", - "example": 0 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "clickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "conversionCount": { - "type": "integer", - "description": "Number of converted clicks.", - "example": 0 - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - } - } - } - } - } - } - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/searches/count": { - "get": { - "tags": [ - "search" - ], - "operationId": "getSearchesCount", - "x-acl": [ - "analytics" - ], - "summary": "Get number of searches.", - "description": "Returns the number of searches within a time range.", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getSearchesCountResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "dates", - "count" - ], - "properties": { - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "dates": { - "type": "array", - "description": "Search events with their associated dates and hit counts.", - "items": { - "type": "object", - "title": "searchEvent", - "additionalProperties": false, - "required": [ - "date", - "count" - ], - "properties": { - "date": { - "type": "string", - "description": "Date of the event in the format YYYY-MM-DD.", - "example": "2023-06-14" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/searches/noResults": { - "get": { - "tags": [ - "search" - ], - "operationId": "getSearchesNoResults", - "x-acl": [ - "analytics" - ], - "summary": "Get top searches with no results.", - "description": "Returns the most popular of the latest 1,000 searches that didn't return any results.", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "limit", - "description": "Number of records to return (page size).", - "schema": { - "type": "integer", - "default": 10 - } - }, - { - "in": "query", - "name": "offset", - "description": "Position of the starting record. Used for paging. 0 is the first record.", - "schema": { - "type": "integer", - "default": 0 - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getSearchesNoResultsResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "searches" - ], - "properties": { - "searches": { - "type": "array", - "description": "Searches with no results.", - "items": { - "type": "object", - "title": "searchNoResultEvent", - "additionalProperties": false, - "required": [ - "search", - "count", - "nbHits" - ], - "properties": { - "search": { - "description": "User query.", - "example": "separator", - "type": "string" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/searches/noClicks": { - "get": { - "tags": [ - "search" - ], - "operationId": "getSearchesNoClicks", - "x-acl": [ - "analytics" - ], - "summary": "Get top searches with no clicks.", - "description": "Return the most popular of the last 1,000 searches that didn't lead to any clicks.", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "limit", - "description": "Number of records to return (page size).", - "schema": { - "type": "integer", - "default": 10 - } - }, - { - "in": "query", - "name": "offset", - "description": "Position of the starting record. Used for paging. 0 is the first record.", - "schema": { - "type": "integer", - "default": 0 - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getSearchesNoClicksResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "searches" - ], - "properties": { - "searches": { - "type": "array", - "description": "Searches with no clicks.", - "items": { - "type": "object", - "title": "searchNoClickEvent", - "additionalProperties": false, - "required": [ - "search", - "count", - "withFilterCount" - ], - "properties": { - "search": { - "description": "User query.", - "example": "separator", - "type": "string" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "withFilterCount": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/searches/noResultRate": { - "get": { - "tags": [ - "search" - ], - "operationId": "getNoResultsRate", - "x-acl": [ - "analytics" - ], - "summary": "Get no results rate.", - "description": "Returns the rate at which searches didn't return any results.", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getNoResultsRateResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "rate", - "count", - "noResultCount", - "dates" - ], - "properties": { - "rate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "noResultCount": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "dates": { - "type": "array", - "description": "Overall count of searches without results plus a daily breakdown.", - "items": { - "type": "object", - "title": "noResultsRateEvent", - "additionalProperties": false, - "required": [ - "date", - "noResultCount", - "count", - "rate" - ], - "properties": { - "date": { - "type": "string", - "description": "Date of the event in the format YYYY-MM-DD.", - "example": "2023-06-14" - }, - "noResultCount": { - "description": "Number of occurences.", - "type": "integer", - "example": 54 - }, - "count": { - "description": "Number of tracked _and_ untracked searches (where the `clickAnalytics` parameter isn't `true`).", - "type": "integer", - "example": 504 - }, - "rate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/searches/noClickRate": { - "get": { - "tags": [ - "search" - ], - "operationId": "getNoClickRate", - "x-acl": [ - "analytics" - ], - "summary": "Get no click rate.", - "description": "Returns the rate at which searches don't lead to any clicks. The endpoint returns a value for the complete given time range, as well as a value per day. It also returns the count of searches and searches without clicks.", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getNoClickRateResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "dates", - "count", - "noClickCount", - "rate" - ], - "properties": { - "rate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "count": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "noClickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "dates": { - "type": "array", - "description": "Overall count of searches without clicks plus a daily breakdown.", - "items": { - "type": "object", - "title": "noClickRateEvent", - "additionalProperties": false, - "required": [ - "rate", - "count", - "noClickCount", - "date" - ], - "properties": { - "rate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "count": { - "description": "Number of tracked _and_ untracked searches (where the `clickAnalytics` parameter isn't `true`).", - "type": "integer", - "example": 504 - }, - "noClickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "date": { - "type": "string", - "description": "Date of the event in the format YYYY-MM-DD.", - "example": "2023-06-14" - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/hits": { - "get": { - "tags": [ - "search" - ], - "operationId": "getTopHits", - "x-acl": [ - "analytics" - ], - "summary": "Get top hits.", - "description": "Return the most popular clicked results in the last 1,000 searches.", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "search", - "description": "User query.", - "example": "enable ab test", - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "clickAnalytics", - "description": "Whether to include [click and conversion](https://www.algolia.com/doc/guides/sending-events/getting-started/) rates for a search.", - "schema": { - "type": "boolean", - "default": false - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "limit", - "description": "Number of records to return (page size).", - "schema": { - "type": "integer", - "default": 10 - } - }, - { - "in": "query", - "name": "offset", - "description": "Position of the starting record. Used for paging. 0 is the first record.", - "schema": { - "type": "integer", - "default": 0 - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "required": [ - "hits" - ], - "properties": { - "hits": { - "type": "array", - "description": "Top hits.", - "items": { - "type": "object", - "title": "topHit", - "additionalProperties": false, - "required": [ - "hit", - "count" - ], - "properties": { - "hit": { - "description": "Hit.", - "type": "string", - "example": "method-export-rules-php" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - } - } - } - }, - { - "type": "object", - "additionalProperties": false, - "required": [ - "hits" - ], - "properties": { - "hits": { - "type": "array", - "description": "Top hits.", - "items": { - "type": "object", - "title": "topHitWithAnalytics", - "additionalProperties": false, - "required": [ - "hit", - "count", - "clickThroughRate", - "conversionRate", - "trackedSearchCount", - "clickCount", - "conversionCount" - ], - "properties": { - "hit": { - "description": "Hit.", - "type": "string", - "example": "method-export-rules-php" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "clickThroughRate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "conversionRate": { - "type": "number", - "format": "double", - "description": "[Conversion rate (CR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).\n", - "example": 0 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "clickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "conversionCount": { - "type": "integer", - "description": "Number of converted clicks.", - "example": 0 - } - } - } - } - } - } - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/users/count": { - "get": { - "tags": [ - "search" - ], - "operationId": "getUsersCount", - "x-acl": [ - "analytics" - ], - "summary": "Get user count.", - "description": "Return the count of unique users.", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getUsersCountResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "dates", - "count" - ], - "properties": { - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "dates": { - "type": "array", - "description": "User count.", - "items": { - "type": "object", - "title": "userWithDate", - "additionalProperties": false, - "required": [ - "date", - "count" - ], - "properties": { - "date": { - "type": "string", - "description": "Date of the event in the format YYYY-MM-DD.", - "example": "2023-06-14" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/filters": { - "get": { - "tags": [ - "search" - ], - "operationId": "getTopFilterAttributes", - "x-acl": [ - "analytics" - ], - "summary": "Get top filterable attributes.", - "description": "Return the most popular [filterable attributes](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) in the 1,000 most recently used filters.", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "search", - "description": "User query.", - "example": "enable ab test", - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "limit", - "description": "Number of records to return (page size).", - "schema": { - "type": "integer", - "default": 10 - } - }, - { - "in": "query", - "name": "offset", - "description": "Position of the starting record. Used for paging. 0 is the first record.", - "schema": { - "type": "integer", - "default": 0 - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "attributes" - ], - "properties": { - "attributes": { - "type": "array", - "description": "Filterable attributes.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "attribute", - "count" - ], - "properties": { - "attribute": { - "description": "Attribute name.", - "type": "string", - "example": "url" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/filters/{attribute}": { - "get": { - "tags": [ - "search" - ], - "operationId": "getTopFilterForAttribute", - "x-acl": [ - "analytics" - ], - "summary": "Get top filter values for an attribute.", - "description": "Returns the most popular filter values for an attribute in the 1,000 most recently used filters.", - "parameters": [ - { - "in": "path", - "name": "attribute", - "description": "Attribute name.", - "required": true, - "schema": { - "type": "string", - "example": "brand" - } - }, - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "search", - "description": "User query.", - "example": "enable ab test", - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "limit", - "description": "Number of records to return (page size).", - "schema": { - "type": "integer", - "default": 10 - } - }, - { - "in": "query", - "name": "offset", - "description": "Position of the starting record. Used for paging. 0 is the first record.", - "schema": { - "type": "integer", - "default": 0 - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "values" - ], - "properties": { - "values": { - "type": "array", - "description": "Filter values for an attribute.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "operator", - "attribute", - "value", - "count" - ], - "properties": { - "attribute": { - "description": "Attribute name.", - "type": "string", - "example": "url" - }, - "operator": { - "description": "Operator.", - "type": "string", - "example": ":" - }, - "value": { - "description": "Attribute value.", - "type": "string", - "example": "integration" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/filters/noResults": { - "get": { - "tags": [ - "search" - ], - "operationId": "getTopFiltersNoResults", - "x-acl": [ - "analytics" - ], - "summary": "Get top filters for a no result search.", - "description": "Returns top filters for filter-enabled searches that don't return results. Limited to the 1,000 most recently used filters.", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "search", - "description": "User query.", - "example": "enable ab test", - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "limit", - "description": "Number of records to return (page size).", - "schema": { - "type": "integer", - "default": 10 - } - }, - { - "in": "query", - "name": "offset", - "description": "Position of the starting record. Used for paging. 0 is the first record.", - "schema": { - "type": "integer", - "default": 0 - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "values" - ], - "properties": { - "values": { - "type": "array", - "description": "Filters with no results.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "values", - "count" - ], - "properties": { - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - }, - "values": { - "type": "array", - "description": "Filters with no results.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "attribute", - "operator", - "value" - ], - "properties": { - "attribute": { - "description": "Attribute name.", - "type": "string", - "example": "url" - }, - "operator": { - "description": "Operator.", - "type": "string", - "example": ":" - }, - "value": { - "description": "Attribute value.", - "type": "string", - "example": "integration" - } - } - } - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/countries": { - "get": { - "tags": [ - "search" - ], - "operationId": "getTopCountries", - "x-acl": [ - "analytics" - ], - "summary": "Get top countries.", - "description": "Returns top countries. Limited to the 1,000 most frequent ones.", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "limit", - "description": "Number of records to return (page size).", - "schema": { - "type": "integer", - "default": 10 - } - }, - { - "in": "query", - "name": "offset", - "description": "Position of the starting record. Used for paging. 0 is the first record.", - "schema": { - "type": "integer", - "default": 0 - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getTopCountriesResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "countries" - ], - "properties": { - "countries": { - "type": "array", - "description": "Countries", - "items": { - "type": "object", - "title": "topCountry", - "additionalProperties": false, - "required": [ - "country", - "count" - ], - "properties": { - "country": { - "description": "Country.", - "type": "string", - "example": "UK" - }, - "count": { - "description": "Number of occurrences.", - "example": 2, - "type": "integer" - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/clicks/averageClickPosition": { - "get": { - "tags": [ - "click" - ], - "operationId": "getAverageClickPosition", - "x-acl": [ - "analytics" - ], - "summary": "Get average click position.", - "description": "Return the average click position for the complete time range and for individual days.\n> **Note**: If all `positions` have a `clickCount` of `0` or `null`, it means Algolia didn't receive any click events for tracked searches. A _tracked_ search is a search request where the `clickAnalytics` parameter is `true`.\n", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getAverageClickPositionResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "average", - "clickCount", - "dates" - ], - "properties": { - "average": { - "type": "number", - "format": "double", - "description": "Average count of all click events.", - "example": 2.3344634550185286 - }, - "clickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "dates": { - "type": "array", - "description": "Average click positions.", - "items": { - "type": "object", - "title": "averageClickEvent", - "additionalProperties": false, - "required": [ - "average", - "clickCount", - "date" - ], - "properties": { - "average": { - "type": "number", - "format": "double", - "description": "Average count of all click events.", - "example": 2.3344634550185286 - }, - "clickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "date": { - "type": "string", - "description": "Date of the event in the format YYYY-MM-DD.", - "example": "2023-06-14" - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/clicks/positions": { - "get": { - "tags": [ - "click" - ], - "operationId": "getClickPositions", - "x-acl": [ - "analytics" - ], - "summary": "Get click positions.", - "description": "Show the number of clicks events and their associated position in the search results.\n\n> **Note**: If all `positions` have a `clickCount` of `0` or `null`, it means Algolia didn't receive any click events for tracked searches. A _tracked_ search is a search request where the `clickAnalytics` parameter is `true`.\n", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getClickPositionsResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "positions" - ], - "properties": { - "positions": { - "type": "array", - "description": "Click positions.", - "minItems": 2, - "maxItems": 2, - "items": { - "type": "object", - "title": "clickPosition", - "additionalProperties": false, - "required": [ - "position", - "clickCount" - ], - "properties": { - "position": { - "description": "Range of positions with the following pattern:\n- For positions 1 to 10, the number of click events are shown for each position - For positions 11 to 20, all click events are grouped - For positions 21 and up, all click events are grouped.\n", - "type": "array", - "example": [ - 10, - 10 - ], - "items": { - "type": "integer" - } - }, - "clickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/clicks/clickThroughRate": { - "get": { - "tags": [ - "click" - ], - "operationId": "getClickThroughRate", - "x-acl": [ - "analytics" - ], - "summary": "Get click-through rate (CTR).", - "description": "Returns a [click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getClickThroughRateResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "dates", - "clickCount", - "trackedSearchCount", - "rate" - ], - "properties": { - "rate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "clickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "dates": { - "type": "array", - "description": "Click-through rate events.", - "items": { - "type": "object", - "title": "clickThroughRateEvent", - "additionalProperties": false, - "required": [ - "rate", - "clickCount", - "trackedSearchCount", - "date" - ], - "properties": { - "rate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "clickCount": { - "type": "integer", - "description": "Number of click events.", - "example": 162 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "date": { - "type": "string", - "description": "Date of the event in the format YYYY-MM-DD.", - "example": "2023-06-14" - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/conversions/conversionRate": { - "get": { - "tags": [ - "click" - ], - "operationId": "getConversationRate", - "x-acl": [ - "analytics" - ], - "summary": "Get conversion rate (CR).", - "description": "Return a [conversion rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - }, - { - "in": "query", - "name": "startDate", - "description": "Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2022-09-19", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "in": "query", - "name": "endDate", - "description": "End date (a string in the format `YYYY-MM-DD`) of the period to analyze.", - "schema": { - "type": "string", - "example": "2023-01-21", - "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" - } - }, - { - "name": "tags", - "in": "query", - "description": "Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.", - "example": "device:mobile%20phone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getConversationRateResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "dates", - "trackedSearchCount", - "conversionCount", - "rate" - ], - "properties": { - "rate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "conversionCount": { - "type": "integer", - "description": "Number of converted clicks.", - "example": 0 - }, - "dates": { - "type": "array", - "description": "Conversion events.", - "items": { - "type": "object", - "title": "conversionRateEvent", - "additionalProperties": false, - "required": [ - "rate", - "trackedSearchCount", - "conversionCount", - "date" - ], - "properties": { - "rate": { - "type": "number", - "format": "double", - "description": "[Click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).\n", - "minimum": 0, - "maximum": 1, - "example": 0.14634193523426317 - }, - "trackedSearchCount": { - "type": "integer", - "example": 2, - "nullable": true, - "description": "Number of tracked searches. This is the number of search requests where the `clickAnalytics` parameter is `true`." - }, - "conversionCount": { - "type": "integer", - "description": "Number of converted clicks.", - "example": 0 - }, - "date": { - "type": "string", - "description": "Date of the event in the format YYYY-MM-DD.", - "example": "2023-06-14" - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/2/status": { - "get": { - "tags": [ - "advanced" - ], - "operationId": "getStatus", - "x-acl": [ - "analytics" - ], - "summary": "Get Analytics API status.", - "description": "Return the latest update time of the Analytics API for an index. If the index has been recently created or no search has been performed yet, `updatedAt` will be `null`.\n> **Note**: The Analytics API is updated every 5 minutes.\n", - "parameters": [ - { - "in": "query", - "name": "index", - "description": "Index name to target.", - "required": true, - "schema": { - "type": "string", - "example": "YourIndexName" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getStatusResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "updatedAt" - ], - "properties": { - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - } - } -} \ No newline at end of file diff --git a/specs/bundled/crawler.json b/specs/bundled/crawler.json deleted file mode 100644 index 45679ca991..0000000000 --- a/specs/bundled/crawler.json +++ /dev/null @@ -1,2913 +0,0 @@ -{ - "openapi": "3.0.2", - "info": { - "title": "Crawler API", - "description": "API to configure and manage the Algolia Crawler.", - "version": "1.0.0" - }, - "components": { - "securitySchemes": { - "BasicAuth": { - "type": "http", - "scheme": "basic" - } - }, - "schemas": { - "Pagination": { - "type": "object", - "description": "Represent a group of items and pagination information.", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object" - } - }, - "itemsPerPage": { - "type": "integer", - "description": "The maximum number of items returned by this request.", - "default": 20, - "example": 20 - }, - "page": { - "type": "integer", - "description": "The current page browsed by this request.", - "default": 1, - "example": 1 - }, - "total": { - "type": "integer", - "description": "The total number of items.", - "example": 100 - } - } - }, - "CrawlerId": { - "type": "string", - "description": "The unique id of the Crawler.", - "example": "e0f6db8a-24f5-4092-83a4-1b2c6cb6d809" - }, - "CrawlerName": { - "type": "string", - "maxLength": 64, - "description": "The name of the Crawler.", - "example": "My Crawler" - }, - "crawlersResponse": { - "allOf": [ - { - "type": "object", - "description": "Represent a group of items and pagination information.", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object" - } - }, - "itemsPerPage": { - "type": "integer", - "description": "The maximum number of items returned by this request.", - "default": 20, - "example": 20 - }, - "page": { - "type": "integer", - "description": "The current page browsed by this request.", - "default": 1, - "example": 1 - }, - "total": { - "type": "integer", - "description": "The total number of items.", - "example": 100 - } - } - }, - { - "type": "object", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object", - "properties": { - "id": { - "type": "string", - "description": "The unique id of the Crawler.", - "example": "e0f6db8a-24f5-4092-83a4-1b2c6cb6d809" - }, - "name": { - "type": "string", - "maxLength": 64, - "description": "The name of the Crawler.", - "example": "My Crawler" - } - } - } - } - } - } - ] - }, - "configurationRecordExtractorType": { - "type": "string", - "enum": [ - "function" - ] - }, - "Configuration": { - "type": "object", - "description": "A Crawler configuration object. See the Crawler documentation to have more details about it.", - "properties": { - "appId": { - "type": "string", - "example": "ABC9DEFGHI" - }, - "apiKey": { - "type": "string", - "example": "c69564c68bad256f8d11399bf2048f82" - }, - "indexPrefix": { - "type": "string", - "example": "crawler_" - }, - "rateLimit": { - "type": "number", - "example": 8 - }, - "startUrls": { - "type": "array", - "items": { - "type": "string", - "example": "https://www.algolia.com" - } - }, - "actions": { - "type": "array", - "items": { - "type": "object", - "properties": { - "indexName": { - "type": "string", - "example": "algolia_website" - }, - "pathsToMatch": { - "type": "array", - "items": { - "type": "string", - "example": "https://www.algolia.com/**" - } - }, - "selectorsToMatch": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - ".products", - "!.featured" - ] - }, - "fileTypesToMatch": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "html", - "pdf" - ] - }, - "recordExtractor": { - "type": "object", - "properties": { - "__type": { - "type": "string", - "enum": [ - "function" - ] - }, - "source": { - "type": "string", - "example": "() => {}" - } - } - } - }, - "required": [ - "indexName", - "recordExtractor" - ] - } - } - } - }, - "urlsCrawledGroupStatus": { - "type": "string", - "description": "A string corresponding to the status of the group.", - "enum": [ - "DONE", - "SKIPPED", - "FAILED" - ] - }, - "urlsCrawledGroupCategory": { - "type": "string", - "description": "In case of error, will be set to the step where the error occurred, otherwise will be set to 'success'.", - "enum": [ - "fetch", - "extraction", - "indexing", - "success" - ] - }, - "UrlsCrawledGroup": { - "type": "object", - "description": "Represent a group of URLs that have been crawled and have the same final state.", - "properties": { - "status": { - "type": "string", - "description": "A string corresponding to the status of the group.", - "enum": [ - "DONE", - "SKIPPED", - "FAILED" - ] - }, - "reason": { - "type": "string", - "description": "The code of the reason why when ended up in this status." - }, - "category": { - "type": "string", - "description": "In case of error, will be set to the step where the error occurred, otherwise will be set to 'success'.", - "enum": [ - "fetch", - "extraction", - "indexing", - "success" - ] - }, - "count": { - "type": "integer", - "description": "Number of URLs belonging to this group." - }, - "readable": { - "type": "string", - "description": "Human redeable version of the error." - } - }, - "example": { - "status": "SKIPPED", - "reason": "forbidden_by_robotstxt", - "category": "fetch", - "nbUrls": 3, - "readable": "Forbidden by robots.txt" - } - }, - "crawlerConfigVersionsResponse": { - "allOf": [ - { - "type": "object", - "description": "Represent a group of items and pagination information.", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object" - } - }, - "itemsPerPage": { - "type": "integer", - "description": "The maximum number of items returned by this request.", - "default": 20, - "example": 20 - }, - "page": { - "type": "integer", - "description": "The current page browsed by this request.", - "default": 1, - "example": 1 - }, - "total": { - "type": "integer", - "description": "The total number of items.", - "example": 100 - } - } - }, - { - "type": "object", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object", - "properties": { - "version": { - "type": "integer", - "minimum": 1 - }, - "createdAt": { - "type": "string" - }, - "authorId": { - "type": "string" - } - }, - "required": [ - "version", - "createdAt" - ] - } - } - } - } - ] - }, - "domainsResponse": { - "allOf": [ - { - "type": "object", - "description": "Represent a group of items and pagination information.", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object" - } - }, - "itemsPerPage": { - "type": "integer", - "description": "The maximum number of items returned by this request.", - "default": 20, - "example": 20 - }, - "page": { - "type": "integer", - "description": "The current page browsed by this request.", - "default": 1, - "example": 1 - }, - "total": { - "type": "integer", - "description": "The total number of items.", - "example": 100 - } - } - }, - { - "type": "object", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object", - "properties": { - "appId": { - "type": "string", - "description": "The app for which the domain is registered." - }, - "domain": { - "type": "string", - "description": "The registered domain name." - }, - "validated": { - "type": "boolean", - "description": "Indicates whether the domain is validated or not." - } - } - } - } - } - } - ] - } - }, - "responses": { - "InvalidRequest": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "MissingAuthorization": { - "description": "Authorization information is missing or invalid." - }, - "NoRightsOnCrawler": { - "description": "The user doesn't have enough rights on the specified Crawler, or it doesn't exists." - }, - "ActionAcknowledged": { - "description": "The request has been acknowledged by the crawler.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "taskId": { - "type": "string", - "example": "e0f6db8a-24f5-4092-83a4-1b2c6cb6d809" - } - }, - "required": [ - "taskId" - ] - } - } - } - }, - "Forbidden": { - "description": "Invalid credentials.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - } - }, - "parameters": { - "CrawlerIdParameter": { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - }, - "TaskIdParameter": { - "name": "tid", - "in": "path", - "description": "The Id of the targeted Task.", - "required": true, - "schema": { - "type": "string" - } - }, - "CrawlerVersionParameter": { - "name": "version", - "in": "path", - "description": "The version of the targeted Crawler revision.", - "required": true, - "schema": { - "type": "integer" - } - } - } - }, - "servers": [ - { - "url": "https://crawler.algolia.com/api/1" - }, - { - "url": "https://crawler-dev.algolia.com/api/1" - }, - { - "url": "http://localhost:8000/api/1" - } - ], - "security": [ - { - "BasicAuth": [] - } - ], - "paths": { - "/crawlers": { - "get": { - "operationId": "listCrawlers", - "summary": "List available Crawlers.", - "description": "List available Crawlers.", - "parameters": [ - { - "in": "query", - "name": "itemsPerPage", - "schema": { - "type": "integer", - "minimum": 1, - "default": 20, - "maximum": 100 - }, - "description": "Change the number of items per page." - }, - { - "in": "query", - "name": "page", - "schema": { - "type": "integer", - "minimum": 1, - "default": 1, - "maximum": 100 - }, - "description": "Change the page number." - }, - { - "in": "query", - "name": "name", - "schema": { - "type": "string", - "example": "MyCrawlerName" - }, - "description": "Filter by crawler name." - }, - { - "in": "query", - "name": "appId", - "schema": { - "type": "string", - "example": "XXXXXXX123" - }, - "description": "Filter by Application ID." - } - ], - "responses": { - "200": { - "description": "A list of Crawlers and pagination information.", - "content": { - "application/json": { - "schema": { - "allOf": [ - { - "type": "object", - "description": "Represent a group of items and pagination information.", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object" - } - }, - "itemsPerPage": { - "type": "integer", - "description": "The maximum number of items returned by this request.", - "default": 20, - "example": 20 - }, - "page": { - "type": "integer", - "description": "The current page browsed by this request.", - "default": 1, - "example": 1 - }, - "total": { - "type": "integer", - "description": "The total number of items.", - "example": 100 - } - } - }, - { - "type": "object", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object", - "properties": { - "id": { - "type": "string", - "description": "The unique id of the Crawler.", - "example": "e0f6db8a-24f5-4092-83a4-1b2c6cb6d809" - }, - "name": { - "type": "string", - "maxLength": 64, - "description": "The name of the Crawler.", - "example": "My Crawler" - } - } - } - } - } - } - ] - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "Invalid credentials." - }, - "404": { - "description": "The call does not have results for this combinaison of query params." - } - } - }, - "post": { - "operationId": "createCrawler", - "summary": "Create a new Crawler with the given config.", - "description": "Create a new Crawler with the given config.", - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "name": { - "type": "string", - "maxLength": 64, - "description": "The name of the Crawler.", - "example": "My Crawler" - }, - "config": { - "type": "object", - "description": "A Crawler configuration object. See the Crawler documentation to have more details about it.", - "properties": { - "appId": { - "type": "string", - "example": "ABC9DEFGHI" - }, - "apiKey": { - "type": "string", - "example": "c69564c68bad256f8d11399bf2048f82" - }, - "indexPrefix": { - "type": "string", - "example": "crawler_" - }, - "rateLimit": { - "type": "number", - "example": 8 - }, - "startUrls": { - "type": "array", - "items": { - "type": "string", - "example": "https://www.algolia.com" - } - }, - "actions": { - "type": "array", - "items": { - "type": "object", - "properties": { - "indexName": { - "type": "string", - "example": "algolia_website" - }, - "pathsToMatch": { - "type": "array", - "items": { - "type": "string", - "example": "https://www.algolia.com/**" - } - }, - "selectorsToMatch": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - ".products", - "!.featured" - ] - }, - "fileTypesToMatch": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "html", - "pdf" - ] - }, - "recordExtractor": { - "type": "object", - "properties": { - "__type": { - "type": "string", - "enum": [ - "function" - ] - }, - "source": { - "type": "string", - "example": "() => {}" - } - } - } - }, - "required": [ - "indexName", - "recordExtractor" - ] - } - } - } - } - }, - "required": [ - "name", - "config" - ] - } - } - } - }, - "responses": { - "200": { - "description": "A new Crawler has been created with the given configuration.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "id": { - "type": "string", - "description": "The id of the Crawler created." - } - }, - "required": [ - "id" - ] - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "The user doesn't have enough rights to create a Crawler." - } - } - } - }, - "/crawlers/{id}": { - "get": { - "operationId": "getCrawler", - "summary": "Get information about the specified Crawler and its configuration.", - "description": "Get information about the specified Crawler and its configuration.", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "withConfig", - "schema": { - "type": "boolean" - }, - "description": "Whether or not the configuration should be returned in the response (in the 'config' field)." - } - ], - "responses": { - "200": { - "description": "Several field with information about the specified Crawler.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "name": { - "type": "string", - "maxLength": 64, - "description": "The name of the Crawler.", - "example": "My Crawler" - }, - "createdAt": { - "type": "string", - "description": "The creation date of this Crawler.", - "example": "2019-05-10T07:58:41.146Z" - }, - "updatedAt": { - "type": "string", - "description": "The date this Crawler was last updated.", - "example": "2019-05-10T08:16:47.920Z" - }, - "running": { - "type": "boolean", - "description": "Indicate if this Crawler is running, i.e. will crawl regularly based on its configuration." - }, - "reindexing": { - "type": "boolean", - "description": "Indicate if this Crawler is currently doing a complete reindex." - }, - "blocked": { - "type": "boolean", - "description": "Indicate if this Crawler is currently blocked and need a manual intervention in the Console.", - "example": false - }, - "blockingError": { - "type": "string", - "description": "The reason for which the Crawler has been blocked.", - "example": "Error: Failed to fetch external data for source 'testCSV': 404" - }, - "blockingTaskId": { - "type": "string", - "description": "The ID of the task that is currently blocking the Crawler." - }, - "lastReindexStartedAt": { - "type": "string", - "nullable": true, - "description": "The date when the last complete reindex was started. Will be null if no reindex was ever done.", - "example": "2019-05-10T08:16:47.920Z" - }, - "lastReindexEndedAt": { - "type": "string", - "nullable": true, - "description": "The date when the last complete reindex finished. Can be null if the reindex is still running.", - "example": null - }, - "config": { - "type": "object", - "description": "A Crawler configuration object. See the Crawler documentation to have more details about it.", - "properties": { - "appId": { - "type": "string", - "example": "ABC9DEFGHI" - }, - "apiKey": { - "type": "string", - "example": "c69564c68bad256f8d11399bf2048f82" - }, - "indexPrefix": { - "type": "string", - "example": "crawler_" - }, - "rateLimit": { - "type": "number", - "example": 8 - }, - "startUrls": { - "type": "array", - "items": { - "type": "string", - "example": "https://www.algolia.com" - } - }, - "actions": { - "type": "array", - "items": { - "type": "object", - "properties": { - "indexName": { - "type": "string", - "example": "algolia_website" - }, - "pathsToMatch": { - "type": "array", - "items": { - "type": "string", - "example": "https://www.algolia.com/**" - } - }, - "selectorsToMatch": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - ".products", - "!.featured" - ] - }, - "fileTypesToMatch": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "html", - "pdf" - ] - }, - "recordExtractor": { - "type": "object", - "properties": { - "__type": { - "type": "string", - "enum": [ - "function" - ] - }, - "source": { - "type": "string", - "example": "() => {}" - } - } - } - }, - "required": [ - "indexName", - "recordExtractor" - ] - } - } - } - } - }, - "required": [ - "name", - "createdAt", - "updatedAt", - "running", - "reindexing", - "blocked", - "lastReindexStartedAt", - "lastReindexEndedAt" - ] - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "The user doesn't have enough rights on the specified Crawler, or it doesn't exists." - } - } - }, - "patch": { - "operationId": "patchCrawler", - "summary": "Update parts of the Crawler, either its name, its config, or both.", - "description": "Update parts of the Crawler, either its name, its config, or both.", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "name": { - "type": "string", - "maxLength": 64, - "description": "The name of the Crawler.", - "example": "My Crawler" - }, - "config": { - "type": "object", - "description": "A Crawler configuration object. See the Crawler documentation to have more details about it.", - "properties": { - "appId": { - "type": "string", - "example": "ABC9DEFGHI" - }, - "apiKey": { - "type": "string", - "example": "c69564c68bad256f8d11399bf2048f82" - }, - "indexPrefix": { - "type": "string", - "example": "crawler_" - }, - "rateLimit": { - "type": "number", - "example": 8 - }, - "startUrls": { - "type": "array", - "items": { - "type": "string", - "example": "https://www.algolia.com" - } - }, - "actions": { - "type": "array", - "items": { - "type": "object", - "properties": { - "indexName": { - "type": "string", - "example": "algolia_website" - }, - "pathsToMatch": { - "type": "array", - "items": { - "type": "string", - "example": "https://www.algolia.com/**" - } - }, - "selectorsToMatch": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - ".products", - "!.featured" - ] - }, - "fileTypesToMatch": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "html", - "pdf" - ] - }, - "recordExtractor": { - "type": "object", - "properties": { - "__type": { - "type": "string", - "enum": [ - "function" - ] - }, - "source": { - "type": "string", - "example": "() => {}" - } - } - } - }, - "required": [ - "indexName", - "recordExtractor" - ] - } - } - } - } - } - } - } - } - }, - "responses": { - "200": { - "description": "The request has been acknowledged by the crawler.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "taskId": { - "type": "string", - "example": "e0f6db8a-24f5-4092-83a4-1b2c6cb6d809" - } - }, - "required": [ - "taskId" - ] - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "The user doesn't have enough rights on the specified Crawler, or it doesn't exists." - } - } - } - }, - "/crawlers/{id}/config": { - "patch": { - "operationId": "patchConfig", - "summary": "Update parts of the Crawler configuration.", - "description": "Update parts of the Crawler configuration.", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "A partial config object that will be injected into the current one.", - "example": { - "rateLimit": 10, - "startUrls": [ - "https://www.algolia.com/doc", - "https://www.algolia.com/blog" - ] - } - } - } - } - }, - "responses": { - "200": { - "description": "The request has been acknowledged by the crawler.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "taskId": { - "type": "string", - "example": "e0f6db8a-24f5-4092-83a4-1b2c6cb6d809" - } - }, - "required": [ - "taskId" - ] - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "The user doesn't have enough rights on the specified Crawler, or it doesn't exists." - } - } - } - }, - "/crawlers/{id}/run": { - "post": { - "operationId": "runCrawler", - "summary": "Request the specified Crawler to run.", - "description": "Request the specified Crawler to run.", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "The request has been acknowledged by the crawler.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "taskId": { - "type": "string", - "example": "e0f6db8a-24f5-4092-83a4-1b2c6cb6d809" - } - }, - "required": [ - "taskId" - ] - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "The user doesn't have enough rights on the specified Crawler, or it doesn't exists." - } - } - } - }, - "/crawlers/{id}/pause": { - "post": { - "operationId": "pauseCrawler", - "summary": "Request the specified Crawler to pause itself.", - "description": "Request the specified Crawler to pause itself.", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "The request has been acknowledged by the crawler.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "taskId": { - "type": "string", - "example": "e0f6db8a-24f5-4092-83a4-1b2c6cb6d809" - } - }, - "required": [ - "taskId" - ] - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "The user doesn't have enough rights on the specified Crawler, or it doesn't exists." - } - } - } - }, - "/crawlers/{id}/reindex": { - "post": { - "operationId": "startReindex", - "summary": "Request the specified Crawler to start a reindex.", - "description": "Request the specified Crawler to start a reindex.", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "The request has been acknowledged by the crawler.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "taskId": { - "type": "string", - "example": "e0f6db8a-24f5-4092-83a4-1b2c6cb6d809" - } - }, - "required": [ - "taskId" - ] - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "The user doesn't have enough rights on the specified Crawler, or it doesn't exists." - } - } - } - }, - "/crawlers/{id}/stats/urls": { - "get": { - "operationId": "getStats", - "summary": "Get a summary of the current status of crawled URLs for the specified Crawler.", - "description": "Get a summary of the current status of crawled URLs for the specified Crawler.", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "Several metrics to know what the Crawler did during since the last reindex.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "count": { - "type": "integer", - "description": "The total number of crawled URLs." - }, - "data": { - "type": "array", - "items": { - "type": "object", - "description": "Represent a group of URLs that have been crawled and have the same final state.", - "properties": { - "status": { - "type": "string", - "description": "A string corresponding to the status of the group.", - "enum": [ - "DONE", - "SKIPPED", - "FAILED" - ] - }, - "reason": { - "type": "string", - "description": "The code of the reason why when ended up in this status." - }, - "category": { - "type": "string", - "description": "In case of error, will be set to the step where the error occurred, otherwise will be set to 'success'.", - "enum": [ - "fetch", - "extraction", - "indexing", - "success" - ] - }, - "count": { - "type": "integer", - "description": "Number of URLs belonging to this group." - }, - "readable": { - "type": "string", - "description": "Human redeable version of the error." - } - }, - "example": { - "status": "SKIPPED", - "reason": "forbidden_by_robotstxt", - "category": "fetch", - "nbUrls": 3, - "readable": "Forbidden by robots.txt" - } - } - } - }, - "required": [ - "count", - "data" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "The user doesn't have enough rights on the specified Crawler, or it doesn't exists." - } - } - } - }, - "/crawlers/{id}/test": { - "post": { - "operationId": "testUrl", - "summary": "Test an URL against the crawler's config.", - "description": "Test an URL against the given Crawler's config and see what will be processed.\nYou can also override parts of the configuration to try your changes before updating the configuration.", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "url": { - "type": "string", - "description": "The URL to test.", - "example": "https://www.algolia.com/blog" - }, - "config": { - "type": "object", - "description": "A partial configuration object, that will be merged with the configuration saved.\nThis allows to tests changes in a configuration before saving it.\nNote that it's not a deep merge, we will simply override all top level fields with the ones that\nyou will pass." - } - }, - "required": [ - "url" - ] - } - } - } - }, - "responses": { - "200": { - "description": "Several information to know how the Crawler processed the given URL.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "startDate": { - "type": "string", - "description": "The datetime when the test started.", - "example": "2019-05-21T09:04:33.742Z" - }, - "endDate": { - "type": "string", - "description": "The datetime when the test ended.", - "example": "2019-05-21T09:04:33.923Z" - }, - "logs": { - "type": "array", - "description": "The list of logs generated by `console.log()` in the recordExtractors.", - "items": { - "type": "array", - "description": "Each console.log() accepts many parameter. They will be returned in an array.", - "items": { - "type": "string", - "example": "Processing url 'https://www.algolia.com/blog'" - } - } - }, - "records": { - "type": "array", - "description": "The list of records generated for the given URL.", - "items": { - "type": "object", - "properties": { - "indexName": { - "type": "string", - "description": "The name of the targeted index.", - "example": "testIndex" - }, - "records": { - "type": "array", - "description": "The list of records generated by each action.", - "items": { - "type": "object", - "description": "An actual Algolia record.", - "example": { - "objectID": "https://www.algolia.com/blog", - "numberOfLinks": 2 - } - } - }, - "recordsPerExtractor": { - "type": "array", - "description": "The record's parts generated by each extractor.", - "items": { - "type": "object", - "properties": { - "index": { - "type": "number", - "description": "Index of the extractor." - }, - "type": { - "type": "string", - "description": "Type of the extractor." - }, - "records": { - "type": "array", - "items": { - "type": "object", - "description": "The partial record generated by the extractor." - } - } - } - }, - "example": [ - { - "index": 0, - "type": "custom", - "records": [ - { - "objectID": "https://www.algolia.com/blog" - } - ] - } - ] - } - } - } - }, - "links": { - "type": "array", - "description": "The list of links found on the page, that match the configuration (and would be processed).", - "items": { - "type": "string" - }, - "example": [ - "https://blog.algolia.com/challenging-migration-heroku-google-kubernetes-engine/", - "https://blog.algolia.com/tale-two-engines-algolia-unity/" - ] - }, - "externalData": { - "type": "object", - "description": "The External Data associated to the tested URL. External data are refreshed automatically before reindex.", - "example": { - "externalData1": { - "data1": "val1", - "data2": "val2" - }, - "externalData2": { - "data1": "val1", - "data2": "val2" - } - } - }, - "error": { - "type": "object", - "properties": { - "code": { - "type": "string", - "example": "http_internal_server_error" - }, - "message": { - "type": "string", - "example": "HTTP Internal Server Error (500)" - } - }, - "example": {} - } - }, - "required": [ - "startDate", - "endDate", - "logs", - "records", - "links" - ] - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "The user doesn't have enough rights on the specified Crawler, or it doesn't exists." - } - } - } - }, - "/crawlers/{id}/tasks/{tid}": { - "get": { - "operationId": "getTaskStatus", - "summary": "Get the status of a specific task.", - "description": "Get the status of a specific task.", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "tid", - "in": "path", - "description": "The Id of the targeted Task.", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "A response telling you if an action is still pending or not.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "pending": { - "type": "boolean", - "description": "A boolean that will be true if the action hasn't been processed yet, false if it has been processed or if the action doesn't exists.\n" - } - }, - "required": [ - "pending" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "The user doesn't have enough rights on the specified Crawler, or it doesn't exists." - } - } - } - }, - "/crawlers/{id}/tasks/{tid}/cancel": { - "post": { - "operationId": "cancelBlockingAction", - "summary": "Cancel a blocking action on your Crawler.", - "description": "Cancel a blocking action on your Crawler.", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "tid", - "in": "path", - "description": "The Id of the targeted Task.", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "Your request was processed correctly." - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "The user doesn't have enough rights on the specified Crawler, or it doesn't exists." - } - } - } - }, - "/crawlers/{id}/config/versions": { - "get": { - "operationId": "listConfigVersions", - "summary": "List crawler versions.", - "description": "List crawler config versions.", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "itemsPerPage", - "schema": { - "type": "integer", - "minimum": 1, - "default": 20, - "maximum": 100 - }, - "description": "Change the number of versions per page." - }, - { - "in": "query", - "name": "page", - "schema": { - "type": "integer", - "minimum": 1, - "default": 1, - "maximum": 5000 - }, - "description": "Change the page number." - } - ], - "responses": { - "200": { - "description": "A list of crawler versions and pagination information.", - "content": { - "application/json": { - "schema": { - "allOf": [ - { - "type": "object", - "description": "Represent a group of items and pagination information.", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object" - } - }, - "itemsPerPage": { - "type": "integer", - "description": "The maximum number of items returned by this request.", - "default": 20, - "example": 20 - }, - "page": { - "type": "integer", - "description": "The current page browsed by this request.", - "default": 1, - "example": 1 - }, - "total": { - "type": "integer", - "description": "The total number of items.", - "example": 100 - } - } - }, - { - "type": "object", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object", - "properties": { - "version": { - "type": "integer", - "minimum": 1 - }, - "createdAt": { - "type": "string" - }, - "authorId": { - "type": "string" - } - }, - "required": [ - "version", - "createdAt" - ] - } - } - } - } - ] - } - } - } - } - } - } - }, - "/crawlers/{id}/config/versions/{version}": { - "get": { - "operationId": "getConfigVersion", - "summary": "Get a specific version of the configuration of a crawler.", - "description": "Get a specific version of the configuration of a crawler.", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "version", - "in": "path", - "description": "The version of the targeted Crawler revision.", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "description": "A specific revision of the crawler.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "version": { - "type": "integer", - "minimum": 1 - }, - "config": { - "type": "object", - "description": "A Crawler configuration object. See the Crawler documentation to have more details about it.", - "properties": { - "appId": { - "type": "string", - "example": "ABC9DEFGHI" - }, - "apiKey": { - "type": "string", - "example": "c69564c68bad256f8d11399bf2048f82" - }, - "indexPrefix": { - "type": "string", - "example": "crawler_" - }, - "rateLimit": { - "type": "number", - "example": 8 - }, - "startUrls": { - "type": "array", - "items": { - "type": "string", - "example": "https://www.algolia.com" - } - }, - "actions": { - "type": "array", - "items": { - "type": "object", - "properties": { - "indexName": { - "type": "string", - "example": "algolia_website" - }, - "pathsToMatch": { - "type": "array", - "items": { - "type": "string", - "example": "https://www.algolia.com/**" - } - }, - "selectorsToMatch": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - ".products", - "!.featured" - ] - }, - "fileTypesToMatch": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "html", - "pdf" - ] - }, - "recordExtractor": { - "type": "object", - "properties": { - "__type": { - "type": "string", - "enum": [ - "function" - ] - }, - "source": { - "type": "string", - "example": "() => {}" - } - } - } - }, - "required": [ - "indexName", - "recordExtractor" - ] - } - } - } - }, - "createdAt": { - "type": "string" - }, - "authorId": { - "type": "string" - } - }, - "required": [ - "version", - "config", - "createdAt" - ] - } - } - } - } - } - } - }, - "/crawlers/{id}/urls/crawl": { - "post": { - "operationId": "crawlUrls", - "summary": "Immediately crawl some URLs and update the live index.", - "description": "The passed URLs will be crawled immediately, and the generated records will be pushed to the live index if no reindex is currently running.\nIf a reindex is running, the records will be pushed to the temporary index.\n", - "parameters": [ - { - "name": "id", - "in": "path", - "description": "The Id of the targeted Crawler.", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "urls": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "https://www.algolia.com/products/crawler/" - ] - }, - "save": { - "type": "boolean", - "description": "If true, the given URLs will be added to the `extraUrls` field of the config (if not already in `startUrls` or `sitemaps`).\nIf false, the URLs will not be saved in the config.\nIf unspecified, the URLs will be saved to the `extraUrls` field of the config only if they haven't been indexed during the last reindex.\n" - } - }, - "required": [ - "urls" - ] - } - } - } - }, - "responses": { - "200": { - "description": "The request has been acknowledged by the crawler.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "taskId": { - "type": "string", - "example": "e0f6db8a-24f5-4092-83a4-1b2c6cb6d809" - } - }, - "required": [ - "taskId" - ] - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "The user doesn't have enough rights on the specified Crawler, or it doesn't exists." - } - } - } - }, - "/domains": { - "get": { - "operationId": "listDomains", - "summary": "List registered Domains.", - "description": "List registered Domains.", - "parameters": [ - { - "in": "query", - "name": "itemsPerPage", - "schema": { - "type": "integer", - "minimum": 1, - "maximum": 100, - "default": 20 - }, - "description": "Change the number of items per page." - }, - { - "in": "query", - "name": "page", - "schema": { - "type": "integer", - "minimum": 1, - "maximum": 100, - "default": 1 - }, - "description": "Change the page number." - }, - { - "in": "query", - "name": "appId", - "schema": { - "type": "string", - "example": "XXXXXXX123" - }, - "description": "Filter by Application ID." - } - ], - "responses": { - "200": { - "description": "A list of Domains and pagination information.", - "content": { - "application/json": { - "schema": { - "allOf": [ - { - "type": "object", - "description": "Represent a group of items and pagination information.", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object" - } - }, - "itemsPerPage": { - "type": "integer", - "description": "The maximum number of items returned by this request.", - "default": 20, - "example": 20 - }, - "page": { - "type": "integer", - "description": "The current page browsed by this request.", - "default": 1, - "example": 1 - }, - "total": { - "type": "integer", - "description": "The total number of items.", - "example": 100 - } - } - }, - { - "type": "object", - "properties": { - "items": { - "type": "array", - "items": { - "type": "object", - "properties": { - "appId": { - "type": "string", - "description": "The app for which the domain is registered." - }, - "domain": { - "type": "string", - "description": "The registered domain name." - }, - "validated": { - "type": "boolean", - "description": "Indicates whether the domain is validated or not." - } - } - } - } - } - } - ] - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "Invalid credentials.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - } - } - } - } - } -} \ No newline at end of file diff --git a/specs/bundled/ingestion.json b/specs/bundled/ingestion.json deleted file mode 100644 index f8a03d44fa..0000000000 --- a/specs/bundled/ingestion.json +++ /dev/null @@ -1,12562 +0,0 @@ -{ - "openapi": "3.0.2", - "info": { - "title": "Ingestion API", - "description": "API powering the Data Ingestion connectors of Algolia.", - "version": "1.0" - }, - "components": { - "securitySchemes": { - "appId": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-Application-Id" - }, - "apiKey": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-API-Key" - } - }, - "parameters": { - "PathInPath": { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - "Parameters": { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - }, - "itemsPerPage": { - "name": "itemsPerPage", - "in": "query", - "description": "The number of items per page to return.", - "required": false, - "schema": { - "type": "integer" - } - }, - "page": { - "name": "page", - "in": "query", - "description": "The page number to fetch, starting at 1.", - "required": false, - "schema": { - "type": "integer" - } - }, - "type": { - "name": "type", - "in": "query", - "description": "The type of the authentications to retrieve.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "Type of the Authentication, defines what kind of object is stored in the input.", - "enum": [ - "googleServiceAccount", - "basic", - "apiKey", - "oauth", - "algolia" - ] - }, - "example": "basic,oauth" - } - }, - "platform": { - "name": "platform", - "in": "query", - "description": "The platform of the authentications to retrieve.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "oneOf": [ - { - "type": "string", - "nullable": true, - "description": "Describe which platform the Authentication is used for.", - "enum": [ - "bigcommerce", - "commercetools" - ] - }, - { - "type": "string", - "description": "Used to filter Authentication without platform property.", - "enum": [ - "none" - ] - } - ] - }, - "example": "commercetools,none" - } - }, - "sort": { - "name": "sort", - "in": "query", - "description": "The key by which the list should be sorted.", - "required": false, - "schema": { - "type": "string", - "description": "Used to sort the Authentication list endpoint.", - "enum": [ - "name", - "auth_type", - "platform", - "updatedAt", - "createdAt" - ] - } - }, - "order": { - "name": "order", - "in": "query", - "description": "The order of the returned list.", - "required": false, - "schema": { - "type": "string", - "description": "Used to order a sorted request.", - "enum": [ - "asc", - "desc" - ] - } - }, - "pathAuthenticationID": { - "name": "authenticationID", - "in": "path", - "required": true, - "description": "The authentication UUID.", - "schema": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "destinationParameters_type": { - "name": "type", - "in": "query", - "description": "The type of the destinations to retrive.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "Type of the Destination, defines in which Algolia product the data will be stored.", - "enum": [ - "search", - "insights", - "flow" - ] - }, - "example": "search" - } - }, - "authenticationID": { - "name": "authenticationID", - "in": "query", - "description": "The authenticationIDs of the destinations to retrive.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - "destinationParameters_sort": { - "name": "sort", - "in": "query", - "description": "The key by which the list should be sorted.", - "required": false, - "schema": { - "type": "string", - "description": "Used to sort the Destination list endpoint.", - "enum": [ - "name", - "type", - "updatedAt", - "createdAt" - ] - } - }, - "pathDestinationID": { - "name": "destinationID", - "in": "path", - "required": true, - "description": "The destination UUID.", - "schema": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "sourceParameters_type": { - "name": "type", - "in": "query", - "description": "The type of the sources to retrieve.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "bigcommerce", - "commercetools", - "json", - "csv", - "bigquery", - "docker" - ] - }, - "example": "commercetools,bigcommerce" - } - }, - "sourceParameters_authenticationID": { - "name": "authenticationID", - "in": "query", - "description": "The authenticationIDs of the sources to retrieve. 'none' returns sources that doesn't have an authentication.\n", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "example": [ - "10000000-0a75-4000-a000-000000000001", - "none" - ] - } - }, - "sourceParameters_sort": { - "name": "sort", - "in": "query", - "description": "The key by which the list should be sorted.", - "required": false, - "schema": { - "type": "string", - "description": "Used to sort the Source list endpoint.", - "enum": [ - "name", - "type", - "updatedAt", - "createdAt" - ] - } - }, - "pathSourceID": { - "name": "sourceID", - "in": "path", - "required": true, - "description": "The source UUID.", - "schema": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "action": { - "name": "action", - "in": "query", - "required": false, - "description": "The action of the tasks to retrieve.", - "style": "form", - "explode": false, - "schema": { - "type": "array", - "description": "An array of actions to perform on the Algolia index.", - "items": { - "type": "string", - "description": "The action to perform on the Algolia index.", - "enum": [ - "replace", - "save", - "partial" - ] - }, - "example": "save,replace" - } - }, - "enabled": { - "name": "enabled", - "in": "query", - "description": "Whether the task is enabled or not.", - "required": false, - "schema": { - "type": "boolean" - } - }, - "sourceID": { - "name": "sourceID", - "in": "query", - "description": "The sourceIDs of the tasks to retrive.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - "destinationID": { - "name": "destinationID", - "in": "query", - "description": "The destinationIDs of the tasks to retrive.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - "triggerType": { - "name": "triggerType", - "in": "query", - "description": "The trigger type of the task.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "The type of the task reflect how it can be used:\n - onDemand: a task that runs manually\n - schedule: a task that runs regularly, following a given cron expression\n - subscription: a task that runs after a subscription event is received from an integration (e.g. Webhook).\n", - "enum": [ - "onDemand", - "schedule", - "subscription" - ] - }, - "example": "onDemand,schedule" - } - }, - "taskParameters_sort": { - "name": "sort", - "in": "query", - "description": "The key by which the list should be sorted.", - "required": false, - "schema": { - "type": "string", - "description": "Used to sort the Task list endpoint.", - "enum": [ - "enabled", - "triggerType", - "action", - "updatedAt", - "createdAt" - ] - } - }, - "pathTaskID": { - "name": "taskID", - "in": "path", - "required": true, - "description": "The task UUID.", - "schema": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "runStatus": { - "name": "status", - "in": "query", - "description": "Filter the status of the runs.", - "schema": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "created", - "started", - "idled", - "finished", - "skipped" - ] - } - } - }, - "taskID": { - "name": "taskID", - "in": "query", - "description": "Filter by taskID.", - "schema": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "runSort": { - "name": "sort", - "in": "query", - "description": "The key by which the list should be sorted.", - "required": false, - "schema": { - "type": "string", - "description": "Used to sort the Run list endpoint.", - "enum": [ - "status", - "updatedAt", - "createdAt" - ] - } - }, - "pathRunID": { - "name": "runID", - "in": "path", - "required": true, - "description": "The run UUID.", - "schema": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "eventStatus": { - "name": "status", - "in": "query", - "description": "Filter the status of the events.", - "schema": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "created", - "started", - "retried", - "failed", - "succeeded", - "critical" - ] - } - } - }, - "eventType": { - "name": "type", - "in": "query", - "description": "Filter the type of the events.", - "schema": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "fetch", - "record", - "log", - "transform" - ] - } - } - }, - "eventSort": { - "name": "sort", - "in": "query", - "description": "The key by which the list should be sorted.", - "required": false, - "schema": { - "type": "string", - "description": "Used to sort the Event list endpoint.", - "enum": [ - "status", - "type", - "publishedAt" - ] - } - }, - "pathEventID": { - "name": "eventID", - "in": "path", - "required": true, - "description": "The event UUID.", - "schema": { - "type": "string", - "description": "The event UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - "schemas": { - "ErrorBase": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - }, - "AuthenticationType": { - "type": "string", - "description": "Type of the Authentication, defines what kind of object is stored in the input.", - "enum": [ - "googleServiceAccount", - "basic", - "apiKey", - "oauth", - "algolia" - ] - }, - "Platform": { - "type": "string", - "nullable": true, - "description": "Describe which platform the Authentication is used for.", - "enum": [ - "bigcommerce", - "commercetools" - ] - }, - "platformNone": { - "type": "string", - "description": "Used to filter Authentication without platform property.", - "enum": [ - "none" - ] - }, - "platformWithNone": { - "oneOf": [ - { - "type": "string", - "nullable": true, - "description": "Describe which platform the Authentication is used for.", - "enum": [ - "bigcommerce", - "commercetools" - ] - }, - { - "type": "string", - "description": "Used to filter Authentication without platform property.", - "enum": [ - "none" - ] - } - ] - }, - "authenticationSortKeys": { - "type": "string", - "description": "Used to sort the Authentication list endpoint.", - "enum": [ - "name", - "auth_type", - "platform", - "updatedAt", - "createdAt" - ] - }, - "orderKeys": { - "type": "string", - "description": "Used to order a sorted request.", - "enum": [ - "asc", - "desc" - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "AuthGoogleServiceAccountPartial": { - "type": "object", - "description": "Authentication input to connect to a Google service (e.g. BigQuery).", - "additionalProperties": false, - "properties": { - "clientEmail": { - "type": "string", - "description": "Email address of the Service Account.", - "example": "service-account-name@project-id.iam.gserviceaccount.com" - }, - "privateKey": { - "type": "string", - "description": "Private key of the Service Account." - } - } - }, - "AuthBasicPartial": { - "type": "object", - "description": "Authentication input for Basic login with username and password.", - "additionalProperties": false, - "properties": { - "username": { - "type": "string" - }, - "password": { - "type": "string" - } - } - }, - "AuthAPIKeyPartial": { - "type": "object", - "description": "Authentication input used for token credentials.", - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - } - } - }, - "AuthOAuthPartial": { - "type": "object", - "description": "Authentication input for OAuth login.", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The OAuth endpoint URL." - }, - "client_id": { - "type": "string", - "description": "The clientID." - }, - "client_secret": { - "type": "string", - "description": "The secret." - } - } - }, - "AuthAlgoliaPartial": { - "type": "object", - "additionalProperties": false, - "properties": { - "appID": { - "type": "string", - "description": "Algolia Application ID." - }, - "apiKey": { - "type": "string", - "description": "Algolia API Key, with the correct rights to push to an index and change settings." - } - } - }, - "AuthInputPartial": { - "oneOf": [ - { - "type": "object", - "description": "Authentication input to connect to a Google service (e.g. BigQuery).", - "additionalProperties": false, - "properties": { - "clientEmail": { - "type": "string", - "description": "Email address of the Service Account.", - "example": "service-account-name@project-id.iam.gserviceaccount.com" - }, - "privateKey": { - "type": "string", - "description": "Private key of the Service Account." - } - } - }, - { - "type": "object", - "description": "Authentication input for Basic login with username and password.", - "additionalProperties": false, - "properties": { - "username": { - "type": "string" - }, - "password": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input used for token credentials.", - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input for OAuth login.", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The OAuth endpoint URL." - }, - "client_id": { - "type": "string", - "description": "The clientID." - }, - "client_secret": { - "type": "string", - "description": "The secret." - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "appID": { - "type": "string", - "description": "Algolia Application ID." - }, - "apiKey": { - "type": "string", - "description": "Algolia API Key, with the correct rights to push to an index and change settings." - } - } - } - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - }, - "Authentication": { - "type": "object", - "description": "An authentication is used to login into a Source or a Destination, with obfuscated input.", - "additionalProperties": false, - "properties": { - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "type": { - "type": "string", - "description": "Type of the Authentication, defines what kind of object is stored in the input.", - "enum": [ - "googleServiceAccount", - "basic", - "apiKey", - "oauth", - "algolia" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "platform": { - "type": "string", - "nullable": true, - "description": "Describe which platform the Authentication is used for.", - "enum": [ - "bigcommerce", - "commercetools" - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "description": "Authentication input to connect to a Google service (e.g. BigQuery).", - "additionalProperties": false, - "properties": { - "clientEmail": { - "type": "string", - "description": "Email address of the Service Account.", - "example": "service-account-name@project-id.iam.gserviceaccount.com" - }, - "privateKey": { - "type": "string", - "description": "Private key of the Service Account." - } - } - }, - { - "type": "object", - "description": "Authentication input for Basic login with username and password.", - "additionalProperties": false, - "properties": { - "username": { - "type": "string" - }, - "password": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input used for token credentials.", - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input for OAuth login.", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The OAuth endpoint URL." - }, - "client_id": { - "type": "string", - "description": "The clientID." - }, - "client_secret": { - "type": "string", - "description": "The secret." - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "appID": { - "type": "string", - "description": "Algolia Application ID." - }, - "apiKey": { - "type": "string", - "description": "Algolia API Key, with the correct rights to push to an index and change settings." - } - } - } - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "authenticationID", - "type", - "name", - "input", - "createdAt" - ] - }, - "Pagination": { - "type": "object", - "additionalProperties": false, - "properties": { - "nbPages": { - "type": "integer" - }, - "page": { - "type": "integer" - }, - "nbItems": { - "type": "integer" - }, - "itemsPerPage": { - "type": "integer" - } - }, - "required": [ - "nbPages", - "page", - "nbItems", - "itemsPerPage" - ] - }, - "AuthGoogleServiceAccount": { - "type": "object", - "description": "Authentication input to connect to a Google service (e.g. BigQuery).", - "additionalProperties": false, - "properties": { - "clientEmail": { - "type": "string", - "description": "Email address of the Service Account.", - "example": "service-account-name@project-id.iam.gserviceaccount.com" - }, - "privateKey": { - "type": "string", - "description": "Private key of the Service Account." - } - }, - "required": [ - "clientEmail", - "privateKey" - ] - }, - "AuthBasic": { - "type": "object", - "description": "Authentication input for Basic login with username and password.", - "additionalProperties": false, - "properties": { - "username": { - "type": "string" - }, - "password": { - "type": "string" - } - }, - "required": [ - "username", - "password" - ] - }, - "AuthAPIKey": { - "type": "object", - "description": "Authentication input used for token credentials.", - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - } - }, - "required": [ - "key" - ] - }, - "AuthOAuth": { - "type": "object", - "description": "Authentication input for OAuth login.", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The OAuth endpoint URL." - }, - "client_id": { - "type": "string", - "description": "The clientID." - }, - "client_secret": { - "type": "string", - "description": "The secret." - } - }, - "required": [ - "url", - "client_id", - "client_secret" - ] - }, - "AuthAlgolia": { - "type": "object", - "additionalProperties": false, - "properties": { - "appID": { - "type": "string", - "description": "Algolia Application ID." - }, - "apiKey": { - "type": "string", - "description": "Algolia API Key, with the correct rights to push to an index and change settings." - } - }, - "required": [ - "appID", - "apiKey" - ] - }, - "AuthInput": { - "oneOf": [ - { - "type": "object", - "description": "Authentication input to connect to a Google service (e.g. BigQuery).", - "additionalProperties": false, - "properties": { - "clientEmail": { - "type": "string", - "description": "Email address of the Service Account.", - "example": "service-account-name@project-id.iam.gserviceaccount.com" - }, - "privateKey": { - "type": "string", - "description": "Private key of the Service Account." - } - }, - "required": [ - "clientEmail", - "privateKey" - ] - }, - { - "type": "object", - "description": "Authentication input for Basic login with username and password.", - "additionalProperties": false, - "properties": { - "username": { - "type": "string" - }, - "password": { - "type": "string" - } - }, - "required": [ - "username", - "password" - ] - }, - { - "type": "object", - "description": "Authentication input used for token credentials.", - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - } - }, - "required": [ - "key" - ] - }, - { - "type": "object", - "description": "Authentication input for OAuth login.", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The OAuth endpoint URL." - }, - "client_id": { - "type": "string", - "description": "The clientID." - }, - "client_secret": { - "type": "string", - "description": "The secret." - } - }, - "required": [ - "url", - "client_id", - "client_secret" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "appID": { - "type": "string", - "description": "Algolia Application ID." - }, - "apiKey": { - "type": "string", - "description": "Algolia API Key, with the correct rights to push to an index and change settings." - } - }, - "required": [ - "appID", - "apiKey" - ] - } - ] - }, - "AuthenticationCreate": { - "type": "object", - "description": "The payload when creating an authentication.", - "additionalProperties": false, - "properties": { - "type": { - "type": "string", - "description": "Type of the Authentication, defines what kind of object is stored in the input.", - "enum": [ - "googleServiceAccount", - "basic", - "apiKey", - "oauth", - "algolia" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "platform": { - "type": "string", - "nullable": true, - "description": "Describe which platform the Authentication is used for.", - "enum": [ - "bigcommerce", - "commercetools" - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "description": "Authentication input to connect to a Google service (e.g. BigQuery).", - "additionalProperties": false, - "properties": { - "clientEmail": { - "type": "string", - "description": "Email address of the Service Account.", - "example": "service-account-name@project-id.iam.gserviceaccount.com" - }, - "privateKey": { - "type": "string", - "description": "Private key of the Service Account." - } - }, - "required": [ - "clientEmail", - "privateKey" - ] - }, - { - "type": "object", - "description": "Authentication input for Basic login with username and password.", - "additionalProperties": false, - "properties": { - "username": { - "type": "string" - }, - "password": { - "type": "string" - } - }, - "required": [ - "username", - "password" - ] - }, - { - "type": "object", - "description": "Authentication input used for token credentials.", - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - } - }, - "required": [ - "key" - ] - }, - { - "type": "object", - "description": "Authentication input for OAuth login.", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The OAuth endpoint URL." - }, - "client_id": { - "type": "string", - "description": "The clientID." - }, - "client_secret": { - "type": "string", - "description": "The secret." - } - }, - "required": [ - "url", - "client_id", - "client_secret" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "appID": { - "type": "string", - "description": "Algolia Application ID." - }, - "apiKey": { - "type": "string", - "description": "Algolia API Key, with the correct rights to push to an index and change settings." - } - }, - "required": [ - "appID", - "apiKey" - ] - } - ] - } - }, - "required": [ - "type", - "name", - "input" - ] - }, - "AuthenticationCreateResponse": { - "type": "object", - "description": "Response from the API when the Authentication is successfully created.", - "additionalProperties": false, - "properties": { - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - } - }, - "required": [ - "authenticationID", - "name", - "createdAt" - ] - }, - "AuthenticationSearch": { - "type": "object", - "additionalProperties": false, - "description": "Payload to search for multiple authentications, based on the given `authenticationIDs`.", - "properties": { - "authenticationIDs": { - "type": "array", - "items": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - "required": [ - "authenticationIDs" - ] - }, - "DeleteResponse": { - "type": "object", - "properties": { - "deletedAt": { - "type": "string", - "description": "Date of deletion (RFC3339 format)." - } - }, - "required": [ - "deletedAt" - ] - }, - "AuthenticationUpdate": { - "type": "object", - "description": "Payload to partially update an Authentication.", - "additionalProperties": false, - "properties": { - "type": { - "type": "string", - "description": "Type of the Authentication, defines what kind of object is stored in the input.", - "enum": [ - "googleServiceAccount", - "basic", - "apiKey", - "oauth", - "algolia" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "platform": { - "type": "string", - "nullable": true, - "description": "Describe which platform the Authentication is used for.", - "enum": [ - "bigcommerce", - "commercetools" - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "description": "Authentication input to connect to a Google service (e.g. BigQuery).", - "additionalProperties": false, - "properties": { - "clientEmail": { - "type": "string", - "description": "Email address of the Service Account.", - "example": "service-account-name@project-id.iam.gserviceaccount.com" - }, - "privateKey": { - "type": "string", - "description": "Private key of the Service Account." - } - } - }, - { - "type": "object", - "description": "Authentication input for Basic login with username and password.", - "additionalProperties": false, - "properties": { - "username": { - "type": "string" - }, - "password": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input used for token credentials.", - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input for OAuth login.", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The OAuth endpoint URL." - }, - "client_id": { - "type": "string", - "description": "The clientID." - }, - "client_secret": { - "type": "string", - "description": "The secret." - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "appID": { - "type": "string", - "description": "Algolia Application ID." - }, - "apiKey": { - "type": "string", - "description": "Algolia API Key, with the correct rights to push to an index and change settings." - } - } - } - ] - } - } - }, - "AuthenticationUpdateResponse": { - "type": "object", - "additionalProperties": false, - "description": "Response from the API when the Authentication is successfully updated.", - "properties": { - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "authenticationID", - "name", - "updatedAt" - ] - }, - "DestinationType": { - "type": "string", - "description": "Type of the Destination, defines in which Algolia product the data will be stored.", - "enum": [ - "search", - "insights", - "flow" - ] - }, - "destinationSortKeys": { - "type": "string", - "description": "Used to sort the Destination list endpoint.", - "enum": [ - "name", - "type", - "updatedAt", - "createdAt" - ] - }, - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "DestinationIndexPrefix": { - "type": "object", - "additionalProperties": false, - "properties": { - "indexPrefix": { - "type": "string", - "description": "The prefix of the final index name." - } - }, - "required": [ - "indexPrefix" - ] - }, - "RecordType": { - "type": "string", - "description": "Determines the indexing strategy to use for a given e-commerce source.", - "enum": [ - "product", - "variant" - ] - }, - "AttributesToExclude": { - "type": "array", - "description": "Determines the attributes to exclude from an Algolia record.\nTo remove nested element, you can separate the path to the element with dots (`.`):\n - \"foo.bar\": will remove `bar` from `foo`.\nTo remove elements from an array, you can use the following:\n - \"foo.[0].bar\": will only remove `bar` from the first element of `foo`.\n - \"foo.[*].bar\": will remove `bar` from every elements of `foo`.\n", - "items": { - "type": "string" - } - }, - "DestinationIndexName": { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "description": "The index name to store data in." - }, - "recordType": { - "type": "string", - "description": "Determines the indexing strategy to use for a given e-commerce source.", - "enum": [ - "product", - "variant" - ] - }, - "attributesToExclude": { - "type": "array", - "description": "Determines the attributes to exclude from an Algolia record.\nTo remove nested element, you can separate the path to the element with dots (`.`):\n - \"foo.bar\": will remove `bar` from `foo`.\nTo remove elements from an array, you can use the following:\n - \"foo.[0].bar\": will only remove `bar` from the first element of `foo`.\n - \"foo.[*].bar\": will remove `bar` from every elements of `foo`.\n", - "items": { - "type": "string" - } - } - }, - "required": [ - "indexName" - ] - }, - "DestinationInput": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexPrefix": { - "type": "string", - "description": "The prefix of the final index name." - } - }, - "required": [ - "indexPrefix" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "description": "The index name to store data in." - }, - "recordType": { - "type": "string", - "description": "Determines the indexing strategy to use for a given e-commerce source.", - "enum": [ - "product", - "variant" - ] - }, - "attributesToExclude": { - "type": "array", - "description": "Determines the attributes to exclude from an Algolia record.\nTo remove nested element, you can separate the path to the element with dots (`.`):\n - \"foo.bar\": will remove `bar` from `foo`.\nTo remove elements from an array, you can use the following:\n - \"foo.[0].bar\": will only remove `bar` from the first element of `foo`.\n - \"foo.[*].bar\": will remove `bar` from every elements of `foo`.\n", - "items": { - "type": "string" - } - } - }, - "required": [ - "indexName" - ] - } - ] - }, - "Destination": { - "type": "object", - "description": "A destination describe how the data is indexed on the Algolia side.", - "additionalProperties": false, - "properties": { - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "type": { - "type": "string", - "description": "Type of the Destination, defines in which Algolia product the data will be stored.", - "enum": [ - "search", - "insights", - "flow" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexPrefix": { - "type": "string", - "description": "The prefix of the final index name." - } - }, - "required": [ - "indexPrefix" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "description": "The index name to store data in." - }, - "recordType": { - "type": "string", - "description": "Determines the indexing strategy to use for a given e-commerce source.", - "enum": [ - "product", - "variant" - ] - }, - "attributesToExclude": { - "type": "array", - "description": "Determines the attributes to exclude from an Algolia record.\nTo remove nested element, you can separate the path to the element with dots (`.`):\n - \"foo.bar\": will remove `bar` from `foo`.\nTo remove elements from an array, you can use the following:\n - \"foo.[0].bar\": will only remove `bar` from the first element of `foo`.\n - \"foo.[*].bar\": will remove `bar` from every elements of `foo`.\n", - "items": { - "type": "string" - } - } - }, - "required": [ - "indexName" - ] - } - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "required": [ - "destinationID", - "type", - "name", - "input", - "createdAt" - ] - }, - "DestinationCreate": { - "type": "object", - "additionalProperties": false, - "description": "The payload when creating a destination.", - "properties": { - "type": { - "type": "string", - "description": "Type of the Destination, defines in which Algolia product the data will be stored.", - "enum": [ - "search", - "insights", - "flow" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexPrefix": { - "type": "string", - "description": "The prefix of the final index name." - } - }, - "required": [ - "indexPrefix" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "description": "The index name to store data in." - }, - "recordType": { - "type": "string", - "description": "Determines the indexing strategy to use for a given e-commerce source.", - "enum": [ - "product", - "variant" - ] - }, - "attributesToExclude": { - "type": "array", - "description": "Determines the attributes to exclude from an Algolia record.\nTo remove nested element, you can separate the path to the element with dots (`.`):\n - \"foo.bar\": will remove `bar` from `foo`.\nTo remove elements from an array, you can use the following:\n - \"foo.[0].bar\": will only remove `bar` from the first element of `foo`.\n - \"foo.[*].bar\": will remove `bar` from every elements of `foo`.\n", - "items": { - "type": "string" - } - } - }, - "required": [ - "indexName" - ] - } - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "required": [ - "type", - "name", - "input" - ] - }, - "DestinationCreateResponse": { - "type": "object", - "additionalProperties": false, - "description": "Response from the API when the Destination is successfully created.", - "properties": { - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - } - }, - "required": [ - "destinationID", - "name", - "createdAt" - ] - }, - "DestinationSearch": { - "type": "object", - "additionalProperties": false, - "description": "Payload to search for multiple destinations, based on the given `destinationIDs`.", - "properties": { - "destinationIDs": { - "type": "array", - "items": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - "required": [ - "destinationIDs" - ] - }, - "DestinationUpdate": { - "type": "object", - "additionalProperties": false, - "description": "Payload to partially update a Destination.", - "properties": { - "type": { - "type": "string", - "description": "Type of the Destination, defines in which Algolia product the data will be stored.", - "enum": [ - "search", - "insights", - "flow" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexPrefix": { - "type": "string", - "description": "The prefix of the final index name." - } - }, - "required": [ - "indexPrefix" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "description": "The index name to store data in." - }, - "recordType": { - "type": "string", - "description": "Determines the indexing strategy to use for a given e-commerce source.", - "enum": [ - "product", - "variant" - ] - }, - "attributesToExclude": { - "type": "array", - "description": "Determines the attributes to exclude from an Algolia record.\nTo remove nested element, you can separate the path to the element with dots (`.`):\n - \"foo.bar\": will remove `bar` from `foo`.\nTo remove elements from an array, you can use the following:\n - \"foo.[0].bar\": will only remove `bar` from the first element of `foo`.\n - \"foo.[*].bar\": will remove `bar` from every elements of `foo`.\n", - "items": { - "type": "string" - } - } - }, - "required": [ - "indexName" - ] - } - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - "DestinationUpdateResponse": { - "type": "object", - "additionalProperties": false, - "description": "Response from the API when the Destination is successfully updated.", - "properties": { - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "destinationID", - "name", - "updatedAt" - ] - }, - "SourceType": { - "type": "string", - "enum": [ - "bigcommerce", - "commercetools", - "json", - "csv", - "bigquery", - "docker" - ] - }, - "sourceSortKeys": { - "type": "string", - "description": "Used to sort the Source list endpoint.", - "enum": [ - "name", - "type", - "updatedAt", - "createdAt" - ] - }, - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "CommercetoolsCustomFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - }, - "SourceCommercetools": { - "type": "object", - "additionalProperties": false, - "properties": { - "storeKeys": { - "type": "array", - "items": { - "description": "Unique and immutable key of the referenced Store.", - "type": "string" - } - }, - "locales": { - "type": "array", - "description": "Array of locales that must match the following pattern: ^[a-z]{2}(-[A-Z]{2})?$. For example [\"fr-FR\", \"en\"].\n", - "items": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "projectKey": { - "type": "string" - }, - "fallbackIsInStockValue": { - "type": "boolean", - "default": true, - "description": "Determines the value that will be stored in the Algolia record if there's no inventory information on the product.\n" - }, - "customFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - } - }, - "required": [ - "url", - "projectKey" - ], - "x-discriminator-fields": [ - "projectKey" - ] - }, - "BigCommerceChannel": { - "type": "object", - "additionalProperties": false, - "properties": { - "id": { - "type": "integer", - "description": "The ID of the bigcommerce channel." - }, - "currencies": { - "type": "array", - "description": "An array of currencies for the given channel `ID`, a currency is a trigram string that represents the currency code.", - "example": [ - "usd", - "eur" - ], - "items": { - "type": "string", - "example": "usd" - } - } - }, - "required": [ - "id" - ] - }, - "BigCommerceMetafield": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - }, - "SourceBigCommerce": { - "type": "object", - "additionalProperties": false, - "properties": { - "storeHash": { - "type": "string", - "description": "The store hash identifying the store the shopper is signing in to." - }, - "channel": { - "type": "object", - "additionalProperties": false, - "properties": { - "id": { - "type": "integer", - "description": "The ID of the bigcommerce channel." - }, - "currencies": { - "type": "array", - "description": "An array of currencies for the given channel `ID`, a currency is a trigram string that represents the currency code.", - "example": [ - "usd", - "eur" - ], - "items": { - "type": "string", - "example": "usd" - } - } - }, - "required": [ - "id" - ] - }, - "customFields": { - "type": "array", - "items": { - "type": "string" - } - }, - "productMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - }, - "variantMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - } - }, - "required": [ - "storeHash" - ], - "x-discriminator-fields": [ - "storeHash" - ] - }, - "UniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "MethodType": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - }, - "SourceJSON": { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - } - }, - "required": [ - "url" - ] - }, - "MappingTypeCSV": { - "type": "string", - "enum": [ - "string", - "integer", - "float", - "boolean", - "json" - ] - }, - "SourceCSV": { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "mapping": { - "type": "object", - "description": "Mapping of type for every column. For example {\"myColumn\": \"boolean\", \"myOtherColumn\": \"json\"}.\n", - "additionalProperties": { - "type": "string", - "enum": [ - "string", - "integer", - "float", - "boolean", - "json" - ] - } - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - }, - "delimiter": { - "type": "string", - "minLength": 1, - "maxLength": 1, - "default": ",", - "description": "The character used to split the value on each line, default to a comma (\\r, \\n, 0xFFFD, and space are forbidden)." - } - }, - "required": [ - "url" - ] - }, - "BigQueryDataType": { - "type": "string", - "enum": [ - "ga4", - "ga360" - ] - }, - "SourceBigQuery": { - "type": "object", - "additionalProperties": false, - "properties": { - "projectID": { - "type": "string", - "description": "Project ID of the BigQuery Source." - }, - "datasetID": { - "type": "string", - "description": "Dataset ID of the BigQuery Source." - }, - "dataType": { - "type": "string", - "enum": [ - "ga4", - "ga360" - ] - }, - "table": { - "type": "string", - "description": "Table name (for default BQ)." - }, - "tablePrefix": { - "type": "string", - "description": "Table prefix (for Google Analytics)." - }, - "customSQLRequest": { - "type": "string", - "description": "Custom SQL request to extract data from the BigQuery table." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - } - }, - "required": [ - "projectID", - "datasetID" - ], - "x-discriminator-fields": [ - "projectID" - ] - }, - "DockerImageType": { - "type": "string", - "enum": [ - "singer", - "custom", - "airbyte" - ], - "description": "The type of the image." - }, - "DockerRegistry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "SourceDocker": { - "type": "object", - "additionalProperties": false, - "properties": { - "imageType": { - "type": "string", - "enum": [ - "singer", - "custom", - "airbyte" - ], - "description": "The type of the image." - }, - "registry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "image": { - "type": "string", - "description": "The name of the image to pull.", - "example": "algolia/zendesk" - }, - "version": { - "type": "string", - "description": "The version of the image, defaults to `latest`.", - "example": "v2.1.0" - }, - "configuration": { - "type": "object", - "description": "The configuration of the spec." - } - }, - "required": [ - "registry", - "image", - "imageType", - "configuration" - ] - }, - "SourceInput": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeKeys": { - "type": "array", - "items": { - "description": "Unique and immutable key of the referenced Store.", - "type": "string" - } - }, - "locales": { - "type": "array", - "description": "Array of locales that must match the following pattern: ^[a-z]{2}(-[A-Z]{2})?$. For example [\"fr-FR\", \"en\"].\n", - "items": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "projectKey": { - "type": "string" - }, - "fallbackIsInStockValue": { - "type": "boolean", - "default": true, - "description": "Determines the value that will be stored in the Algolia record if there's no inventory information on the product.\n" - }, - "customFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - } - }, - "required": [ - "url", - "projectKey" - ], - "x-discriminator-fields": [ - "projectKey" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeHash": { - "type": "string", - "description": "The store hash identifying the store the shopper is signing in to." - }, - "channel": { - "type": "object", - "additionalProperties": false, - "properties": { - "id": { - "type": "integer", - "description": "The ID of the bigcommerce channel." - }, - "currencies": { - "type": "array", - "description": "An array of currencies for the given channel `ID`, a currency is a trigram string that represents the currency code.", - "example": [ - "usd", - "eur" - ], - "items": { - "type": "string", - "example": "usd" - } - } - }, - "required": [ - "id" - ] - }, - "customFields": { - "type": "array", - "items": { - "type": "string" - } - }, - "productMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - }, - "variantMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - } - }, - "required": [ - "storeHash" - ], - "x-discriminator-fields": [ - "storeHash" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "mapping": { - "type": "object", - "description": "Mapping of type for every column. For example {\"myColumn\": \"boolean\", \"myOtherColumn\": \"json\"}.\n", - "additionalProperties": { - "type": "string", - "enum": [ - "string", - "integer", - "float", - "boolean", - "json" - ] - } - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - }, - "delimiter": { - "type": "string", - "minLength": 1, - "maxLength": 1, - "default": ",", - "description": "The character used to split the value on each line, default to a comma (\\r, \\n, 0xFFFD, and space are forbidden)." - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "projectID": { - "type": "string", - "description": "Project ID of the BigQuery Source." - }, - "datasetID": { - "type": "string", - "description": "Dataset ID of the BigQuery Source." - }, - "dataType": { - "type": "string", - "enum": [ - "ga4", - "ga360" - ] - }, - "table": { - "type": "string", - "description": "Table name (for default BQ)." - }, - "tablePrefix": { - "type": "string", - "description": "Table prefix (for Google Analytics)." - }, - "customSQLRequest": { - "type": "string", - "description": "Custom SQL request to extract data from the BigQuery table." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - } - }, - "required": [ - "projectID", - "datasetID" - ], - "x-discriminator-fields": [ - "projectID" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "imageType": { - "type": "string", - "enum": [ - "singer", - "custom", - "airbyte" - ], - "description": "The type of the image." - }, - "registry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "image": { - "type": "string", - "description": "The name of the image to pull.", - "example": "algolia/zendesk" - }, - "version": { - "type": "string", - "description": "The version of the image, defaults to `latest`.", - "example": "v2.1.0" - }, - "configuration": { - "type": "object", - "description": "The configuration of the spec." - } - }, - "required": [ - "registry", - "image", - "imageType", - "configuration" - ] - } - ] - }, - "Source": { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "type": { - "type": "string", - "enum": [ - "bigcommerce", - "commercetools", - "json", - "csv", - "bigquery", - "docker" - ] - }, - "name": { - "type": "string" - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeKeys": { - "type": "array", - "items": { - "description": "Unique and immutable key of the referenced Store.", - "type": "string" - } - }, - "locales": { - "type": "array", - "description": "Array of locales that must match the following pattern: ^[a-z]{2}(-[A-Z]{2})?$. For example [\"fr-FR\", \"en\"].\n", - "items": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "projectKey": { - "type": "string" - }, - "fallbackIsInStockValue": { - "type": "boolean", - "default": true, - "description": "Determines the value that will be stored in the Algolia record if there's no inventory information on the product.\n" - }, - "customFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - } - }, - "required": [ - "url", - "projectKey" - ], - "x-discriminator-fields": [ - "projectKey" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeHash": { - "type": "string", - "description": "The store hash identifying the store the shopper is signing in to." - }, - "channel": { - "type": "object", - "additionalProperties": false, - "properties": { - "id": { - "type": "integer", - "description": "The ID of the bigcommerce channel." - }, - "currencies": { - "type": "array", - "description": "An array of currencies for the given channel `ID`, a currency is a trigram string that represents the currency code.", - "example": [ - "usd", - "eur" - ], - "items": { - "type": "string", - "example": "usd" - } - } - }, - "required": [ - "id" - ] - }, - "customFields": { - "type": "array", - "items": { - "type": "string" - } - }, - "productMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - }, - "variantMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - } - }, - "required": [ - "storeHash" - ], - "x-discriminator-fields": [ - "storeHash" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "mapping": { - "type": "object", - "description": "Mapping of type for every column. For example {\"myColumn\": \"boolean\", \"myOtherColumn\": \"json\"}.\n", - "additionalProperties": { - "type": "string", - "enum": [ - "string", - "integer", - "float", - "boolean", - "json" - ] - } - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - }, - "delimiter": { - "type": "string", - "minLength": 1, - "maxLength": 1, - "default": ",", - "description": "The character used to split the value on each line, default to a comma (\\r, \\n, 0xFFFD, and space are forbidden)." - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "projectID": { - "type": "string", - "description": "Project ID of the BigQuery Source." - }, - "datasetID": { - "type": "string", - "description": "Dataset ID of the BigQuery Source." - }, - "dataType": { - "type": "string", - "enum": [ - "ga4", - "ga360" - ] - }, - "table": { - "type": "string", - "description": "Table name (for default BQ)." - }, - "tablePrefix": { - "type": "string", - "description": "Table prefix (for Google Analytics)." - }, - "customSQLRequest": { - "type": "string", - "description": "Custom SQL request to extract data from the BigQuery table." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - } - }, - "required": [ - "projectID", - "datasetID" - ], - "x-discriminator-fields": [ - "projectID" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "imageType": { - "type": "string", - "enum": [ - "singer", - "custom", - "airbyte" - ], - "description": "The type of the image." - }, - "registry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "image": { - "type": "string", - "description": "The name of the image to pull.", - "example": "algolia/zendesk" - }, - "version": { - "type": "string", - "description": "The version of the image, defaults to `latest`.", - "example": "v2.1.0" - }, - "configuration": { - "type": "object", - "description": "The configuration of the spec." - } - }, - "required": [ - "registry", - "image", - "imageType", - "configuration" - ] - } - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "sourceID", - "type", - "name", - "input", - "createdAt" - ] - }, - "SourceCreate": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "type": "string", - "enum": [ - "bigcommerce", - "commercetools", - "json", - "csv", - "bigquery", - "docker" - ] - }, - "name": { - "type": "string" - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeKeys": { - "type": "array", - "items": { - "description": "Unique and immutable key of the referenced Store.", - "type": "string" - } - }, - "locales": { - "type": "array", - "description": "Array of locales that must match the following pattern: ^[a-z]{2}(-[A-Z]{2})?$. For example [\"fr-FR\", \"en\"].\n", - "items": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "projectKey": { - "type": "string" - }, - "fallbackIsInStockValue": { - "type": "boolean", - "default": true, - "description": "Determines the value that will be stored in the Algolia record if there's no inventory information on the product.\n" - }, - "customFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - } - }, - "required": [ - "url", - "projectKey" - ], - "x-discriminator-fields": [ - "projectKey" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeHash": { - "type": "string", - "description": "The store hash identifying the store the shopper is signing in to." - }, - "channel": { - "type": "object", - "additionalProperties": false, - "properties": { - "id": { - "type": "integer", - "description": "The ID of the bigcommerce channel." - }, - "currencies": { - "type": "array", - "description": "An array of currencies for the given channel `ID`, a currency is a trigram string that represents the currency code.", - "example": [ - "usd", - "eur" - ], - "items": { - "type": "string", - "example": "usd" - } - } - }, - "required": [ - "id" - ] - }, - "customFields": { - "type": "array", - "items": { - "type": "string" - } - }, - "productMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - }, - "variantMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - } - }, - "required": [ - "storeHash" - ], - "x-discriminator-fields": [ - "storeHash" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "mapping": { - "type": "object", - "description": "Mapping of type for every column. For example {\"myColumn\": \"boolean\", \"myOtherColumn\": \"json\"}.\n", - "additionalProperties": { - "type": "string", - "enum": [ - "string", - "integer", - "float", - "boolean", - "json" - ] - } - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - }, - "delimiter": { - "type": "string", - "minLength": 1, - "maxLength": 1, - "default": ",", - "description": "The character used to split the value on each line, default to a comma (\\r, \\n, 0xFFFD, and space are forbidden)." - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "projectID": { - "type": "string", - "description": "Project ID of the BigQuery Source." - }, - "datasetID": { - "type": "string", - "description": "Dataset ID of the BigQuery Source." - }, - "dataType": { - "type": "string", - "enum": [ - "ga4", - "ga360" - ] - }, - "table": { - "type": "string", - "description": "Table name (for default BQ)." - }, - "tablePrefix": { - "type": "string", - "description": "Table prefix (for Google Analytics)." - }, - "customSQLRequest": { - "type": "string", - "description": "Custom SQL request to extract data from the BigQuery table." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - } - }, - "required": [ - "projectID", - "datasetID" - ], - "x-discriminator-fields": [ - "projectID" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "imageType": { - "type": "string", - "enum": [ - "singer", - "custom", - "airbyte" - ], - "description": "The type of the image." - }, - "registry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "image": { - "type": "string", - "description": "The name of the image to pull.", - "example": "algolia/zendesk" - }, - "version": { - "type": "string", - "description": "The version of the image, defaults to `latest`.", - "example": "v2.1.0" - }, - "configuration": { - "type": "object", - "description": "The configuration of the spec." - } - }, - "required": [ - "registry", - "image", - "imageType", - "configuration" - ] - } - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "required": [ - "type", - "name", - "input" - ] - }, - "SourceCreateResponse": { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string" - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - } - }, - "required": [ - "sourceID", - "name", - "createdAt" - ] - }, - "SourceSearch": { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceIDs": { - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "sourceIDs" - ] - }, - "SourceUpdateCommercetools": { - "type": "object", - "additionalProperties": false, - "properties": { - "storeKeys": { - "type": "array", - "description": "Unique and immutable key of the referenced Store.", - "items": { - "type": "string" - } - }, - "locales": { - "type": "array", - "description": "Array of locales that must match the following pattern: ^[a-z]{2}(-[A-Z]{2})?$. For example [\"fr-FR\", \"en\"].\n", - "items": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "fallbackIsInStockValue": { - "type": "boolean", - "description": "Determines the value that will be stored in the Algolia record if there's no inventory information on the product.\n" - }, - "customFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - } - } - }, - "SourceUpdateDocker": { - "type": "object", - "additionalProperties": false, - "properties": { - "registry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "image": { - "type": "string", - "description": "The name of the image to pull.", - "example": "algolia/zendesk" - }, - "version": { - "type": "string", - "description": "The version of the image, defaults to `latest`.", - "example": "v2.1.0" - }, - "configuration": { - "type": "object", - "description": "The configuration of the spec." - } - }, - "required": [ - "configuration" - ] - }, - "SourceUpdateInput": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeKeys": { - "type": "array", - "description": "Unique and immutable key of the referenced Store.", - "items": { - "type": "string" - } - }, - "locales": { - "type": "array", - "description": "Array of locales that must match the following pattern: ^[a-z]{2}(-[A-Z]{2})?$. For example [\"fr-FR\", \"en\"].\n", - "items": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "fallbackIsInStockValue": { - "type": "boolean", - "description": "Determines the value that will be stored in the Algolia record if there's no inventory information on the product.\n" - }, - "customFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "mapping": { - "type": "object", - "description": "Mapping of type for every column. For example {\"myColumn\": \"boolean\", \"myOtherColumn\": \"json\"}.\n", - "additionalProperties": { - "type": "string", - "enum": [ - "string", - "integer", - "float", - "boolean", - "json" - ] - } - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - }, - "delimiter": { - "type": "string", - "minLength": 1, - "maxLength": 1, - "default": ",", - "description": "The character used to split the value on each line, default to a comma (\\r, \\n, 0xFFFD, and space are forbidden)." - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "projectID": { - "type": "string", - "description": "Project ID of the BigQuery Source." - }, - "datasetID": { - "type": "string", - "description": "Dataset ID of the BigQuery Source." - }, - "dataType": { - "type": "string", - "enum": [ - "ga4", - "ga360" - ] - }, - "table": { - "type": "string", - "description": "Table name (for default BQ)." - }, - "tablePrefix": { - "type": "string", - "description": "Table prefix (for Google Analytics)." - }, - "customSQLRequest": { - "type": "string", - "description": "Custom SQL request to extract data from the BigQuery table." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - } - }, - "required": [ - "projectID", - "datasetID" - ], - "x-discriminator-fields": [ - "projectID" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "registry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "image": { - "type": "string", - "description": "The name of the image to pull.", - "example": "algolia/zendesk" - }, - "version": { - "type": "string", - "description": "The version of the image, defaults to `latest`.", - "example": "v2.1.0" - }, - "configuration": { - "type": "object", - "description": "The configuration of the spec." - } - }, - "required": [ - "configuration" - ] - } - ] - }, - "SourceUpdate": { - "type": "object", - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeKeys": { - "type": "array", - "description": "Unique and immutable key of the referenced Store.", - "items": { - "type": "string" - } - }, - "locales": { - "type": "array", - "description": "Array of locales that must match the following pattern: ^[a-z]{2}(-[A-Z]{2})?$. For example [\"fr-FR\", \"en\"].\n", - "items": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "fallbackIsInStockValue": { - "type": "boolean", - "description": "Determines the value that will be stored in the Algolia record if there's no inventory information on the product.\n" - }, - "customFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "mapping": { - "type": "object", - "description": "Mapping of type for every column. For example {\"myColumn\": \"boolean\", \"myOtherColumn\": \"json\"}.\n", - "additionalProperties": { - "type": "string", - "enum": [ - "string", - "integer", - "float", - "boolean", - "json" - ] - } - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - }, - "delimiter": { - "type": "string", - "minLength": 1, - "maxLength": 1, - "default": ",", - "description": "The character used to split the value on each line, default to a comma (\\r, \\n, 0xFFFD, and space are forbidden)." - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "projectID": { - "type": "string", - "description": "Project ID of the BigQuery Source." - }, - "datasetID": { - "type": "string", - "description": "Dataset ID of the BigQuery Source." - }, - "dataType": { - "type": "string", - "enum": [ - "ga4", - "ga360" - ] - }, - "table": { - "type": "string", - "description": "Table name (for default BQ)." - }, - "tablePrefix": { - "type": "string", - "description": "Table prefix (for Google Analytics)." - }, - "customSQLRequest": { - "type": "string", - "description": "Custom SQL request to extract data from the BigQuery table." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - } - }, - "required": [ - "projectID", - "datasetID" - ], - "x-discriminator-fields": [ - "projectID" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "registry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "image": { - "type": "string", - "description": "The name of the image to pull.", - "example": "algolia/zendesk" - }, - "version": { - "type": "string", - "description": "The version of the image, defaults to `latest`.", - "example": "v2.1.0" - }, - "configuration": { - "type": "object", - "description": "The configuration of the spec." - } - }, - "required": [ - "configuration" - ] - } - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - "SourceUpdateResponse": { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string" - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "sourceID", - "name", - "updatedAt" - ] - }, - "DockerSourceStream": { - "type": "object", - "description": "A stream definition (see the Singer specification for details)." - }, - "runID": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "ActionType": { - "type": "string", - "description": "The action to perform on the Algolia index.", - "enum": [ - "replace", - "save", - "partial" - ] - }, - "TriggerType": { - "type": "string", - "description": "The type of the task reflect how it can be used:\n - onDemand: a task that runs manually\n - schedule: a task that runs regularly, following a given cron expression\n - subscription: a task that runs after a subscription event is received from an integration (e.g. Webhook).\n", - "enum": [ - "onDemand", - "schedule", - "subscription" - ] - }, - "taskSortKeys": { - "type": "string", - "description": "Used to sort the Task list endpoint.", - "enum": [ - "enabled", - "triggerType", - "action", - "updatedAt", - "createdAt" - ] - }, - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "OnDemandTriggerType": { - "type": "string", - "description": "A task which is manually executed via the run task endpoint.", - "enum": [ - "onDemand" - ] - }, - "LastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - }, - "OnDemandTrigger": { - "type": "object", - "additionalProperties": false, - "description": "The trigger information of a task of type `onDemand`.", - "properties": { - "type": { - "type": "string", - "description": "A task which is manually executed via the run task endpoint.", - "enum": [ - "onDemand" - ] - }, - "lastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "type" - ] - }, - "ScheduleTriggerType": { - "type": "string", - "description": "A task which is triggered by a schedule (cron expression).", - "enum": [ - "schedule" - ] - }, - "Cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - }, - "ScheduleTrigger": { - "type": "object", - "additionalProperties": false, - "description": "The trigger information for a task of type 'schedule'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by a schedule (cron expression).", - "enum": [ - "schedule" - ] - }, - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - }, - "lastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - }, - "nextRun": { - "description": "The next scheduled run of the task (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "type", - "cron", - "nextRun" - ] - }, - "SubscriptionTriggerType": { - "type": "string", - "description": "A task which is triggered by an external subscription (e.g. Webhook).", - "enum": [ - "subscription" - ] - }, - "SubscriptionTrigger": { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'subscription'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by an external subscription (e.g. Webhook).", - "enum": [ - "subscription" - ] - } - }, - "required": [ - "type" - ] - }, - "Trigger": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information of a task of type `onDemand`.", - "properties": { - "type": { - "type": "string", - "description": "A task which is manually executed via the run task endpoint.", - "enum": [ - "onDemand" - ] - }, - "lastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "type" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information for a task of type 'schedule'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by a schedule (cron expression).", - "enum": [ - "schedule" - ] - }, - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - }, - "lastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - }, - "nextRun": { - "description": "The next scheduled run of the task (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "type", - "cron", - "nextRun" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'subscription'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by an external subscription (e.g. Webhook).", - "enum": [ - "subscription" - ] - } - }, - "required": [ - "type" - ] - } - ] - }, - "OnDemandDateUtilsInput": { - "type": "object", - "additionalProperties": false, - "description": "The input for an `onDemand` task whose source is of type `bigquery` and for which extracted data spans a given time range.", - "properties": { - "startDate": { - "description": "The start date of the extraction (RFC3339 format).", - "type": "string" - }, - "endDate": { - "description": "The end date of the extraction (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "startDate", - "endDate" - ] - }, - "ScheduleDateUtilsInput": { - "type": "object", - "additionalProperties": false, - "description": "The input for a `schedule` task whose source is of type `bigquery` and for which extracted data spans a fixed number of days.", - "properties": { - "timeframe": { - "description": "The timeframe of the extraction, in number of days from today.", - "type": "integer", - "minimum": 1, - "maximum": 30 - } - }, - "required": [ - "timeframe" - ] - }, - "TaskInput": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The input for an `onDemand` task whose source is of type `bigquery` and for which extracted data spans a given time range.", - "properties": { - "startDate": { - "description": "The start date of the extraction (RFC3339 format).", - "type": "string" - }, - "endDate": { - "description": "The end date of the extraction (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "startDate", - "endDate" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The input for a `schedule` task whose source is of type `bigquery` and for which extracted data spans a fixed number of days.", - "properties": { - "timeframe": { - "description": "The timeframe of the extraction, in number of days from today.", - "type": "integer", - "minimum": 1, - "maximum": 30 - } - }, - "required": [ - "timeframe" - ] - } - ] - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - }, - "Task": { - "type": "object", - "additionalProperties": false, - "properties": { - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "trigger": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information of a task of type `onDemand`.", - "properties": { - "type": { - "type": "string", - "description": "A task which is manually executed via the run task endpoint.", - "enum": [ - "onDemand" - ] - }, - "lastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "type" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information for a task of type 'schedule'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by a schedule (cron expression).", - "enum": [ - "schedule" - ] - }, - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - }, - "lastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - }, - "nextRun": { - "description": "The next scheduled run of the task (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "type", - "cron", - "nextRun" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'subscription'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by an external subscription (e.g. Webhook).", - "enum": [ - "subscription" - ] - } - }, - "required": [ - "type" - ] - } - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The input for an `onDemand` task whose source is of type `bigquery` and for which extracted data spans a given time range.", - "properties": { - "startDate": { - "description": "The start date of the extraction (RFC3339 format).", - "type": "string" - }, - "endDate": { - "description": "The end date of the extraction (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "startDate", - "endDate" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The input for a `schedule` task whose source is of type `bigquery` and for which extracted data spans a fixed number of days.", - "properties": { - "timeframe": { - "description": "The timeframe of the extraction, in number of days from today.", - "type": "integer", - "minimum": 1, - "maximum": 30 - } - }, - "required": [ - "timeframe" - ] - } - ] - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Whether the task is enabled or not." - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - }, - "action": { - "type": "string", - "description": "The action to perform on the Algolia index.", - "enum": [ - "replace", - "save", - "partial" - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "taskID", - "sourceID", - "destinationID", - "trigger", - "enabled", - "action", - "createdAt" - ] - }, - "OnDemandTriggerInput": { - "type": "object", - "additionalProperties": false, - "description": "The trigger information of a task of type `onDemand`.", - "properties": { - "type": { - "type": "string", - "description": "A task which is manually executed via the run task endpoint.", - "enum": [ - "onDemand" - ] - } - }, - "required": [ - "type" - ] - }, - "ScheduleTriggerInput": { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'schedule'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by a schedule (cron expression).", - "enum": [ - "schedule" - ] - }, - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - } - }, - "required": [ - "type", - "cron" - ] - }, - "TaskCreateTrigger": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information of a task of type `onDemand`.", - "properties": { - "type": { - "type": "string", - "description": "A task which is manually executed via the run task endpoint.", - "enum": [ - "onDemand" - ] - } - }, - "required": [ - "type" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'schedule'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by a schedule (cron expression).", - "enum": [ - "schedule" - ] - }, - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - } - }, - "required": [ - "type", - "cron" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'subscription'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by an external subscription (e.g. Webhook).", - "enum": [ - "subscription" - ] - } - }, - "required": [ - "type" - ] - } - ] - }, - "TaskCreate": { - "type": "object", - "additionalProperties": false, - "description": "The payload for a task creation.", - "properties": { - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "trigger": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information of a task of type `onDemand`.", - "properties": { - "type": { - "type": "string", - "description": "A task which is manually executed via the run task endpoint.", - "enum": [ - "onDemand" - ] - } - }, - "required": [ - "type" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'schedule'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by a schedule (cron expression).", - "enum": [ - "schedule" - ] - }, - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - } - }, - "required": [ - "type", - "cron" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'subscription'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by an external subscription (e.g. Webhook).", - "enum": [ - "subscription" - ] - } - }, - "required": [ - "type" - ] - } - ] - }, - "action": { - "type": "string", - "description": "The action to perform on the Algolia index.", - "enum": [ - "replace", - "save", - "partial" - ] - }, - "enabled": { - "type": "boolean", - "description": "Whether the task is enabled or not." - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The input for an `onDemand` task whose source is of type `bigquery` and for which extracted data spans a given time range.", - "properties": { - "startDate": { - "description": "The start date of the extraction (RFC3339 format).", - "type": "string" - }, - "endDate": { - "description": "The end date of the extraction (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "startDate", - "endDate" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The input for a `schedule` task whose source is of type `bigquery` and for which extracted data spans a fixed number of days.", - "properties": { - "timeframe": { - "description": "The timeframe of the extraction, in number of days from today.", - "type": "integer", - "minimum": 1, - "maximum": 30 - } - }, - "required": [ - "timeframe" - ] - } - ] - } - }, - "required": [ - "sourceID", - "destinationID", - "trigger", - "action" - ] - }, - "TaskCreateResponse": { - "type": "object", - "additionalProperties": false, - "description": "The response from the API after a task creation.", - "properties": { - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - } - }, - "required": [ - "taskID", - "createdAt" - ] - }, - "TaskSearch": { - "type": "object", - "additionalProperties": false, - "properties": { - "taskIDs": { - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "taskIDs" - ] - }, - "TriggerUpdateInput": { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task update.", - "properties": { - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - } - }, - "required": [ - "cron" - ] - }, - "TaskUpdate": { - "type": "object", - "additionalProperties": false, - "description": "The payload for a task update.", - "properties": { - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "trigger": { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task update.", - "properties": { - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - } - }, - "required": [ - "cron" - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The input for an `onDemand` task whose source is of type `bigquery` and for which extracted data spans a given time range.", - "properties": { - "startDate": { - "description": "The start date of the extraction (RFC3339 format).", - "type": "string" - }, - "endDate": { - "description": "The end date of the extraction (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "startDate", - "endDate" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The input for a `schedule` task whose source is of type `bigquery` and for which extracted data spans a fixed number of days.", - "properties": { - "timeframe": { - "description": "The timeframe of the extraction, in number of days from today.", - "type": "integer", - "minimum": 1, - "maximum": 30 - } - }, - "required": [ - "timeframe" - ] - } - ] - }, - "enabled": { - "type": "boolean", - "description": "Whether the task is enabled or not." - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - } - } - }, - "TaskUpdateResponse": { - "type": "object", - "description": "The response from the API after a task update.", - "additionalProperties": false, - "properties": { - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "taskID", - "updatedAt" - ] - }, - "RunResponse": { - "type": "object", - "additionalProperties": false, - "description": "The response from the run task API, containing an Observability Run ID and the time it was created at.", - "properties": { - "runID": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - } - }, - "required": [ - "runID", - "createdAt" - ] - }, - "RunStatus": { - "type": "string", - "enum": [ - "created", - "started", - "idled", - "finished", - "skipped" - ] - }, - "runSortKeys": { - "type": "string", - "description": "Used to sort the Run list endpoint.", - "enum": [ - "status", - "updatedAt", - "createdAt" - ] - }, - "RunOutcome": { - "type": "string", - "enum": [ - "success", - "failure", - "processing" - ] - }, - "RunReasonCode": { - "type": "string", - "description": "An identifier that pairs with the outcome reason.", - "enum": [ - "internal", - "critical", - "no_events", - "too_many_errors", - "ok", - "discarded", - "blocking" - ] - }, - "RunType": { - "type": "string", - "enum": [ - "reindex", - "update", - "discover" - ] - }, - "startedAt": { - "type": "string", - "description": "Date of start (RFC3339 format)." - }, - "finishedAt": { - "type": "string", - "description": "Date of finish (RFC3339 format)." - }, - "Run": { - "type": "object", - "additionalProperties": false, - "properties": { - "runID": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "appID": { - "type": "string" - }, - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "status": { - "type": "string", - "enum": [ - "created", - "started", - "idled", - "finished", - "skipped" - ] - }, - "progress": { - "type": "object", - "additionalProperties": false, - "properties": { - "expectedNbOfEvents": { - "type": "integer" - }, - "receivedNbOfEvents": { - "type": "integer" - } - } - }, - "outcome": { - "type": "string", - "enum": [ - "success", - "failure", - "processing" - ] - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - }, - "reason": { - "type": "string", - "description": "Explains the result of outcome." - }, - "reasonCode": { - "type": "string", - "description": "An identifier that pairs with the outcome reason.", - "enum": [ - "internal", - "critical", - "no_events", - "too_many_errors", - "ok", - "discarded", - "blocking" - ] - }, - "type": { - "type": "string", - "enum": [ - "reindex", - "update", - "discover" - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "startedAt": { - "type": "string", - "description": "Date of start (RFC3339 format)." - }, - "finishedAt": { - "type": "string", - "description": "Date of finish (RFC3339 format)." - } - }, - "required": [ - "runID", - "appID", - "taskID", - "status", - "type", - "createdAt" - ] - }, - "Window": { - "type": "object", - "additionalProperties": false, - "description": "The window parameter represents the holds the dates used to query the Observability data from the database in a given window.", - "properties": { - "startDate": { - "type": "string", - "description": "A date in format RFC3339 representing the oldest possible data in query window." - }, - "endDate": { - "type": "string", - "description": "A date in format RFC3339 representing the newest possible data in query window." - } - }, - "required": [ - "startDate", - "endDate" - ] - }, - "RunListResponse": { - "type": "object", - "additionalProperties": false, - "properties": { - "runs": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "runID": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "appID": { - "type": "string" - }, - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "status": { - "type": "string", - "enum": [ - "created", - "started", - "idled", - "finished", - "skipped" - ] - }, - "progress": { - "type": "object", - "additionalProperties": false, - "properties": { - "expectedNbOfEvents": { - "type": "integer" - }, - "receivedNbOfEvents": { - "type": "integer" - } - } - }, - "outcome": { - "type": "string", - "enum": [ - "success", - "failure", - "processing" - ] - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - }, - "reason": { - "type": "string", - "description": "Explains the result of outcome." - }, - "reasonCode": { - "type": "string", - "description": "An identifier that pairs with the outcome reason.", - "enum": [ - "internal", - "critical", - "no_events", - "too_many_errors", - "ok", - "discarded", - "blocking" - ] - }, - "type": { - "type": "string", - "enum": [ - "reindex", - "update", - "discover" - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "startedAt": { - "type": "string", - "description": "Date of start (RFC3339 format)." - }, - "finishedAt": { - "type": "string", - "description": "Date of finish (RFC3339 format)." - } - }, - "required": [ - "runID", - "appID", - "taskID", - "status", - "type", - "createdAt" - ] - } - }, - "pagination": { - "type": "object", - "additionalProperties": false, - "properties": { - "nbPages": { - "type": "integer" - }, - "page": { - "type": "integer" - }, - "nbItems": { - "type": "integer" - }, - "itemsPerPage": { - "type": "integer" - } - }, - "required": [ - "nbPages", - "page", - "nbItems", - "itemsPerPage" - ] - }, - "window": { - "type": "object", - "additionalProperties": false, - "description": "The window parameter represents the holds the dates used to query the Observability data from the database in a given window.", - "properties": { - "startDate": { - "type": "string", - "description": "A date in format RFC3339 representing the oldest possible data in query window." - }, - "endDate": { - "type": "string", - "description": "A date in format RFC3339 representing the newest possible data in query window." - } - }, - "required": [ - "startDate", - "endDate" - ] - } - }, - "required": [ - "runs", - "pagination", - "window" - ] - }, - "EventStatus": { - "type": "string", - "enum": [ - "created", - "started", - "retried", - "failed", - "succeeded", - "critical" - ] - }, - "EventType": { - "type": "string", - "enum": [ - "fetch", - "record", - "log", - "transform" - ] - }, - "eventSortKeys": { - "type": "string", - "description": "Used to sort the Event list endpoint.", - "enum": [ - "status", - "type", - "publishedAt" - ] - }, - "eventID": { - "type": "string", - "description": "The event UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "publishedAt": { - "type": "string", - "description": "Date of publish (RFC3339 format)." - }, - "Event": { - "type": "object", - "description": "An event describe a step of the task execution flow..", - "additionalProperties": false, - "properties": { - "eventID": { - "type": "string", - "description": "The event UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "runID": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "parentID": { - "type": "string", - "description": "The parent event, the cause of this event.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "status": { - "type": "string", - "enum": [ - "created", - "started", - "retried", - "failed", - "succeeded", - "critical" - ] - }, - "type": { - "type": "string", - "enum": [ - "fetch", - "record", - "log", - "transform" - ] - }, - "batchSize": { - "type": "integer", - "description": "The extracted record batch size.", - "example": 10, - "minimum": 0, - "multipleOf": 1 - }, - "data": { - "type": "object", - "additionalProperties": true - }, - "publishedAt": { - "type": "string", - "description": "Date of publish (RFC3339 format)." - } - }, - "required": [ - "eventID", - "runID", - "status", - "type", - "batchSize", - "publishedAt" - ] - } - }, - "responses": { - "BadRequest": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "FeatureNotEnabled": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "MethodNotAllowed": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "IndexNotFound": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "servers": [ - { - "url": "https://data.{region}.algolia.com", - "variables": { - "region": { - "enum": [ - "eu", - "us" - ], - "default": "us" - } - } - } - ], - "security": [ - { - "appId": [], - "apiKey": [] - } - ], - "tags": [ - { - "name": "authentications", - "x-displayName": "Authentications", - "description": "An authentication describe the way we connect to Algolia, or any supported connector." - }, - { - "name": "destinations", - "x-displayName": "Destinations", - "description": "A destination refers to an Algolia product (Search, Insight, Recommend, ...)." - }, - { - "name": "observability", - "x-displayName": "Observability", - "description": "The observability API associates a run to a task execution." - }, - { - "name": "sources", - "x-displayName": "Sources", - "description": "A source describe the platform informations." - }, - { - "name": "tasks", - "x-displayName": "Tasks", - "description": "A Task describe how we fetch the data (onDemand, schedule, subscription) from a source and how we index it on the Algolia side." - } - ], - "paths": { - "/1{path}": { - "get": { - "operationId": "customGet", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "operationId": "customPost", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "operationId": "customPut", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "operationId": "customDelete", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/authentications": { - "get": { - "tags": [ - "authentications" - ], - "summary": "Get a list of authentications.", - "description": "Get a list of authentications for the given query parameters, with pagination details.", - "operationId": "getAuthentications", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "itemsPerPage", - "in": "query", - "description": "The number of items per page to return.", - "required": false, - "schema": { - "type": "integer" - } - }, - { - "name": "page", - "in": "query", - "description": "The page number to fetch, starting at 1.", - "required": false, - "schema": { - "type": "integer" - } - }, - { - "name": "type", - "in": "query", - "description": "The type of the authentications to retrieve.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "Type of the Authentication, defines what kind of object is stored in the input.", - "enum": [ - "googleServiceAccount", - "basic", - "apiKey", - "oauth", - "algolia" - ] - }, - "example": "basic,oauth" - } - }, - { - "name": "platform", - "in": "query", - "description": "The platform of the authentications to retrieve.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "oneOf": [ - { - "type": "string", - "nullable": true, - "description": "Describe which platform the Authentication is used for.", - "enum": [ - "bigcommerce", - "commercetools" - ] - }, - { - "type": "string", - "description": "Used to filter Authentication without platform property.", - "enum": [ - "none" - ] - } - ] - }, - "example": "commercetools,none" - } - }, - { - "name": "sort", - "in": "query", - "description": "The key by which the list should be sorted.", - "required": false, - "schema": { - "type": "string", - "description": "Used to sort the Authentication list endpoint.", - "enum": [ - "name", - "auth_type", - "platform", - "updatedAt", - "createdAt" - ] - } - }, - { - "name": "order", - "in": "query", - "description": "The order of the returned list.", - "required": false, - "schema": { - "type": "string", - "description": "Used to order a sorted request.", - "enum": [ - "asc", - "desc" - ] - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "listAuthenticationsResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "authentications": { - "type": "array", - "items": { - "type": "object", - "description": "An authentication is used to login into a Source or a Destination, with obfuscated input.", - "additionalProperties": false, - "properties": { - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "type": { - "type": "string", - "description": "Type of the Authentication, defines what kind of object is stored in the input.", - "enum": [ - "googleServiceAccount", - "basic", - "apiKey", - "oauth", - "algolia" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "platform": { - "type": "string", - "nullable": true, - "description": "Describe which platform the Authentication is used for.", - "enum": [ - "bigcommerce", - "commercetools" - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "description": "Authentication input to connect to a Google service (e.g. BigQuery).", - "additionalProperties": false, - "properties": { - "clientEmail": { - "type": "string", - "description": "Email address of the Service Account.", - "example": "service-account-name@project-id.iam.gserviceaccount.com" - }, - "privateKey": { - "type": "string", - "description": "Private key of the Service Account." - } - } - }, - { - "type": "object", - "description": "Authentication input for Basic login with username and password.", - "additionalProperties": false, - "properties": { - "username": { - "type": "string" - }, - "password": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input used for token credentials.", - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input for OAuth login.", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The OAuth endpoint URL." - }, - "client_id": { - "type": "string", - "description": "The clientID." - }, - "client_secret": { - "type": "string", - "description": "The secret." - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "appID": { - "type": "string", - "description": "Algolia Application ID." - }, - "apiKey": { - "type": "string", - "description": "Algolia API Key, with the correct rights to push to an index and change settings." - } - } - } - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "authenticationID", - "type", - "name", - "input", - "createdAt" - ] - } - }, - "pagination": { - "type": "object", - "additionalProperties": false, - "properties": { - "nbPages": { - "type": "integer" - }, - "page": { - "type": "integer" - }, - "nbItems": { - "type": "integer" - }, - "itemsPerPage": { - "type": "integer" - } - }, - "required": [ - "nbPages", - "page", - "nbItems", - "itemsPerPage" - ] - } - }, - "required": [ - "authentications", - "pagination" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "tags": [ - "authentications" - ], - "summary": "Create a authentication.", - "description": "Create a authentication.", - "operationId": "createAuthentication", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "requestBody": { - "description": "", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "The payload when creating an authentication.", - "additionalProperties": false, - "properties": { - "type": { - "type": "string", - "description": "Type of the Authentication, defines what kind of object is stored in the input.", - "enum": [ - "googleServiceAccount", - "basic", - "apiKey", - "oauth", - "algolia" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "platform": { - "type": "string", - "nullable": true, - "description": "Describe which platform the Authentication is used for.", - "enum": [ - "bigcommerce", - "commercetools" - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "description": "Authentication input to connect to a Google service (e.g. BigQuery).", - "additionalProperties": false, - "properties": { - "clientEmail": { - "type": "string", - "description": "Email address of the Service Account.", - "example": "service-account-name@project-id.iam.gserviceaccount.com" - }, - "privateKey": { - "type": "string", - "description": "Private key of the Service Account." - } - }, - "required": [ - "clientEmail", - "privateKey" - ] - }, - { - "type": "object", - "description": "Authentication input for Basic login with username and password.", - "additionalProperties": false, - "properties": { - "username": { - "type": "string" - }, - "password": { - "type": "string" - } - }, - "required": [ - "username", - "password" - ] - }, - { - "type": "object", - "description": "Authentication input used for token credentials.", - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - } - }, - "required": [ - "key" - ] - }, - { - "type": "object", - "description": "Authentication input for OAuth login.", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The OAuth endpoint URL." - }, - "client_id": { - "type": "string", - "description": "The clientID." - }, - "client_secret": { - "type": "string", - "description": "The secret." - } - }, - "required": [ - "url", - "client_id", - "client_secret" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "appID": { - "type": "string", - "description": "Algolia Application ID." - }, - "apiKey": { - "type": "string", - "description": "Algolia API Key, with the correct rights to push to an index and change settings." - } - }, - "required": [ - "appID", - "apiKey" - ] - } - ] - } - }, - "required": [ - "type", - "name", - "input" - ] - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "Response from the API when the Authentication is successfully created.", - "additionalProperties": false, - "properties": { - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - } - }, - "required": [ - "authenticationID", - "name", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/authentications/search": { - "post": { - "tags": [ - "authentications" - ], - "summary": "Search among authentications.", - "description": "Search among authentications with a defined set of parameters.", - "operationId": "searchAuthentications", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "description": "Payload to search for multiple authentications, based on the given `authenticationIDs`.", - "properties": { - "authenticationIDs": { - "type": "array", - "items": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - "required": [ - "authenticationIDs" - ] - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "searchAuthenticationsResponse", - "type": "array", - "items": { - "type": "object", - "description": "An authentication is used to login into a Source or a Destination, with obfuscated input.", - "additionalProperties": false, - "properties": { - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "type": { - "type": "string", - "description": "Type of the Authentication, defines what kind of object is stored in the input.", - "enum": [ - "googleServiceAccount", - "basic", - "apiKey", - "oauth", - "algolia" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "platform": { - "type": "string", - "nullable": true, - "description": "Describe which platform the Authentication is used for.", - "enum": [ - "bigcommerce", - "commercetools" - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "description": "Authentication input to connect to a Google service (e.g. BigQuery).", - "additionalProperties": false, - "properties": { - "clientEmail": { - "type": "string", - "description": "Email address of the Service Account.", - "example": "service-account-name@project-id.iam.gserviceaccount.com" - }, - "privateKey": { - "type": "string", - "description": "Private key of the Service Account." - } - } - }, - { - "type": "object", - "description": "Authentication input for Basic login with username and password.", - "additionalProperties": false, - "properties": { - "username": { - "type": "string" - }, - "password": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input used for token credentials.", - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input for OAuth login.", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The OAuth endpoint URL." - }, - "client_id": { - "type": "string", - "description": "The clientID." - }, - "client_secret": { - "type": "string", - "description": "The secret." - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "appID": { - "type": "string", - "description": "Algolia Application ID." - }, - "apiKey": { - "type": "string", - "description": "Algolia API Key, with the correct rights to push to an index and change settings." - } - } - } - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "authenticationID", - "type", - "name", - "input", - "createdAt" - ] - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/authentications/{authenticationID}": { - "get": { - "tags": [ - "authentications" - ], - "summary": "Get a authentication.", - "description": "Get the authentication of the given authenticationID.", - "operationId": "getAuthentication", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "authenticationID", - "in": "path", - "required": true, - "description": "The authentication UUID.", - "schema": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "An authentication is used to login into a Source or a Destination, with obfuscated input.", - "additionalProperties": false, - "properties": { - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "type": { - "type": "string", - "description": "Type of the Authentication, defines what kind of object is stored in the input.", - "enum": [ - "googleServiceAccount", - "basic", - "apiKey", - "oauth", - "algolia" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "platform": { - "type": "string", - "nullable": true, - "description": "Describe which platform the Authentication is used for.", - "enum": [ - "bigcommerce", - "commercetools" - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "description": "Authentication input to connect to a Google service (e.g. BigQuery).", - "additionalProperties": false, - "properties": { - "clientEmail": { - "type": "string", - "description": "Email address of the Service Account.", - "example": "service-account-name@project-id.iam.gserviceaccount.com" - }, - "privateKey": { - "type": "string", - "description": "Private key of the Service Account." - } - } - }, - { - "type": "object", - "description": "Authentication input for Basic login with username and password.", - "additionalProperties": false, - "properties": { - "username": { - "type": "string" - }, - "password": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input used for token credentials.", - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input for OAuth login.", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The OAuth endpoint URL." - }, - "client_id": { - "type": "string", - "description": "The clientID." - }, - "client_secret": { - "type": "string", - "description": "The secret." - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "appID": { - "type": "string", - "description": "Algolia Application ID." - }, - "apiKey": { - "type": "string", - "description": "Algolia API Key, with the correct rights to push to an index and change settings." - } - } - } - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "authenticationID", - "type", - "name", - "input", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "patch": { - "tags": [ - "authentications" - ], - "summary": "Update a authentication.", - "description": "Update the authentication of the given authenticationID.", - "operationId": "updateAuthentication", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "authenticationID", - "in": "path", - "required": true, - "description": "The authentication UUID.", - "schema": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "Payload to partially update an Authentication.", - "additionalProperties": false, - "properties": { - "type": { - "type": "string", - "description": "Type of the Authentication, defines what kind of object is stored in the input.", - "enum": [ - "googleServiceAccount", - "basic", - "apiKey", - "oauth", - "algolia" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "platform": { - "type": "string", - "nullable": true, - "description": "Describe which platform the Authentication is used for.", - "enum": [ - "bigcommerce", - "commercetools" - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "description": "Authentication input to connect to a Google service (e.g. BigQuery).", - "additionalProperties": false, - "properties": { - "clientEmail": { - "type": "string", - "description": "Email address of the Service Account.", - "example": "service-account-name@project-id.iam.gserviceaccount.com" - }, - "privateKey": { - "type": "string", - "description": "Private key of the Service Account." - } - } - }, - { - "type": "object", - "description": "Authentication input for Basic login with username and password.", - "additionalProperties": false, - "properties": { - "username": { - "type": "string" - }, - "password": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input used for token credentials.", - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - } - } - }, - { - "type": "object", - "description": "Authentication input for OAuth login.", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The OAuth endpoint URL." - }, - "client_id": { - "type": "string", - "description": "The clientID." - }, - "client_secret": { - "type": "string", - "description": "The secret." - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "appID": { - "type": "string", - "description": "Algolia Application ID." - }, - "apiKey": { - "type": "string", - "description": "Algolia API Key, with the correct rights to push to an index and change settings." - } - } - } - ] - } - } - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "description": "Response from the API when the Authentication is successfully updated.", - "properties": { - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "authenticationID", - "name", - "updatedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "authentications" - ], - "summary": "Delete a authentication.", - "description": "Soft delete the authentication of the given authenticationID.", - "operationId": "deleteAuthentication", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "authenticationID", - "in": "path", - "required": true, - "description": "The authentication UUID.", - "schema": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "deletedAt": { - "type": "string", - "description": "Date of deletion (RFC3339 format)." - } - }, - "required": [ - "deletedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/destinations": { - "get": { - "tags": [ - "destinations" - ], - "summary": "Get a list of destinations.", - "description": "Get a list of destinations for the given query parameters, with pagination details.", - "operationId": "getDestinations", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "itemsPerPage", - "in": "query", - "description": "The number of items per page to return.", - "required": false, - "schema": { - "type": "integer" - } - }, - { - "name": "page", - "in": "query", - "description": "The page number to fetch, starting at 1.", - "required": false, - "schema": { - "type": "integer" - } - }, - { - "name": "type", - "in": "query", - "description": "The type of the destinations to retrive.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "Type of the Destination, defines in which Algolia product the data will be stored.", - "enum": [ - "search", - "insights", - "flow" - ] - }, - "example": "search" - } - }, - { - "name": "authenticationID", - "in": "query", - "description": "The authenticationIDs of the destinations to retrive.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - { - "name": "sort", - "in": "query", - "description": "The key by which the list should be sorted.", - "required": false, - "schema": { - "type": "string", - "description": "Used to sort the Destination list endpoint.", - "enum": [ - "name", - "type", - "updatedAt", - "createdAt" - ] - } - }, - { - "name": "order", - "in": "query", - "description": "The order of the returned list.", - "required": false, - "schema": { - "type": "string", - "description": "Used to order a sorted request.", - "enum": [ - "asc", - "desc" - ] - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "listDestinationsResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "destinations": { - "type": "array", - "items": { - "type": "object", - "description": "A destination describe how the data is indexed on the Algolia side.", - "additionalProperties": false, - "properties": { - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "type": { - "type": "string", - "description": "Type of the Destination, defines in which Algolia product the data will be stored.", - "enum": [ - "search", - "insights", - "flow" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexPrefix": { - "type": "string", - "description": "The prefix of the final index name." - } - }, - "required": [ - "indexPrefix" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "description": "The index name to store data in." - }, - "recordType": { - "type": "string", - "description": "Determines the indexing strategy to use for a given e-commerce source.", - "enum": [ - "product", - "variant" - ] - }, - "attributesToExclude": { - "type": "array", - "description": "Determines the attributes to exclude from an Algolia record.\nTo remove nested element, you can separate the path to the element with dots (`.`):\n - \"foo.bar\": will remove `bar` from `foo`.\nTo remove elements from an array, you can use the following:\n - \"foo.[0].bar\": will only remove `bar` from the first element of `foo`.\n - \"foo.[*].bar\": will remove `bar` from every elements of `foo`.\n", - "items": { - "type": "string" - } - } - }, - "required": [ - "indexName" - ] - } - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "required": [ - "destinationID", - "type", - "name", - "input", - "createdAt" - ] - } - }, - "pagination": { - "type": "object", - "additionalProperties": false, - "properties": { - "nbPages": { - "type": "integer" - }, - "page": { - "type": "integer" - }, - "nbItems": { - "type": "integer" - }, - "itemsPerPage": { - "type": "integer" - } - }, - "required": [ - "nbPages", - "page", - "nbItems", - "itemsPerPage" - ] - } - }, - "required": [ - "destinations", - "pagination" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "tags": [ - "destinations" - ], - "summary": "Create a destination.", - "description": "Create a destination.", - "operationId": "createDestination", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "requestBody": { - "description": "", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "description": "The payload when creating a destination.", - "properties": { - "type": { - "type": "string", - "description": "Type of the Destination, defines in which Algolia product the data will be stored.", - "enum": [ - "search", - "insights", - "flow" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexPrefix": { - "type": "string", - "description": "The prefix of the final index name." - } - }, - "required": [ - "indexPrefix" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "description": "The index name to store data in." - }, - "recordType": { - "type": "string", - "description": "Determines the indexing strategy to use for a given e-commerce source.", - "enum": [ - "product", - "variant" - ] - }, - "attributesToExclude": { - "type": "array", - "description": "Determines the attributes to exclude from an Algolia record.\nTo remove nested element, you can separate the path to the element with dots (`.`):\n - \"foo.bar\": will remove `bar` from `foo`.\nTo remove elements from an array, you can use the following:\n - \"foo.[0].bar\": will only remove `bar` from the first element of `foo`.\n - \"foo.[*].bar\": will remove `bar` from every elements of `foo`.\n", - "items": { - "type": "string" - } - } - }, - "required": [ - "indexName" - ] - } - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "required": [ - "type", - "name", - "input" - ] - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "description": "Response from the API when the Destination is successfully created.", - "properties": { - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - } - }, - "required": [ - "destinationID", - "name", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/destinations/search": { - "post": { - "tags": [ - "destinations" - ], - "summary": "Search among destinations.", - "description": "Search among destinations with a defined set of parameters.", - "operationId": "searchDestinations", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "description": "Payload to search for multiple destinations, based on the given `destinationIDs`.", - "properties": { - "destinationIDs": { - "type": "array", - "items": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - "required": [ - "destinationIDs" - ] - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "searchDestinationsResponse", - "type": "array", - "items": { - "type": "object", - "description": "A destination describe how the data is indexed on the Algolia side.", - "additionalProperties": false, - "properties": { - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "type": { - "type": "string", - "description": "Type of the Destination, defines in which Algolia product the data will be stored.", - "enum": [ - "search", - "insights", - "flow" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexPrefix": { - "type": "string", - "description": "The prefix of the final index name." - } - }, - "required": [ - "indexPrefix" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "description": "The index name to store data in." - }, - "recordType": { - "type": "string", - "description": "Determines the indexing strategy to use for a given e-commerce source.", - "enum": [ - "product", - "variant" - ] - }, - "attributesToExclude": { - "type": "array", - "description": "Determines the attributes to exclude from an Algolia record.\nTo remove nested element, you can separate the path to the element with dots (`.`):\n - \"foo.bar\": will remove `bar` from `foo`.\nTo remove elements from an array, you can use the following:\n - \"foo.[0].bar\": will only remove `bar` from the first element of `foo`.\n - \"foo.[*].bar\": will remove `bar` from every elements of `foo`.\n", - "items": { - "type": "string" - } - } - }, - "required": [ - "indexName" - ] - } - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "required": [ - "destinationID", - "type", - "name", - "input", - "createdAt" - ] - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/destinations/{destinationID}": { - "get": { - "tags": [ - "destinations" - ], - "summary": "Get a destination.", - "description": "Get the destination of the given destinationID.", - "operationId": "getDestination", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "destinationID", - "in": "path", - "required": true, - "description": "The destination UUID.", - "schema": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "A destination describe how the data is indexed on the Algolia side.", - "additionalProperties": false, - "properties": { - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "type": { - "type": "string", - "description": "Type of the Destination, defines in which Algolia product the data will be stored.", - "enum": [ - "search", - "insights", - "flow" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexPrefix": { - "type": "string", - "description": "The prefix of the final index name." - } - }, - "required": [ - "indexPrefix" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "description": "The index name to store data in." - }, - "recordType": { - "type": "string", - "description": "Determines the indexing strategy to use for a given e-commerce source.", - "enum": [ - "product", - "variant" - ] - }, - "attributesToExclude": { - "type": "array", - "description": "Determines the attributes to exclude from an Algolia record.\nTo remove nested element, you can separate the path to the element with dots (`.`):\n - \"foo.bar\": will remove `bar` from `foo`.\nTo remove elements from an array, you can use the following:\n - \"foo.[0].bar\": will only remove `bar` from the first element of `foo`.\n - \"foo.[*].bar\": will remove `bar` from every elements of `foo`.\n", - "items": { - "type": "string" - } - } - }, - "required": [ - "indexName" - ] - } - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "required": [ - "destinationID", - "type", - "name", - "input", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "patch": { - "tags": [ - "destinations" - ], - "summary": "Update a destination.", - "description": "Update the destination of the given destinationID.", - "operationId": "updateDestination", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "destinationID", - "in": "path", - "required": true, - "description": "The destination UUID.", - "schema": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "description": "Payload to partially update a Destination.", - "properties": { - "type": { - "type": "string", - "description": "Type of the Destination, defines in which Algolia product the data will be stored.", - "enum": [ - "search", - "insights", - "flow" - ] - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexPrefix": { - "type": "string", - "description": "The prefix of the final index name." - } - }, - "required": [ - "indexPrefix" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "description": "The index name to store data in." - }, - "recordType": { - "type": "string", - "description": "Determines the indexing strategy to use for a given e-commerce source.", - "enum": [ - "product", - "variant" - ] - }, - "attributesToExclude": { - "type": "array", - "description": "Determines the attributes to exclude from an Algolia record.\nTo remove nested element, you can separate the path to the element with dots (`.`):\n - \"foo.bar\": will remove `bar` from `foo`.\nTo remove elements from an array, you can use the following:\n - \"foo.[0].bar\": will only remove `bar` from the first element of `foo`.\n - \"foo.[*].bar\": will remove `bar` from every elements of `foo`.\n", - "items": { - "type": "string" - } - } - }, - "required": [ - "indexName" - ] - } - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "description": "Response from the API when the Destination is successfully updated.", - "properties": { - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string", - "description": "An human readable name describing the object." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "destinationID", - "name", - "updatedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "destinations" - ], - "summary": "Delete a destination.", - "description": "Soft delete the destination of the given destinationID.", - "operationId": "deleteDestination", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "destinationID", - "in": "path", - "required": true, - "description": "The destination UUID.", - "schema": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "deletedAt": { - "type": "string", - "description": "Date of deletion (RFC3339 format)." - } - }, - "required": [ - "deletedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/sources": { - "get": { - "tags": [ - "sources" - ], - "summary": "Get a list of sources.", - "description": "Get a list of sources for the given query parameters, with pagination details.", - "operationId": "getSources", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "itemsPerPage", - "in": "query", - "description": "The number of items per page to return.", - "required": false, - "schema": { - "type": "integer" - } - }, - { - "name": "page", - "in": "query", - "description": "The page number to fetch, starting at 1.", - "required": false, - "schema": { - "type": "integer" - } - }, - { - "name": "type", - "in": "query", - "description": "The type of the sources to retrieve.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "bigcommerce", - "commercetools", - "json", - "csv", - "bigquery", - "docker" - ] - }, - "example": "commercetools,bigcommerce" - } - }, - { - "name": "authenticationID", - "in": "query", - "description": "The authenticationIDs of the sources to retrieve. 'none' returns sources that doesn't have an authentication.\n", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "example": [ - "10000000-0a75-4000-a000-000000000001", - "none" - ] - } - }, - { - "name": "sort", - "in": "query", - "description": "The key by which the list should be sorted.", - "required": false, - "schema": { - "type": "string", - "description": "Used to sort the Source list endpoint.", - "enum": [ - "name", - "type", - "updatedAt", - "createdAt" - ] - } - }, - { - "name": "order", - "in": "query", - "description": "The order of the returned list.", - "required": false, - "schema": { - "type": "string", - "description": "Used to order a sorted request.", - "enum": [ - "asc", - "desc" - ] - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "listSourcesResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "sources": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "type": { - "type": "string", - "enum": [ - "bigcommerce", - "commercetools", - "json", - "csv", - "bigquery", - "docker" - ] - }, - "name": { - "type": "string" - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeKeys": { - "type": "array", - "items": { - "description": "Unique and immutable key of the referenced Store.", - "type": "string" - } - }, - "locales": { - "type": "array", - "description": "Array of locales that must match the following pattern: ^[a-z]{2}(-[A-Z]{2})?$. For example [\"fr-FR\", \"en\"].\n", - "items": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "projectKey": { - "type": "string" - }, - "fallbackIsInStockValue": { - "type": "boolean", - "default": true, - "description": "Determines the value that will be stored in the Algolia record if there's no inventory information on the product.\n" - }, - "customFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - } - }, - "required": [ - "url", - "projectKey" - ], - "x-discriminator-fields": [ - "projectKey" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeHash": { - "type": "string", - "description": "The store hash identifying the store the shopper is signing in to." - }, - "channel": { - "type": "object", - "additionalProperties": false, - "properties": { - "id": { - "type": "integer", - "description": "The ID of the bigcommerce channel." - }, - "currencies": { - "type": "array", - "description": "An array of currencies for the given channel `ID`, a currency is a trigram string that represents the currency code.", - "example": [ - "usd", - "eur" - ], - "items": { - "type": "string", - "example": "usd" - } - } - }, - "required": [ - "id" - ] - }, - "customFields": { - "type": "array", - "items": { - "type": "string" - } - }, - "productMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - }, - "variantMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - } - }, - "required": [ - "storeHash" - ], - "x-discriminator-fields": [ - "storeHash" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "mapping": { - "type": "object", - "description": "Mapping of type for every column. For example {\"myColumn\": \"boolean\", \"myOtherColumn\": \"json\"}.\n", - "additionalProperties": { - "type": "string", - "enum": [ - "string", - "integer", - "float", - "boolean", - "json" - ] - } - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - }, - "delimiter": { - "type": "string", - "minLength": 1, - "maxLength": 1, - "default": ",", - "description": "The character used to split the value on each line, default to a comma (\\r, \\n, 0xFFFD, and space are forbidden)." - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "projectID": { - "type": "string", - "description": "Project ID of the BigQuery Source." - }, - "datasetID": { - "type": "string", - "description": "Dataset ID of the BigQuery Source." - }, - "dataType": { - "type": "string", - "enum": [ - "ga4", - "ga360" - ] - }, - "table": { - "type": "string", - "description": "Table name (for default BQ)." - }, - "tablePrefix": { - "type": "string", - "description": "Table prefix (for Google Analytics)." - }, - "customSQLRequest": { - "type": "string", - "description": "Custom SQL request to extract data from the BigQuery table." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - } - }, - "required": [ - "projectID", - "datasetID" - ], - "x-discriminator-fields": [ - "projectID" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "imageType": { - "type": "string", - "enum": [ - "singer", - "custom", - "airbyte" - ], - "description": "The type of the image." - }, - "registry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "image": { - "type": "string", - "description": "The name of the image to pull.", - "example": "algolia/zendesk" - }, - "version": { - "type": "string", - "description": "The version of the image, defaults to `latest`.", - "example": "v2.1.0" - }, - "configuration": { - "type": "object", - "description": "The configuration of the spec." - } - }, - "required": [ - "registry", - "image", - "imageType", - "configuration" - ] - } - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "sourceID", - "type", - "name", - "input", - "createdAt" - ] - } - }, - "pagination": { - "type": "object", - "additionalProperties": false, - "properties": { - "nbPages": { - "type": "integer" - }, - "page": { - "type": "integer" - }, - "nbItems": { - "type": "integer" - }, - "itemsPerPage": { - "type": "integer" - } - }, - "required": [ - "nbPages", - "page", - "nbItems", - "itemsPerPage" - ] - } - }, - "required": [ - "sources", - "pagination" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "tags": [ - "sources" - ], - "summary": "Create a source.", - "description": "Create a source.", - "operationId": "createSource", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "requestBody": { - "description": "", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "type": "string", - "enum": [ - "bigcommerce", - "commercetools", - "json", - "csv", - "bigquery", - "docker" - ] - }, - "name": { - "type": "string" - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeKeys": { - "type": "array", - "items": { - "description": "Unique and immutable key of the referenced Store.", - "type": "string" - } - }, - "locales": { - "type": "array", - "description": "Array of locales that must match the following pattern: ^[a-z]{2}(-[A-Z]{2})?$. For example [\"fr-FR\", \"en\"].\n", - "items": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "projectKey": { - "type": "string" - }, - "fallbackIsInStockValue": { - "type": "boolean", - "default": true, - "description": "Determines the value that will be stored in the Algolia record if there's no inventory information on the product.\n" - }, - "customFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - } - }, - "required": [ - "url", - "projectKey" - ], - "x-discriminator-fields": [ - "projectKey" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeHash": { - "type": "string", - "description": "The store hash identifying the store the shopper is signing in to." - }, - "channel": { - "type": "object", - "additionalProperties": false, - "properties": { - "id": { - "type": "integer", - "description": "The ID of the bigcommerce channel." - }, - "currencies": { - "type": "array", - "description": "An array of currencies for the given channel `ID`, a currency is a trigram string that represents the currency code.", - "example": [ - "usd", - "eur" - ], - "items": { - "type": "string", - "example": "usd" - } - } - }, - "required": [ - "id" - ] - }, - "customFields": { - "type": "array", - "items": { - "type": "string" - } - }, - "productMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - }, - "variantMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - } - }, - "required": [ - "storeHash" - ], - "x-discriminator-fields": [ - "storeHash" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "mapping": { - "type": "object", - "description": "Mapping of type for every column. For example {\"myColumn\": \"boolean\", \"myOtherColumn\": \"json\"}.\n", - "additionalProperties": { - "type": "string", - "enum": [ - "string", - "integer", - "float", - "boolean", - "json" - ] - } - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - }, - "delimiter": { - "type": "string", - "minLength": 1, - "maxLength": 1, - "default": ",", - "description": "The character used to split the value on each line, default to a comma (\\r, \\n, 0xFFFD, and space are forbidden)." - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "projectID": { - "type": "string", - "description": "Project ID of the BigQuery Source." - }, - "datasetID": { - "type": "string", - "description": "Dataset ID of the BigQuery Source." - }, - "dataType": { - "type": "string", - "enum": [ - "ga4", - "ga360" - ] - }, - "table": { - "type": "string", - "description": "Table name (for default BQ)." - }, - "tablePrefix": { - "type": "string", - "description": "Table prefix (for Google Analytics)." - }, - "customSQLRequest": { - "type": "string", - "description": "Custom SQL request to extract data from the BigQuery table." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - } - }, - "required": [ - "projectID", - "datasetID" - ], - "x-discriminator-fields": [ - "projectID" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "imageType": { - "type": "string", - "enum": [ - "singer", - "custom", - "airbyte" - ], - "description": "The type of the image." - }, - "registry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "image": { - "type": "string", - "description": "The name of the image to pull.", - "example": "algolia/zendesk" - }, - "version": { - "type": "string", - "description": "The version of the image, defaults to `latest`.", - "example": "v2.1.0" - }, - "configuration": { - "type": "object", - "description": "The configuration of the spec." - } - }, - "required": [ - "registry", - "image", - "imageType", - "configuration" - ] - } - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - "required": [ - "type", - "name", - "input" - ] - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string" - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - } - }, - "required": [ - "sourceID", - "name", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/sources/search": { - "post": { - "tags": [ - "sources" - ], - "summary": "Search among sources.", - "description": "Search among sources with a defined set of parameters.", - "operationId": "searchSources", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceIDs": { - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "sourceIDs" - ] - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "searchSourcesResponse", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "type": { - "type": "string", - "enum": [ - "bigcommerce", - "commercetools", - "json", - "csv", - "bigquery", - "docker" - ] - }, - "name": { - "type": "string" - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeKeys": { - "type": "array", - "items": { - "description": "Unique and immutable key of the referenced Store.", - "type": "string" - } - }, - "locales": { - "type": "array", - "description": "Array of locales that must match the following pattern: ^[a-z]{2}(-[A-Z]{2})?$. For example [\"fr-FR\", \"en\"].\n", - "items": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "projectKey": { - "type": "string" - }, - "fallbackIsInStockValue": { - "type": "boolean", - "default": true, - "description": "Determines the value that will be stored in the Algolia record if there's no inventory information on the product.\n" - }, - "customFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - } - }, - "required": [ - "url", - "projectKey" - ], - "x-discriminator-fields": [ - "projectKey" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeHash": { - "type": "string", - "description": "The store hash identifying the store the shopper is signing in to." - }, - "channel": { - "type": "object", - "additionalProperties": false, - "properties": { - "id": { - "type": "integer", - "description": "The ID of the bigcommerce channel." - }, - "currencies": { - "type": "array", - "description": "An array of currencies for the given channel `ID`, a currency is a trigram string that represents the currency code.", - "example": [ - "usd", - "eur" - ], - "items": { - "type": "string", - "example": "usd" - } - } - }, - "required": [ - "id" - ] - }, - "customFields": { - "type": "array", - "items": { - "type": "string" - } - }, - "productMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - }, - "variantMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - } - }, - "required": [ - "storeHash" - ], - "x-discriminator-fields": [ - "storeHash" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "mapping": { - "type": "object", - "description": "Mapping of type for every column. For example {\"myColumn\": \"boolean\", \"myOtherColumn\": \"json\"}.\n", - "additionalProperties": { - "type": "string", - "enum": [ - "string", - "integer", - "float", - "boolean", - "json" - ] - } - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - }, - "delimiter": { - "type": "string", - "minLength": 1, - "maxLength": 1, - "default": ",", - "description": "The character used to split the value on each line, default to a comma (\\r, \\n, 0xFFFD, and space are forbidden)." - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "projectID": { - "type": "string", - "description": "Project ID of the BigQuery Source." - }, - "datasetID": { - "type": "string", - "description": "Dataset ID of the BigQuery Source." - }, - "dataType": { - "type": "string", - "enum": [ - "ga4", - "ga360" - ] - }, - "table": { - "type": "string", - "description": "Table name (for default BQ)." - }, - "tablePrefix": { - "type": "string", - "description": "Table prefix (for Google Analytics)." - }, - "customSQLRequest": { - "type": "string", - "description": "Custom SQL request to extract data from the BigQuery table." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - } - }, - "required": [ - "projectID", - "datasetID" - ], - "x-discriminator-fields": [ - "projectID" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "imageType": { - "type": "string", - "enum": [ - "singer", - "custom", - "airbyte" - ], - "description": "The type of the image." - }, - "registry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "image": { - "type": "string", - "description": "The name of the image to pull.", - "example": "algolia/zendesk" - }, - "version": { - "type": "string", - "description": "The version of the image, defaults to `latest`.", - "example": "v2.1.0" - }, - "configuration": { - "type": "object", - "description": "The configuration of the spec." - } - }, - "required": [ - "registry", - "image", - "imageType", - "configuration" - ] - } - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "sourceID", - "type", - "name", - "input", - "createdAt" - ] - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/sources/{sourceID}": { - "get": { - "tags": [ - "sources" - ], - "summary": "Get a source.", - "description": "Get the source of the given sourceID.", - "operationId": "getSource", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "sourceID", - "in": "path", - "required": true, - "description": "The source UUID.", - "schema": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "type": { - "type": "string", - "enum": [ - "bigcommerce", - "commercetools", - "json", - "csv", - "bigquery", - "docker" - ] - }, - "name": { - "type": "string" - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeKeys": { - "type": "array", - "items": { - "description": "Unique and immutable key of the referenced Store.", - "type": "string" - } - }, - "locales": { - "type": "array", - "description": "Array of locales that must match the following pattern: ^[a-z]{2}(-[A-Z]{2})?$. For example [\"fr-FR\", \"en\"].\n", - "items": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "projectKey": { - "type": "string" - }, - "fallbackIsInStockValue": { - "type": "boolean", - "default": true, - "description": "Determines the value that will be stored in the Algolia record if there's no inventory information on the product.\n" - }, - "customFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - } - }, - "required": [ - "url", - "projectKey" - ], - "x-discriminator-fields": [ - "projectKey" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeHash": { - "type": "string", - "description": "The store hash identifying the store the shopper is signing in to." - }, - "channel": { - "type": "object", - "additionalProperties": false, - "properties": { - "id": { - "type": "integer", - "description": "The ID of the bigcommerce channel." - }, - "currencies": { - "type": "array", - "description": "An array of currencies for the given channel `ID`, a currency is a trigram string that represents the currency code.", - "example": [ - "usd", - "eur" - ], - "items": { - "type": "string", - "example": "usd" - } - } - }, - "required": [ - "id" - ] - }, - "customFields": { - "type": "array", - "items": { - "type": "string" - } - }, - "productMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - }, - "variantMetafields": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "namespace": { - "type": "string", - "description": "The namespace of the metafield." - }, - "key": { - "type": "string", - "description": "The key identifier of the metafield." - } - }, - "required": [ - "namespace", - "key" - ] - } - } - }, - "required": [ - "storeHash" - ], - "x-discriminator-fields": [ - "storeHash" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "mapping": { - "type": "object", - "description": "Mapping of type for every column. For example {\"myColumn\": \"boolean\", \"myOtherColumn\": \"json\"}.\n", - "additionalProperties": { - "type": "string", - "enum": [ - "string", - "integer", - "float", - "boolean", - "json" - ] - } - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - }, - "delimiter": { - "type": "string", - "minLength": 1, - "maxLength": 1, - "default": ",", - "description": "The character used to split the value on each line, default to a comma (\\r, \\n, 0xFFFD, and space are forbidden)." - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "projectID": { - "type": "string", - "description": "Project ID of the BigQuery Source." - }, - "datasetID": { - "type": "string", - "description": "Dataset ID of the BigQuery Source." - }, - "dataType": { - "type": "string", - "enum": [ - "ga4", - "ga360" - ] - }, - "table": { - "type": "string", - "description": "Table name (for default BQ)." - }, - "tablePrefix": { - "type": "string", - "description": "Table prefix (for Google Analytics)." - }, - "customSQLRequest": { - "type": "string", - "description": "Custom SQL request to extract data from the BigQuery table." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - } - }, - "required": [ - "projectID", - "datasetID" - ], - "x-discriminator-fields": [ - "projectID" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "imageType": { - "type": "string", - "enum": [ - "singer", - "custom", - "airbyte" - ], - "description": "The type of the image." - }, - "registry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "image": { - "type": "string", - "description": "The name of the image to pull.", - "example": "algolia/zendesk" - }, - "version": { - "type": "string", - "description": "The version of the image, defaults to `latest`.", - "example": "v2.1.0" - }, - "configuration": { - "type": "object", - "description": "The configuration of the spec." - } - }, - "required": [ - "registry", - "image", - "imageType", - "configuration" - ] - } - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "sourceID", - "type", - "name", - "input", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "patch": { - "tags": [ - "sources" - ], - "summary": "Update a source.", - "description": "Update the source of the given sourceID.", - "operationId": "updateSource", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "sourceID", - "in": "path", - "required": true, - "description": "The source UUID.", - "schema": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "storeKeys": { - "type": "array", - "description": "Unique and immutable key of the referenced Store.", - "items": { - "type": "string" - } - }, - "locales": { - "type": "array", - "description": "Array of locales that must match the following pattern: ^[a-z]{2}(-[A-Z]{2})?$. For example [\"fr-FR\", \"en\"].\n", - "items": { - "type": "string" - } - }, - "url": { - "type": "string" - }, - "fallbackIsInStockValue": { - "type": "boolean", - "description": "Determines the value that will be stored in the Algolia record if there's no inventory information on the product.\n" - }, - "customFields": { - "type": "object", - "additionalProperties": false, - "description": "Custom fields from Commercetools to index in the records (see https://docs.commercetools.com/tutorials/custom-types).", - "properties": { - "inventory": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Inventory custom fields.", - "nullable": true - }, - "price": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Price custom fields.", - "nullable": true - }, - "category": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Category custom fields.", - "nullable": true - } - } - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "url": { - "type": "string", - "description": "The URL of the file." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - }, - "mapping": { - "type": "object", - "description": "Mapping of type for every column. For example {\"myColumn\": \"boolean\", \"myOtherColumn\": \"json\"}.\n", - "additionalProperties": { - "type": "string", - "enum": [ - "string", - "integer", - "float", - "boolean", - "json" - ] - } - }, - "method": { - "type": "string", - "enum": [ - "GET", - "POST" - ] - }, - "delimiter": { - "type": "string", - "minLength": 1, - "maxLength": 1, - "default": ",", - "description": "The character used to split the value on each line, default to a comma (\\r, \\n, 0xFFFD, and space are forbidden)." - } - }, - "required": [ - "url" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "projectID": { - "type": "string", - "description": "Project ID of the BigQuery Source." - }, - "datasetID": { - "type": "string", - "description": "Dataset ID of the BigQuery Source." - }, - "dataType": { - "type": "string", - "enum": [ - "ga4", - "ga360" - ] - }, - "table": { - "type": "string", - "description": "Table name (for default BQ)." - }, - "tablePrefix": { - "type": "string", - "description": "Table prefix (for Google Analytics)." - }, - "customSQLRequest": { - "type": "string", - "description": "Custom SQL request to extract data from the BigQuery table." - }, - "uniqueIDColumn": { - "type": "string", - "description": "The name of the column that contains the unique ID, used as `objectID` in Algolia." - } - }, - "required": [ - "projectID", - "datasetID" - ], - "x-discriminator-fields": [ - "projectID" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "registry": { - "type": "string", - "enum": [ - "dockerhub", - "ghcr" - ], - "description": "The registry where the image is stored." - }, - "image": { - "type": "string", - "description": "The name of the image to pull.", - "example": "algolia/zendesk" - }, - "version": { - "type": "string", - "description": "The version of the image, defaults to `latest`.", - "example": "v2.1.0" - }, - "configuration": { - "type": "object", - "description": "The configuration of the spec." - } - }, - "required": [ - "configuration" - ] - } - ] - }, - "authenticationID": { - "type": "string", - "description": "The authentication UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "name": { - "type": "string" - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "sourceID", - "name", - "updatedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "sources" - ], - "summary": "Delete a source.", - "description": "Soft delete the source of the given sourceID.", - "operationId": "deleteSource", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "sourceID", - "in": "path", - "required": true, - "description": "The source UUID.", - "schema": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "deletedAt": { - "type": "string", - "description": "Date of deletion (RFC3339 format)." - } - }, - "required": [ - "deletedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/sources/{sourceID}/discover": { - "get": { - "tags": [ - "sources" - ], - "summary": "Retrieve a stream listing.", - "description": "Retrieve a stream listing for a given Singer specification compatible docker type source ID.", - "operationId": "getDockerSourceStreams", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "sourceID", - "in": "path", - "required": true, - "description": "The source UUID.", - "schema": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "dockerSourceStreams", - "type": "object", - "additionalProperties": false, - "properties": { - "streams": { - "type": "array", - "items": { - "type": "object", - "description": "A stream definition (see the Singer specification for details)." - } - } - }, - "required": [ - "streams" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "tags": [ - "sources" - ], - "summary": "Trigger a stream listing request.", - "description": "Trigger a stream listing request for a Singer specification compatible docker type source.", - "operationId": "triggerDockerSourceDiscover", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "sourceID", - "in": "path", - "required": true, - "description": "The source UUID.", - "schema": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "dockerSourceDiscover", - "type": "object", - "additionalProperties": false, - "properties": { - "runID": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - } - }, - "required": [ - "runID", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/tasks": { - "get": { - "tags": [ - "tasks" - ], - "summary": "Get a list of tasks.", - "description": "Get a list of tasks for the given query parameters, with pagination details.", - "operationId": "getTasks", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "itemsPerPage", - "in": "query", - "description": "The number of items per page to return.", - "required": false, - "schema": { - "type": "integer" - } - }, - { - "name": "page", - "in": "query", - "description": "The page number to fetch, starting at 1.", - "required": false, - "schema": { - "type": "integer" - } - }, - { - "name": "action", - "in": "query", - "required": false, - "description": "The action of the tasks to retrieve.", - "style": "form", - "explode": false, - "schema": { - "type": "array", - "description": "An array of actions to perform on the Algolia index.", - "items": { - "type": "string", - "description": "The action to perform on the Algolia index.", - "enum": [ - "replace", - "save", - "partial" - ] - }, - "example": "save,replace" - } - }, - { - "name": "enabled", - "in": "query", - "description": "Whether the task is enabled or not.", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "name": "sourceID", - "in": "query", - "description": "The sourceIDs of the tasks to retrive.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - { - "name": "destinationID", - "in": "query", - "description": "The destinationIDs of the tasks to retrive.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - }, - { - "name": "triggerType", - "in": "query", - "description": "The trigger type of the task.", - "required": false, - "style": "form", - "explode": false, - "schema": { - "type": "array", - "items": { - "type": "string", - "description": "The type of the task reflect how it can be used:\n - onDemand: a task that runs manually\n - schedule: a task that runs regularly, following a given cron expression\n - subscription: a task that runs after a subscription event is received from an integration (e.g. Webhook).\n", - "enum": [ - "onDemand", - "schedule", - "subscription" - ] - }, - "example": "onDemand,schedule" - } - }, - { - "name": "sort", - "in": "query", - "description": "The key by which the list should be sorted.", - "required": false, - "schema": { - "type": "string", - "description": "Used to sort the Task list endpoint.", - "enum": [ - "enabled", - "triggerType", - "action", - "updatedAt", - "createdAt" - ] - } - }, - { - "name": "order", - "in": "query", - "description": "The order of the returned list.", - "required": false, - "schema": { - "type": "string", - "description": "Used to order a sorted request.", - "enum": [ - "asc", - "desc" - ] - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "listTasksResponse", - "type": "object", - "description": "A list of tasks with pagination details.", - "additionalProperties": false, - "properties": { - "tasks": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "trigger": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information of a task of type `onDemand`.", - "properties": { - "type": { - "type": "string", - "description": "A task which is manually executed via the run task endpoint.", - "enum": [ - "onDemand" - ] - }, - "lastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "type" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information for a task of type 'schedule'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by a schedule (cron expression).", - "enum": [ - "schedule" - ] - }, - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - }, - "lastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - }, - "nextRun": { - "description": "The next scheduled run of the task (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "type", - "cron", - "nextRun" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'subscription'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by an external subscription (e.g. Webhook).", - "enum": [ - "subscription" - ] - } - }, - "required": [ - "type" - ] - } - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The input for an `onDemand` task whose source is of type `bigquery` and for which extracted data spans a given time range.", - "properties": { - "startDate": { - "description": "The start date of the extraction (RFC3339 format).", - "type": "string" - }, - "endDate": { - "description": "The end date of the extraction (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "startDate", - "endDate" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The input for a `schedule` task whose source is of type `bigquery` and for which extracted data spans a fixed number of days.", - "properties": { - "timeframe": { - "description": "The timeframe of the extraction, in number of days from today.", - "type": "integer", - "minimum": 1, - "maximum": 30 - } - }, - "required": [ - "timeframe" - ] - } - ] - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Whether the task is enabled or not." - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - }, - "action": { - "type": "string", - "description": "The action to perform on the Algolia index.", - "enum": [ - "replace", - "save", - "partial" - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "taskID", - "sourceID", - "destinationID", - "trigger", - "enabled", - "action", - "createdAt" - ] - } - }, - "pagination": { - "type": "object", - "additionalProperties": false, - "properties": { - "nbPages": { - "type": "integer" - }, - "page": { - "type": "integer" - }, - "nbItems": { - "type": "integer" - }, - "itemsPerPage": { - "type": "integer" - } - }, - "required": [ - "nbPages", - "page", - "nbItems", - "itemsPerPage" - ] - } - }, - "required": [ - "tasks", - "pagination" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "tags": [ - "tasks" - ], - "summary": "Create a task.", - "description": "Create a task.", - "operationId": "createTask", - "requestBody": { - "description": "", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "description": "The payload for a task creation.", - "properties": { - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "trigger": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information of a task of type `onDemand`.", - "properties": { - "type": { - "type": "string", - "description": "A task which is manually executed via the run task endpoint.", - "enum": [ - "onDemand" - ] - } - }, - "required": [ - "type" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'schedule'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by a schedule (cron expression).", - "enum": [ - "schedule" - ] - }, - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - } - }, - "required": [ - "type", - "cron" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'subscription'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by an external subscription (e.g. Webhook).", - "enum": [ - "subscription" - ] - } - }, - "required": [ - "type" - ] - } - ] - }, - "action": { - "type": "string", - "description": "The action to perform on the Algolia index.", - "enum": [ - "replace", - "save", - "partial" - ] - }, - "enabled": { - "type": "boolean", - "description": "Whether the task is enabled or not." - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The input for an `onDemand` task whose source is of type `bigquery` and for which extracted data spans a given time range.", - "properties": { - "startDate": { - "description": "The start date of the extraction (RFC3339 format).", - "type": "string" - }, - "endDate": { - "description": "The end date of the extraction (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "startDate", - "endDate" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The input for a `schedule` task whose source is of type `bigquery` and for which extracted data spans a fixed number of days.", - "properties": { - "timeframe": { - "description": "The timeframe of the extraction, in number of days from today.", - "type": "integer", - "minimum": 1, - "maximum": 30 - } - }, - "required": [ - "timeframe" - ] - } - ] - } - }, - "required": [ - "sourceID", - "destinationID", - "trigger", - "action" - ] - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "description": "The response from the API after a task creation.", - "properties": { - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - } - }, - "required": [ - "taskID", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/tasks/search": { - "post": { - "tags": [ - "tasks" - ], - "summary": "Search among tasks.", - "description": "Search among tasks with a defined set of parameters.", - "operationId": "searchTasks", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "taskIDs": { - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "taskIDs" - ] - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "searchTasksResponse", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "trigger": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information of a task of type `onDemand`.", - "properties": { - "type": { - "type": "string", - "description": "A task which is manually executed via the run task endpoint.", - "enum": [ - "onDemand" - ] - }, - "lastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "type" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information for a task of type 'schedule'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by a schedule (cron expression).", - "enum": [ - "schedule" - ] - }, - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - }, - "lastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - }, - "nextRun": { - "description": "The next scheduled run of the task (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "type", - "cron", - "nextRun" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'subscription'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by an external subscription (e.g. Webhook).", - "enum": [ - "subscription" - ] - } - }, - "required": [ - "type" - ] - } - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The input for an `onDemand` task whose source is of type `bigquery` and for which extracted data spans a given time range.", - "properties": { - "startDate": { - "description": "The start date of the extraction (RFC3339 format).", - "type": "string" - }, - "endDate": { - "description": "The end date of the extraction (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "startDate", - "endDate" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The input for a `schedule` task whose source is of type `bigquery` and for which extracted data spans a fixed number of days.", - "properties": { - "timeframe": { - "description": "The timeframe of the extraction, in number of days from today.", - "type": "integer", - "minimum": 1, - "maximum": 30 - } - }, - "required": [ - "timeframe" - ] - } - ] - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Whether the task is enabled or not." - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - }, - "action": { - "type": "string", - "description": "The action to perform on the Algolia index.", - "enum": [ - "replace", - "save", - "partial" - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "taskID", - "sourceID", - "destinationID", - "trigger", - "enabled", - "action", - "createdAt" - ] - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/tasks/{taskID}": { - "get": { - "tags": [ - "tasks" - ], - "summary": "Get a task.", - "description": "Get the task of the given taskID.", - "operationId": "getTask", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "taskID", - "in": "path", - "required": true, - "description": "The task UUID.", - "schema": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "sourceID": { - "type": "string", - "description": "The source UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "trigger": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information of a task of type `onDemand`.", - "properties": { - "type": { - "type": "string", - "description": "A task which is manually executed via the run task endpoint.", - "enum": [ - "onDemand" - ] - }, - "lastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "type" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger information for a task of type 'schedule'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by a schedule (cron expression).", - "enum": [ - "schedule" - ] - }, - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - }, - "lastRun": { - "description": "The last time the scheduled task ran (RFC3339 format).", - "type": "string" - }, - "nextRun": { - "description": "The next scheduled run of the task (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "type", - "cron", - "nextRun" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task of type 'subscription'.", - "properties": { - "type": { - "type": "string", - "description": "A task which is triggered by an external subscription (e.g. Webhook).", - "enum": [ - "subscription" - ] - } - }, - "required": [ - "type" - ] - } - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The input for an `onDemand` task whose source is of type `bigquery` and for which extracted data spans a given time range.", - "properties": { - "startDate": { - "description": "The start date of the extraction (RFC3339 format).", - "type": "string" - }, - "endDate": { - "description": "The end date of the extraction (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "startDate", - "endDate" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The input for a `schedule` task whose source is of type `bigquery` and for which extracted data spans a fixed number of days.", - "properties": { - "timeframe": { - "description": "The timeframe of the extraction, in number of days from today.", - "type": "integer", - "minimum": 1, - "maximum": 30 - } - }, - "required": [ - "timeframe" - ] - } - ] - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Whether the task is enabled or not." - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - }, - "action": { - "type": "string", - "description": "The action to perform on the Algolia index.", - "enum": [ - "replace", - "save", - "partial" - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "taskID", - "sourceID", - "destinationID", - "trigger", - "enabled", - "action", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "patch": { - "tags": [ - "tasks" - ], - "summary": "Update a task.", - "description": "Update the task of the given taskID.", - "operationId": "updateTask", - "parameters": [ - { - "name": "taskID", - "in": "path", - "required": true, - "description": "The task UUID.", - "schema": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "description": "The payload for a task update.", - "properties": { - "destinationID": { - "type": "string", - "description": "The destination UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "trigger": { - "type": "object", - "additionalProperties": false, - "description": "The trigger input for a task update.", - "properties": { - "cron": { - "type": "string", - "description": "A cron expression that represent at which regularity the task should run.", - "example": "* * 1 * *" - } - }, - "required": [ - "cron" - ] - }, - "input": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "description": "The input for an `onDemand` task whose source is of type `bigquery` and for which extracted data spans a given time range.", - "properties": { - "startDate": { - "description": "The start date of the extraction (RFC3339 format).", - "type": "string" - }, - "endDate": { - "description": "The end date of the extraction (RFC3339 format).", - "type": "string" - } - }, - "required": [ - "startDate", - "endDate" - ] - }, - { - "type": "object", - "additionalProperties": false, - "description": "The input for a `schedule` task whose source is of type `bigquery` and for which extracted data spans a fixed number of days.", - "properties": { - "timeframe": { - "description": "The timeframe of the extraction, in number of days from today.", - "type": "integer", - "minimum": 1, - "maximum": 30 - } - }, - "required": [ - "timeframe" - ] - } - ] - }, - "enabled": { - "type": "boolean", - "description": "Whether the task is enabled or not." - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - } - } - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "The response from the API after a task update.", - "additionalProperties": false, - "properties": { - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "taskID", - "updatedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "tasks" - ], - "summary": "Delete a task.", - "description": "Soft delete the task of the given taskID.", - "operationId": "deleteTask", - "parameters": [ - { - "name": "taskID", - "in": "path", - "required": true, - "description": "The task UUID.", - "schema": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "deletedAt": { - "type": "string", - "description": "Date of deletion (RFC3339 format)." - } - }, - "required": [ - "deletedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/tasks/{taskID}/run": { - "post": { - "tags": [ - "tasks" - ], - "summary": "Run a task.", - "description": "Run the task of the given taskID.", - "operationId": "runTask", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "taskID", - "in": "path", - "required": true, - "description": "The task UUID.", - "schema": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "description": "The response from the run task API, containing an Observability Run ID and the time it was created at.", - "properties": { - "runID": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - } - }, - "required": [ - "runID", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/tasks/{taskID}/enable": { - "put": { - "tags": [ - "tasks" - ], - "summary": "Enable a task.", - "description": "Enable the task of the given taskID.", - "operationId": "enableTask", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "taskID", - "in": "path", - "required": true, - "description": "The task UUID.", - "schema": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "The response from the API after a task update.", - "additionalProperties": false, - "properties": { - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "taskID", - "updatedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/tasks/{taskID}/disable": { - "put": { - "tags": [ - "tasks" - ], - "summary": "Disable a task.", - "description": "Disable the task of the given taskID.", - "operationId": "disableTask", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "taskID", - "in": "path", - "required": true, - "description": "The task UUID.", - "schema": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "The response from the API after a task update.", - "additionalProperties": false, - "properties": { - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "updatedAt": { - "type": "string", - "description": "Date of last update (RFC3339 format)." - } - }, - "required": [ - "taskID", - "updatedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/runs": { - "get": { - "tags": [ - "observability" - ], - "summary": "Get a list of runs.", - "description": "Get a list of runs for the given query parameters, with pagination details.", - "operationId": "getRuns", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "itemsPerPage", - "in": "query", - "description": "The number of items per page to return.", - "required": false, - "schema": { - "type": "integer" - } - }, - { - "name": "page", - "in": "query", - "description": "The page number to fetch, starting at 1.", - "required": false, - "schema": { - "type": "integer" - } - }, - { - "name": "status", - "in": "query", - "description": "Filter the status of the runs.", - "schema": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "created", - "started", - "idled", - "finished", - "skipped" - ] - } - } - }, - { - "name": "taskID", - "in": "query", - "description": "Filter by taskID.", - "schema": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - { - "name": "sort", - "in": "query", - "description": "The key by which the list should be sorted.", - "required": false, - "schema": { - "type": "string", - "description": "Used to sort the Run list endpoint.", - "enum": [ - "status", - "updatedAt", - "createdAt" - ] - } - }, - { - "name": "order", - "in": "query", - "description": "The order of the returned list.", - "required": false, - "schema": { - "type": "string", - "description": "Used to order a sorted request.", - "enum": [ - "asc", - "desc" - ] - } - }, - { - "name": "startDate", - "in": "query", - "description": "The start date (in RFC3339 format) of the runs fetching window. Defaults to 'now'-7 days if omitted.", - "schema": { - "type": "string" - } - }, - { - "name": "endDate", - "in": "query", - "description": "The end date (in RFC3339 format) of the runs fetching window. Defaults to 'now' days if omitted.", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "runs": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "runID": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "appID": { - "type": "string" - }, - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "status": { - "type": "string", - "enum": [ - "created", - "started", - "idled", - "finished", - "skipped" - ] - }, - "progress": { - "type": "object", - "additionalProperties": false, - "properties": { - "expectedNbOfEvents": { - "type": "integer" - }, - "receivedNbOfEvents": { - "type": "integer" - } - } - }, - "outcome": { - "type": "string", - "enum": [ - "success", - "failure", - "processing" - ] - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - }, - "reason": { - "type": "string", - "description": "Explains the result of outcome." - }, - "reasonCode": { - "type": "string", - "description": "An identifier that pairs with the outcome reason.", - "enum": [ - "internal", - "critical", - "no_events", - "too_many_errors", - "ok", - "discarded", - "blocking" - ] - }, - "type": { - "type": "string", - "enum": [ - "reindex", - "update", - "discover" - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "startedAt": { - "type": "string", - "description": "Date of start (RFC3339 format)." - }, - "finishedAt": { - "type": "string", - "description": "Date of finish (RFC3339 format)." - } - }, - "required": [ - "runID", - "appID", - "taskID", - "status", - "type", - "createdAt" - ] - } - }, - "pagination": { - "type": "object", - "additionalProperties": false, - "properties": { - "nbPages": { - "type": "integer" - }, - "page": { - "type": "integer" - }, - "nbItems": { - "type": "integer" - }, - "itemsPerPage": { - "type": "integer" - } - }, - "required": [ - "nbPages", - "page", - "nbItems", - "itemsPerPage" - ] - }, - "window": { - "type": "object", - "additionalProperties": false, - "description": "The window parameter represents the holds the dates used to query the Observability data from the database in a given window.", - "properties": { - "startDate": { - "type": "string", - "description": "A date in format RFC3339 representing the oldest possible data in query window." - }, - "endDate": { - "type": "string", - "description": "A date in format RFC3339 representing the newest possible data in query window." - } - }, - "required": [ - "startDate", - "endDate" - ] - } - }, - "required": [ - "runs", - "pagination", - "window" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/runs/{runID}": { - "get": { - "tags": [ - "observability" - ], - "summary": "Get a run.", - "description": "Get a single run for the given ID.", - "operationId": "getRun", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "runID", - "in": "path", - "required": true, - "description": "The run UUID.", - "schema": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "runID": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "appID": { - "type": "string" - }, - "taskID": { - "type": "string", - "description": "The task UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "status": { - "type": "string", - "enum": [ - "created", - "started", - "idled", - "finished", - "skipped" - ] - }, - "progress": { - "type": "object", - "additionalProperties": false, - "properties": { - "expectedNbOfEvents": { - "type": "integer" - }, - "receivedNbOfEvents": { - "type": "integer" - } - } - }, - "outcome": { - "type": "string", - "enum": [ - "success", - "failure", - "processing" - ] - }, - "failureThreshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "A percentage representing the accepted failure threshold to determine if a `run` succeeded or not." - }, - "reason": { - "type": "string", - "description": "Explains the result of outcome." - }, - "reasonCode": { - "type": "string", - "description": "An identifier that pairs with the outcome reason.", - "enum": [ - "internal", - "critical", - "no_events", - "too_many_errors", - "ok", - "discarded", - "blocking" - ] - }, - "type": { - "type": "string", - "enum": [ - "reindex", - "update", - "discover" - ] - }, - "createdAt": { - "type": "string", - "description": "Date of creation (RFC3339 format)." - }, - "startedAt": { - "type": "string", - "description": "Date of start (RFC3339 format)." - }, - "finishedAt": { - "type": "string", - "description": "Date of finish (RFC3339 format)." - } - }, - "required": [ - "runID", - "appID", - "taskID", - "status", - "type", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/runs/{runID}/events": { - "get": { - "tags": [ - "observability" - ], - "summary": "Get a list of events.", - "description": "Get a list of events associated to the given runID, for the given query parameters.", - "operationId": "getEvents", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "runID", - "in": "path", - "required": true, - "description": "The run UUID.", - "schema": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - { - "name": "itemsPerPage", - "in": "query", - "description": "The number of items per page to return.", - "required": false, - "schema": { - "type": "integer" - } - }, - { - "name": "page", - "in": "query", - "description": "The page number to fetch, starting at 1.", - "required": false, - "schema": { - "type": "integer" - } - }, - { - "name": "status", - "in": "query", - "description": "Filter the status of the events.", - "schema": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "created", - "started", - "retried", - "failed", - "succeeded", - "critical" - ] - } - } - }, - { - "name": "type", - "in": "query", - "description": "Filter the type of the events.", - "schema": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "fetch", - "record", - "log", - "transform" - ] - } - } - }, - { - "name": "sort", - "in": "query", - "description": "The key by which the list should be sorted.", - "required": false, - "schema": { - "type": "string", - "description": "Used to sort the Event list endpoint.", - "enum": [ - "status", - "type", - "publishedAt" - ] - } - }, - { - "name": "order", - "in": "query", - "description": "The order of the returned list.", - "required": false, - "schema": { - "type": "string", - "description": "Used to order a sorted request.", - "enum": [ - "asc", - "desc" - ] - } - }, - { - "name": "startDate", - "in": "query", - "description": "The start date (in RFC3339 format) of the events fetching window. Defaults to 'now'-3 hours if omitted.", - "schema": { - "type": "string" - } - }, - { - "name": "endDate", - "in": "query", - "description": "The end date (in RFC3339 format) of the events fetching window. Defaults to 'now' days if omitted.", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "listEventsResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "events": { - "type": "array", - "items": { - "type": "object", - "description": "An event describe a step of the task execution flow..", - "additionalProperties": false, - "properties": { - "eventID": { - "type": "string", - "description": "The event UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "runID": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "parentID": { - "type": "string", - "description": "The parent event, the cause of this event.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "status": { - "type": "string", - "enum": [ - "created", - "started", - "retried", - "failed", - "succeeded", - "critical" - ] - }, - "type": { - "type": "string", - "enum": [ - "fetch", - "record", - "log", - "transform" - ] - }, - "batchSize": { - "type": "integer", - "description": "The extracted record batch size.", - "example": 10, - "minimum": 0, - "multipleOf": 1 - }, - "data": { - "type": "object", - "additionalProperties": true - }, - "publishedAt": { - "type": "string", - "description": "Date of publish (RFC3339 format)." - } - }, - "required": [ - "eventID", - "runID", - "status", - "type", - "batchSize", - "publishedAt" - ] - } - }, - "pagination": { - "type": "object", - "additionalProperties": false, - "properties": { - "nbPages": { - "type": "integer" - }, - "page": { - "type": "integer" - }, - "nbItems": { - "type": "integer" - }, - "itemsPerPage": { - "type": "integer" - } - }, - "required": [ - "nbPages", - "page", - "nbItems", - "itemsPerPage" - ] - }, - "window": { - "type": "object", - "additionalProperties": false, - "description": "The window parameter represents the holds the dates used to query the Observability data from the database in a given window.", - "properties": { - "startDate": { - "type": "string", - "description": "A date in format RFC3339 representing the oldest possible data in query window." - }, - "endDate": { - "type": "string", - "description": "A date in format RFC3339 representing the newest possible data in query window." - } - }, - "required": [ - "startDate", - "endDate" - ] - } - }, - "required": [ - "events", - "pagination", - "window" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/runs/{runID}/events/{eventID}": { - "get": { - "tags": [ - "observability" - ], - "summary": "Get an event.", - "description": "Get a single event for a specific runID.", - "operationId": "getEvent", - "x-acl": [ - "addObject", - "deleteIndex", - "editSettings" - ], - "parameters": [ - { - "name": "runID", - "in": "path", - "required": true, - "description": "The run UUID.", - "schema": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - }, - { - "name": "eventID", - "in": "path", - "required": true, - "description": "The event UUID.", - "schema": { - "type": "string", - "description": "The event UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "An event describe a step of the task execution flow..", - "additionalProperties": false, - "properties": { - "eventID": { - "type": "string", - "description": "The event UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "runID": { - "type": "string", - "description": "The run UUID.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "parentID": { - "type": "string", - "description": "The parent event, the cause of this event.", - "example": "6c02aeb1-775e-418e-870b-1faccd4b2c0f" - }, - "status": { - "type": "string", - "enum": [ - "created", - "started", - "retried", - "failed", - "succeeded", - "critical" - ] - }, - "type": { - "type": "string", - "enum": [ - "fetch", - "record", - "log", - "transform" - ] - }, - "batchSize": { - "type": "integer", - "description": "The extracted record batch size.", - "example": 10, - "minimum": 0, - "multipleOf": 1 - }, - "data": { - "type": "object", - "additionalProperties": true - }, - "publishedAt": { - "type": "string", - "description": "Date of publish (RFC3339 format)." - } - }, - "required": [ - "eventID", - "runID", - "status", - "type", - "batchSize", - "publishedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - } - } -} \ No newline at end of file diff --git a/specs/bundled/insights.json b/specs/bundled/insights.json deleted file mode 100644 index 77e5ebec66..0000000000 --- a/specs/bundled/insights.json +++ /dev/null @@ -1,5472 +0,0 @@ -{ - "openapi": "3.0.2", - "info": { - "title": "Insights API", - "description": "The Algolia Insights API lets you collect events related to your search and discovery experience. Events represent actions that users take on your app or website. They unlock powerful features, such as recommendations, personalization, smarter search results, and analytics that help you optimize your user experience.", - "version": "1.0.0" - }, - "components": { - "securitySchemes": { - "appId": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-Application-Id" - }, - "apiKey": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-API-Key" - } - }, - "parameters": { - "PathInPath": { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - "Parameters": { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - }, - "schemas": { - "ErrorBase": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - }, - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "ClickEvent": { - "type": "string", - "enum": [ - "click" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "positions": { - "type": "array", - "items": { - "type": "integer" - }, - "minimum": 1, - "minItems": 1, - "maxItems": 20, - "description": "The position of the clicked item the search results.\n\nThe first search result has a position of 1 (not 0).\nYou must provide 1 `position` for each `objectID`.\n", - "example": [ - 1, - 2, - 5 - ] - }, - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query.\n\nThe query ID is required for events related to search or browse requests.\nIf you add `clickAnalytics: true` as a search request parameter, the query ID is included in the API response.\n", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "ClickedObjectIDsAfterSearch": { - "type": "object", - "title": "Clicked object IDs after search", - "description": "Click event after an Algolia request.\n\nUse this event to track when users click items in the search results.\nIf you're building your category pages with Algolia,\nyou'll also use this event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "click" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "positions": { - "type": "array", - "items": { - "type": "integer" - }, - "minimum": 1, - "minItems": 1, - "maxItems": 20, - "description": "The position of the clicked item the search results.\n\nThe first search result has a position of 1 (not 0).\nYou must provide 1 `position` for each `objectID`.\n", - "example": [ - 1, - 2, - 5 - ] - }, - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query.\n\nThe query ID is required for events related to search or browse requests.\nIf you add `clickAnalytics: true` as a search request parameter, the query ID is included in the API response.\n", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "positions", - "queryID", - "userToken" - ], - "x-discriminator-fields": [ - "positions", - "queryID", - "eventType" - ] - }, - "ConversionEvent": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "AddToCartEvent": { - "type": "string", - "enum": [ - "addToCart" - ] - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - }, - "objectDataAfterSearch": { - "type": "object", - "additionalProperties": false, - "properties": { - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query, used to track purchase events with multiple records that originate from different searches.", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "objectDataAfterSearchList": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart events.\n\nIf provided, it must be the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query, used to track purchase events with multiple records that originate from different searches.", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - }, - "AddedToCartObjectIDsAfterSearch": { - "type": "object", - "title": "Added to cart object IDs after search", - "description": "Use this event to track when users add items to their shopping cart after a previous Algolia request.\nIf you're building your category pages with Algolia, you'll also use this event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "eventSubtype": { - "type": "string", - "enum": [ - "addToCart" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query.\n\nThe query ID is required for events related to search or browse requests.\nIf you add `clickAnalytics: true` as a search request parameter, the query ID is included in the API response.\n", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "objectData": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart events.\n\nIf provided, it must be the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query, used to track purchase events with multiple records that originate from different searches.", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - } - }, - "required": [ - "eventName", - "eventType", - "eventSubtype", - "queryID", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "eventSubtype", - "queryID", - "objectIDs" - ] - }, - "PurchaseEvent": { - "type": "string", - "enum": [ - "purchase" - ] - }, - "PurchasedObjectIDsAfterSearch": { - "type": "object", - "title": "Purchased object IDs after search", - "description": "Use this event to track when users make a purchase after a previous Algolia request.\nIf you're building your category pages with Algolia, you'll also use this event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "eventSubtype": { - "type": "string", - "enum": [ - "purchase" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "objectData": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart events.\n\nIf provided, it must be the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query, used to track purchase events with multiple records that originate from different searches.", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - } - }, - "required": [ - "eventName", - "eventType", - "eventSubtype", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "eventSubtype", - "objectIDs", - "objectData" - ] - }, - "ConvertedObjectIDsAfterSearch": { - "type": "object", - "title": "Converted object IDs after search", - "description": "Use this event to track when users convert after a previous Algolia request.\nFor example, a user clicks on an item in the search results to view the product detail page.\nThen, the user adds the item to their shopping cart.\n\nIf you're building your category pages with Algolia,\nyou'll also use this event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query.\n\nThe query ID is required for events related to search or browse requests.\nIf you add `clickAnalytics: true` as a search request parameter, the query ID is included in the API response.\n", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "queryID", - "userToken" - ], - "x-discriminator-fields": [ - "queryID", - "eventType" - ] - }, - "ClickedObjectIDs": { - "type": "object", - "title": "Clicked object IDs", - "description": "Use this event to track when users click items unrelated to a previous Algolia request.\nFor example, if you don't use Algolia to build your category pages, use this event.\n\nTo track click events related to Algolia requests, use the \"Clicked object IDs after search\" event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "click" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "objectIDs" - ] - }, - "objectData": { - "type": "object", - "additionalProperties": false, - "properties": { - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "objectDataList": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart event.\n\nIf specified, it must have the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "PurchasedObjectIDs": { - "type": "object", - "title": "Purchased object IDs", - "description": "Use this event to track when users make a purchase unrelated to a previous Algolia request. For example, if you don't use Algolia to build your category pages, use this event.\n\nTo track purchase events related to Algolia requests, use the \"Purchased object IDs after search\" event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "eventSubtype": { - "type": "string", - "enum": [ - "purchase" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "objectData": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart event.\n\nIf specified, it must have the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - } - }, - "required": [ - "eventName", - "eventType", - "eventSubtype", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "eventSubtype", - "objectIDs" - ] - }, - "AddedToCartObjectIDs": { - "type": "object", - "title": "Added to cart object IDs", - "description": "Use this event to track when users add items to their shopping cart unrelated to a previous Algolia request. For example, if you don't use Algolia to build your category pages, use this event.\n\nTo track add-to-cart events related to Algolia requests, use the \"Added to cart object IDs after search\" event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "eventSubtype": { - "type": "string", - "enum": [ - "addToCart" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "objectData": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart event.\n\nIf specified, it must have the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - } - }, - "required": [ - "eventName", - "eventType", - "eventSubtype", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "eventSubtype", - "objectIDs" - ] - }, - "ConvertedObjectIDs": { - "type": "object", - "title": "Converted object IDs", - "description": "Use this event to track when users convert on items unrelated to a previous Algolia request.\nFor example, if you don't use Algolia to build your category pages, use this event.\n\nTo track conversion events related to Algolia requests, use the \"Converted object IDs after search\" event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "objectIDs" - ] - }, - "filters": { - "type": "array", - "description": "Facet filters.\n\nEach facet filter string must be URL-encoded, such as, `discount:10%25`.\n", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "brand:apple" - ] - }, - "ClickedFilters": { - "type": "object", - "title": "Clicked filters", - "description": "Use this event to track when users click facet filters in your user interface.", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "click" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "filters": { - "type": "array", - "description": "Facet filters.\n\nEach facet filter string must be URL-encoded, such as, `discount:10%25`.\n", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "brand:apple" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "filters", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "filters" - ] - }, - "ConvertedFilters": { - "type": "object", - "title": "Converted filters", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "filters": { - "type": "array", - "description": "Facet filters.\n\nEach facet filter string must be URL-encoded, such as, `discount:10%25`.\n", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "brand:apple" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "filters", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "filters" - ] - }, - "ViewEvent": { - "type": "string", - "enum": [ - "view" - ] - }, - "ViewedObjectIDs": { - "type": "object", - "title": "Viewed object IDs", - "description": "Use this event to track when users viewed items in the search results.", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "view" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "objectIDs" - ] - }, - "ViewedFilters": { - "type": "object", - "title": "Viewed filters", - "description": "Use this method to capture active filters.\nFor example, when browsing a category page,\nusers see content filtered on that specific category.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "view" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "filters": { - "type": "array", - "description": "Facet filters.\n\nEach facet filter string must be URL-encoded, such as, `discount:10%25`.\n", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "brand:apple" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "filters", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "filters" - ] - }, - "EventsItems": { - "oneOf": [ - { - "type": "object", - "title": "Clicked object IDs after search", - "description": "Click event after an Algolia request.\n\nUse this event to track when users click items in the search results.\nIf you're building your category pages with Algolia,\nyou'll also use this event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "click" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "positions": { - "type": "array", - "items": { - "type": "integer" - }, - "minimum": 1, - "minItems": 1, - "maxItems": 20, - "description": "The position of the clicked item the search results.\n\nThe first search result has a position of 1 (not 0).\nYou must provide 1 `position` for each `objectID`.\n", - "example": [ - 1, - 2, - 5 - ] - }, - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query.\n\nThe query ID is required for events related to search or browse requests.\nIf you add `clickAnalytics: true` as a search request parameter, the query ID is included in the API response.\n", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "positions", - "queryID", - "userToken" - ], - "x-discriminator-fields": [ - "positions", - "queryID", - "eventType" - ] - }, - { - "type": "object", - "title": "Added to cart object IDs after search", - "description": "Use this event to track when users add items to their shopping cart after a previous Algolia request.\nIf you're building your category pages with Algolia, you'll also use this event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "eventSubtype": { - "type": "string", - "enum": [ - "addToCart" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query.\n\nThe query ID is required for events related to search or browse requests.\nIf you add `clickAnalytics: true` as a search request parameter, the query ID is included in the API response.\n", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "objectData": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart events.\n\nIf provided, it must be the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query, used to track purchase events with multiple records that originate from different searches.", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - } - }, - "required": [ - "eventName", - "eventType", - "eventSubtype", - "queryID", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "eventSubtype", - "queryID", - "objectIDs" - ] - }, - { - "type": "object", - "title": "Purchased object IDs after search", - "description": "Use this event to track when users make a purchase after a previous Algolia request.\nIf you're building your category pages with Algolia, you'll also use this event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "eventSubtype": { - "type": "string", - "enum": [ - "purchase" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "objectData": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart events.\n\nIf provided, it must be the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query, used to track purchase events with multiple records that originate from different searches.", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - } - }, - "required": [ - "eventName", - "eventType", - "eventSubtype", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "eventSubtype", - "objectIDs", - "objectData" - ] - }, - { - "type": "object", - "title": "Converted object IDs after search", - "description": "Use this event to track when users convert after a previous Algolia request.\nFor example, a user clicks on an item in the search results to view the product detail page.\nThen, the user adds the item to their shopping cart.\n\nIf you're building your category pages with Algolia,\nyou'll also use this event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query.\n\nThe query ID is required for events related to search or browse requests.\nIf you add `clickAnalytics: true` as a search request parameter, the query ID is included in the API response.\n", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "queryID", - "userToken" - ], - "x-discriminator-fields": [ - "queryID", - "eventType" - ] - }, - { - "type": "object", - "title": "Clicked object IDs", - "description": "Use this event to track when users click items unrelated to a previous Algolia request.\nFor example, if you don't use Algolia to build your category pages, use this event.\n\nTo track click events related to Algolia requests, use the \"Clicked object IDs after search\" event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "click" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "objectIDs" - ] - }, - { - "type": "object", - "title": "Purchased object IDs", - "description": "Use this event to track when users make a purchase unrelated to a previous Algolia request. For example, if you don't use Algolia to build your category pages, use this event.\n\nTo track purchase events related to Algolia requests, use the \"Purchased object IDs after search\" event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "eventSubtype": { - "type": "string", - "enum": [ - "purchase" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "objectData": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart event.\n\nIf specified, it must have the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - } - }, - "required": [ - "eventName", - "eventType", - "eventSubtype", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "eventSubtype", - "objectIDs" - ] - }, - { - "type": "object", - "title": "Added to cart object IDs", - "description": "Use this event to track when users add items to their shopping cart unrelated to a previous Algolia request. For example, if you don't use Algolia to build your category pages, use this event.\n\nTo track add-to-cart events related to Algolia requests, use the \"Added to cart object IDs after search\" event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "eventSubtype": { - "type": "string", - "enum": [ - "addToCart" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "objectData": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart event.\n\nIf specified, it must have the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - } - }, - "required": [ - "eventName", - "eventType", - "eventSubtype", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "eventSubtype", - "objectIDs" - ] - }, - { - "type": "object", - "title": "Converted object IDs", - "description": "Use this event to track when users convert on items unrelated to a previous Algolia request.\nFor example, if you don't use Algolia to build your category pages, use this event.\n\nTo track conversion events related to Algolia requests, use the \"Converted object IDs after search\" event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "objectIDs" - ] - }, - { - "type": "object", - "title": "Clicked filters", - "description": "Use this event to track when users click facet filters in your user interface.", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "click" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "filters": { - "type": "array", - "description": "Facet filters.\n\nEach facet filter string must be URL-encoded, such as, `discount:10%25`.\n", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "brand:apple" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "filters", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "filters" - ] - }, - { - "type": "object", - "title": "Converted filters", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "filters": { - "type": "array", - "description": "Facet filters.\n\nEach facet filter string must be URL-encoded, such as, `discount:10%25`.\n", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "brand:apple" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "filters", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "filters" - ] - }, - { - "type": "object", - "title": "Viewed object IDs", - "description": "Use this event to track when users viewed items in the search results.", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "view" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "objectIDs" - ] - }, - { - "type": "object", - "title": "Viewed filters", - "description": "Use this method to capture active filters.\nFor example, when browsing a category page,\nusers see content filtered on that specific category.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "view" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "filters": { - "type": "array", - "description": "Facet filters.\n\nEach facet filter string must be URL-encoded, such as, `discount:10%25`.\n", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "brand:apple" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "filters", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "filters" - ] - } - ] - }, - "EventsResponse": { - "type": "object", - "description": "The response of the Insights API.", - "additionalProperties": false, - "properties": { - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - }, - "status": { - "type": "integer", - "description": "The HTTP status code of the response." - } - } - } - }, - "responses": { - "BadRequest": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "FeatureNotEnabled": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "MethodNotAllowed": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "IndexNotFound": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "servers": [ - { - "url": "https://insights.{region}.algolia.io", - "variables": { - "region": { - "enum": [ - "us", - "de" - ], - "default": "us" - } - } - }, - { - "url": "https://insights.algolia.io" - } - ], - "security": [ - { - "appId": [], - "apiKey": [] - } - ], - "tags": [ - { - "name": "events", - "x-displayName": "Events", - "description": "Events represent user interactions with your website or app. They include details like the event's name, type, a timestamp or a user token." - }, - { - "name": "usertokens", - "x-displayName": "User tokens", - "description": "Delete events related to a specific user token.\n" - } - ], - "x-tagGroups": [ - { - "name": "General", - "tags": [ - "events", - "usertokens" - ] - } - ], - "paths": { - "/1{path}": { - "get": { - "operationId": "customGet", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "operationId": "customPost", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "operationId": "customPut", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "operationId": "customDelete", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/events": { - "post": { - "tags": [ - "events" - ], - "operationId": "pushEvents", - "summary": "Send events.", - "description": "Send a list of events to the Insights API.\n\nYou can include up to 1,000 events in a single request,\nbut the request body must be smaller than 2 MB.\n", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "title": "InsightsEvents", - "type": "object", - "additionalProperties": false, - "required": [ - "events" - ], - "properties": { - "events": { - "type": "array", - "description": "List of click and conversion events.\n\nAn event is an object representing a user interaction.\nEvents have attributes that describe the interaction,\nsuch as an event name, a type, or a user token.\n\n**All** events must be valid, otherwise the API returns an error.\n", - "minItems": 1, - "maxItems": 1000, - "items": { - "oneOf": [ - { - "type": "object", - "title": "Clicked object IDs after search", - "description": "Click event after an Algolia request.\n\nUse this event to track when users click items in the search results.\nIf you're building your category pages with Algolia,\nyou'll also use this event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "click" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "positions": { - "type": "array", - "items": { - "type": "integer" - }, - "minimum": 1, - "minItems": 1, - "maxItems": 20, - "description": "The position of the clicked item the search results.\n\nThe first search result has a position of 1 (not 0).\nYou must provide 1 `position` for each `objectID`.\n", - "example": [ - 1, - 2, - 5 - ] - }, - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query.\n\nThe query ID is required for events related to search or browse requests.\nIf you add `clickAnalytics: true` as a search request parameter, the query ID is included in the API response.\n", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "positions", - "queryID", - "userToken" - ], - "x-discriminator-fields": [ - "positions", - "queryID", - "eventType" - ] - }, - { - "type": "object", - "title": "Added to cart object IDs after search", - "description": "Use this event to track when users add items to their shopping cart after a previous Algolia request.\nIf you're building your category pages with Algolia, you'll also use this event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "eventSubtype": { - "type": "string", - "enum": [ - "addToCart" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query.\n\nThe query ID is required for events related to search or browse requests.\nIf you add `clickAnalytics: true` as a search request parameter, the query ID is included in the API response.\n", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "objectData": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart events.\n\nIf provided, it must be the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query, used to track purchase events with multiple records that originate from different searches.", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - } - }, - "required": [ - "eventName", - "eventType", - "eventSubtype", - "queryID", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "eventSubtype", - "queryID", - "objectIDs" - ] - }, - { - "type": "object", - "title": "Purchased object IDs after search", - "description": "Use this event to track when users make a purchase after a previous Algolia request.\nIf you're building your category pages with Algolia, you'll also use this event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "eventSubtype": { - "type": "string", - "enum": [ - "purchase" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "objectData": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart events.\n\nIf provided, it must be the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query, used to track purchase events with multiple records that originate from different searches.", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - } - }, - "required": [ - "eventName", - "eventType", - "eventSubtype", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "eventSubtype", - "objectIDs", - "objectData" - ] - }, - { - "type": "object", - "title": "Converted object IDs after search", - "description": "Use this event to track when users convert after a previous Algolia request.\nFor example, a user clicks on an item in the search results to view the product detail page.\nThen, the user adds the item to their shopping cart.\n\nIf you're building your category pages with Algolia,\nyou'll also use this event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "queryID": { - "type": "string", - "pattern": "[0-9a-f]{32}", - "minLength": 32, - "maxLength": 32, - "description": "Unique identifier for a search query.\n\nThe query ID is required for events related to search or browse requests.\nIf you add `clickAnalytics: true` as a search request parameter, the query ID is included in the API response.\n", - "example": "3e48cd0616e466948dd85abf5c3fbbe2" - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "queryID", - "userToken" - ], - "x-discriminator-fields": [ - "queryID", - "eventType" - ] - }, - { - "type": "object", - "title": "Clicked object IDs", - "description": "Use this event to track when users click items unrelated to a previous Algolia request.\nFor example, if you don't use Algolia to build your category pages, use this event.\n\nTo track click events related to Algolia requests, use the \"Clicked object IDs after search\" event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "click" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "objectIDs" - ] - }, - { - "type": "object", - "title": "Purchased object IDs", - "description": "Use this event to track when users make a purchase unrelated to a previous Algolia request. For example, if you don't use Algolia to build your category pages, use this event.\n\nTo track purchase events related to Algolia requests, use the \"Purchased object IDs after search\" event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "eventSubtype": { - "type": "string", - "enum": [ - "purchase" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "objectData": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart event.\n\nIf specified, it must have the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - } - }, - "required": [ - "eventName", - "eventType", - "eventSubtype", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "eventSubtype", - "objectIDs" - ] - }, - { - "type": "object", - "title": "Added to cart object IDs", - "description": "Use this event to track when users add items to their shopping cart unrelated to a previous Algolia request. For example, if you don't use Algolia to build your category pages, use this event.\n\nTo track add-to-cart events related to Algolia requests, use the \"Added to cart object IDs after search\" event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "eventSubtype": { - "type": "string", - "enum": [ - "addToCart" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "currency": { - "type": "string", - "format": "ISO 4217", - "description": "Three-letter [currency code](https://www.iso.org/iso-4217-currency-codes.html).", - "example": "EUR" - }, - "objectData": { - "type": "array", - "description": "Extra information about the records involved in a purchase or add-to-cart event.\n\nIf specified, it must have the same length as `objectIDs`.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "price": { - "description": "The total price of a product, including any discounts, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 9.99 - }, - { - "type": "string", - "example": "9.99" - } - ] - }, - "quantity": { - "type": "integer", - "format": "int32", - "example": 2, - "description": "The quantity of a product that has been purchased or added to the cart.\nThe total value of a purchase is the sum of `quantity` multiplied with the `price` for each purchased item.\n" - }, - "discount": { - "description": "The absolute value of the discount for this product, in units of `currency`.\n", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 20 - }, - { - "type": "string", - "example": "20" - } - ] - } - } - }, - "minItems": 1, - "maxItems": 20 - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - }, - "value": { - "description": "Total monetary value of this event in units of `currency`.", - "oneOf": [ - { - "type": "number", - "format": "double", - "example": 1000 - }, - { - "type": "string", - "example": "1000.00" - } - ] - } - }, - "required": [ - "eventName", - "eventType", - "eventSubtype", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "eventSubtype", - "objectIDs" - ] - }, - { - "type": "object", - "title": "Converted object IDs", - "description": "Use this event to track when users convert on items unrelated to a previous Algolia request.\nFor example, if you don't use Algolia to build your category pages, use this event.\n\nTo track conversion events related to Algolia requests, use the \"Converted object IDs after search\" event.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "objectIDs" - ] - }, - { - "type": "object", - "title": "Clicked filters", - "description": "Use this event to track when users click facet filters in your user interface.", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "click" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "filters": { - "type": "array", - "description": "Facet filters.\n\nEach facet filter string must be URL-encoded, such as, `discount:10%25`.\n", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "brand:apple" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "filters", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "filters" - ] - }, - { - "type": "object", - "title": "Converted filters", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "conversion" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "filters": { - "type": "array", - "description": "Facet filters.\n\nEach facet filter string must be URL-encoded, such as, `discount:10%25`.\n", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "brand:apple" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "filters", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "filters" - ] - }, - { - "type": "object", - "title": "Viewed object IDs", - "description": "Use this event to track when users viewed items in the search results.", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "view" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "objectIDs": { - "type": "array", - "description": "The object IDs of the records that are part of the event.", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "object-1", - "object-2", - "object-3" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "objectIDs", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "objectIDs" - ] - }, - { - "type": "object", - "title": "Viewed filters", - "description": "Use this method to capture active filters.\nFor example, when browsing a category page,\nusers see content filtered on that specific category.\n", - "additionalProperties": false, - "properties": { - "eventName": { - "type": "string", - "minLength": 1, - "maxLength": 64, - "pattern": "[\\x20-\\x7E]{1,64}", - "description": "The name of the event, up to 64 ASCII characters.\n\nConsider naming events consistently—for example, by adopting Segment's\n[object-action](https://segment.com/academy/collecting-data/naming-conventions-for-clean-data/#the-object-action-framework)\nframework.\n", - "example": "Product Clicked" - }, - "eventType": { - "type": "string", - "enum": [ - "view" - ] - }, - "index": { - "type": "string", - "description": "The name of an Algolia index.", - "example": "YourIndexName" - }, - "filters": { - "type": "array", - "description": "Facet filters.\n\nEach facet filter string must be URL-encoded, such as, `discount:10%25`.\n", - "items": { - "type": "string" - }, - "minItems": 1, - "maxItems": 20, - "example": [ - "brand:apple" - ] - }, - "userToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An anonymous or pseudonymous user identifier.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "test-user-1" - }, - "authenticatedUserToken": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+-]{1,129}", - "description": "An identifier for authenticated users.\n\n> **Note**: Never include personally identifiable information in user tokens.\n", - "example": "c6a52c02-d0c7-4b53-8ce3-2b8fd202f3f9" - }, - "timestamp": { - "type": "integer", - "format": "int64", - "description": "The timestamp of the event in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time).\nBy default, the Insights API uses the time it receives an event as its timestamp.\n", - "example": 1687193127 - } - }, - "required": [ - "eventName", - "eventType", - "index", - "filters", - "userToken" - ], - "x-discriminator-fields": [ - "eventType", - "filters" - ] - } - ] - } - } - } - }, - "examples": { - "ClickObjectIDsAfterSearch": { - "summary": "Click event after search requests.", - "value": { - "events": [ - { - "eventName": "Products Clicked", - "eventType": "click", - "index": "test-index", - "userToken": "anonymous-user-1", - "authenticatedUserToken": "user-1", - "objectIDs": [ - "object-1" - ], - "positions": [ - 1 - ], - "queryID": "7dfe2ada7bca48bdd0629649df0bee07" - } - ] - } - }, - "ConversionObjectIDsAfterSearch": { - "summary": "Conversion event after search or browse requests.", - "value": { - "events": [ - { - "eventName": "Articles Liked", - "eventType": "conversion", - "index": "test-index", - "userToken": "anonymous-user-1", - "authenticatedUserToken": "user-1", - "objectIDs": [ - "article-1" - ], - "queryID": "7dfe2ada7bca48bdd0629649df0bee07" - } - ] - } - }, - "AddedToCartAfterSearch": { - "summary": "Add-to-cart event after search or browse requests.", - "value": { - "events": [ - { - "eventName": "Products Added To Cart", - "eventType": "conversion", - "eventSubtype": "addToCart", - "index": "test-index", - "userToken": "anonymous-user-1", - "authenticatedUserToken": "user-1", - "objectIDs": [ - "product-1" - ], - "objectData": [ - { - "price": 50, - "quantity": 1 - } - ], - "currency": "USD", - "queryID": "7dfe2ada7bca48bdd0629649df0bee07" - } - ] - } - }, - "PurchasedAfterSearch": { - "summary": "Purchase event after search or browse requests.", - "value": { - "events": [ - { - "eventName": "Products Purchased", - "eventType": "conversion", - "eventSubtype": "purchase", - "index": "test-index", - "userToken": "anonymous-user-1", - "authenticatedUserToken": "user-1", - "objectIDs": [ - "product-1", - "product-2" - ], - "objectData": [ - { - "price": 49.99, - "discount": 1.99, - "quantity": 1, - "queryID": "7dfe2ada7bca48bdd0629649df0bee07" - }, - { - "price": 9.99, - "discount": 0, - "quantity": 2, - "queryID": "54ed4c9d94050a25e4e5ccf5d256ca42" - } - ], - "value": 69.97, - "currency": "USD" - } - ] - } - }, - "ClickObjectIDs": { - "summary": "Click event.", - "value": { - "events": [ - { - "eventName": "Products Clicked", - "eventType": "click", - "index": "test-index", - "userToken": "anonymous-user-1", - "authenticatedUserToken": "user-1", - "objectIDs": [ - "object-1" - ] - } - ] - } - }, - "ConversionObjectIDs": { - "summary": "Conversion event.", - "value": { - "events": [ - { - "eventName": "Products Added To Cart", - "eventType": "conversion", - "index": "test-index", - "userToken": "anonymous-user-1", - "authenticatedUserToken": "user-1", - "objectIDs": [ - "object-1" - ] - } - ] - } - }, - "AddedToCart": { - "summary": "Add-to-cart event.", - "value": { - "events": [ - { - "eventName": "Products Added To Cart", - "eventType": "conversion", - "eventSubtype": "addToCart", - "index": "test-index", - "userToken": "anonymous-user-1", - "authenticatedUserToken": "user-1", - "objectIDs": [ - "product-1" - ], - "objectData": [ - { - "price": 19.99, - "quantity": 1 - } - ], - "currency": "EUR" - } - ] - } - }, - "Purchased": { - "summary": "Purchase event.", - "value": { - "events": [ - { - "eventName": "Products Purchased", - "eventType": "conversion", - "eventSubtype": "purchase", - "index": "test-index", - "userToken": "anonymous-user-1", - "authenticatedUserToken": "user-1", - "objectIDs": [ - "product-1", - "product-2" - ], - "objectData": [ - { - "price": 49.99, - "quantity": 1 - }, - { - "price": 9.99, - "quantity": 2 - } - ], - "currency": "USD", - "value": 69.97 - } - ] - } - }, - "ClickFilter": { - "summary": "Click event with filters.", - "value": { - "events": [ - { - "eventName": "Category Clicked", - "eventType": "click", - "index": "test-index", - "userToken": "anonymous-user-1", - "authenticatedUserToken": "user-1", - "filters": [ - "category:books" - ] - } - ] - } - }, - "ConversionFilter": { - "summary": "Conversion event with filters.", - "value": { - "events": [ - { - "eventName": "Category Converted", - "eventType": "conversion", - "index": "test-index", - "userToken": "anonymous-user-1", - "authenticatedUserToken": "user-1", - "filters": [ - "category:books" - ] - } - ] - } - }, - "ViewObjectIDs": { - "summary": "View event.", - "value": { - "events": [ - { - "eventName": "Products Viewed", - "eventType": "view", - "index": "test-index", - "userToken": "anonymous-user-1", - "authenticatedUserToken": "user-1", - "objectIDs": [ - "object-1" - ] - } - ] - } - }, - "ViewFilters": { - "summary": "View event with filters.", - "value": { - "events": [ - { - "eventName": "Category Viewed", - "eventType": "view", - "index": "test-index", - "userToken": "anonymous-user-1", - "authenticatedUserToken": "user-1", - "filters": [ - "category:books" - ] - } - ] - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "The response of the Insights API.", - "additionalProperties": false, - "properties": { - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - }, - "status": { - "type": "integer", - "description": "The HTTP status code of the response." - } - } - }, - "examples": { - "Success": { - "summary": "Events successfully sent to the Insights API.", - "description": "Success indicates that the Insights API received the events correctly, and that event properties are formatted correctly. Success doesn't imply that the event can be used by any Algolia feature. For example, the Insights API doesn't check if the index name you provided exists, or if the object IDs exist in your index.", - "value": { - "status": 200, - "message": "OK" - } - } - } - } - } - }, - "400": { - "description": "Bad Request.", - "content": { - "text/html": { - "schema": { - "type": "string", - "title": "HTML" - }, - "examples": { - "BadRequest": { - "summary": "Bad request.", - "description": "This error doesn't return a JSON object, but HTML.", - "value": "Error: Bad Request. Your client has issued a malformed or illegal request." - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "The response of the Insights API.", - "additionalProperties": false, - "properties": { - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - }, - "status": { - "type": "integer", - "description": "The HTTP status code of the response." - } - } - }, - "examples": { - "Unauthorized": { - "summary": "Invalid credentials.", - "description": "You need to provide your application ID using the `X-Algolia-Application-ID` header and your (search) API key with the `X-Algolia-API-Key` header.", - "value": { - "status": 401, - "message": "Invalid credentials" - } - } - } - } - } - }, - "404": { - "description": "Not Found.", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "The response of the Insights API.", - "additionalProperties": false, - "properties": { - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - }, - "status": { - "type": "integer", - "description": "The HTTP status code of the response." - } - } - }, - "examples": { - "NotFound": { - "summary": "Unsupported operation.", - "description": "Check that you're using the correct URL.", - "value": { - "status": 404, - "message": "Path not supported by Insights REST API. Please have a look at [https://www.algolia.com/doc/rest-api/insights/](https://www.algolia.com/doc/rest-api/insights/) for the list of valid commands." - } - } - } - } - } - }, - "405": { - "description": "Method Not Allowed.", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "The response of the Insights API.", - "additionalProperties": false, - "properties": { - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - }, - "status": { - "type": "integer", - "description": "The HTTP status code of the response." - } - } - }, - "examples": { - "MethodNotAllowed": { - "summary": "Method not allowed.", - "description": "Check, that you send events with the `POST` method.", - "value": { - "status": 405, - "message": "Method Not Allowed" - } - } - } - } - } - }, - "413": { - "description": "Payload Too Large.", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "The response of the Insights API.", - "additionalProperties": false, - "properties": { - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - }, - "status": { - "type": "integer", - "description": "The HTTP status code of the response." - } - } - }, - "examples": { - "PayloadTooLarge": { - "summary": "Request body larger than 2 MB.", - "value": { - "status": 413, - "message": "Request Entity Too Large" - } - } - } - } - } - }, - "422": { - "description": "Unprocessable Entity.", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "The response of the Insights API.", - "additionalProperties": false, - "properties": { - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - }, - "status": { - "type": "integer", - "description": "The HTTP status code of the response." - } - } - }, - "examples": { - "InvalidPayload": { - "summary": "Incorrect event object.", - "value": { - "status": 422, - "message": "Invalid payload" - } - }, - "NoEvents": { - "summary": "No events.", - "description": "This can happen if you're sending an empty `events` array, or if you try to send a single event object instead of the `events` array.", - "value": { - "status": 422, - "message": "No events to process" - } - }, - "NoEventsField": { - "summary": "Missing events attribute.", - "description": "This can happen if you try to send an array of events directly instead of using the `events` attribute.", - "value": { - "status": 422, - "message": "Invalid type for field : expected insights.PublicEventsBatch, got array" - } - }, - "EventNameRequired": { - "summary": "Missing eventName attribute.", - "value": { - "status": 422, - "message": "EventName is required" - } - }, - "WrongEventName": { - "summary": "Event name too long or wrong characters.", - "value": { - "status": 422, - "message": "EventName must contain only visible ASCII characters, and be between 1 and 64 characters long" - } - }, - "EventTypeRequired": { - "summary": "Missing eventType attribute.", - "value": { - "status": 422, - "message": "EventType is required" - } - }, - "WrongEventType": { - "summary": "Wrong event type.", - "value": { - "status": 422, - "message": "EventType must be one of \"click\", \"conversion\" or \"view\"" - } - }, - "IndexRequired": { - "summary": "Missing index attribute.", - "value": { - "status": 422, - "message": "The index field is required" - } - }, - "UserTokenRequired": { - "summary": "Missing userToken attribute.", - "value": { - "status": 422, - "message": "The userToken field is required" - } - }, - "WrongUserToken": { - "summary": "Malformed user token.", - "value": { - "status": 422, - "message": "UserToken must contain only alphanumeric, equal, plus, slash, hyphen, or underscore characters, and be between 1 and 128 characters long" - } - }, - "NoObjectIDsOrFilters": { - "summary": "Missing objectIDs or filters attribute.", - "description": "Each event must include either the `objectIDs` or `filters` attribute.", - "value": { - "status": 422, - "message": "Event should specify either some ObjectIDs or some Filters" - } - }, - "BothDefined": { - "summary": "Both objectIDs and filters attributes defined.", - "value": { - "status": 422, - "message": "Event should specify ObjectIDs or Filters, but not both" - } - }, - "PositionsOnWrongEventType": { - "summary": "Wrong combination of positions and eventType attributes.", - "value": { - "status": 422, - "message": "Only event of type click should specify the positions attribute" - } - }, - "PositionsWithoutQueryID": { - "summary": "Positions attribute without queryID.", - "description": "Click events with the `positions` attribute require the `queryID` attribute.", - "value": { - "status": 422, - "message": "Event of type click with positions should specify a queryID" - } - }, - "WrongPositionsValue": { - "summary": "Wrong value in positions array.", - "description": "Any value in the `positions` array must be greater than 0.", - "value": { - "status": 422, - "message": "Event of type click may only have strictly positive positions" - } - }, - "WrongPositionsItems": { - "summary": "Wrong number of items in positions array.", - "description": "For click events with the `queryID` and `objectIDs` attributes, you must include the `positions` attribute with the same number of items as the `objectIDs` attribute.", - "value": { - "status": 422, - "message": "Event of type click should have the same number of ObjectIDs and Positions" - } - }, - "WrongQueryID": { - "summary": "Malformed query ID.", - "value": { - "status": 422, - "message": "Query ID must be a search query ID (32 characters hexadecimal string)" - } - }, - "InvalidDataType": { - "summary": "Wrong data type.", - "description": "This can happen if one or more attribute is a number instead of a string.", - "value": { - "status": 422, - "message": "Invalid type for field events: expected string, got number" - } - }, - "InvalidTimestamp": { - "summary": "Timestamp too old.", - "value": { - "status": 422, - "message": "The timestamp must be at most 4 days in the past" - } - }, - "TooManyEvents": { - "summary": "Too many events.", - "description": "You can include up to 1,000 events in a single API request.", - "value": { - "status": 422, - "message": "Cannot process more than 1000 events in a batch" - } - } - } - } - } - } - } - } - }, - "/1/usertokens/{userToken}": { - "delete": { - "tags": [ - "usertokens" - ], - "operationId": "deleteUserToken", - "summary": "Delete user token.", - "description": "Delete all events related to a certain user token from events metrics and analytics.\nTo delete a personalization user profile, see [Delete a user profile](https://www.algolia.com/doc/rest-api/personalization/#delete-a-user-profile).\n", - "parameters": [ - { - "name": "userToken", - "in": "path", - "description": "The user token for which to delete all associated events.", - "required": true, - "schema": { - "type": "string", - "minLength": 1, - "maxLength": 129, - "pattern": "[a-zA-Z0-9_=/+]{1,129}", - "example": "test-user-1" - } - } - ], - "responses": { - "204": { - "description": "No content.", - "headers": { - "x-ratelimit-limit": { - "description": "The current rate limit. The maximum number of requests you can make to this endpoint.", - "schema": { - "type": "integer" - } - }, - "x-ratelimit-remaining": { - "description": "The number of remaining API requests you can make to this endpoint before reaching the rate limit.", - "schema": { - "type": "integer" - } - }, - "x-ratelimit-reset": { - "description": "The timestamp in Unix epoch time when the rate limit will reset.", - "schema": { - "type": "integer" - } - } - } - }, - "422": { - "description": "Unprocessable Entity.", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "The response of the Insights API.", - "additionalProperties": false, - "properties": { - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - }, - "status": { - "type": "integer", - "description": "The HTTP status code of the response." - } - } - } - } - } - }, - "429": { - "description": "Too Many Requests. This operation is rate-limited. Check the `x-ratelimit-limit` and `x-ratelimit-reset` headers of the response.\n", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "The response of the Insights API.", - "additionalProperties": false, - "properties": { - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - }, - "status": { - "type": "integer", - "description": "The HTTP status code of the response." - } - } - } - } - } - } - } - } - } - } -} \ No newline at end of file diff --git a/specs/bundled/monitoring.json b/specs/bundled/monitoring.json deleted file mode 100644 index b511ec16cc..0000000000 --- a/specs/bundled/monitoring.json +++ /dev/null @@ -1,2803 +0,0 @@ -{ - "openapi": "3.0.2", - "info": { - "title": "Algolia Monitoring API", - "description": "The Monitoring API lets you check the status and performance of your Algolia\ninfrastructure.\n\n> **Note**: The Monitoring API is available on [Premium\nplans](https://www.algolia.com/pricing/) and plans including the Enterprise\nadd-on.\n", - "version": "1.0.0" - }, - "servers": [ - { - "url": "https://status.algolia.com" - } - ], - "components": { - "securitySchemes": { - "appId": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-Application-Id", - "description": "Your Algolia application ID." - }, - "apiKey": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-API-Key", - "description": "Your Algolia API key. Make sure to use your Monitoring API key." - } - }, - "parameters": { - "PathInPath": { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - "Parameters": { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - }, - "Clusters": { - "name": "clusters", - "in": "path", - "required": true, - "description": "Subset of clusters, separated by comma.", - "schema": { - "type": "string", - "example": "c1-de,c2-de,c3-de" - } - }, - "MetricInPath": { - "name": "metric", - "in": "path", - "required": true, - "description": "Metric to report.\n\nFor more information about the individual metrics, see the response.\nTo include all metrics, use `*` as the parameter.\n", - "schema": { - "type": "string", - "enum": [ - "avg_build_time", - "ssd_usage", - "ram_search_usage", - "ram_indexing_usage", - "cpu_usage", - "*" - ], - "example": "*" - } - }, - "PeriodInPath": { - "name": "period", - "in": "path", - "required": true, - "description": "Period over which to aggregate the metrics:\n\n- `minute`. Aggregate the last minute. 1 data point per 10 seconds.\n- `hour`. Aggregate the last hour. 1 data point per minute.\n- `day`. Aggregate the last day. 1 data point per 10 minutes.\n- `week`. Aggregate the last week. 1 data point per hour.\n- `month`. Aggregate the last month. 1 data point per day.\n", - "schema": { - "type": "string", - "enum": [ - "minute", - "hour", - "day", - "week", - "month" - ], - "example": "week" - } - } - }, - "schemas": { - "ErrorBase": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - }, - "Status": { - "title": "status", - "type": "string", - "description": "Status of the cluster.", - "enum": [ - "operational", - "degraded_performance", - "partial_outage", - "major_outage" - ] - }, - "Timestamp": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "Incident": { - "title": "incident", - "description": "Incident details.", - "type": "object", - "properties": { - "title": { - "type": "string", - "description": "Description of the incident." - }, - "status": { - "title": "status", - "type": "string", - "description": "Status of the cluster.", - "enum": [ - "operational", - "degraded_performance", - "partial_outage", - "major_outage" - ] - } - } - }, - "Incidents": { - "title": "incidents", - "description": "Key-value pairs with the cluster names as keys and the list of incidents reported for this cluster as values.", - "type": "array", - "items": { - "type": "object", - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "title": "incident", - "description": "Incident details.", - "type": "object", - "properties": { - "title": { - "type": "string", - "description": "Description of the incident." - }, - "status": { - "title": "status", - "type": "string", - "description": "Status of the cluster.", - "enum": [ - "operational", - "degraded_performance", - "partial_outage", - "major_outage" - ] - } - } - } - } - } - }, - "Region": { - "title": "region", - "type": "string", - "description": "The region where the cluster is located.", - "enum": [ - "au", - "br", - "ca", - "de", - "eu", - "hk", - "in", - "jp", - "sg", - "uae", - "uk", - "usc", - "use", - "usw", - "za" - ], - "example": "de" - }, - "ServerStatus": { - "title": "status", - "type": "string", - "enum": [ - "PRODUCTION" - ] - }, - "Type": { - "title": "type", - "type": "string", - "enum": [ - "cluster" - ] - }, - "Server": { - "title": "server", - "additionalProperties": false, - "properties": { - "name": { - "type": "string", - "description": "Server name.", - "example": "c16-de-1" - }, - "region": { - "title": "region", - "type": "string", - "description": "The region where the cluster is located.", - "enum": [ - "au", - "br", - "ca", - "de", - "eu", - "hk", - "in", - "jp", - "sg", - "uae", - "uk", - "usc", - "use", - "usw", - "za" - ], - "example": "de" - }, - "is_slave": { - "type": "boolean", - "default": false, - "deprecated": true, - "description": "Included to support legacy applications.\nDo not rely on this attribute being present in the response.\nUse `is_replica` instead.\n", - "example": false - }, - "is_replica": { - "type": "boolean", - "default": false, - "description": "Indicates whether this server is a replica of another server.", - "example": false - }, - "cluster": { - "type": "string", - "description": "Name of the cluster to which this server belongs.", - "example": "c16-de" - }, - "status": { - "title": "status", - "type": "string", - "enum": [ - "PRODUCTION" - ] - }, - "type": { - "title": "type", - "type": "string", - "enum": [ - "cluster" - ] - } - } - }, - "Time": { - "title": "time", - "description": "Time measured by a probe.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Time in ms." - } - } - } - }, - "Probes": { - "title": "probes", - "description": "Probes and their response.", - "type": "object", - "additionalProperties": { - "x-additionalPropertiesName": "probe", - "type": "boolean", - "description": "Key-value pair with the probe name as the key and the reachability status as the value." - } - }, - "Metric": { - "type": "string", - "enum": [ - "avg_build_time", - "ssd_usage", - "ram_search_usage", - "ram_indexing_usage", - "cpu_usage", - "*" - ], - "example": "*" - }, - "Period": { - "type": "string", - "enum": [ - "minute", - "hour", - "day", - "week", - "month" - ], - "example": "week" - }, - "ProbesMetric": { - "title": "metric", - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Value of the metric." - } - } - }, - "InfraProbes": { - "title": "probes", - "type": "array", - "items": { - "title": "metric", - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Value of the metric." - } - } - } - } - }, - "responses": { - "BadRequest": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "FeatureNotEnabled": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "MethodNotAllowed": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "IndexNotFound": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "StatusResponse": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "StatusResponse", - "type": "object", - "properties": { - "status": { - "type": "object", - "additionalProperties": { - "x-additionalPropertiesName": "status", - "title": "status", - "type": "string", - "description": "Status of the cluster.", - "enum": [ - "operational", - "degraded_performance", - "partial_outage", - "major_outage" - ] - } - } - } - }, - "examples": { - "Success": { - "value": { - "status": { - "c16-de": "operational" - } - } - } - } - } - } - }, - "UnauthorizedResponse": { - "description": "Unauthorized", - "content": { - "text/plain": { - "schema": { - "type": "string" - }, - "examples": { - "Unauthorized": { - "summary": "Invalid credentials.", - "description": "Make sure to use the Monitoring API key if you authenticate your API requests.", - "value": "Invalid credentials" - } - } - } - } - }, - "NotFoundResponse": { - "description": "Not Found.", - "content": { - "text/plain": { - "schema": { - "type": "string" - }, - "examples": { - "NotFound": { - "value": "Unknown cluster \"test\"" - } - } - } - } - }, - "IncidentsResponse": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "IncidentsResponse", - "type": "object", - "properties": { - "incidents": { - "type": "object", - "additionalProperties": { - "x-additionalPropertiesName": "cluster", - "title": "incidents", - "description": "Key-value pairs with the cluster names as keys and the list of incidents reported for this cluster as values.", - "type": "array", - "items": { - "type": "object", - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "title": "incident", - "description": "Incident details.", - "type": "object", - "properties": { - "title": { - "type": "string", - "description": "Description of the incident." - }, - "status": { - "title": "status", - "type": "string", - "description": "Status of the cluster.", - "enum": [ - "operational", - "degraded_performance", - "partial_outage", - "major_outage" - ] - } - } - } - } - } - } - } - } - }, - "examples": { - "success": { - "value": { - "incidents": { - "m134-de": [ - { - "t": 1687441685000, - "v": { - "title": "Incident on cluster m134-de: Everything operating normally.", - "status": "operational" - } - }, - { - "t": 1687441579000, - "v": { - "title": "Incident on cluster m134-de: We are encountering a major issue that impact all API calls.", - "status": "major_outage" - } - } - ] - } - } - } - } - } - } - }, - "InventoryResponse": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "InventoryResponse", - "type": "object", - "properties": { - "inventory": { - "type": "array", - "items": { - "title": "server", - "additionalProperties": false, - "properties": { - "name": { - "type": "string", - "description": "Server name.", - "example": "c16-de-1" - }, - "region": { - "title": "region", - "type": "string", - "description": "The region where the cluster is located.", - "enum": [ - "au", - "br", - "ca", - "de", - "eu", - "hk", - "in", - "jp", - "sg", - "uae", - "uk", - "usc", - "use", - "usw", - "za" - ], - "example": "de" - }, - "is_slave": { - "type": "boolean", - "default": false, - "deprecated": true, - "description": "Included to support legacy applications.\nDo not rely on this attribute being present in the response.\nUse `is_replica` instead.\n", - "example": false - }, - "is_replica": { - "type": "boolean", - "default": false, - "description": "Indicates whether this server is a replica of another server.", - "example": false - }, - "cluster": { - "type": "string", - "description": "Name of the cluster to which this server belongs.", - "example": "c16-de" - }, - "status": { - "title": "status", - "type": "string", - "enum": [ - "PRODUCTION" - ] - }, - "type": { - "title": "type", - "type": "string", - "enum": [ - "cluster" - ] - } - } - } - } - } - }, - "examples": { - "Success": { - "value": { - "inventory": [ - { - "name": "c16-de-3", - "region": "de", - "is_slave": false, - "is_replica": false, - "cluster": "c16-de", - "status": "PRODUCTION", - "type": "cluster" - }, - { - "name": "c16-de-2", - "region": "de", - "is_slave": false, - "is_replica": false, - "cluster": "c16-de", - "status": "PRODUCTION", - "type": "cluster" - }, - { - "name": "c16-de-1", - "region": "de", - "is_slave": false, - "is_replica": false, - "cluster": "c16-de", - "status": "PRODUCTION", - "type": "cluster" - } - ] - } - } - } - } - } - }, - "ForbiddenResponse": { - "description": "Forbidden", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "reason": { - "type": "string" - } - } - }, - "examples": { - "Forbidden": { - "value": { - "reason": "invalid credentials" - } - } - } - } - } - }, - "LatencyResponse": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "LatencyResponse", - "type": "object", - "properties": { - "metrics": { - "type": "object", - "additionalProperties": false, - "properties": { - "latency": { - "additionalProperties": { - "x-additionalPropertiesName": "latencies", - "title": "time", - "description": "Time measured by a probe.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Time in ms." - } - } - } - } - } - } - } - } - }, - "examples": { - "Success": { - "value": { - "metrics": { - "latency": { - "c16-de": [ - { - "t": 1688056200000, - "v": 64 - }, - { - "t": 1688056800000, - "v": 59 - }, - { - "t": 1688057400000, - "v": 55 - } - ] - } - } - } - } - } - } - } - }, - "BadRequestResponse": { - "description": "Bad Request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "reason": { - "type": "string" - } - } - }, - "examples": { - "BadRequest": { - "value": { - "reason": "Unknown servers" - } - } - } - } - } - }, - "IndexingResponse": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "IndexingTimeResponse", - "type": "object", - "properties": { - "metrics": { - "type": "object", - "additionalProperties": false, - "properties": { - "indexing": { - "additionalProperties": { - "x-additionalPropertiesName": "times", - "title": "time", - "description": "Time measured by a probe.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Time in ms." - } - } - } - } - } - } - } - } - }, - "examples": { - "Success": { - "value": { - "metrics": { - "indexing": { - "c16-de": [ - { - "t": 1688056200000, - "v": 1562 - }, - { - "t": 1688056800000, - "v": 1637 - }, - { - "t": 1688057400000, - "v": 1754 - } - ] - } - } - } - } - } - } - } - }, - "ReachabilityResponse": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "ReachabilityResponse", - "type": "object", - "additionalProperties": { - "x-additionalPropertiesName": "Server", - "title": "probes", - "description": "Probes and their response.", - "type": "object", - "additionalProperties": { - "x-additionalPropertiesName": "probe", - "type": "boolean", - "description": "Key-value pair with the probe name as the key and the reachability status as the value." - } - } - }, - "examples": { - "Success": { - "value": { - "c16-de": { - "sdn-probe-frankfurt": false, - "monitoring-2": false, - "sdn-probe-awswest1": false - } - } - } - } - } - } - }, - "InfrastructureResponse": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "InfrastructureResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "metrics": { - "type": "object", - "additionalProperties": false, - "properties": { - "cpu_usage": { - "type": "object", - "description": "CPU idleness in %.", - "additionalProperties": { - "x-additionalPropertiesName": "probes", - "title": "probes", - "type": "array", - "items": { - "title": "metric", - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Value of the metric." - } - } - } - } - }, - "ram_indexing_usage": { - "type": "object", - "description": "RAM used for indexing in MB.", - "additionalProperties": { - "x-additionalPropertiesName": "probes", - "title": "probes", - "type": "array", - "items": { - "title": "metric", - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Value of the metric." - } - } - } - } - }, - "ram_search_usage": { - "type": "object", - "description": "RAM used for search in MB.", - "additionalProperties": { - "x-additionalPropertiesName": "probes", - "title": "probes", - "type": "array", - "items": { - "title": "metric", - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Value of the metric." - } - } - } - } - }, - "ssd_usage": { - "type": "object", - "description": "Solid-state disk (SSD) usage expressed as % of RAM. \n0% means no SSD usage. A value of 50% indicates 32 GB SSD usage for a machine with 64 RAM.\n", - "additionalProperties": { - "x-additionalPropertiesName": "probes", - "title": "probes", - "type": "array", - "items": { - "title": "metric", - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Value of the metric." - } - } - } - } - }, - "avg_build_time": { - "type": "object", - "description": "Average build time of the indices in seconds.", - "additionalProperties": { - "x-additionalPropertiesName": "probes", - "title": "probes", - "type": "array", - "items": { - "title": "metric", - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Value of the metric." - } - } - } - } - } - } - } - } - }, - "examples": { - "success": { - "value": { - "metrics": { - "cpu_usage": { - "s4-fr": [ - { - "t": 1455101280, - "v": 46 - }, - { - "t": 1455101290, - "v": 46 - }, - { - "t": 1455101300, - "v": 46 - } - ], - "c3-use-1": [ - { - "t": 1455101280, - "v": 42 - }, - { - "t": 1455101290, - "v": 42 - }, - { - "t": 1455101300, - "v": 42 - }, - { - "t": 1455101310, - "v": 37 - } - ], - "c3-use-2": [ - { - "t": 1455101280, - "v": 56 - }, - { - "t": 1455101290, - "v": 56 - }, - { - "t": 1455101300, - "v": 56 - }, - { - "t": 1455101310, - "v": 56 - }, - { - "t": 1455101320, - "v": 51 - } - ] - } - } - } - } - } - } - } - }, - "InfrastructureAPIUnauthorized": { - "description": "Unauthorized", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "reason": { - "type": "string" - } - } - }, - "examples": { - "Unauthorized": { - "value": { - "reason": "The infrastructure usage API is only available on Enterprise plans. Please contact enterprise@algolia.com for more detail." - } - } - } - } - } - } - } - }, - "tags": [ - { - "name": "incidents", - "description": "List the known incidents.", - "x-displayName": "Incidents" - }, - { - "name": "infrastructure", - "description": "Return information about the Algolia infrastructure used by your application.", - "x-displayName": "Infrastructure" - }, - { - "name": "monitoring-tag", - "description": "Report search and indexing times for your clusters, and get a list of servers.", - "x-displayName": "Monitoring" - }, - { - "name": "status", - "description": "Report the status of your clusters.\n\nAt Algolia, your application is hosted on a [cluster with three\nservers](https://www.algolia.com/doc/guides/scaling/servers-clusters/).\n\nCluster names follow a pattern: `c{[0-9]+}-{region}` where `{region}` is\none of the supported Algolia regions.\n\nServer names follow the pattern: `{cluster-name}-{1|2|3}`.\n", - "x-displayName": "Status" - } - ], - "paths": { - "/1{path}": { - "get": { - "operationId": "customGet", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "operationId": "customPost", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "operationId": "customPut", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "operationId": "customDelete", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/status": { - "get": { - "operationId": "getStatus", - "summary": "List cluster statuses.", - "tags": [ - "status" - ], - "security": [ - { - "appId": [] - }, - { - "apiKey": [] - } - ], - "description": "Report whether clusters are operational.\n\nThe response depends on whether you authenticate your API request.\n\n- With authentication, the response includes the status of the cluster\nassigned to your Algolia application.\n\n- Without authentication, the response lists the statuses of all public\nAlgolia clusters.\n", - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "StatusResponse", - "type": "object", - "properties": { - "status": { - "type": "object", - "additionalProperties": { - "x-additionalPropertiesName": "status", - "title": "status", - "type": "string", - "description": "Status of the cluster.", - "enum": [ - "operational", - "degraded_performance", - "partial_outage", - "major_outage" - ] - } - } - } - }, - "examples": { - "Success": { - "value": { - "status": { - "c16-de": "operational" - } - } - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "text/plain": { - "schema": { - "type": "string" - }, - "examples": { - "Unauthorized": { - "summary": "Invalid credentials.", - "description": "Make sure to use the Monitoring API key if you authenticate your API requests.", - "value": "Invalid credentials" - } - } - } - } - } - } - } - }, - "/1/status/{clusters}": { - "get": { - "summary": "List statuses of selected clusters.", - "description": "Report whether a cluster is operational.", - "operationId": "getClusterStatus", - "tags": [ - "status" - ], - "security": [], - "parameters": [ - { - "name": "clusters", - "in": "path", - "required": true, - "description": "Subset of clusters, separated by comma.", - "schema": { - "type": "string", - "example": "c1-de,c2-de,c3-de" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "StatusResponse", - "type": "object", - "properties": { - "status": { - "type": "object", - "additionalProperties": { - "x-additionalPropertiesName": "status", - "title": "status", - "type": "string", - "description": "Status of the cluster.", - "enum": [ - "operational", - "degraded_performance", - "partial_outage", - "major_outage" - ] - } - } - } - }, - "examples": { - "Success": { - "value": { - "status": { - "c16-de": "operational" - } - } - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "text/plain": { - "schema": { - "type": "string" - }, - "examples": { - "Unauthorized": { - "summary": "Invalid credentials.", - "description": "Make sure to use the Monitoring API key if you authenticate your API requests.", - "value": "Invalid credentials" - } - } - } - } - }, - "404": { - "description": "Not Found.", - "content": { - "text/plain": { - "schema": { - "type": "string" - }, - "examples": { - "NotFound": { - "value": "Unknown cluster \"test\"" - } - } - } - } - } - } - } - }, - "/1/incidents": { - "get": { - "summary": "List incidents.", - "description": "List known incidents for all clusters.", - "operationId": "getIncidents", - "security": [], - "tags": [ - "incidents" - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "IncidentsResponse", - "type": "object", - "properties": { - "incidents": { - "type": "object", - "additionalProperties": { - "x-additionalPropertiesName": "cluster", - "title": "incidents", - "description": "Key-value pairs with the cluster names as keys and the list of incidents reported for this cluster as values.", - "type": "array", - "items": { - "type": "object", - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "title": "incident", - "description": "Incident details.", - "type": "object", - "properties": { - "title": { - "type": "string", - "description": "Description of the incident." - }, - "status": { - "title": "status", - "type": "string", - "description": "Status of the cluster.", - "enum": [ - "operational", - "degraded_performance", - "partial_outage", - "major_outage" - ] - } - } - } - } - } - } - } - } - }, - "examples": { - "success": { - "value": { - "incidents": { - "m134-de": [ - { - "t": 1687441685000, - "v": { - "title": "Incident on cluster m134-de: Everything operating normally.", - "status": "operational" - } - }, - { - "t": 1687441579000, - "v": { - "title": "Incident on cluster m134-de: We are encountering a major issue that impact all API calls.", - "status": "major_outage" - } - } - ] - } - } - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "text/plain": { - "schema": { - "type": "string" - }, - "examples": { - "Unauthorized": { - "summary": "Invalid credentials.", - "description": "Make sure to use the Monitoring API key if you authenticate your API requests.", - "value": "Invalid credentials" - } - } - } - } - } - } - } - }, - "/1/incidents/{clusters}": { - "get": { - "summary": "List incidents for selected clusters.", - "description": "List known incidents for selected clusters.", - "operationId": "getClusterIncidents", - "tags": [ - "incidents" - ], - "security": [], - "parameters": [ - { - "name": "clusters", - "in": "path", - "required": true, - "description": "Subset of clusters, separated by comma.", - "schema": { - "type": "string", - "example": "c1-de,c2-de,c3-de" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "IncidentsResponse", - "type": "object", - "properties": { - "incidents": { - "type": "object", - "additionalProperties": { - "x-additionalPropertiesName": "cluster", - "title": "incidents", - "description": "Key-value pairs with the cluster names as keys and the list of incidents reported for this cluster as values.", - "type": "array", - "items": { - "type": "object", - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "title": "incident", - "description": "Incident details.", - "type": "object", - "properties": { - "title": { - "type": "string", - "description": "Description of the incident." - }, - "status": { - "title": "status", - "type": "string", - "description": "Status of the cluster.", - "enum": [ - "operational", - "degraded_performance", - "partial_outage", - "major_outage" - ] - } - } - } - } - } - } - } - } - }, - "examples": { - "success": { - "value": { - "incidents": { - "m134-de": [ - { - "t": 1687441685000, - "v": { - "title": "Incident on cluster m134-de: Everything operating normally.", - "status": "operational" - } - }, - { - "t": 1687441579000, - "v": { - "title": "Incident on cluster m134-de: We are encountering a major issue that impact all API calls.", - "status": "major_outage" - } - } - ] - } - } - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "text/plain": { - "schema": { - "type": "string" - }, - "examples": { - "Unauthorized": { - "summary": "Invalid credentials.", - "description": "Make sure to use the Monitoring API key if you authenticate your API requests.", - "value": "Invalid credentials" - } - } - } - } - }, - "404": { - "description": "Not Found.", - "content": { - "text/plain": { - "schema": { - "type": "string" - }, - "examples": { - "NotFound": { - "value": "Unknown cluster \"test\"" - } - } - } - } - } - } - } - }, - "/1/inventory/servers": { - "get": { - "summary": "List servers.", - "operationId": "getInventory", - "security": [ - { - "appId": [] - }, - { - "apiKey": [] - } - ], - "description": "List the servers belonging to clusters.\n\nThe response depends on whether you authenticate your API request:\n\n- With authentication, the response lists the servers assigned to your\nAlgolia application's cluster.\n\n- Without authentication, the response lists the servers for all Algolia\nclusters.\n", - "tags": [ - "monitoring-tag" - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "InventoryResponse", - "type": "object", - "properties": { - "inventory": { - "type": "array", - "items": { - "title": "server", - "additionalProperties": false, - "properties": { - "name": { - "type": "string", - "description": "Server name.", - "example": "c16-de-1" - }, - "region": { - "title": "region", - "type": "string", - "description": "The region where the cluster is located.", - "enum": [ - "au", - "br", - "ca", - "de", - "eu", - "hk", - "in", - "jp", - "sg", - "uae", - "uk", - "usc", - "use", - "usw", - "za" - ], - "example": "de" - }, - "is_slave": { - "type": "boolean", - "default": false, - "deprecated": true, - "description": "Included to support legacy applications.\nDo not rely on this attribute being present in the response.\nUse `is_replica` instead.\n", - "example": false - }, - "is_replica": { - "type": "boolean", - "default": false, - "description": "Indicates whether this server is a replica of another server.", - "example": false - }, - "cluster": { - "type": "string", - "description": "Name of the cluster to which this server belongs.", - "example": "c16-de" - }, - "status": { - "title": "status", - "type": "string", - "enum": [ - "PRODUCTION" - ] - }, - "type": { - "title": "type", - "type": "string", - "enum": [ - "cluster" - ] - } - } - } - } - } - }, - "examples": { - "Success": { - "value": { - "inventory": [ - { - "name": "c16-de-3", - "region": "de", - "is_slave": false, - "is_replica": false, - "cluster": "c16-de", - "status": "PRODUCTION", - "type": "cluster" - }, - { - "name": "c16-de-2", - "region": "de", - "is_slave": false, - "is_replica": false, - "cluster": "c16-de", - "status": "PRODUCTION", - "type": "cluster" - }, - { - "name": "c16-de-1", - "region": "de", - "is_slave": false, - "is_replica": false, - "cluster": "c16-de", - "status": "PRODUCTION", - "type": "cluster" - } - ] - } - } - } - } - } - }, - "403": { - "description": "Forbidden", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "reason": { - "type": "string" - } - } - }, - "examples": { - "Forbidden": { - "value": { - "reason": "invalid credentials" - } - } - } - } - } - } - } - } - }, - "/1/latency/{clusters}": { - "get": { - "summary": "Get search latency times.", - "description": "List the average latency for search requests for selected clusters.", - "operationId": "getLatency", - "security": [], - "tags": [ - "monitoring-tag" - ], - "parameters": [ - { - "name": "clusters", - "in": "path", - "required": true, - "description": "Subset of clusters, separated by comma.", - "schema": { - "type": "string", - "example": "c1-de,c2-de,c3-de" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "LatencyResponse", - "type": "object", - "properties": { - "metrics": { - "type": "object", - "additionalProperties": false, - "properties": { - "latency": { - "additionalProperties": { - "x-additionalPropertiesName": "latencies", - "title": "time", - "description": "Time measured by a probe.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Time in ms." - } - } - } - } - } - } - } - } - }, - "examples": { - "Success": { - "value": { - "metrics": { - "latency": { - "c16-de": [ - { - "t": 1688056200000, - "v": 64 - }, - { - "t": 1688056800000, - "v": 59 - }, - { - "t": 1688057400000, - "v": 55 - } - ] - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad Request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "reason": { - "type": "string" - } - } - }, - "examples": { - "BadRequest": { - "value": { - "reason": "Unknown servers" - } - } - } - } - } - } - } - } - }, - "/1/indexing/{clusters}": { - "get": { - "summary": "Get indexing times.", - "description": "List the average times for indexing operations for selected clusters.", - "operationId": "getIndexingTime", - "security": [], - "tags": [ - "monitoring-tag" - ], - "parameters": [ - { - "name": "clusters", - "in": "path", - "required": true, - "description": "Subset of clusters, separated by comma.", - "schema": { - "type": "string", - "example": "c1-de,c2-de,c3-de" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "IndexingTimeResponse", - "type": "object", - "properties": { - "metrics": { - "type": "object", - "additionalProperties": false, - "properties": { - "indexing": { - "additionalProperties": { - "x-additionalPropertiesName": "times", - "title": "time", - "description": "Time measured by a probe.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Time in ms." - } - } - } - } - } - } - } - } - }, - "examples": { - "Success": { - "value": { - "metrics": { - "indexing": { - "c16-de": [ - { - "t": 1688056200000, - "v": 1562 - }, - { - "t": 1688056800000, - "v": 1637 - }, - { - "t": 1688057400000, - "v": 1754 - } - ] - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad Request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "reason": { - "type": "string" - } - } - }, - "examples": { - "BadRequest": { - "value": { - "reason": "Unknown servers" - } - } - } - } - } - } - } - } - }, - "/1/reachability/{clusters}/probes": { - "get": { - "summary": "Test the reachability of clusters.", - "description": "Test whether clusters are reachable or not.", - "operationId": "getReachability", - "security": [], - "tags": [ - "monitoring-tag" - ], - "parameters": [ - { - "name": "clusters", - "in": "path", - "required": true, - "description": "Subset of clusters, separated by comma.", - "schema": { - "type": "string", - "example": "c1-de,c2-de,c3-de" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "ReachabilityResponse", - "type": "object", - "additionalProperties": { - "x-additionalPropertiesName": "Server", - "title": "probes", - "description": "Probes and their response.", - "type": "object", - "additionalProperties": { - "x-additionalPropertiesName": "probe", - "type": "boolean", - "description": "Key-value pair with the probe name as the key and the reachability status as the value." - } - } - }, - "examples": { - "Success": { - "value": { - "c16-de": { - "sdn-probe-frankfurt": false, - "monitoring-2": false, - "sdn-probe-awswest1": false - } - } - } - } - } - } - }, - "400": { - "description": "Bad Request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "reason": { - "type": "string" - } - } - }, - "examples": { - "BadRequest": { - "value": { - "reason": "Unknown servers" - } - } - } - } - } - } - } - } - }, - "/1/infrastructure/{metric}/period/{period}": { - "get": { - "summary": "Get metrics for a given period.", - "description": "Report the aggregate value of a metric for a selected period of time.", - "operationId": "getMetrics", - "tags": [ - "infrastructure" - ], - "parameters": [ - { - "name": "metric", - "in": "path", - "required": true, - "description": "Metric to report.\n\nFor more information about the individual metrics, see the response.\nTo include all metrics, use `*` as the parameter.\n", - "schema": { - "type": "string", - "enum": [ - "avg_build_time", - "ssd_usage", - "ram_search_usage", - "ram_indexing_usage", - "cpu_usage", - "*" - ], - "example": "*" - } - }, - { - "name": "period", - "in": "path", - "required": true, - "description": "Period over which to aggregate the metrics:\n\n- `minute`. Aggregate the last minute. 1 data point per 10 seconds.\n- `hour`. Aggregate the last hour. 1 data point per minute.\n- `day`. Aggregate the last day. 1 data point per 10 minutes.\n- `week`. Aggregate the last week. 1 data point per hour.\n- `month`. Aggregate the last month. 1 data point per day.\n", - "schema": { - "type": "string", - "enum": [ - "minute", - "hour", - "day", - "week", - "month" - ], - "example": "week" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "InfrastructureResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "metrics": { - "type": "object", - "additionalProperties": false, - "properties": { - "cpu_usage": { - "type": "object", - "description": "CPU idleness in %.", - "additionalProperties": { - "x-additionalPropertiesName": "probes", - "title": "probes", - "type": "array", - "items": { - "title": "metric", - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Value of the metric." - } - } - } - } - }, - "ram_indexing_usage": { - "type": "object", - "description": "RAM used for indexing in MB.", - "additionalProperties": { - "x-additionalPropertiesName": "probes", - "title": "probes", - "type": "array", - "items": { - "title": "metric", - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Value of the metric." - } - } - } - } - }, - "ram_search_usage": { - "type": "object", - "description": "RAM used for search in MB.", - "additionalProperties": { - "x-additionalPropertiesName": "probes", - "title": "probes", - "type": "array", - "items": { - "title": "metric", - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Value of the metric." - } - } - } - } - }, - "ssd_usage": { - "type": "object", - "description": "Solid-state disk (SSD) usage expressed as % of RAM. \n0% means no SSD usage. A value of 50% indicates 32 GB SSD usage for a machine with 64 RAM.\n", - "additionalProperties": { - "x-additionalPropertiesName": "probes", - "title": "probes", - "type": "array", - "items": { - "title": "metric", - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Value of the metric." - } - } - } - } - }, - "avg_build_time": { - "type": "object", - "description": "Average build time of the indices in seconds.", - "additionalProperties": { - "x-additionalPropertiesName": "probes", - "title": "probes", - "type": "array", - "items": { - "title": "metric", - "type": "object", - "additionalProperties": false, - "properties": { - "t": { - "type": "integer", - "format": "int64", - "description": "Timestamp in [Unix epoch time](https://wikipedia.org/wiki/Unix_time) in milliseconds." - }, - "v": { - "type": "integer", - "description": "Value of the metric." - } - } - } - } - } - } - } - } - }, - "examples": { - "success": { - "value": { - "metrics": { - "cpu_usage": { - "s4-fr": [ - { - "t": 1455101280, - "v": 46 - }, - { - "t": 1455101290, - "v": 46 - }, - { - "t": 1455101300, - "v": 46 - } - ], - "c3-use-1": [ - { - "t": 1455101280, - "v": 42 - }, - { - "t": 1455101290, - "v": 42 - }, - { - "t": 1455101300, - "v": 42 - }, - { - "t": 1455101310, - "v": 37 - } - ], - "c3-use-2": [ - { - "t": 1455101280, - "v": 56 - }, - { - "t": 1455101290, - "v": 56 - }, - { - "t": 1455101300, - "v": 56 - }, - { - "t": 1455101310, - "v": 56 - }, - { - "t": 1455101320, - "v": 51 - } - ] - } - } - } - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "reason": { - "type": "string" - } - } - }, - "examples": { - "Unauthorized": { - "value": { - "reason": "The infrastructure usage API is only available on Enterprise plans. Please contact enterprise@algolia.com for more detail." - } - } - } - } - } - } - } - } - } - } -} \ No newline at end of file diff --git a/specs/bundled/personalization.json b/specs/bundled/personalization.json deleted file mode 100644 index a600acf7b1..0000000000 --- a/specs/bundled/personalization.json +++ /dev/null @@ -1,1345 +0,0 @@ -{ - "openapi": "3.0.2", - "info": { - "title": "Personalization API", - "description": "API powering the Personalization feature of Algolia.", - "version": "1.0.0" - }, - "components": { - "securitySchemes": { - "appId": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-Application-Id" - }, - "apiKey": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-API-Key" - } - }, - "parameters": { - "PathInPath": { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - "Parameters": { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - }, - "UserToken": { - "name": "userToken", - "in": "path", - "required": true, - "description": "userToken representing the user for which to fetch the Personalization profile.", - "schema": { - "type": "string" - } - } - }, - "schemas": { - "ErrorBase": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - }, - "userToken": { - "type": "string", - "description": "userToken representing the user for which to fetch the Personalization profile." - }, - "score": { - "type": "integer", - "description": "The score for the event." - }, - "eventScoring": { - "type": "object", - "additionalProperties": false, - "required": [ - "score", - "eventName", - "eventType" - ], - "properties": { - "score": { - "type": "integer", - "description": "The score for the event." - }, - "eventName": { - "type": "string", - "description": "The name of the event." - }, - "eventType": { - "type": "string", - "description": "The type of the event." - } - } - }, - "facetScoring": { - "type": "object", - "additionalProperties": false, - "required": [ - "score", - "facetName" - ], - "properties": { - "score": { - "type": "integer", - "description": "The score for the event." - }, - "facetName": { - "type": "string", - "description": "The name of the facet." - } - } - }, - "personalizationStrategyParams": { - "type": "object", - "additionalProperties": false, - "required": [ - "eventScoring", - "facetScoring", - "personalizationImpact" - ], - "properties": { - "eventScoring": { - "type": "array", - "description": "Scores associated with the events.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "score", - "eventName", - "eventType" - ], - "properties": { - "score": { - "type": "integer", - "description": "The score for the event." - }, - "eventName": { - "type": "string", - "description": "The name of the event." - }, - "eventType": { - "type": "string", - "description": "The type of the event." - } - } - } - }, - "facetScoring": { - "type": "array", - "description": "Scores associated with the facets.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "score", - "facetName" - ], - "properties": { - "score": { - "type": "integer", - "description": "The score for the event." - }, - "facetName": { - "type": "string", - "description": "The name of the facet." - } - } - } - }, - "personalizationImpact": { - "type": "integer", - "description": "The impact that personalization has on search results: a number between 0 (personalization disabled) and 100 (personalization fully enabled)." - } - } - } - }, - "responses": { - "BadRequest": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "FeatureNotEnabled": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "MethodNotAllowed": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "IndexNotFound": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "servers": [ - { - "url": "https://personalization.{region}.algolia.com", - "variables": { - "region": { - "enum": [ - "us", - "eu" - ], - "default": "us" - } - } - } - ], - "security": [ - { - "appId": [], - "apiKey": [] - } - ], - "tags": [ - { - "name": "profiles", - "x-displayName": "Profiles", - "description": "Manage users' profiles." - }, - { - "name": "strategies", - "x-displayName": "Strategies", - "description": "Manage personalization strategies." - } - ], - "x-tagGroups": [ - { - "name": "General", - "tags": [ - "profiles", - "strategies" - ] - } - ], - "paths": { - "/1{path}": { - "get": { - "operationId": "customGet", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "operationId": "customPost", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "operationId": "customPut", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "operationId": "customDelete", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/profiles/personalization/{userToken}": { - "get": { - "tags": [ - "profiles" - ], - "operationId": "getUserTokenProfile", - "x-acl": [ - "recommendation" - ], - "summary": "Get a user profile.", - "description": "Get the user profile built from Personalization strategy.\n\nThe profile is structured by facet name used in the strategy. Each facet value is mapped to its score. Each score represents the user affinity for a specific facet value given the userToken past events and the Personalization strategy defined. Scores are bounded to 20. The last processed event timestamp is provided using the ISO 8601 format for debugging purposes.\n", - "parameters": [ - { - "name": "userToken", - "in": "path", - "required": true, - "description": "userToken representing the user for which to fetch the Personalization profile.", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getUserTokenResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "userToken", - "scores", - "lastEventAt" - ], - "properties": { - "userToken": { - "type": "string", - "description": "userToken representing the user for which to fetch the Personalization profile." - }, - "lastEventAt": { - "type": "string", - "description": "Date of last event update. (ISO-8601 format)." - }, - "scores": { - "type": "object", - "description": "The userToken scores." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/profiles/{userToken}": { - "delete": { - "tags": [ - "profiles" - ], - "operationId": "deleteUserProfile", - "x-acl": [ - "recommendation" - ], - "summary": "Delete a user profile.", - "description": "Delete the user profile and all its associated data.\n\nReturns, as part of the response, a date until which the data can safely be considered as deleted for the given user. This means if you send events for the given user before this date, they will be ignored. Any data received after the deletedUntil date will start building a new user profile.\n\nIt might take a couple hours for the deletion request to be fully processed.\n", - "parameters": [ - { - "name": "userToken", - "in": "path", - "required": true, - "description": "userToken representing the user for which to fetch the Personalization profile.", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "deleteUserProfileResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "userToken", - "deletedUntil" - ], - "properties": { - "userToken": { - "type": "string", - "description": "userToken representing the user for which to fetch the Personalization profile." - }, - "deletedUntil": { - "type": "string", - "description": "A date until which the data can safely be considered as deleted for the given user. Any data received after the `deletedUntil` date will start building a new user profile." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/strategies/personalization": { - "get": { - "tags": [ - "strategies" - ], - "operationId": "getPersonalizationStrategy", - "x-acl": [ - "recommendation" - ], - "summary": "Get the current strategy.", - "description": "The strategy contains information on the events and facets that impact user profiles and personalized search results.", - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "eventScoring", - "facetScoring", - "personalizationImpact" - ], - "properties": { - "eventScoring": { - "type": "array", - "description": "Scores associated with the events.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "score", - "eventName", - "eventType" - ], - "properties": { - "score": { - "type": "integer", - "description": "The score for the event." - }, - "eventName": { - "type": "string", - "description": "The name of the event." - }, - "eventType": { - "type": "string", - "description": "The type of the event." - } - } - } - }, - "facetScoring": { - "type": "array", - "description": "Scores associated with the facets.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "score", - "facetName" - ], - "properties": { - "score": { - "type": "integer", - "description": "The score for the event." - }, - "facetName": { - "type": "string", - "description": "The name of the facet." - } - } - } - }, - "personalizationImpact": { - "type": "integer", - "description": "The impact that personalization has on search results: a number between 0 (personalization disabled) and 100 (personalization fully enabled)." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "tags": [ - "strategies" - ], - "operationId": "setPersonalizationStrategy", - "x-acl": [ - "recommendation" - ], - "summary": "Set a new strategy.", - "description": "A strategy defines the events and facets that impact user profiles and personalized search results.", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "eventScoring", - "facetScoring", - "personalizationImpact" - ], - "properties": { - "eventScoring": { - "type": "array", - "description": "Scores associated with the events.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "score", - "eventName", - "eventType" - ], - "properties": { - "score": { - "type": "integer", - "description": "The score for the event." - }, - "eventName": { - "type": "string", - "description": "The name of the event." - }, - "eventType": { - "type": "string", - "description": "The type of the event." - } - } - } - }, - "facetScoring": { - "type": "array", - "description": "Scores associated with the facets.", - "items": { - "type": "object", - "additionalProperties": false, - "required": [ - "score", - "facetName" - ], - "properties": { - "score": { - "type": "integer", - "description": "The score for the event." - }, - "facetName": { - "type": "string", - "description": "The name of the facet." - } - } - } - }, - "personalizationImpact": { - "type": "integer", - "description": "The impact that personalization has on search results: a number between 0 (personalization disabled) and 100 (personalization fully enabled)." - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "setPersonalizationStrategyResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "message" - ], - "properties": { - "message": { - "type": "string", - "description": "A message confirming the strategy update." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - } - } -} \ No newline at end of file diff --git a/specs/bundled/query-suggestions.json b/specs/bundled/query-suggestions.json deleted file mode 100644 index a468762116..0000000000 --- a/specs/bundled/query-suggestions.json +++ /dev/null @@ -1,3389 +0,0 @@ -{ - "openapi": "3.0.2", - "info": { - "title": "Query Suggestions API", - "description": "The Query Suggestions API lets you manage Algolia's Query Suggestions configurations.\nQuery Suggestions add new indices with popular search queries, external suggestions, or facet values to your Algolia application.\nIn your user interface, you can query the Query Suggestions indices like regular indices and add [suggested searches](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/query-suggestions/js/) to guide users and speed up their search.\n", - "version": "1.0.0" - }, - "components": { - "securitySchemes": { - "appId": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-Application-Id" - }, - "apiKey": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-API-Key" - } - }, - "parameters": { - "PathInPath": { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - "Parameters": { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - }, - "IndexName": { - "name": "indexName", - "in": "path", - "required": true, - "description": "Query Suggestions index name.", - "schema": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - } - } - }, - "schemas": { - "ErrorBase": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - }, - "baseQuerySuggestionsConfigurationResponse": { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceIndicesAPIKey": { - "type": "string", - "description": "API key used to read from your source index." - }, - "suggestionsIndicesAPIKey": { - "type": "string", - "description": "API key used to write and configure your Query Suggestions index." - }, - "externalIndicesAPIKey": { - "type": "string", - "default": "", - "description": "API key used to read from external Algolia indices." - } - } - }, - "QuerySuggestionsIndexName": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - }, - "baseQuerySuggestionsConfigurationWithIndex": { - "type": "object", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - } - } - }, - "Facet": { - "title": "facet", - "description": "Facet to use as category.", - "type": "object", - "additionalProperties": false, - "properties": { - "attribute": { - "type": "string", - "description": "Facet name." - }, - "amount": { - "type": "integer", - "description": "Number of suggestions." - } - } - }, - "SourceIndex": { - "title": "sourceIndex", - "type": "object", - "description": "Configuration of an Algolia index for Query Suggestions.", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "type": "string", - "description": "Name of the Algolia index to use as source for query suggestions.", - "example": "products" - }, - "replicas": { - "type": "boolean", - "default": false, - "description": "If true, Query Suggestions uses all replicas of the primary index to find popular searches.\nIf false, only the primary index is used. \n", - "example": false - }, - "analyticsTags": { - "type": "array", - "description": "[Analytics tags](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) for filtering the popular searches.\n", - "nullable": true, - "items": { - "type": "string" - } - }, - "facets": { - "type": "array", - "items": { - "title": "facet", - "description": "Facet to use as category.", - "type": "object", - "additionalProperties": false, - "properties": { - "attribute": { - "type": "string", - "description": "Facet name." - }, - "amount": { - "type": "integer", - "description": "Number of suggestions." - } - } - }, - "nullable": true, - "description": "Facets to use as top categories with your suggestions.\n\nIf provided, Query Suggestions adds the top facet values to each suggestion.\n", - "example": [ - { - "attribute": "category", - "amount": 3 - }, - { - "attribute": "brand", - "amount": 2 - } - ] - }, - "minHits": { - "type": "integer", - "minimum": 0, - "default": 5, - "description": "Minimum number of hits required to be included as a suggestion.\n\nA search query must at least generate `minHits` hits to be included in the Query Suggestions index.\n" - }, - "minLetters": { - "type": "integer", - "minimum": 0, - "default": 4, - "description": "Minimum letters required to be included as a suggestion.\n\nA search query must be at least `minLetters` long to be included in the Query Suggestions index.\n" - }, - "generate": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Facets used for generating query suggestions from facet values.\n\nFor example, if you set `generate: [\"color\", \"brand\"]`, combinations from the facet values are added as query suggestions,\nsuch as \"blue adidas\", \"red adidas\", \"blue nike\", \"red nike\", etc.\n\nYou can include nested lists.\n", - "example": [ - "color", - "brand" - ] - } - }, - "external": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Algolia indices with popular searches to use as query suggestions.\n\nRecords of these indices must have these attributes:\n\n - `query`: search query which will be added as a suggestion\n - `count`: measure of popularity of that search query\n\nFor example, you can export popular searches from an external analytics tool, such as Google Analytics or Adobe Analytics,\nand feed this data into an external Algolia index.\nYou can use this external index to generate query suggestions until your Algolia analytics has collected enough data.\n" - } - } - }, - "SourceIndices": { - "title": "sourceIndices", - "type": "array", - "description": "Algolia indices from which to get the popular searches for query suggestions.", - "minItems": 1, - "items": { - "title": "sourceIndex", - "type": "object", - "description": "Configuration of an Algolia index for Query Suggestions.", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "type": "string", - "description": "Name of the Algolia index to use as source for query suggestions.", - "example": "products" - }, - "replicas": { - "type": "boolean", - "default": false, - "description": "If true, Query Suggestions uses all replicas of the primary index to find popular searches.\nIf false, only the primary index is used. \n", - "example": false - }, - "analyticsTags": { - "type": "array", - "description": "[Analytics tags](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) for filtering the popular searches.\n", - "nullable": true, - "items": { - "type": "string" - } - }, - "facets": { - "type": "array", - "items": { - "title": "facet", - "description": "Facet to use as category.", - "type": "object", - "additionalProperties": false, - "properties": { - "attribute": { - "type": "string", - "description": "Facet name." - }, - "amount": { - "type": "integer", - "description": "Number of suggestions." - } - } - }, - "nullable": true, - "description": "Facets to use as top categories with your suggestions.\n\nIf provided, Query Suggestions adds the top facet values to each suggestion.\n", - "example": [ - { - "attribute": "category", - "amount": 3 - }, - { - "attribute": "brand", - "amount": 2 - } - ] - }, - "minHits": { - "type": "integer", - "minimum": 0, - "default": 5, - "description": "Minimum number of hits required to be included as a suggestion.\n\nA search query must at least generate `minHits` hits to be included in the Query Suggestions index.\n" - }, - "minLetters": { - "type": "integer", - "minimum": 0, - "default": 4, - "description": "Minimum letters required to be included as a suggestion.\n\nA search query must be at least `minLetters` long to be included in the Query Suggestions index.\n" - }, - "generate": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Facets used for generating query suggestions from facet values.\n\nFor example, if you set `generate: [\"color\", \"brand\"]`, combinations from the facet values are added as query suggestions,\nsuch as \"blue adidas\", \"red adidas\", \"blue nike\", \"red nike\", etc.\n\nYou can include nested lists.\n", - "example": [ - "color", - "brand" - ] - } - }, - "external": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Algolia indices with popular searches to use as query suggestions.\n\nRecords of these indices must have these attributes:\n\n - `query`: search query which will be added as a suggestion\n - `count`: measure of popularity of that search query\n\nFor example, you can export popular searches from an external analytics tool, such as Google Analytics or Adobe Analytics,\nand feed this data into an external Algolia index.\nYou can use this external index to generate query suggestions until your Algolia analytics has collected enough data.\n" - } - } - } - }, - "Languages": { - "title": "languages", - "description": "Set the language for deduplicating singular and plural suggestions.\nIf specified, only the more popular form is included.\n", - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ] - }, - "QuerySuggestionsConfiguration": { - "type": "object", - "description": "Query Suggestions configuration.", - "additionalProperties": false, - "required": [ - "sourceIndices" - ], - "properties": { - "sourceIndices": { - "title": "sourceIndices", - "type": "array", - "description": "Algolia indices from which to get the popular searches for query suggestions.", - "minItems": 1, - "items": { - "title": "sourceIndex", - "type": "object", - "description": "Configuration of an Algolia index for Query Suggestions.", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "type": "string", - "description": "Name of the Algolia index to use as source for query suggestions.", - "example": "products" - }, - "replicas": { - "type": "boolean", - "default": false, - "description": "If true, Query Suggestions uses all replicas of the primary index to find popular searches.\nIf false, only the primary index is used. \n", - "example": false - }, - "analyticsTags": { - "type": "array", - "description": "[Analytics tags](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) for filtering the popular searches.\n", - "nullable": true, - "items": { - "type": "string" - } - }, - "facets": { - "type": "array", - "items": { - "title": "facet", - "description": "Facet to use as category.", - "type": "object", - "additionalProperties": false, - "properties": { - "attribute": { - "type": "string", - "description": "Facet name." - }, - "amount": { - "type": "integer", - "description": "Number of suggestions." - } - } - }, - "nullable": true, - "description": "Facets to use as top categories with your suggestions.\n\nIf provided, Query Suggestions adds the top facet values to each suggestion.\n", - "example": [ - { - "attribute": "category", - "amount": 3 - }, - { - "attribute": "brand", - "amount": 2 - } - ] - }, - "minHits": { - "type": "integer", - "minimum": 0, - "default": 5, - "description": "Minimum number of hits required to be included as a suggestion.\n\nA search query must at least generate `minHits` hits to be included in the Query Suggestions index.\n" - }, - "minLetters": { - "type": "integer", - "minimum": 0, - "default": 4, - "description": "Minimum letters required to be included as a suggestion.\n\nA search query must be at least `minLetters` long to be included in the Query Suggestions index.\n" - }, - "generate": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Facets used for generating query suggestions from facet values.\n\nFor example, if you set `generate: [\"color\", \"brand\"]`, combinations from the facet values are added as query suggestions,\nsuch as \"blue adidas\", \"red adidas\", \"blue nike\", \"red nike\", etc.\n\nYou can include nested lists.\n", - "example": [ - "color", - "brand" - ] - } - }, - "external": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Algolia indices with popular searches to use as query suggestions.\n\nRecords of these indices must have these attributes:\n\n - `query`: search query which will be added as a suggestion\n - `count`: measure of popularity of that search query\n\nFor example, you can export popular searches from an external analytics tool, such as Google Analytics or Adobe Analytics,\nand feed this data into an external Algolia index.\nYou can use this external index to generate query suggestions until your Algolia analytics has collected enough data.\n" - } - } - } - }, - "languages": { - "title": "languages", - "description": "Set the language for deduplicating singular and plural suggestions.\nIf specified, only the more popular form is included.\n", - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ] - }, - "exclude": { - "type": "array", - "description": "Patterns to exclude from query suggestions.", - "nullable": true, - "items": { - "type": "string" - } - }, - "enablePersonalization": { - "type": "boolean", - "default": false, - "description": "Turn on personalized query suggestions." - }, - "allowSpecialCharacters": { - "type": "boolean", - "default": false, - "description": "Allow suggestions with special characters." - } - } - }, - "QuerySuggestionsConfigurationWithIndex": { - "type": "object", - "description": "Query Suggestions configuration.", - "required": [ - "indexName", - "sourceIndices" - ], - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - } - } - }, - { - "type": "object", - "description": "Query Suggestions configuration.", - "additionalProperties": false, - "required": [ - "sourceIndices" - ], - "properties": { - "sourceIndices": { - "title": "sourceIndices", - "type": "array", - "description": "Algolia indices from which to get the popular searches for query suggestions.", - "minItems": 1, - "items": { - "title": "sourceIndex", - "type": "object", - "description": "Configuration of an Algolia index for Query Suggestions.", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "type": "string", - "description": "Name of the Algolia index to use as source for query suggestions.", - "example": "products" - }, - "replicas": { - "type": "boolean", - "default": false, - "description": "If true, Query Suggestions uses all replicas of the primary index to find popular searches.\nIf false, only the primary index is used. \n", - "example": false - }, - "analyticsTags": { - "type": "array", - "description": "[Analytics tags](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) for filtering the popular searches.\n", - "nullable": true, - "items": { - "type": "string" - } - }, - "facets": { - "type": "array", - "items": { - "title": "facet", - "description": "Facet to use as category.", - "type": "object", - "additionalProperties": false, - "properties": { - "attribute": { - "type": "string", - "description": "Facet name." - }, - "amount": { - "type": "integer", - "description": "Number of suggestions." - } - } - }, - "nullable": true, - "description": "Facets to use as top categories with your suggestions.\n\nIf provided, Query Suggestions adds the top facet values to each suggestion.\n", - "example": [ - { - "attribute": "category", - "amount": 3 - }, - { - "attribute": "brand", - "amount": 2 - } - ] - }, - "minHits": { - "type": "integer", - "minimum": 0, - "default": 5, - "description": "Minimum number of hits required to be included as a suggestion.\n\nA search query must at least generate `minHits` hits to be included in the Query Suggestions index.\n" - }, - "minLetters": { - "type": "integer", - "minimum": 0, - "default": 4, - "description": "Minimum letters required to be included as a suggestion.\n\nA search query must be at least `minLetters` long to be included in the Query Suggestions index.\n" - }, - "generate": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Facets used for generating query suggestions from facet values.\n\nFor example, if you set `generate: [\"color\", \"brand\"]`, combinations from the facet values are added as query suggestions,\nsuch as \"blue adidas\", \"red adidas\", \"blue nike\", \"red nike\", etc.\n\nYou can include nested lists.\n", - "example": [ - "color", - "brand" - ] - } - }, - "external": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Algolia indices with popular searches to use as query suggestions.\n\nRecords of these indices must have these attributes:\n\n - `query`: search query which will be added as a suggestion\n - `count`: measure of popularity of that search query\n\nFor example, you can export popular searches from an external analytics tool, such as Google Analytics or Adobe Analytics,\nand feed this data into an external Algolia index.\nYou can use this external index to generate query suggestions until your Algolia analytics has collected enough data.\n" - } - } - } - }, - "languages": { - "title": "languages", - "description": "Set the language for deduplicating singular and plural suggestions.\nIf specified, only the more popular form is included.\n", - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ] - }, - "exclude": { - "type": "array", - "description": "Patterns to exclude from query suggestions.", - "nullable": true, - "items": { - "type": "string" - } - }, - "enablePersonalization": { - "type": "boolean", - "default": false, - "description": "Turn on personalized query suggestions." - }, - "allowSpecialCharacters": { - "type": "boolean", - "default": false, - "description": "Allow suggestions with special characters." - } - } - } - ] - }, - "QuerySuggestionsConfigurationResponse": { - "type": "object", - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceIndicesAPIKey": { - "type": "string", - "description": "API key used to read from your source index." - }, - "suggestionsIndicesAPIKey": { - "type": "string", - "description": "API key used to write and configure your Query Suggestions index." - }, - "externalIndicesAPIKey": { - "type": "string", - "default": "", - "description": "API key used to read from external Algolia indices." - } - } - }, - { - "type": "object", - "description": "Query Suggestions configuration.", - "required": [ - "indexName", - "sourceIndices" - ], - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - } - } - }, - { - "type": "object", - "description": "Query Suggestions configuration.", - "additionalProperties": false, - "required": [ - "sourceIndices" - ], - "properties": { - "sourceIndices": { - "title": "sourceIndices", - "type": "array", - "description": "Algolia indices from which to get the popular searches for query suggestions.", - "minItems": 1, - "items": { - "title": "sourceIndex", - "type": "object", - "description": "Configuration of an Algolia index for Query Suggestions.", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "type": "string", - "description": "Name of the Algolia index to use as source for query suggestions.", - "example": "products" - }, - "replicas": { - "type": "boolean", - "default": false, - "description": "If true, Query Suggestions uses all replicas of the primary index to find popular searches.\nIf false, only the primary index is used. \n", - "example": false - }, - "analyticsTags": { - "type": "array", - "description": "[Analytics tags](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) for filtering the popular searches.\n", - "nullable": true, - "items": { - "type": "string" - } - }, - "facets": { - "type": "array", - "items": { - "title": "facet", - "description": "Facet to use as category.", - "type": "object", - "additionalProperties": false, - "properties": { - "attribute": { - "type": "string", - "description": "Facet name." - }, - "amount": { - "type": "integer", - "description": "Number of suggestions." - } - } - }, - "nullable": true, - "description": "Facets to use as top categories with your suggestions.\n\nIf provided, Query Suggestions adds the top facet values to each suggestion.\n", - "example": [ - { - "attribute": "category", - "amount": 3 - }, - { - "attribute": "brand", - "amount": 2 - } - ] - }, - "minHits": { - "type": "integer", - "minimum": 0, - "default": 5, - "description": "Minimum number of hits required to be included as a suggestion.\n\nA search query must at least generate `minHits` hits to be included in the Query Suggestions index.\n" - }, - "minLetters": { - "type": "integer", - "minimum": 0, - "default": 4, - "description": "Minimum letters required to be included as a suggestion.\n\nA search query must be at least `minLetters` long to be included in the Query Suggestions index.\n" - }, - "generate": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Facets used for generating query suggestions from facet values.\n\nFor example, if you set `generate: [\"color\", \"brand\"]`, combinations from the facet values are added as query suggestions,\nsuch as \"blue adidas\", \"red adidas\", \"blue nike\", \"red nike\", etc.\n\nYou can include nested lists.\n", - "example": [ - "color", - "brand" - ] - } - }, - "external": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Algolia indices with popular searches to use as query suggestions.\n\nRecords of these indices must have these attributes:\n\n - `query`: search query which will be added as a suggestion\n - `count`: measure of popularity of that search query\n\nFor example, you can export popular searches from an external analytics tool, such as Google Analytics or Adobe Analytics,\nand feed this data into an external Algolia index.\nYou can use this external index to generate query suggestions until your Algolia analytics has collected enough data.\n" - } - } - } - }, - "languages": { - "title": "languages", - "description": "Set the language for deduplicating singular and plural suggestions.\nIf specified, only the more popular form is included.\n", - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ] - }, - "exclude": { - "type": "array", - "description": "Patterns to exclude from query suggestions.", - "nullable": true, - "items": { - "type": "string" - } - }, - "enablePersonalization": { - "type": "boolean", - "default": false, - "description": "Turn on personalized query suggestions." - }, - "allowSpecialCharacters": { - "type": "boolean", - "default": false, - "description": "Allow suggestions with special characters." - } - } - } - ] - } - ] - }, - "BaseResponse": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "LogLevel": { - "title": "level", - "type": "string", - "description": "The type of log entry. \n\n- `SKIP`. A query is skipped because it doesn't match the conditions for successful inclusion. For example, when a query doesn't generate enough search results.\n- `INFO`. An informative log entry.\n- `ERROR`. The Query Suggestions process encountered an error.\n", - "enum": [ - "SKIP", - "INFO", - "ERROR" - ] - } - }, - "responses": { - "BadRequest": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "FeatureNotEnabled": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "MethodNotAllowed": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "IndexNotFound": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "Unauthorized": { - "description": "Unauthorized", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Unauthorized": { - "summary": "Wrong region.", - "description": "Make sure to make your request to the server corresponding to your region. \n\nYou can check the region for your application in the [Algolia dashboard](https://dashboard.algolia.com/account/infrastructure/analytics).\n", - "value": { - "status": 401, - "message": "The log processing region does not match" - } - }, - "InvalidCredentials": { - "summary": "Invalid credentials.", - "description": "Your application ID or API key is wrong.", - "value": { - "status": 401, - "message": "Invalid credentials" - } - }, - "MissingACL": { - "summary": "Key is missing ACL.", - "description": "Your API key is missing the required ACL for this operation.", - "value": { - "status": 401, - "message": "The provided API key is missing the \\\"editSettings\\\" ACL" - } - } - } - } - } - }, - "BadRequest-2": { - "description": "Bad Request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "IndexNameRequired": { - "summary": "Index name required.", - "value": { - "status": 400, - "message": "IndexName cannot be empty" - } - }, - "SourceIndicesRequired": { - "summary": "Source indices required.", - "value": { - "status": 400, - "message": "Invalid body \"sourceIndices needs to contain at least one index\"." - } - }, - "SourceIndexNameRequired": { - "summary": "Source index name required.", - "value": { - "status": 400, - "message": "Invalid body \"every source index must have an `indexName`\"." - } - }, - "MinHitsPositive": { - "summary": "MinHits must be positive.", - "value": { - "status": 400, - "message": "Invalid body \"every source index `minHits` must be positive\"." - } - }, - "MinLettersPositive": { - "summary": "MinLetters must be positive.", - "value": { - "status": 400, - "message": "Invalid body \"every source index `minLetters` must be positive\"." - } - } - } - } - } - }, - "UnprocessableEntity": { - "description": "Unprocessable Entity.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "UnprocessableEntity": { - "summary": "Configuration already exists.", - "value": { - "status": 422, - "message": "Configuration already exists for index: test-qs" - } - } - } - } - } - }, - "InternalError": { - "description": "Internal error.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "NotFound": { - "description": "Not Found.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "NotFound": { - "summary": "Index not found.", - "value": { - "status": 404, - "message": "Not Found" - } - } - } - } - } - }, - "InternalError-2": { - "description": "Internal Server Error.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Error": { - "description": "This error can happen if you use a non-existing `indexName` as a path parameter when trying to update or delete a Query Suggestions configuration.", - "value": { - "status": 500, - "message": "Internal Server Error" - } - } - } - } - } - } - } - }, - "servers": [ - { - "url": "https://query-suggestions.{region}.algolia.com", - "description": "You can check the region for your application in the [Algolia dashboard](https://dashboard.algolia.com/account/infrastructure/analytics).\nIf you connect to the wrong region, the API returns an error with the status `401` and the message: \"The log processing region does not match\".\n", - "variables": { - "region": { - "enum": [ - "us", - "eu" - ], - "default": "us" - } - } - } - ], - "security": [ - { - "appId": [], - "apiKey": [] - } - ], - "tags": [ - { - "name": "configurations", - "x-displayName": "Configurations", - "description": "Manage Query Suggestions configurations." - }, - { - "name": "logs", - "x-displayName": "Logs", - "description": "Get logs for a Query Suggestions index." - } - ], - "x-tagGroups": [ - { - "name": "Configurations", - "tags": [ - "configurations" - ] - }, - { - "name": "Logs", - "tags": [ - "logs" - ] - } - ], - "paths": { - "/1{path}": { - "get": { - "operationId": "customGet", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "operationId": "customPost", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "operationId": "customPut", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "operationId": "customDelete", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/configs": { - "get": { - "tags": [ - "configurations" - ], - "operationId": "getAllConfigs", - "x-acl": [ - "settings" - ], - "summary": "List configurations.", - "description": "List all Query Suggestions configurations of your Algolia application.", - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "type": "object", - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceIndicesAPIKey": { - "type": "string", - "description": "API key used to read from your source index." - }, - "suggestionsIndicesAPIKey": { - "type": "string", - "description": "API key used to write and configure your Query Suggestions index." - }, - "externalIndicesAPIKey": { - "type": "string", - "default": "", - "description": "API key used to read from external Algolia indices." - } - } - }, - { - "type": "object", - "description": "Query Suggestions configuration.", - "required": [ - "indexName", - "sourceIndices" - ], - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - } - } - }, - { - "type": "object", - "description": "Query Suggestions configuration.", - "additionalProperties": false, - "required": [ - "sourceIndices" - ], - "properties": { - "sourceIndices": { - "title": "sourceIndices", - "type": "array", - "description": "Algolia indices from which to get the popular searches for query suggestions.", - "minItems": 1, - "items": { - "title": "sourceIndex", - "type": "object", - "description": "Configuration of an Algolia index for Query Suggestions.", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "type": "string", - "description": "Name of the Algolia index to use as source for query suggestions.", - "example": "products" - }, - "replicas": { - "type": "boolean", - "default": false, - "description": "If true, Query Suggestions uses all replicas of the primary index to find popular searches.\nIf false, only the primary index is used. \n", - "example": false - }, - "analyticsTags": { - "type": "array", - "description": "[Analytics tags](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) for filtering the popular searches.\n", - "nullable": true, - "items": { - "type": "string" - } - }, - "facets": { - "type": "array", - "items": { - "title": "facet", - "description": "Facet to use as category.", - "type": "object", - "additionalProperties": false, - "properties": { - "attribute": { - "type": "string", - "description": "Facet name." - }, - "amount": { - "type": "integer", - "description": "Number of suggestions." - } - } - }, - "nullable": true, - "description": "Facets to use as top categories with your suggestions.\n\nIf provided, Query Suggestions adds the top facet values to each suggestion.\n", - "example": [ - { - "attribute": "category", - "amount": 3 - }, - { - "attribute": "brand", - "amount": 2 - } - ] - }, - "minHits": { - "type": "integer", - "minimum": 0, - "default": 5, - "description": "Minimum number of hits required to be included as a suggestion.\n\nA search query must at least generate `minHits` hits to be included in the Query Suggestions index.\n" - }, - "minLetters": { - "type": "integer", - "minimum": 0, - "default": 4, - "description": "Minimum letters required to be included as a suggestion.\n\nA search query must be at least `minLetters` long to be included in the Query Suggestions index.\n" - }, - "generate": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Facets used for generating query suggestions from facet values.\n\nFor example, if you set `generate: [\"color\", \"brand\"]`, combinations from the facet values are added as query suggestions,\nsuch as \"blue adidas\", \"red adidas\", \"blue nike\", \"red nike\", etc.\n\nYou can include nested lists.\n", - "example": [ - "color", - "brand" - ] - } - }, - "external": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Algolia indices with popular searches to use as query suggestions.\n\nRecords of these indices must have these attributes:\n\n - `query`: search query which will be added as a suggestion\n - `count`: measure of popularity of that search query\n\nFor example, you can export popular searches from an external analytics tool, such as Google Analytics or Adobe Analytics,\nand feed this data into an external Algolia index.\nYou can use this external index to generate query suggestions until your Algolia analytics has collected enough data.\n" - } - } - } - }, - "languages": { - "title": "languages", - "description": "Set the language for deduplicating singular and plural suggestions.\nIf specified, only the more popular form is included.\n", - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ] - }, - "exclude": { - "type": "array", - "description": "Patterns to exclude from query suggestions.", - "nullable": true, - "items": { - "type": "string" - } - }, - "enablePersonalization": { - "type": "boolean", - "default": false, - "description": "Turn on personalized query suggestions." - }, - "allowSpecialCharacters": { - "type": "boolean", - "default": false, - "description": "Allow suggestions with special characters." - } - } - } - ] - } - ] - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Unauthorized": { - "summary": "Wrong region.", - "description": "Make sure to make your request to the server corresponding to your region. \n\nYou can check the region for your application in the [Algolia dashboard](https://dashboard.algolia.com/account/infrastructure/analytics).\n", - "value": { - "status": 401, - "message": "The log processing region does not match" - } - }, - "InvalidCredentials": { - "summary": "Invalid credentials.", - "description": "Your application ID or API key is wrong.", - "value": { - "status": 401, - "message": "Invalid credentials" - } - }, - "MissingACL": { - "summary": "Key is missing ACL.", - "description": "Your API key is missing the required ACL for this operation.", - "value": { - "status": 401, - "message": "The provided API key is missing the \\\"editSettings\\\" ACL" - } - } - } - } - } - } - } - }, - "post": { - "tags": [ - "configurations" - ], - "operationId": "createConfig", - "x-acl": [ - "editSettings" - ], - "summary": "Create a configuration.", - "description": "Create a new Query Suggestions configuration.\n\nYou can have up to 100 configurations per Algolia application.\n", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "Query Suggestions configuration.", - "required": [ - "indexName", - "sourceIndices" - ], - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - } - } - }, - { - "type": "object", - "description": "Query Suggestions configuration.", - "additionalProperties": false, - "required": [ - "sourceIndices" - ], - "properties": { - "sourceIndices": { - "title": "sourceIndices", - "type": "array", - "description": "Algolia indices from which to get the popular searches for query suggestions.", - "minItems": 1, - "items": { - "title": "sourceIndex", - "type": "object", - "description": "Configuration of an Algolia index for Query Suggestions.", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "type": "string", - "description": "Name of the Algolia index to use as source for query suggestions.", - "example": "products" - }, - "replicas": { - "type": "boolean", - "default": false, - "description": "If true, Query Suggestions uses all replicas of the primary index to find popular searches.\nIf false, only the primary index is used. \n", - "example": false - }, - "analyticsTags": { - "type": "array", - "description": "[Analytics tags](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) for filtering the popular searches.\n", - "nullable": true, - "items": { - "type": "string" - } - }, - "facets": { - "type": "array", - "items": { - "title": "facet", - "description": "Facet to use as category.", - "type": "object", - "additionalProperties": false, - "properties": { - "attribute": { - "type": "string", - "description": "Facet name." - }, - "amount": { - "type": "integer", - "description": "Number of suggestions." - } - } - }, - "nullable": true, - "description": "Facets to use as top categories with your suggestions.\n\nIf provided, Query Suggestions adds the top facet values to each suggestion.\n", - "example": [ - { - "attribute": "category", - "amount": 3 - }, - { - "attribute": "brand", - "amount": 2 - } - ] - }, - "minHits": { - "type": "integer", - "minimum": 0, - "default": 5, - "description": "Minimum number of hits required to be included as a suggestion.\n\nA search query must at least generate `minHits` hits to be included in the Query Suggestions index.\n" - }, - "minLetters": { - "type": "integer", - "minimum": 0, - "default": 4, - "description": "Minimum letters required to be included as a suggestion.\n\nA search query must be at least `minLetters` long to be included in the Query Suggestions index.\n" - }, - "generate": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Facets used for generating query suggestions from facet values.\n\nFor example, if you set `generate: [\"color\", \"brand\"]`, combinations from the facet values are added as query suggestions,\nsuch as \"blue adidas\", \"red adidas\", \"blue nike\", \"red nike\", etc.\n\nYou can include nested lists.\n", - "example": [ - "color", - "brand" - ] - } - }, - "external": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Algolia indices with popular searches to use as query suggestions.\n\nRecords of these indices must have these attributes:\n\n - `query`: search query which will be added as a suggestion\n - `count`: measure of popularity of that search query\n\nFor example, you can export popular searches from an external analytics tool, such as Google Analytics or Adobe Analytics,\nand feed this data into an external Algolia index.\nYou can use this external index to generate query suggestions until your Algolia analytics has collected enough data.\n" - } - } - } - }, - "languages": { - "title": "languages", - "description": "Set the language for deduplicating singular and plural suggestions.\nIf specified, only the more popular form is included.\n", - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ] - }, - "exclude": { - "type": "array", - "description": "Patterns to exclude from query suggestions.", - "nullable": true, - "items": { - "type": "string" - } - }, - "enablePersonalization": { - "type": "boolean", - "default": false, - "description": "Turn on personalized query suggestions." - }, - "allowSpecialCharacters": { - "type": "boolean", - "default": false, - "description": "Allow suggestions with special characters." - } - } - } - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Created": { - "summary": "Configuration created.", - "value": { - "status": 200, - "message": "Configuration was created, and a new indexing job has been scheduled." - } - } - } - } - } - }, - "400": { - "description": "Bad Request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "IndexNameRequired": { - "summary": "Index name required.", - "value": { - "status": 400, - "message": "IndexName cannot be empty" - } - }, - "SourceIndicesRequired": { - "summary": "Source indices required.", - "value": { - "status": 400, - "message": "Invalid body \"sourceIndices needs to contain at least one index\"." - } - }, - "SourceIndexNameRequired": { - "summary": "Source index name required.", - "value": { - "status": 400, - "message": "Invalid body \"every source index must have an `indexName`\"." - } - }, - "MinHitsPositive": { - "summary": "MinHits must be positive.", - "value": { - "status": 400, - "message": "Invalid body \"every source index `minHits` must be positive\"." - } - }, - "MinLettersPositive": { - "summary": "MinLetters must be positive.", - "value": { - "status": 400, - "message": "Invalid body \"every source index `minLetters` must be positive\"." - } - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Unauthorized": { - "summary": "Wrong region.", - "description": "Make sure to make your request to the server corresponding to your region. \n\nYou can check the region for your application in the [Algolia dashboard](https://dashboard.algolia.com/account/infrastructure/analytics).\n", - "value": { - "status": 401, - "message": "The log processing region does not match" - } - }, - "InvalidCredentials": { - "summary": "Invalid credentials.", - "description": "Your application ID or API key is wrong.", - "value": { - "status": 401, - "message": "Invalid credentials" - } - }, - "MissingACL": { - "summary": "Key is missing ACL.", - "description": "Your API key is missing the required ACL for this operation.", - "value": { - "status": 401, - "message": "The provided API key is missing the \\\"editSettings\\\" ACL" - } - } - } - } - } - }, - "422": { - "description": "Unprocessable Entity.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "UnprocessableEntity": { - "summary": "Configuration already exists.", - "value": { - "status": 422, - "message": "Configuration already exists for index: test-qs" - } - } - } - } - } - }, - "500": { - "description": "Internal error.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/configs/{indexName}": { - "get": { - "tags": [ - "configurations" - ], - "operationId": "getConfig", - "x-acl": [ - "settings" - ], - "summary": "Get a configuration.", - "description": "Get a single Query Suggestions configuration.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "required": true, - "description": "Query Suggestions index name.", - "schema": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "sourceIndicesAPIKey": { - "type": "string", - "description": "API key used to read from your source index." - }, - "suggestionsIndicesAPIKey": { - "type": "string", - "description": "API key used to write and configure your Query Suggestions index." - }, - "externalIndicesAPIKey": { - "type": "string", - "default": "", - "description": "API key used to read from external Algolia indices." - } - } - }, - { - "type": "object", - "description": "Query Suggestions configuration.", - "required": [ - "indexName", - "sourceIndices" - ], - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - } - } - }, - { - "type": "object", - "description": "Query Suggestions configuration.", - "additionalProperties": false, - "required": [ - "sourceIndices" - ], - "properties": { - "sourceIndices": { - "title": "sourceIndices", - "type": "array", - "description": "Algolia indices from which to get the popular searches for query suggestions.", - "minItems": 1, - "items": { - "title": "sourceIndex", - "type": "object", - "description": "Configuration of an Algolia index for Query Suggestions.", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "type": "string", - "description": "Name of the Algolia index to use as source for query suggestions.", - "example": "products" - }, - "replicas": { - "type": "boolean", - "default": false, - "description": "If true, Query Suggestions uses all replicas of the primary index to find popular searches.\nIf false, only the primary index is used. \n", - "example": false - }, - "analyticsTags": { - "type": "array", - "description": "[Analytics tags](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) for filtering the popular searches.\n", - "nullable": true, - "items": { - "type": "string" - } - }, - "facets": { - "type": "array", - "items": { - "title": "facet", - "description": "Facet to use as category.", - "type": "object", - "additionalProperties": false, - "properties": { - "attribute": { - "type": "string", - "description": "Facet name." - }, - "amount": { - "type": "integer", - "description": "Number of suggestions." - } - } - }, - "nullable": true, - "description": "Facets to use as top categories with your suggestions.\n\nIf provided, Query Suggestions adds the top facet values to each suggestion.\n", - "example": [ - { - "attribute": "category", - "amount": 3 - }, - { - "attribute": "brand", - "amount": 2 - } - ] - }, - "minHits": { - "type": "integer", - "minimum": 0, - "default": 5, - "description": "Minimum number of hits required to be included as a suggestion.\n\nA search query must at least generate `minHits` hits to be included in the Query Suggestions index.\n" - }, - "minLetters": { - "type": "integer", - "minimum": 0, - "default": 4, - "description": "Minimum letters required to be included as a suggestion.\n\nA search query must be at least `minLetters` long to be included in the Query Suggestions index.\n" - }, - "generate": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Facets used for generating query suggestions from facet values.\n\nFor example, if you set `generate: [\"color\", \"brand\"]`, combinations from the facet values are added as query suggestions,\nsuch as \"blue adidas\", \"red adidas\", \"blue nike\", \"red nike\", etc.\n\nYou can include nested lists.\n", - "example": [ - "color", - "brand" - ] - } - }, - "external": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Algolia indices with popular searches to use as query suggestions.\n\nRecords of these indices must have these attributes:\n\n - `query`: search query which will be added as a suggestion\n - `count`: measure of popularity of that search query\n\nFor example, you can export popular searches from an external analytics tool, such as Google Analytics or Adobe Analytics,\nand feed this data into an external Algolia index.\nYou can use this external index to generate query suggestions until your Algolia analytics has collected enough data.\n" - } - } - } - }, - "languages": { - "title": "languages", - "description": "Set the language for deduplicating singular and plural suggestions.\nIf specified, only the more popular form is included.\n", - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ] - }, - "exclude": { - "type": "array", - "description": "Patterns to exclude from query suggestions.", - "nullable": true, - "items": { - "type": "string" - } - }, - "enablePersonalization": { - "type": "boolean", - "default": false, - "description": "Turn on personalized query suggestions." - }, - "allowSpecialCharacters": { - "type": "boolean", - "default": false, - "description": "Allow suggestions with special characters." - } - } - } - ] - } - ] - } - } - } - }, - "400": { - "description": "Bad Request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "IndexNameRequired": { - "summary": "Index name required.", - "value": { - "status": 400, - "message": "IndexName cannot be empty" - } - }, - "SourceIndicesRequired": { - "summary": "Source indices required.", - "value": { - "status": 400, - "message": "Invalid body \"sourceIndices needs to contain at least one index\"." - } - }, - "SourceIndexNameRequired": { - "summary": "Source index name required.", - "value": { - "status": 400, - "message": "Invalid body \"every source index must have an `indexName`\"." - } - }, - "MinHitsPositive": { - "summary": "MinHits must be positive.", - "value": { - "status": 400, - "message": "Invalid body \"every source index `minHits` must be positive\"." - } - }, - "MinLettersPositive": { - "summary": "MinLetters must be positive.", - "value": { - "status": 400, - "message": "Invalid body \"every source index `minLetters` must be positive\"." - } - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Unauthorized": { - "summary": "Wrong region.", - "description": "Make sure to make your request to the server corresponding to your region. \n\nYou can check the region for your application in the [Algolia dashboard](https://dashboard.algolia.com/account/infrastructure/analytics).\n", - "value": { - "status": 401, - "message": "The log processing region does not match" - } - }, - "InvalidCredentials": { - "summary": "Invalid credentials.", - "description": "Your application ID or API key is wrong.", - "value": { - "status": 401, - "message": "Invalid credentials" - } - }, - "MissingACL": { - "summary": "Key is missing ACL.", - "description": "Your API key is missing the required ACL for this operation.", - "value": { - "status": 401, - "message": "The provided API key is missing the \\\"editSettings\\\" ACL" - } - } - } - } - } - }, - "404": { - "description": "Not Found.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "NotFound": { - "summary": "Index not found.", - "value": { - "status": 404, - "message": "Not Found" - } - } - } - } - } - } - } - }, - "put": { - "tags": [ - "configurations" - ], - "operationId": "updateConfig", - "x-acl": [ - "editSettings" - ], - "summary": "Update a configuration.", - "description": "Update a QuerySuggestions configuration.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "required": true, - "description": "Query Suggestions index name.", - "schema": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "Query Suggestions configuration.", - "additionalProperties": false, - "required": [ - "sourceIndices" - ], - "properties": { - "sourceIndices": { - "title": "sourceIndices", - "type": "array", - "description": "Algolia indices from which to get the popular searches for query suggestions.", - "minItems": 1, - "items": { - "title": "sourceIndex", - "type": "object", - "description": "Configuration of an Algolia index for Query Suggestions.", - "additionalProperties": false, - "required": [ - "indexName" - ], - "properties": { - "indexName": { - "type": "string", - "description": "Name of the Algolia index to use as source for query suggestions.", - "example": "products" - }, - "replicas": { - "type": "boolean", - "default": false, - "description": "If true, Query Suggestions uses all replicas of the primary index to find popular searches.\nIf false, only the primary index is used. \n", - "example": false - }, - "analyticsTags": { - "type": "array", - "description": "[Analytics tags](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) for filtering the popular searches.\n", - "nullable": true, - "items": { - "type": "string" - } - }, - "facets": { - "type": "array", - "items": { - "title": "facet", - "description": "Facet to use as category.", - "type": "object", - "additionalProperties": false, - "properties": { - "attribute": { - "type": "string", - "description": "Facet name." - }, - "amount": { - "type": "integer", - "description": "Number of suggestions." - } - } - }, - "nullable": true, - "description": "Facets to use as top categories with your suggestions.\n\nIf provided, Query Suggestions adds the top facet values to each suggestion.\n", - "example": [ - { - "attribute": "category", - "amount": 3 - }, - { - "attribute": "brand", - "amount": 2 - } - ] - }, - "minHits": { - "type": "integer", - "minimum": 0, - "default": 5, - "description": "Minimum number of hits required to be included as a suggestion.\n\nA search query must at least generate `minHits` hits to be included in the Query Suggestions index.\n" - }, - "minLetters": { - "type": "integer", - "minimum": 0, - "default": 4, - "description": "Minimum letters required to be included as a suggestion.\n\nA search query must be at least `minLetters` long to be included in the Query Suggestions index.\n" - }, - "generate": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Facets used for generating query suggestions from facet values.\n\nFor example, if you set `generate: [\"color\", \"brand\"]`, combinations from the facet values are added as query suggestions,\nsuch as \"blue adidas\", \"red adidas\", \"blue nike\", \"red nike\", etc.\n\nYou can include nested lists.\n", - "example": [ - "color", - "brand" - ] - } - }, - "external": { - "type": "array", - "items": { - "type": "string" - }, - "nullable": true, - "description": "Algolia indices with popular searches to use as query suggestions.\n\nRecords of these indices must have these attributes:\n\n - `query`: search query which will be added as a suggestion\n - `count`: measure of popularity of that search query\n\nFor example, you can export popular searches from an external analytics tool, such as Google Analytics or Adobe Analytics,\nand feed this data into an external Algolia index.\nYou can use this external index to generate query suggestions until your Algolia analytics has collected enough data.\n" - } - } - } - }, - "languages": { - "title": "languages", - "description": "Set the language for deduplicating singular and plural suggestions.\nIf specified, only the more popular form is included.\n", - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ] - }, - "exclude": { - "type": "array", - "description": "Patterns to exclude from query suggestions.", - "nullable": true, - "items": { - "type": "string" - } - }, - "enablePersonalization": { - "type": "boolean", - "default": false, - "description": "Turn on personalized query suggestions." - }, - "allowSpecialCharacters": { - "type": "boolean", - "default": false, - "description": "Allow suggestions with special characters." - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Created": { - "summary": "Configuration created.", - "value": { - "status": 200, - "message": "Configuration was updated, and a new indexing job has been scheduled." - } - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Unauthorized": { - "summary": "Wrong region.", - "description": "Make sure to make your request to the server corresponding to your region. \n\nYou can check the region for your application in the [Algolia dashboard](https://dashboard.algolia.com/account/infrastructure/analytics).\n", - "value": { - "status": 401, - "message": "The log processing region does not match" - } - }, - "InvalidCredentials": { - "summary": "Invalid credentials.", - "description": "Your application ID or API key is wrong.", - "value": { - "status": 401, - "message": "Invalid credentials" - } - }, - "MissingACL": { - "summary": "Key is missing ACL.", - "description": "Your API key is missing the required ACL for this operation.", - "value": { - "status": 401, - "message": "The provided API key is missing the \\\"editSettings\\\" ACL" - } - } - } - } - } - }, - "500": { - "description": "Internal Server Error.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Error": { - "description": "This error can happen if you use a non-existing `indexName` as a path parameter when trying to update or delete a Query Suggestions configuration.", - "value": { - "status": 500, - "message": "Internal Server Error" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "configurations" - ], - "operationId": "deleteConfig", - "x-acl": [ - "editSettings" - ], - "summary": "Delete a configuration.", - "description": "Delete a Query Suggestions configuration.\n\nDeleting only removes the configuration and stops updates to the Query Suggestions index.\nThe Query Suggestions index itself is not deleted.\n", - "parameters": [ - { - "name": "indexName", - "in": "path", - "required": true, - "description": "Query Suggestions index name.", - "schema": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Created": { - "summary": "Configuration created.", - "value": { - "status": 200, - "message": "Configuration was deleted with success." - } - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Unauthorized": { - "summary": "Wrong region.", - "description": "Make sure to make your request to the server corresponding to your region. \n\nYou can check the region for your application in the [Algolia dashboard](https://dashboard.algolia.com/account/infrastructure/analytics).\n", - "value": { - "status": 401, - "message": "The log processing region does not match" - } - }, - "InvalidCredentials": { - "summary": "Invalid credentials.", - "description": "Your application ID or API key is wrong.", - "value": { - "status": 401, - "message": "Invalid credentials" - } - }, - "MissingACL": { - "summary": "Key is missing ACL.", - "description": "Your API key is missing the required ACL for this operation.", - "value": { - "status": 401, - "message": "The provided API key is missing the \\\"editSettings\\\" ACL" - } - } - } - } - } - }, - "500": { - "description": "Internal Server Error.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Error": { - "description": "This error can happen if you use a non-existing `indexName` as a path parameter when trying to update or delete a Query Suggestions configuration.", - "value": { - "status": 500, - "message": "Internal Server Error" - } - } - } - } - } - } - } - } - }, - "/1/configs/{indexName}/status": { - "get": { - "tags": [ - "configurations" - ], - "operationId": "getConfigStatus", - "x-acl": [ - "settings" - ], - "summary": "Get configuration status.", - "description": "Report the status of a Query Suggestions index.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "required": true, - "description": "Query Suggestions index name.", - "schema": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - }, - "isRunning": { - "type": "boolean", - "description": "Indicates whether the creation or update of the Query Suggestions is in progress.", - "example": false - }, - "lastBuiltAt": { - "type": "string", - "description": "Timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format when the Query Suggestions index was last built.", - "example": "2023-07-05T08:03:53Z" - }, - "lastSuccessfulBuiltAt": { - "type": "string", - "description": "Timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format when the Query Suggestions index was last updated successfully.", - "example": "2023-07-05T08:03:53Z" - }, - "lastSuccessfulBuildDuration": { - "type": "string", - "description": "Duration of the last successful build in seconds.", - "example": 28 - } - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Unauthorized": { - "summary": "Wrong region.", - "description": "Make sure to make your request to the server corresponding to your region. \n\nYou can check the region for your application in the [Algolia dashboard](https://dashboard.algolia.com/account/infrastructure/analytics).\n", - "value": { - "status": 401, - "message": "The log processing region does not match" - } - }, - "InvalidCredentials": { - "summary": "Invalid credentials.", - "description": "Your application ID or API key is wrong.", - "value": { - "status": 401, - "message": "Invalid credentials" - } - }, - "MissingACL": { - "summary": "Key is missing ACL.", - "description": "Your API key is missing the required ACL for this operation.", - "value": { - "status": 401, - "message": "The provided API key is missing the \\\"editSettings\\\" ACL" - } - } - } - } - } - }, - "404": { - "description": "Not Found.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "NotFound": { - "summary": "Index not found.", - "value": { - "status": 404, - "message": "Not Found" - } - } - } - } - } - } - } - } - }, - "/1/logs/{indexName}": { - "get": { - "tags": [ - "logs" - ], - "operationId": "getLogFile", - "x-acl": [ - "settings" - ], - "summary": "Get logs.", - "description": "Get the logs for a single Query Suggestions index.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "required": true, - "description": "Query Suggestions index name.", - "schema": { - "title": "indexName", - "type": "string", - "description": "Query Suggestions index name.", - "example": "products_query_suggestions" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "timestamp": { - "type": "string", - "description": "Timestamp in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-07-05T08:03:33.898076171Z" - }, - "level": { - "title": "level", - "type": "string", - "description": "The type of log entry. \n\n- `SKIP`. A query is skipped because it doesn't match the conditions for successful inclusion. For example, when a query doesn't generate enough search results.\n- `INFO`. An informative log entry.\n- `ERROR`. The Query Suggestions process encountered an error.\n", - "enum": [ - "SKIP", - "INFO", - "ERROR" - ] - }, - "message": { - "type": "string", - "description": "Details about this log entry.", - "example": "skipping query \"Brooke Adams\": not enough search results, got 1, expected 5" - }, - "contextLevel": { - "type": "integer", - "description": "Level indicating the position of a suggestion in a hierarchy of records. \n\nFor example, a `contextLevel` of 1 indicates that this suggestion belongs to a previous suggestion with `contextLevel` 0.\n", - "example": 1 - } - } - } - } - } - }, - "401": { - "description": "Unauthorized", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "Unauthorized": { - "summary": "Wrong region.", - "description": "Make sure to make your request to the server corresponding to your region. \n\nYou can check the region for your application in the [Algolia dashboard](https://dashboard.algolia.com/account/infrastructure/analytics).\n", - "value": { - "status": 401, - "message": "The log processing region does not match" - } - }, - "InvalidCredentials": { - "summary": "Invalid credentials.", - "description": "Your application ID or API key is wrong.", - "value": { - "status": 401, - "message": "Invalid credentials" - } - }, - "MissingACL": { - "summary": "Key is missing ACL.", - "description": "Your API key is missing the required ACL for this operation.", - "value": { - "status": 401, - "message": "The provided API key is missing the \\\"editSettings\\\" ACL" - } - } - } - } - } - }, - "404": { - "description": "Not Found.", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "integer", - "description": "HTTP status code." - }, - "message": { - "type": "string", - "description": "Details about the response, such as error messages." - } - } - }, - "examples": { - "NotFound": { - "summary": "Index not found.", - "value": { - "status": 404, - "message": "Not Found" - } - } - } - } - } - } - } - } - } - } -} \ No newline at end of file diff --git a/specs/bundled/recommend.json b/specs/bundled/recommend.json deleted file mode 100644 index 2fd827385c..0000000000 --- a/specs/bundled/recommend.json +++ /dev/null @@ -1,44814 +0,0 @@ -{ - "openapi": "3.0.2", - "info": { - "title": "Recommend API", - "description": "The Recommend API lets you generate recommendations with several AI models.\n\n> **Note**: You should use Algolia's [libraries and tools](https://www.algolia.com/doc/guides/getting-started/how-algolia-works/in-depth/ecosystem/) to interact with the Recommend API. Using the HTTP endpoints directly is not covered by the [SLA](https://www.algolia.com/policies/sla/).", - "version": "1.0.0" - }, - "components": { - "securitySchemes": { - "appId": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-Application-Id" - }, - "apiKey": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-API-Key" - } - }, - "parameters": { - "PathInPath": { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - "Parameters": { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - }, - "IndexName": { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - "Models": { - "in": "path", - "name": "model", - "required": true, - "description": "[Recommend models](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).\n", - "schema": { - "type": "string", - "enum": [ - "related-products", - "bought-together", - "trending-facets", - "trending-items" - ] - } - }, - "ObjectID": { - "name": "objectID", - "in": "path", - "description": "Unique record (object) identifier.", - "required": true, - "schema": { - "type": "string", - "example": "123" - } - } - }, - "schemas": { - "ErrorBase": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - }, - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "baseRecommendRequest": { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "facetValue": { - "type": "string", - "description": "Facet value for trending models." - }, - "trendingItemsModel": { - "description": "Trending items model.", - "type": "string", - "enum": [ - "trending-items" - ] - }, - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "searchParamsQuery": { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "searchFiltersArrayString": { - "type": "array", - "items": { - "type": "string" - } - }, - "mixedSearchFilters": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - }, - "listOfSearchFilters": { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadiusAll": { - "type": "string", - "enum": [ - "all" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecisionFromValue": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "baseSearchParamsWithoutQuery": { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - "baseSearchParams": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "typoToleranceEnum": { - "type": "string", - "enum": [ - "min", - "strict" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - }, - "value": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - }, - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - }, - "indexSettingsAsSearchParams": { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - "searchParamsObject": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - "baseTrendingItemsQuery": { - "type": "object", - "additionalProperties": false, - "properties": { - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "facetValue": { - "type": "string", - "description": "Facet value for trending models." - }, - "model": { - "description": "Trending items model.", - "type": "string", - "enum": [ - "trending-items" - ] - }, - "queryParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - "fallbackParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - } - }, - "trendingItemsQuery": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "facetValue": { - "type": "string", - "description": "Facet value for trending models." - }, - "model": { - "description": "Trending items model.", - "type": "string", - "enum": [ - "trending-items" - ] - }, - "queryParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - "fallbackParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - } - } - ] - }, - "trendingFacetsModel": { - "description": "Trending facets model.", - "type": "string", - "enum": [ - "trending-facets" - ] - }, - "baseTrendingFacetsQuery": { - "type": "object", - "additionalProperties": false, - "properties": { - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "model": { - "description": "Trending facets model.", - "type": "string", - "enum": [ - "trending-facets" - ] - } - }, - "required": [ - "facetName" - ] - }, - "trendingFacetsQuery": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "model": { - "description": "Trending facets model.", - "type": "string", - "enum": [ - "trending-facets" - ] - } - }, - "required": [ - "facetName" - ] - } - ] - }, - "recommendationModels": { - "description": "Recommendation model.", - "type": "string", - "enum": [ - "related-products", - "bought-together" - ] - }, - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "baseRecommendationsQuery": { - "type": "object", - "additionalProperties": false, - "properties": { - "model": { - "description": "Recommendation model.", - "type": "string", - "enum": [ - "related-products", - "bought-together" - ] - }, - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "queryParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - "fallbackParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - }, - "required": [ - "model", - "objectID" - ] - }, - "recommendationsQuery": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "model": { - "description": "Recommendation model.", - "type": "string", - "enum": [ - "related-products", - "bought-together" - ] - }, - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "queryParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - "fallbackParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - }, - "required": [ - "model", - "objectID" - ] - } - ] - }, - "recommendedForYouModel": { - "description": "Recommended for you model.", - "type": "string", - "enum": [ - "recommended-for-you" - ] - }, - "baseRecommendedForYouQueryParameters": { - "type": "object", - "properties": { - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - } - }, - "required": [ - "userToken" - ] - }, - "recommendedForYouQueryParameters": { - "allOf": [ - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - { - "type": "object", - "properties": { - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - } - }, - "required": [ - "userToken" - ] - } - ] - }, - "baseRecommendedForYouQuery": { - "type": "object", - "additionalProperties": false, - "properties": { - "model": { - "description": "Recommended for you model.", - "type": "string", - "enum": [ - "recommended-for-you" - ] - }, - "queryParameters": { - "allOf": [ - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - { - "type": "object", - "properties": { - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - } - }, - "required": [ - "userToken" - ] - } - ] - }, - "fallbackParameters": { - "allOf": [ - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - { - "type": "object", - "properties": { - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - } - }, - "required": [ - "userToken" - ] - } - ] - } - }, - "required": [ - "model" - ] - }, - "recommendedForYouQuery": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "model": { - "description": "Recommended for you model.", - "type": "string", - "enum": [ - "recommended-for-you" - ] - }, - "queryParameters": { - "allOf": [ - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - { - "type": "object", - "properties": { - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - } - }, - "required": [ - "userToken" - ] - } - ] - }, - "fallbackParameters": { - "allOf": [ - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - { - "type": "object", - "properties": { - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - } - }, - "required": [ - "userToken" - ] - } - ] - } - }, - "required": [ - "model" - ] - } - ] - }, - "recommendationsRequest": { - "oneOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "facetValue": { - "type": "string", - "description": "Facet value for trending models." - }, - "model": { - "description": "Trending items model.", - "type": "string", - "enum": [ - "trending-items" - ] - }, - "queryParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - "fallbackParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - } - } - ] - }, - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "model": { - "description": "Trending facets model.", - "type": "string", - "enum": [ - "trending-facets" - ] - } - }, - "required": [ - "facetName" - ] - } - ] - }, - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "model": { - "description": "Recommendation model.", - "type": "string", - "enum": [ - "related-products", - "bought-together" - ] - }, - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "queryParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - "fallbackParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - }, - "required": [ - "model", - "objectID" - ] - } - ] - }, - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "model": { - "description": "Recommended for you model.", - "type": "string", - "enum": [ - "recommended-for-you" - ] - }, - "queryParameters": { - "allOf": [ - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - { - "type": "object", - "properties": { - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - } - }, - "required": [ - "userToken" - ] - } - ] - }, - "fallbackParameters": { - "allOf": [ - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - { - "type": "object", - "properties": { - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - } - }, - "required": [ - "userToken" - ] - } - ] - } - }, - "required": [ - "model" - ] - } - ] - } - ] - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "RedirectRuleIndexMetadata": { - "type": "object", - "properties": { - "source": { - "type": "string", - "description": "Source index for the redirect rule." - }, - "dest": { - "type": "string", - "description": "Destination index for the redirect rule." - }, - "reason": { - "type": "string", - "description": "Reason for the redirect rule." - }, - "succeed": { - "type": "boolean", - "description": "Redirect rule status." - }, - "data": { - "type": "object", - "description": "Redirect rule data.", - "required": [ - "ruleObjectID" - ], - "properties": { - "ruleObjectID": { - "type": "string" - } - } - } - }, - "required": [ - "data", - "succeed", - "reason", - "dest", - "source" - ] - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - }, - "baseSearchResponse": { - "type": "object", - "additionalProperties": true, - "required": [ - "nbHits", - "page", - "nbPages", - "hitsPerPage", - "processingTimeMS" - ], - "properties": { - "abTestID": { - "type": "integer", - "description": "A/B test ID. This is only included in the response for indices that are part of an A/B test." - }, - "abTestVariantID": { - "type": "integer", - "minimum": 1, - "description": "Variant ID. This is only included in the response for indices that are part of an A/B test." - }, - "aroundLatLng": { - "type": "string", - "description": "Computed geographical location.", - "example": "40.71,-74.01", - "pattern": "^(-?\\d+(\\.\\d+)?),\\s*(-?\\d+(\\.\\d+)?)$" - }, - "automaticRadius": { - "type": "string", - "description": "Automatically-computed radius." - }, - "exhaustive": { - "type": "object", - "title": "exhaustive", - "description": "Whether certain properties of the search response are calculated exhaustive (exact) or approximated.", - "properties": { - "facetsCount": { - "type": "boolean", - "title": "facetsCount", - "description": "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-)." - }, - "facetValues": { - "type": "boolean", - "title": "facetValues", - "description": "The value is `false` if not all facet values are retrieved." - }, - "nbHits": { - "type": "boolean", - "title": "nbHits", - "description": "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." - }, - "rulesMatch": { - "type": "boolean", - "title": "rulesMatch", - "description": "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." - }, - "typo": { - "type": "boolean", - "title": "typo", - "description": "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." - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveNbHits": { - "type": "boolean", - "description": "See the `nbHits` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveTypo": { - "type": "boolean", - "description": "See the `typo` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "facets": { - "title": "facets", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "integer" - } - }, - "description": "Mapping of each facet name to the corresponding facet counts.", - "example": { - "category": { - "food": 1, - "tech": 42 - } - } - }, - "facets_stats": { - "title": "facetsStats", - "type": "object", - "description": "Statistics for numerical facets.", - "additionalProperties": { - "type": "object", - "title": "facetStats", - "properties": { - "min": { - "type": "number", - "format": "double", - "description": "Minimum value in the results." - }, - "max": { - "type": "number", - "format": "double", - "description": "Maximum value in the results." - }, - "avg": { - "type": "number", - "format": "double", - "description": "Average facet value in the results." - }, - "sum": { - "type": "number", - "format": "double", - "description": "Sum of all values in the results." - } - } - } - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "index": { - "type": "string", - "example": "indexName", - "description": "Index name used for the query." - }, - "indexUsed": { - "type": "string", - "description": "Index name used for the query. During A/B testing, the targeted index isn't always the index used by the query.", - "example": "indexNameAlt" - }, - "message": { - "type": "string", - "description": "Warnings about the query." - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - }, - "nbSortedHits": { - "type": "integer", - "description": "Number of hits selected and sorted by the relevant sort algorithm.", - "example": 20 - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "parsedQuery": { - "type": "string", - "description": "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.", - "example": "george clo" - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "processingTimingsMS": { - "type": "object", - "description": "Experimental. List of processing steps and their times, in milliseconds. You can use this list to investigate performance issues." - }, - "queryAfterRemoval": { - "type": "string", - "description": "Markup text indicating which parts of the original query have been removed to retrieve a non-empty result set." - }, - "redirect": { - "title": "redirect", - "type": "object", - "description": "[Redirect results to a URL](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/redirects/).\n", - "properties": { - "index": { - "type": "array", - "items": { - "type": "object", - "properties": { - "source": { - "type": "string", - "description": "Source index for the redirect rule." - }, - "dest": { - "type": "string", - "description": "Destination index for the redirect rule." - }, - "reason": { - "type": "string", - "description": "Reason for the redirect rule." - }, - "succeed": { - "type": "boolean", - "description": "Redirect rule status." - }, - "data": { - "type": "object", - "description": "Redirect rule data.", - "required": [ - "ruleObjectID" - ], - "properties": { - "ruleObjectID": { - "type": "string" - } - } - } - }, - "required": [ - "data", - "succeed", - "reason", - "dest", - "source" - ] - } - } - } - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "serverTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "serverUsed": { - "type": "string", - "description": "Host name of the server that processed the request.", - "example": "c2-uk-3.algolia.net" - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - } - } - }, - "highlightedValue": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "highlightResultOption": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - "highlightResultOptionMap": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - "highlightResultOptionArray": { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - "highlightResult": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - }, - "highlightResultMap": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "snippetResultOption": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - "snippetResultOptionMap": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - "snippetResultOptionArray": { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - "snippetResult": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - }, - "snippetResultMap": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - }, - "recommendScore": { - "type": "number", - "format": "double", - "minimum": 0, - "maximum": 100, - "description": "Recommendation score." - }, - "recommendHit": { - "type": "object", - "description": "Recommend hit.", - "additionalProperties": true, - "required": [ - "objectID", - "_score" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - }, - "_score": { - "type": "number", - "format": "double", - "minimum": 0, - "maximum": 100, - "description": "Recommendation score." - } - } - }, - "trendingFacetHit": { - "type": "object", - "description": "Trending facet hit.", - "required": [ - "_score", - "facetName", - "facetValue" - ], - "properties": { - "_score": { - "type": "number", - "format": "double", - "minimum": 0, - "maximum": 100, - "description": "Recommendation score." - }, - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "facetValue": { - "type": "string", - "description": "Facet value for trending models." - } - } - }, - "recommendationsHit": { - "oneOf": [ - { - "type": "object", - "description": "Recommend hit.", - "additionalProperties": true, - "required": [ - "objectID", - "_score" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - }, - "_score": { - "type": "number", - "format": "double", - "minimum": 0, - "maximum": 100, - "description": "Recommendation score." - } - } - }, - { - "type": "object", - "description": "Trending facet hit.", - "required": [ - "_score", - "facetName", - "facetValue" - ], - "properties": { - "_score": { - "type": "number", - "format": "double", - "minimum": 0, - "maximum": 100, - "description": "Recommendation score." - }, - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "facetValue": { - "type": "string", - "description": "Facet value for trending models." - } - } - } - ] - }, - "recommendationsHits": { - "type": "object", - "additionalProperties": false, - "properties": { - "hits": { - "type": "array", - "items": { - "oneOf": [ - { - "type": "object", - "description": "Recommend hit.", - "additionalProperties": true, - "required": [ - "objectID", - "_score" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - }, - "_score": { - "type": "number", - "format": "double", - "minimum": 0, - "maximum": 100, - "description": "Recommendation score." - } - } - }, - { - "type": "object", - "description": "Trending facet hit.", - "required": [ - "_score", - "facetName", - "facetValue" - ], - "properties": { - "_score": { - "type": "number", - "format": "double", - "minimum": 0, - "maximum": 100, - "description": "Recommendation score." - }, - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "facetValue": { - "type": "string", - "description": "Facet value for trending models." - } - } - } - ] - } - }, - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "params": { - "type": "string", - "description": "URL-encoded string of all search parameters.", - "example": "query=a&hitsPerPage=20" - } - }, - "required": [ - "hits" - ] - }, - "recommendationsResults": { - "allOf": [ - { - "type": "object", - "additionalProperties": true, - "required": [ - "nbHits", - "page", - "nbPages", - "hitsPerPage", - "processingTimeMS" - ], - "properties": { - "abTestID": { - "type": "integer", - "description": "A/B test ID. This is only included in the response for indices that are part of an A/B test." - }, - "abTestVariantID": { - "type": "integer", - "minimum": 1, - "description": "Variant ID. This is only included in the response for indices that are part of an A/B test." - }, - "aroundLatLng": { - "type": "string", - "description": "Computed geographical location.", - "example": "40.71,-74.01", - "pattern": "^(-?\\d+(\\.\\d+)?),\\s*(-?\\d+(\\.\\d+)?)$" - }, - "automaticRadius": { - "type": "string", - "description": "Automatically-computed radius." - }, - "exhaustive": { - "type": "object", - "title": "exhaustive", - "description": "Whether certain properties of the search response are calculated exhaustive (exact) or approximated.", - "properties": { - "facetsCount": { - "type": "boolean", - "title": "facetsCount", - "description": "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-)." - }, - "facetValues": { - "type": "boolean", - "title": "facetValues", - "description": "The value is `false` if not all facet values are retrieved." - }, - "nbHits": { - "type": "boolean", - "title": "nbHits", - "description": "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." - }, - "rulesMatch": { - "type": "boolean", - "title": "rulesMatch", - "description": "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." - }, - "typo": { - "type": "boolean", - "title": "typo", - "description": "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." - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveNbHits": { - "type": "boolean", - "description": "See the `nbHits` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveTypo": { - "type": "boolean", - "description": "See the `typo` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "facets": { - "title": "facets", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "integer" - } - }, - "description": "Mapping of each facet name to the corresponding facet counts.", - "example": { - "category": { - "food": 1, - "tech": 42 - } - } - }, - "facets_stats": { - "title": "facetsStats", - "type": "object", - "description": "Statistics for numerical facets.", - "additionalProperties": { - "type": "object", - "title": "facetStats", - "properties": { - "min": { - "type": "number", - "format": "double", - "description": "Minimum value in the results." - }, - "max": { - "type": "number", - "format": "double", - "description": "Maximum value in the results." - }, - "avg": { - "type": "number", - "format": "double", - "description": "Average facet value in the results." - }, - "sum": { - "type": "number", - "format": "double", - "description": "Sum of all values in the results." - } - } - } - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "index": { - "type": "string", - "example": "indexName", - "description": "Index name used for the query." - }, - "indexUsed": { - "type": "string", - "description": "Index name used for the query. During A/B testing, the targeted index isn't always the index used by the query.", - "example": "indexNameAlt" - }, - "message": { - "type": "string", - "description": "Warnings about the query." - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - }, - "nbSortedHits": { - "type": "integer", - "description": "Number of hits selected and sorted by the relevant sort algorithm.", - "example": 20 - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "parsedQuery": { - "type": "string", - "description": "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.", - "example": "george clo" - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "processingTimingsMS": { - "type": "object", - "description": "Experimental. List of processing steps and their times, in milliseconds. You can use this list to investigate performance issues." - }, - "queryAfterRemoval": { - "type": "string", - "description": "Markup text indicating which parts of the original query have been removed to retrieve a non-empty result set." - }, - "redirect": { - "title": "redirect", - "type": "object", - "description": "[Redirect results to a URL](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/redirects/).\n", - "properties": { - "index": { - "type": "array", - "items": { - "type": "object", - "properties": { - "source": { - "type": "string", - "description": "Source index for the redirect rule." - }, - "dest": { - "type": "string", - "description": "Destination index for the redirect rule." - }, - "reason": { - "type": "string", - "description": "Reason for the redirect rule." - }, - "succeed": { - "type": "boolean", - "description": "Redirect rule status." - }, - "data": { - "type": "object", - "description": "Redirect rule data.", - "required": [ - "ruleObjectID" - ], - "properties": { - "ruleObjectID": { - "type": "string" - } - } - } - }, - "required": [ - "data", - "succeed", - "reason", - "dest", - "source" - ] - } - } - } - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "serverTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "serverUsed": { - "type": "string", - "description": "Host name of the server that processed the request.", - "example": "c2-uk-3.algolia.net" - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "hits": { - "type": "array", - "items": { - "oneOf": [ - { - "type": "object", - "description": "Recommend hit.", - "additionalProperties": true, - "required": [ - "objectID", - "_score" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - }, - "_score": { - "type": "number", - "format": "double", - "minimum": 0, - "maximum": 100, - "description": "Recommendation score." - } - } - }, - { - "type": "object", - "description": "Trending facet hit.", - "required": [ - "_score", - "facetName", - "facetValue" - ], - "properties": { - "_score": { - "type": "number", - "format": "double", - "minimum": 0, - "maximum": 100, - "description": "Recommendation score." - }, - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "facetValue": { - "type": "string", - "description": "Facet value for trending models." - } - } - } - ] - } - }, - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "params": { - "type": "string", - "description": "URL-encoded string of all search parameters.", - "example": "query=a&hitsPerPage=20" - } - }, - "required": [ - "hits" - ] - } - ] - }, - "recommendModels": { - "type": "string", - "enum": [ - "related-products", - "bought-together", - "trending-facets", - "trending-items" - ] - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "condition": { - "type": "object", - "additionalProperties": false, - "properties": { - "pattern": { - "type": "string", - "description": "Query pattern syntax.", - "example": "{facet:brand}" - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "alternatives": { - "type": "boolean", - "description": "Whether the pattern matches on plurals, synonyms, and typos.", - "default": false - }, - "context": { - "type": "string", - "description": "Rule context format: [A-Za-z0-9_-]+).", - "example": "trackedFilters" - } - } - }, - "editType": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "edit": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - }, - "consequenceQueryObject": { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - "consequenceQuery": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilter": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "params": { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - }, - "consequenceParams": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "promotePosition": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - }, - "promoteObjectIDs": { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - "promoteObjectID": { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - }, - "promote": { - "oneOf": [ - { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - } - ] - }, - "consequence": { - "type": "object", - "description": "[Consequences](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#consequences) of a rule.\n", - "additionalProperties": false, - "properties": { - "params": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "promote": { - "type": "array", - "description": "Records to promote.", - "items": { - "oneOf": [ - { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - } - ] - } - }, - "filterPromotes": { - "type": "boolean", - "default": false, - "description": "Only use in combination with the `promote` consequence. When `true`, promoted results will be restricted to match the filters of the current search. When `false`, the promoted results will show up regardless of the filters." - }, - "hide": { - "type": "array", - "description": "Records to hide. By default, you can hide up to 50 records per rule.", - "items": { - "title": "consequenceHide", - "type": "object", - "description": "Unique identifier of the record to hide.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - }, - "required": [ - "objectID" - ] - } - }, - "userData": { - "description": "Custom JSON object that will be appended to the userData array in the response. This object isn't interpreted by the API. It's limited to 1kB of minified JSON.", - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - } - } - } - }, - "RuleResponse": { - "type": "object", - "description": "Rule object.", - "additionalProperties": false, - "properties": { - "_metadata": { - "type": "object", - "properties": { - "lastUpdate": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - }, - "objectID": { - "type": "string", - "description": "Unique identifier for a rule object.", - "example": "hide-12345" - }, - "conditions": { - "type": "array", - "description": "[Conditions](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#conditions) required to activate a rule. You can use up to 25 conditions per rule.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "pattern": { - "type": "string", - "description": "Query pattern syntax.", - "example": "{facet:brand}" - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "alternatives": { - "type": "boolean", - "description": "Whether the pattern matches on plurals, synonyms, and typos.", - "default": false - }, - "context": { - "type": "string", - "description": "Rule context format: [A-Za-z0-9_-]+).", - "example": "trackedFilters" - } - } - } - }, - "consequence": { - "type": "object", - "description": "[Consequences](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#consequences) of a rule.\n", - "additionalProperties": false, - "properties": { - "params": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "promote": { - "type": "array", - "description": "Records to promote.", - "items": { - "oneOf": [ - { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - } - ] - } - }, - "filterPromotes": { - "type": "boolean", - "default": false, - "description": "Only use in combination with the `promote` consequence. When `true`, promoted results will be restricted to match the filters of the current search. When `false`, the promoted results will show up regardless of the filters." - }, - "hide": { - "type": "array", - "description": "Records to hide. By default, you can hide up to 50 records per rule.", - "items": { - "title": "consequenceHide", - "type": "object", - "description": "Unique identifier of the record to hide.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - }, - "required": [ - "objectID" - ] - } - }, - "userData": { - "description": "Custom JSON object that will be appended to the userData array in the response. This object isn't interpreted by the API. It's limited to 1kB of minified JSON.", - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - } - } - } - }, - "description": { - "type": "string", - "description": "Description of the rule's purpose. This can be helpful for display in the Algolia dashboard.", - "example": "Display a promotional banner" - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Indicates whether to enable the rule. If it isn't enabled, it isn't applied at query time." - } - }, - "required": [ - "objectID" - ] - }, - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "deletedAt": { - "type": "string", - "example": "2023-06-27T14:42:38.831Z", - "description": "Timestamp of deletion in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "taskStatus": { - "type": "string", - "enum": [ - "published", - "notPublished" - ], - "description": "_published_ if the task has been processed, _notPublished_ otherwise." - }, - "parameters_query": { - "type": "string", - "description": "Full-text query.", - "default": "" - }, - "parameters_page": { - "type": "integer", - "minimum": 0, - "description": "Requested page (the first page is page 0)." - }, - "parameters_hitsPerPage": { - "type": "integer", - "default": 20, - "minimum": 1, - "maximum": 1000, - "description": "Maximum number of hits per page." - } - }, - "responses": { - "BadRequest": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "FeatureNotEnabled": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "MethodNotAllowed": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "IndexNotFound": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "DeletedAt": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "deletedAtResponse", - "description": "Response, taskID, and deletion timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "deletedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "deletedAt": { - "type": "string", - "example": "2023-06-27T14:42:38.831Z", - "description": "Timestamp of deletion in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - } - } - }, - "servers": [ - { - "url": "https://{appId}.algolianet.com", - "variables": { - "appId": { - "default": "myAppId" - } - } - }, - { - "url": "https://{appId}-1.algolianet.com", - "variables": { - "appId": { - "default": "myAppId" - } - } - }, - { - "url": "https://{appId}-2.algolianet.com", - "variables": { - "appId": { - "default": "myAppId" - } - } - }, - { - "url": "https://{appId}-3.algolianet.com", - "variables": { - "appId": { - "default": "myAppId" - } - } - }, - { - "url": "https://{appId}-dsn.algolianet.com", - "variables": { - "appId": { - "default": "myAppId" - } - } - } - ], - "security": [ - { - "appId": [], - "apiKey": [] - } - ], - "tags": [ - { - "name": "recommendations", - "x-displayName": "Recommend", - "description": "Manage recommendations." - } - ], - "x-tagGroups": [ - { - "name": "General", - "tags": [ - "recommendations" - ] - } - ], - "paths": { - "/1{path}": { - "get": { - "operationId": "customGet", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "operationId": "customPost", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "operationId": "customPut", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "operationId": "customDelete", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/*/recommendations": { - "post": { - "tags": [ - "recommendations" - ], - "operationId": "getRecommendations", - "x-use-read-transporter": true, - "x-cacheable": true, - "x-acl": [ - "search" - ], - "summary": "Get recommendations and trending items.", - "description": "Returns results from either recommendation or trending models:\n\n - **Recommendations** are provided by the [Related Products](https://www.algolia.com/doc/guides/algolia-recommend/overview/#related-products-and-related-content) and [Frequently Bought Together](https://www.algolia.com/doc/guides/algolia-recommend/overview/#frequently-bought-together) models\n - **Trending** models are [Trending Items and Trending Facet Values](https://www.algolia.com/doc/guides/algolia-recommend/overview/#trending-items-and-trending-facet-values).\n", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "title": "getRecommendationsParams", - "description": "Recommend parameters.", - "type": "object", - "additionalProperties": false, - "properties": { - "requests": { - "type": "array", - "description": "Request parameters depend on the model (recommendations or trending).", - "items": { - "oneOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "facetValue": { - "type": "string", - "description": "Facet value for trending models." - }, - "model": { - "description": "Trending items model.", - "type": "string", - "enum": [ - "trending-items" - ] - }, - "queryParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - "fallbackParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - } - } - ] - }, - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "model": { - "description": "Trending facets model.", - "type": "string", - "enum": [ - "trending-facets" - ] - } - }, - "required": [ - "facetName" - ] - } - ] - }, - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "model": { - "description": "Recommendation model.", - "type": "string", - "enum": [ - "related-products", - "bought-together" - ] - }, - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "queryParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - "fallbackParameters": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - }, - "required": [ - "model", - "objectID" - ] - } - ] - }, - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "threshold": { - "type": "integer", - "minimum": 0, - "maximum": 100, - "description": "Recommendations with a confidence score lower than `threshold` won't appear in results.\n> **Note**: Each recommendation has a confidence score of 0 to 100. The closer the score is to 100, the more relevant the recommendations are.\n" - }, - "maxRecommendations": { - "type": "integer", - "default": 0, - "description": "Maximum number of recommendations to retrieve. If 0, all recommendations will be returned." - } - }, - "required": [ - "indexName" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "model": { - "description": "Recommended for you model.", - "type": "string", - "enum": [ - "recommended-for-you" - ] - }, - "queryParameters": { - "allOf": [ - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - { - "type": "object", - "properties": { - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - } - }, - "required": [ - "userToken" - ] - } - ] - }, - "fallbackParameters": { - "allOf": [ - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - { - "type": "object", - "properties": { - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - } - }, - "required": [ - "userToken" - ] - } - ] - } - }, - "required": [ - "model" - ] - } - ] - } - ] - } - } - }, - "required": [ - "requests" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getRecommendationsResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "results": { - "type": "array", - "items": { - "allOf": [ - { - "type": "object", - "additionalProperties": true, - "required": [ - "nbHits", - "page", - "nbPages", - "hitsPerPage", - "processingTimeMS" - ], - "properties": { - "abTestID": { - "type": "integer", - "description": "A/B test ID. This is only included in the response for indices that are part of an A/B test." - }, - "abTestVariantID": { - "type": "integer", - "minimum": 1, - "description": "Variant ID. This is only included in the response for indices that are part of an A/B test." - }, - "aroundLatLng": { - "type": "string", - "description": "Computed geographical location.", - "example": "40.71,-74.01", - "pattern": "^(-?\\d+(\\.\\d+)?),\\s*(-?\\d+(\\.\\d+)?)$" - }, - "automaticRadius": { - "type": "string", - "description": "Automatically-computed radius." - }, - "exhaustive": { - "type": "object", - "title": "exhaustive", - "description": "Whether certain properties of the search response are calculated exhaustive (exact) or approximated.", - "properties": { - "facetsCount": { - "type": "boolean", - "title": "facetsCount", - "description": "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-)." - }, - "facetValues": { - "type": "boolean", - "title": "facetValues", - "description": "The value is `false` if not all facet values are retrieved." - }, - "nbHits": { - "type": "boolean", - "title": "nbHits", - "description": "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." - }, - "rulesMatch": { - "type": "boolean", - "title": "rulesMatch", - "description": "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." - }, - "typo": { - "type": "boolean", - "title": "typo", - "description": "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." - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveNbHits": { - "type": "boolean", - "description": "See the `nbHits` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveTypo": { - "type": "boolean", - "description": "See the `typo` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "facets": { - "title": "facets", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "integer" - } - }, - "description": "Mapping of each facet name to the corresponding facet counts.", - "example": { - "category": { - "food": 1, - "tech": 42 - } - } - }, - "facets_stats": { - "title": "facetsStats", - "type": "object", - "description": "Statistics for numerical facets.", - "additionalProperties": { - "type": "object", - "title": "facetStats", - "properties": { - "min": { - "type": "number", - "format": "double", - "description": "Minimum value in the results." - }, - "max": { - "type": "number", - "format": "double", - "description": "Maximum value in the results." - }, - "avg": { - "type": "number", - "format": "double", - "description": "Average facet value in the results." - }, - "sum": { - "type": "number", - "format": "double", - "description": "Sum of all values in the results." - } - } - } - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "index": { - "type": "string", - "example": "indexName", - "description": "Index name used for the query." - }, - "indexUsed": { - "type": "string", - "description": "Index name used for the query. During A/B testing, the targeted index isn't always the index used by the query.", - "example": "indexNameAlt" - }, - "message": { - "type": "string", - "description": "Warnings about the query." - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - }, - "nbSortedHits": { - "type": "integer", - "description": "Number of hits selected and sorted by the relevant sort algorithm.", - "example": 20 - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "parsedQuery": { - "type": "string", - "description": "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.", - "example": "george clo" - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "processingTimingsMS": { - "type": "object", - "description": "Experimental. List of processing steps and their times, in milliseconds. You can use this list to investigate performance issues." - }, - "queryAfterRemoval": { - "type": "string", - "description": "Markup text indicating which parts of the original query have been removed to retrieve a non-empty result set." - }, - "redirect": { - "title": "redirect", - "type": "object", - "description": "[Redirect results to a URL](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/redirects/).\n", - "properties": { - "index": { - "type": "array", - "items": { - "type": "object", - "properties": { - "source": { - "type": "string", - "description": "Source index for the redirect rule." - }, - "dest": { - "type": "string", - "description": "Destination index for the redirect rule." - }, - "reason": { - "type": "string", - "description": "Reason for the redirect rule." - }, - "succeed": { - "type": "boolean", - "description": "Redirect rule status." - }, - "data": { - "type": "object", - "description": "Redirect rule data.", - "required": [ - "ruleObjectID" - ], - "properties": { - "ruleObjectID": { - "type": "string" - } - } - } - }, - "required": [ - "data", - "succeed", - "reason", - "dest", - "source" - ] - } - } - } - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "serverTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "serverUsed": { - "type": "string", - "description": "Host name of the server that processed the request.", - "example": "c2-uk-3.algolia.net" - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "hits": { - "type": "array", - "items": { - "oneOf": [ - { - "type": "object", - "description": "Recommend hit.", - "additionalProperties": true, - "required": [ - "objectID", - "_score" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - }, - "_score": { - "type": "number", - "format": "double", - "minimum": 0, - "maximum": 100, - "description": "Recommendation score." - } - } - }, - { - "type": "object", - "description": "Trending facet hit.", - "required": [ - "_score", - "facetName", - "facetValue" - ], - "properties": { - "_score": { - "type": "number", - "format": "double", - "minimum": 0, - "maximum": 100, - "description": "Recommendation score." - }, - "facetName": { - "type": "string", - "description": "Facet name for trending models." - }, - "facetValue": { - "type": "string", - "description": "Facet value for trending models." - } - } - } - ] - } - }, - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "params": { - "type": "string", - "description": "URL-encoded string of all search parameters.", - "example": "query=a&hitsPerPage=20" - } - }, - "required": [ - "hits" - ] - } - ] - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/{model}/recommend/rules/{objectID}": { - "get": { - "tags": [ - "recommendations" - ], - "operationId": "getRecommendRule", - "x-acl": [ - "settings" - ], - "summary": "Get a Recommend rule.", - "description": "Return a [Recommend rule](https://www.algolia.com/doc/guides/algolia-recommend/how-to/rules/).", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "in": "path", - "name": "model", - "required": true, - "description": "[Recommend models](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).\n", - "schema": { - "type": "string", - "enum": [ - "related-products", - "bought-together", - "trending-facets", - "trending-items" - ] - } - }, - { - "name": "objectID", - "in": "path", - "description": "Unique record (object) identifier.", - "required": true, - "schema": { - "type": "string", - "example": "123" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "Rule object.", - "additionalProperties": false, - "properties": { - "_metadata": { - "type": "object", - "properties": { - "lastUpdate": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - }, - "objectID": { - "type": "string", - "description": "Unique identifier for a rule object.", - "example": "hide-12345" - }, - "conditions": { - "type": "array", - "description": "[Conditions](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#conditions) required to activate a rule. You can use up to 25 conditions per rule.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "pattern": { - "type": "string", - "description": "Query pattern syntax.", - "example": "{facet:brand}" - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "alternatives": { - "type": "boolean", - "description": "Whether the pattern matches on plurals, synonyms, and typos.", - "default": false - }, - "context": { - "type": "string", - "description": "Rule context format: [A-Za-z0-9_-]+).", - "example": "trackedFilters" - } - } - } - }, - "consequence": { - "type": "object", - "description": "[Consequences](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#consequences) of a rule.\n", - "additionalProperties": false, - "properties": { - "params": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "promote": { - "type": "array", - "description": "Records to promote.", - "items": { - "oneOf": [ - { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - } - ] - } - }, - "filterPromotes": { - "type": "boolean", - "default": false, - "description": "Only use in combination with the `promote` consequence. When `true`, promoted results will be restricted to match the filters of the current search. When `false`, the promoted results will show up regardless of the filters." - }, - "hide": { - "type": "array", - "description": "Records to hide. By default, you can hide up to 50 records per rule.", - "items": { - "title": "consequenceHide", - "type": "object", - "description": "Unique identifier of the record to hide.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - }, - "required": [ - "objectID" - ] - } - }, - "userData": { - "description": "Custom JSON object that will be appended to the userData array in the response. This object isn't interpreted by the API. It's limited to 1kB of minified JSON.", - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - } - } - } - }, - "description": { - "type": "string", - "description": "Description of the rule's purpose. This can be helpful for display in the Algolia dashboard.", - "example": "Display a promotional banner" - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Indicates whether to enable the rule. If it isn't enabled, it isn't applied at query time." - } - }, - "required": [ - "objectID" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "recommendations" - ], - "operationId": "deleteRecommendRule", - "x-acl": [ - "editSettings" - ], - "summary": "Delete a Recommend rule.", - "description": "Delete a [Recommend rule](https://www.algolia.com/doc/guides/algolia-recommend/how-to/rules/).", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "in": "path", - "name": "model", - "required": true, - "description": "[Recommend models](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).\n", - "schema": { - "type": "string", - "enum": [ - "related-products", - "bought-together", - "trending-facets", - "trending-items" - ] - } - }, - { - "name": "objectID", - "in": "path", - "description": "Unique record (object) identifier.", - "required": true, - "schema": { - "type": "string", - "example": "123" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "deletedAtResponse", - "description": "Response, taskID, and deletion timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "deletedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "deletedAt": { - "type": "string", - "example": "2023-06-27T14:42:38.831Z", - "description": "Timestamp of deletion in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/{model}/task/{taskID}": { - "get": { - "tags": [ - "recommendations" - ], - "operationId": "getRecommendStatus", - "x-acl": [ - "editSettings" - ], - "summary": "Get a Recommend task's status.", - "description": "Some operations, such as deleting a Recommend rule, will respond with a `taskID` value. Use this value here to check the status of that task.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "in": "path", - "name": "model", - "required": true, - "description": "[Recommend models](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).\n", - "schema": { - "type": "string", - "enum": [ - "related-products", - "bought-together", - "trending-facets", - "trending-items" - ] - } - }, - { - "name": "taskID", - "in": "path", - "description": "Unique identifier of a task. Numeric value (up to 64bits).", - "required": true, - "schema": { - "type": "integer", - "format": "int64", - "example": 13235 - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getRecommendTaskResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "string", - "enum": [ - "published", - "notPublished" - ], - "description": "_published_ if the task has been processed, _notPublished_ otherwise." - } - }, - "required": [ - "status" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/{model}/recommend/rules/search": { - "post": { - "tags": [ - "recommendations" - ], - "operationId": "searchRecommendRules", - "x-use-read-transporter": true, - "x-cacheable": true, - "x-acl": [ - "settings" - ], - "summary": "List Recommend rules.", - "description": "List [Recommend rules](https://www.algolia.com/doc/guides/algolia-recommend/how-to/rules/).", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "in": "path", - "name": "model", - "required": true, - "description": "[Recommend models](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).\n", - "schema": { - "type": "string", - "enum": [ - "related-products", - "bought-together", - "trending-facets", - "trending-items" - ] - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "title": "searchRecommendRulesParams", - "description": "Recommend rules search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Full-text query.", - "default": "" - }, - "context": { - "type": "string", - "description": "Restricts responses to the specified [contextual rule](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#creating-contextual-rules).", - "example": "mobile" - }, - "page": { - "type": "integer", - "minimum": 0, - "description": "Requested page (the first page is page 0)." - }, - "hitsPerPage": { - "type": "integer", - "default": 20, - "minimum": 1, - "maximum": 1000, - "description": "Maximum number of hits per page." - }, - "enabled": { - "type": "boolean", - "nullable": true, - "default": null, - "description": "Restricts responses to enabled rules. When absent (default), _all_ rules are retrieved." - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "searchRecommendRulesResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "hits", - "nbHits", - "page", - "nbPages" - ], - "properties": { - "hits": { - "type": "array", - "description": "Fetched rules.", - "items": { - "type": "object", - "description": "Rule object.", - "additionalProperties": false, - "properties": { - "_metadata": { - "type": "object", - "properties": { - "lastUpdate": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - }, - "objectID": { - "type": "string", - "description": "Unique identifier for a rule object.", - "example": "hide-12345" - }, - "conditions": { - "type": "array", - "description": "[Conditions](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#conditions) required to activate a rule. You can use up to 25 conditions per rule.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "pattern": { - "type": "string", - "description": "Query pattern syntax.", - "example": "{facet:brand}" - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "alternatives": { - "type": "boolean", - "description": "Whether the pattern matches on plurals, synonyms, and typos.", - "default": false - }, - "context": { - "type": "string", - "description": "Rule context format: [A-Za-z0-9_-]+).", - "example": "trackedFilters" - } - } - } - }, - "consequence": { - "type": "object", - "description": "[Consequences](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#consequences) of a rule.\n", - "additionalProperties": false, - "properties": { - "params": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "promote": { - "type": "array", - "description": "Records to promote.", - "items": { - "oneOf": [ - { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - } - ] - } - }, - "filterPromotes": { - "type": "boolean", - "default": false, - "description": "Only use in combination with the `promote` consequence. When `true`, promoted results will be restricted to match the filters of the current search. When `false`, the promoted results will show up regardless of the filters." - }, - "hide": { - "type": "array", - "description": "Records to hide. By default, you can hide up to 50 records per rule.", - "items": { - "title": "consequenceHide", - "type": "object", - "description": "Unique identifier of the record to hide.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - }, - "required": [ - "objectID" - ] - } - }, - "userData": { - "description": "Custom JSON object that will be appended to the userData array in the response. This object isn't interpreted by the API. It's limited to 1kB of minified JSON.", - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - } - } - } - }, - "description": { - "type": "string", - "description": "Description of the rule's purpose. This can be helpful for display in the Algolia dashboard.", - "example": "Display a promotional banner" - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Indicates whether to enable the rule. If it isn't enabled, it isn't applied at query time." - } - }, - "required": [ - "objectID" - ] - } - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - } - } -} \ No newline at end of file diff --git a/specs/bundled/search.json b/specs/bundled/search.json deleted file mode 100644 index 8013038256..0000000000 --- a/specs/bundled/search.json +++ /dev/null @@ -1,47665 +0,0 @@ -{ - "openapi": "3.0.2", - "info": { - "title": "Search API", - "description": "Use the Search REST API to manage your data (indices and records), implement search, and improve relevance (with Rules, synonyms, and language dictionaries).\n\nAlthough Algolia provides a REST API, you should use the official open source API [clients, libraries, and tools](https://www.algolia.com/doc/guides/getting-started/how-algolia-works/in-depth/ecosystem/) instead.\nThere's no [SLA](https://www.algolia.com/policies/sla/) if you use the REST API directly.", - "version": "1.0.0" - }, - "components": { - "securitySchemes": { - "appId": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-Application-Id" - }, - "apiKey": { - "type": "apiKey", - "in": "header", - "name": "X-Algolia-API-Key" - } - }, - "parameters": { - "PathInPath": { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - "Parameters": { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - }, - "IndexName": { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - "ObjectID": { - "name": "objectID", - "in": "path", - "description": "Unique record (object) identifier.", - "required": true, - "schema": { - "type": "string", - "example": "123" - } - }, - "ForwardToReplicas": { - "in": "query", - "name": "forwardToReplicas", - "description": "Indicates whether changed index settings are forwarded to the replica indices.", - "schema": { - "type": "boolean" - } - }, - "parameters_ObjectID": { - "name": "objectID", - "in": "path", - "description": "Unique identifier of a synonym object.", - "required": true, - "schema": { - "type": "string", - "example": "synonymID" - } - }, - "ReplaceExistingSynonyms": { - "in": "query", - "name": "replaceExistingSynonyms", - "schema": { - "type": "boolean" - }, - "description": "Indicates whether to replace all synonyms in the index with the ones sent with this request." - }, - "KeyString": { - "in": "path", - "name": "key", - "required": true, - "schema": { - "type": "string", - "example": "YourAPIKey" - }, - "description": "API key." - }, - "ObjectIDRule": { - "in": "path", - "name": "objectID", - "description": "Unique identifier of a rule object.", - "example": "a-rule-id", - "required": true, - "schema": { - "type": "string" - } - }, - "ClearExistingRules": { - "in": "query", - "name": "clearExistingRules", - "required": false, - "schema": { - "type": "boolean" - }, - "description": "Indicates whether existing rules should be deleted before adding this batch." - }, - "DictionaryName": { - "in": "path", - "name": "dictionaryName", - "description": "Dictionary to search in.", - "required": true, - "schema": { - "type": "string", - "enum": [ - "plurals", - "stopwords", - "compounds" - ] - } - }, - "Page": { - "in": "query", - "name": "page", - "description": "Returns the requested page number. The page size is determined by the `hitsPerPage` parameter. You can see the number of available pages in the `nbPages` response attribute. When `page` is null, the API response is not paginated.\n", - "schema": { - "type": "integer", - "minimum": 0, - "nullable": true, - "default": null - } - }, - "HitsPerPage": { - "in": "query", - "name": "hitsPerPage", - "description": "Maximum number of hits per page.", - "schema": { - "type": "integer", - "default": 100 - } - }, - "UserIDInHeader": { - "name": "X-Algolia-User-ID", - "description": "userID to assign.", - "in": "header", - "required": true, - "schema": { - "type": "string", - "pattern": "^[a-zA-Z0-9 \\-*.]+$" - } - }, - "UserIDInPath": { - "name": "userID", - "description": "userID to assign.", - "in": "path", - "required": true, - "schema": { - "type": "string", - "pattern": "^[a-zA-Z0-9 \\-*.]+$" - } - } - }, - "schemas": { - "ErrorBase": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - }, - "paramsAsString": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - }, - "searchParamsString": { - "type": "object", - "additionalProperties": false, - "x-discriminator-fields": [ - "params" - ], - "properties": { - "params": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - } - } - }, - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "searchParamsQuery": { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "searchFiltersArrayString": { - "type": "array", - "items": { - "type": "string" - } - }, - "mixedSearchFilters": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - }, - "listOfSearchFilters": { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadiusAll": { - "type": "string", - "enum": [ - "all" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecisionFromValue": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "baseSearchParamsWithoutQuery": { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - "baseSearchParams": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "typoToleranceEnum": { - "type": "string", - "enum": [ - "min", - "strict" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - }, - "value": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - }, - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - }, - "indexSettingsAsSearchParams": { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - "searchParamsObject": { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - "searchParams": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "x-discriminator-fields": [ - "params" - ], - "properties": { - "params": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - } - } - }, - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - ] - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "RedirectRuleIndexMetadata": { - "type": "object", - "properties": { - "source": { - "type": "string", - "description": "Source index for the redirect rule." - }, - "dest": { - "type": "string", - "description": "Destination index for the redirect rule." - }, - "reason": { - "type": "string", - "description": "Reason for the redirect rule." - }, - "succeed": { - "type": "boolean", - "description": "Redirect rule status." - }, - "data": { - "type": "object", - "description": "Redirect rule data.", - "required": [ - "ruleObjectID" - ], - "properties": { - "ruleObjectID": { - "type": "string" - } - } - } - }, - "required": [ - "data", - "succeed", - "reason", - "dest", - "source" - ] - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - }, - "baseSearchResponse": { - "type": "object", - "additionalProperties": true, - "required": [ - "nbHits", - "page", - "nbPages", - "hitsPerPage", - "processingTimeMS" - ], - "properties": { - "abTestID": { - "type": "integer", - "description": "A/B test ID. This is only included in the response for indices that are part of an A/B test." - }, - "abTestVariantID": { - "type": "integer", - "minimum": 1, - "description": "Variant ID. This is only included in the response for indices that are part of an A/B test." - }, - "aroundLatLng": { - "type": "string", - "description": "Computed geographical location.", - "example": "40.71,-74.01", - "pattern": "^(-?\\d+(\\.\\d+)?),\\s*(-?\\d+(\\.\\d+)?)$" - }, - "automaticRadius": { - "type": "string", - "description": "Automatically-computed radius." - }, - "exhaustive": { - "type": "object", - "title": "exhaustive", - "description": "Whether certain properties of the search response are calculated exhaustive (exact) or approximated.", - "properties": { - "facetsCount": { - "type": "boolean", - "title": "facetsCount", - "description": "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-)." - }, - "facetValues": { - "type": "boolean", - "title": "facetValues", - "description": "The value is `false` if not all facet values are retrieved." - }, - "nbHits": { - "type": "boolean", - "title": "nbHits", - "description": "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." - }, - "rulesMatch": { - "type": "boolean", - "title": "rulesMatch", - "description": "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." - }, - "typo": { - "type": "boolean", - "title": "typo", - "description": "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." - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveNbHits": { - "type": "boolean", - "description": "See the `nbHits` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveTypo": { - "type": "boolean", - "description": "See the `typo` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "facets": { - "title": "facets", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "integer" - } - }, - "description": "Mapping of each facet name to the corresponding facet counts.", - "example": { - "category": { - "food": 1, - "tech": 42 - } - } - }, - "facets_stats": { - "title": "facetsStats", - "type": "object", - "description": "Statistics for numerical facets.", - "additionalProperties": { - "type": "object", - "title": "facetStats", - "properties": { - "min": { - "type": "number", - "format": "double", - "description": "Minimum value in the results." - }, - "max": { - "type": "number", - "format": "double", - "description": "Maximum value in the results." - }, - "avg": { - "type": "number", - "format": "double", - "description": "Average facet value in the results." - }, - "sum": { - "type": "number", - "format": "double", - "description": "Sum of all values in the results." - } - } - } - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "index": { - "type": "string", - "example": "indexName", - "description": "Index name used for the query." - }, - "indexUsed": { - "type": "string", - "description": "Index name used for the query. During A/B testing, the targeted index isn't always the index used by the query.", - "example": "indexNameAlt" - }, - "message": { - "type": "string", - "description": "Warnings about the query." - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - }, - "nbSortedHits": { - "type": "integer", - "description": "Number of hits selected and sorted by the relevant sort algorithm.", - "example": 20 - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "parsedQuery": { - "type": "string", - "description": "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.", - "example": "george clo" - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "processingTimingsMS": { - "type": "object", - "description": "Experimental. List of processing steps and their times, in milliseconds. You can use this list to investigate performance issues." - }, - "queryAfterRemoval": { - "type": "string", - "description": "Markup text indicating which parts of the original query have been removed to retrieve a non-empty result set." - }, - "redirect": { - "title": "redirect", - "type": "object", - "description": "[Redirect results to a URL](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/redirects/).\n", - "properties": { - "index": { - "type": "array", - "items": { - "type": "object", - "properties": { - "source": { - "type": "string", - "description": "Source index for the redirect rule." - }, - "dest": { - "type": "string", - "description": "Destination index for the redirect rule." - }, - "reason": { - "type": "string", - "description": "Reason for the redirect rule." - }, - "succeed": { - "type": "boolean", - "description": "Redirect rule status." - }, - "data": { - "type": "object", - "description": "Redirect rule data.", - "required": [ - "ruleObjectID" - ], - "properties": { - "ruleObjectID": { - "type": "string" - } - } - } - }, - "required": [ - "data", - "succeed", - "reason", - "dest", - "source" - ] - } - } - } - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "serverTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "serverUsed": { - "type": "string", - "description": "Host name of the server that processed the request.", - "example": "c2-uk-3.algolia.net" - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - } - } - }, - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "highlightedValue": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "highlightResultOption": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - "highlightResultOptionMap": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - "highlightResultOptionArray": { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - "highlightResult": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - }, - "highlightResultMap": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "snippetResultOption": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - "snippetResultOptionMap": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - "snippetResultOptionArray": { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - "snippetResult": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - }, - "snippetResultMap": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - }, - "hit": { - "type": "object", - "description": "A single hit.", - "x-is-generic": true, - "additionalProperties": true, - "required": [ - "objectID" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - } - } - }, - "searchHits": { - "type": "object", - "additionalProperties": true, - "properties": { - "hits": { - "type": "array", - "items": { - "type": "object", - "description": "A single hit.", - "x-is-generic": true, - "additionalProperties": true, - "required": [ - "objectID" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - } - } - } - }, - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "params": { - "type": "string", - "description": "URL-encoded string of all search parameters.", - "example": "query=a&hitsPerPage=20" - } - }, - "required": [ - "hits", - "query", - "params" - ] - }, - "searchResponse": { - "additionalProperties": true, - "allOf": [ - { - "type": "object", - "additionalProperties": true, - "required": [ - "nbHits", - "page", - "nbPages", - "hitsPerPage", - "processingTimeMS" - ], - "properties": { - "abTestID": { - "type": "integer", - "description": "A/B test ID. This is only included in the response for indices that are part of an A/B test." - }, - "abTestVariantID": { - "type": "integer", - "minimum": 1, - "description": "Variant ID. This is only included in the response for indices that are part of an A/B test." - }, - "aroundLatLng": { - "type": "string", - "description": "Computed geographical location.", - "example": "40.71,-74.01", - "pattern": "^(-?\\d+(\\.\\d+)?),\\s*(-?\\d+(\\.\\d+)?)$" - }, - "automaticRadius": { - "type": "string", - "description": "Automatically-computed radius." - }, - "exhaustive": { - "type": "object", - "title": "exhaustive", - "description": "Whether certain properties of the search response are calculated exhaustive (exact) or approximated.", - "properties": { - "facetsCount": { - "type": "boolean", - "title": "facetsCount", - "description": "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-)." - }, - "facetValues": { - "type": "boolean", - "title": "facetValues", - "description": "The value is `false` if not all facet values are retrieved." - }, - "nbHits": { - "type": "boolean", - "title": "nbHits", - "description": "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." - }, - "rulesMatch": { - "type": "boolean", - "title": "rulesMatch", - "description": "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." - }, - "typo": { - "type": "boolean", - "title": "typo", - "description": "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." - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveNbHits": { - "type": "boolean", - "description": "See the `nbHits` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveTypo": { - "type": "boolean", - "description": "See the `typo` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "facets": { - "title": "facets", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "integer" - } - }, - "description": "Mapping of each facet name to the corresponding facet counts.", - "example": { - "category": { - "food": 1, - "tech": 42 - } - } - }, - "facets_stats": { - "title": "facetsStats", - "type": "object", - "description": "Statistics for numerical facets.", - "additionalProperties": { - "type": "object", - "title": "facetStats", - "properties": { - "min": { - "type": "number", - "format": "double", - "description": "Minimum value in the results." - }, - "max": { - "type": "number", - "format": "double", - "description": "Maximum value in the results." - }, - "avg": { - "type": "number", - "format": "double", - "description": "Average facet value in the results." - }, - "sum": { - "type": "number", - "format": "double", - "description": "Sum of all values in the results." - } - } - } - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "index": { - "type": "string", - "example": "indexName", - "description": "Index name used for the query." - }, - "indexUsed": { - "type": "string", - "description": "Index name used for the query. During A/B testing, the targeted index isn't always the index used by the query.", - "example": "indexNameAlt" - }, - "message": { - "type": "string", - "description": "Warnings about the query." - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - }, - "nbSortedHits": { - "type": "integer", - "description": "Number of hits selected and sorted by the relevant sort algorithm.", - "example": 20 - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "parsedQuery": { - "type": "string", - "description": "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.", - "example": "george clo" - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "processingTimingsMS": { - "type": "object", - "description": "Experimental. List of processing steps and their times, in milliseconds. You can use this list to investigate performance issues." - }, - "queryAfterRemoval": { - "type": "string", - "description": "Markup text indicating which parts of the original query have been removed to retrieve a non-empty result set." - }, - "redirect": { - "title": "redirect", - "type": "object", - "description": "[Redirect results to a URL](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/redirects/).\n", - "properties": { - "index": { - "type": "array", - "items": { - "type": "object", - "properties": { - "source": { - "type": "string", - "description": "Source index for the redirect rule." - }, - "dest": { - "type": "string", - "description": "Destination index for the redirect rule." - }, - "reason": { - "type": "string", - "description": "Reason for the redirect rule." - }, - "succeed": { - "type": "boolean", - "description": "Redirect rule status." - }, - "data": { - "type": "object", - "description": "Redirect rule data.", - "required": [ - "ruleObjectID" - ], - "properties": { - "ruleObjectID": { - "type": "string" - } - } - } - }, - "required": [ - "data", - "succeed", - "reason", - "dest", - "source" - ] - } - } - } - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "serverTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "serverUsed": { - "type": "string", - "description": "Host name of the server that processed the request.", - "example": "c2-uk-3.algolia.net" - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": true, - "properties": { - "hits": { - "type": "array", - "items": { - "type": "object", - "description": "A single hit.", - "x-is-generic": true, - "additionalProperties": true, - "required": [ - "objectID" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - } - } - } - }, - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "params": { - "type": "string", - "description": "URL-encoded string of all search parameters.", - "example": "query=a&hitsPerPage=20" - } - }, - "required": [ - "hits", - "query", - "params" - ] - } - ] - }, - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "searchTypeDefault": { - "type": "string", - "enum": [ - "default" - ], - "default": "default", - "description": "- `default`: perform a search query - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).\n" - }, - "searchForHitsOptions": { - "x-is-SearchForHitsOptions": true, - "type": "object", - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "type": { - "type": "string", - "enum": [ - "default" - ], - "default": "default", - "description": "- `default`: perform a search query - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).\n" - } - }, - "required": [ - "indexName" - ] - }, - "SearchForHits": { - "allOf": [ - { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "x-discriminator-fields": [ - "params" - ], - "properties": { - "params": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - } - } - }, - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - ] - }, - { - "x-is-SearchForHitsOptions": true, - "type": "object", - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "type": { - "type": "string", - "enum": [ - "default" - ], - "default": "default", - "description": "- `default`: perform a search query - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).\n" - } - }, - "required": [ - "indexName" - ] - } - ] - }, - "facetQuery": { - "type": "string", - "description": "Text to search inside the facet's values.", - "example": "george", - "default": "" - }, - "searchTypeFacet": { - "type": "string", - "enum": [ - "facet" - ], - "default": "facet", - "description": "- `default`: perform a search query - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).\n" - }, - "searchForFacetsOptions": { - "type": "object", - "properties": { - "facet": { - "type": "string", - "description": "Facet name." - }, - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "facetQuery": { - "type": "string", - "description": "Text to search inside the facet's values.", - "example": "george", - "default": "" - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "type": { - "type": "string", - "enum": [ - "facet" - ], - "default": "facet", - "description": "- `default`: perform a search query - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).\n" - } - }, - "required": [ - "indexName", - "type", - "facet" - ] - }, - "SearchForFacets": { - "allOf": [ - { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "x-discriminator-fields": [ - "params" - ], - "properties": { - "params": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - } - } - }, - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - ] - }, - { - "type": "object", - "properties": { - "facet": { - "type": "string", - "description": "Facet name." - }, - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "facetQuery": { - "type": "string", - "description": "Text to search inside the facet's values.", - "example": "george", - "default": "" - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "type": { - "type": "string", - "enum": [ - "facet" - ], - "default": "facet", - "description": "- `default`: perform a search query - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).\n" - } - }, - "required": [ - "indexName", - "type", - "facet" - ] - } - ], - "x-discriminator-fields": [ - "facet", - "type" - ] - }, - "SearchQuery": { - "oneOf": [ - { - "allOf": [ - { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "x-discriminator-fields": [ - "params" - ], - "properties": { - "params": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - } - } - }, - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - ] - }, - { - "x-is-SearchForHitsOptions": true, - "type": "object", - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "type": { - "type": "string", - "enum": [ - "default" - ], - "default": "default", - "description": "- `default`: perform a search query - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).\n" - } - }, - "required": [ - "indexName" - ] - } - ] - }, - { - "allOf": [ - { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "x-discriminator-fields": [ - "params" - ], - "properties": { - "params": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - } - } - }, - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - ] - }, - { - "type": "object", - "properties": { - "facet": { - "type": "string", - "description": "Facet name." - }, - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "facetQuery": { - "type": "string", - "description": "Text to search inside the facet's values.", - "example": "george", - "default": "" - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "type": { - "type": "string", - "enum": [ - "facet" - ], - "default": "facet", - "description": "- `default`: perform a search query - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).\n" - } - }, - "required": [ - "indexName", - "type", - "facet" - ] - } - ], - "x-discriminator-fields": [ - "facet", - "type" - ] - } - ] - }, - "searchStrategy": { - "type": "string", - "enum": [ - "none", - "stopIfEnoughMatches" - ], - "description": "- `none`: executes all queries. - `stopIfEnoughMatches`: executes queries one by one, stopping further query execution as soon as a query matches at least the `hitsPerPage` number of results. \n" - }, - "searchForFacetValuesResponse": { - "type": "object", - "additionalProperties": false, - "required": [ - "facetHits", - "exhaustiveFacetsCount" - ], - "x-discriminator-fields": [ - "facetHits" - ], - "properties": { - "facetHits": { - "type": "array", - "items": { - "type": "object", - "title": "facetHits", - "additionalProperties": false, - "required": [ - "value", - "highlighted", - "count" - ], - "properties": { - "value": { - "description": "Facet value.", - "example": "Mobile phone", - "type": "string" - }, - "highlighted": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "count": { - "description": "Number of records containing this facet value. This takes into account the extra search parameters specified in the query. Like for a regular search query, the [counts may not be exhaustive](https://support.algolia.com/hc/en-us/articles/4406975248145-Why-are-my-facet-and-hit-counts-not-accurate-).", - "type": "integer" - } - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - } - } - }, - "searchResult": { - "oneOf": [ - { - "additionalProperties": true, - "allOf": [ - { - "type": "object", - "additionalProperties": true, - "required": [ - "nbHits", - "page", - "nbPages", - "hitsPerPage", - "processingTimeMS" - ], - "properties": { - "abTestID": { - "type": "integer", - "description": "A/B test ID. This is only included in the response for indices that are part of an A/B test." - }, - "abTestVariantID": { - "type": "integer", - "minimum": 1, - "description": "Variant ID. This is only included in the response for indices that are part of an A/B test." - }, - "aroundLatLng": { - "type": "string", - "description": "Computed geographical location.", - "example": "40.71,-74.01", - "pattern": "^(-?\\d+(\\.\\d+)?),\\s*(-?\\d+(\\.\\d+)?)$" - }, - "automaticRadius": { - "type": "string", - "description": "Automatically-computed radius." - }, - "exhaustive": { - "type": "object", - "title": "exhaustive", - "description": "Whether certain properties of the search response are calculated exhaustive (exact) or approximated.", - "properties": { - "facetsCount": { - "type": "boolean", - "title": "facetsCount", - "description": "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-)." - }, - "facetValues": { - "type": "boolean", - "title": "facetValues", - "description": "The value is `false` if not all facet values are retrieved." - }, - "nbHits": { - "type": "boolean", - "title": "nbHits", - "description": "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." - }, - "rulesMatch": { - "type": "boolean", - "title": "rulesMatch", - "description": "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." - }, - "typo": { - "type": "boolean", - "title": "typo", - "description": "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." - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveNbHits": { - "type": "boolean", - "description": "See the `nbHits` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveTypo": { - "type": "boolean", - "description": "See the `typo` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "facets": { - "title": "facets", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "integer" - } - }, - "description": "Mapping of each facet name to the corresponding facet counts.", - "example": { - "category": { - "food": 1, - "tech": 42 - } - } - }, - "facets_stats": { - "title": "facetsStats", - "type": "object", - "description": "Statistics for numerical facets.", - "additionalProperties": { - "type": "object", - "title": "facetStats", - "properties": { - "min": { - "type": "number", - "format": "double", - "description": "Minimum value in the results." - }, - "max": { - "type": "number", - "format": "double", - "description": "Maximum value in the results." - }, - "avg": { - "type": "number", - "format": "double", - "description": "Average facet value in the results." - }, - "sum": { - "type": "number", - "format": "double", - "description": "Sum of all values in the results." - } - } - } - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "index": { - "type": "string", - "example": "indexName", - "description": "Index name used for the query." - }, - "indexUsed": { - "type": "string", - "description": "Index name used for the query. During A/B testing, the targeted index isn't always the index used by the query.", - "example": "indexNameAlt" - }, - "message": { - "type": "string", - "description": "Warnings about the query." - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - }, - "nbSortedHits": { - "type": "integer", - "description": "Number of hits selected and sorted by the relevant sort algorithm.", - "example": 20 - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "parsedQuery": { - "type": "string", - "description": "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.", - "example": "george clo" - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "processingTimingsMS": { - "type": "object", - "description": "Experimental. List of processing steps and their times, in milliseconds. You can use this list to investigate performance issues." - }, - "queryAfterRemoval": { - "type": "string", - "description": "Markup text indicating which parts of the original query have been removed to retrieve a non-empty result set." - }, - "redirect": { - "title": "redirect", - "type": "object", - "description": "[Redirect results to a URL](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/redirects/).\n", - "properties": { - "index": { - "type": "array", - "items": { - "type": "object", - "properties": { - "source": { - "type": "string", - "description": "Source index for the redirect rule." - }, - "dest": { - "type": "string", - "description": "Destination index for the redirect rule." - }, - "reason": { - "type": "string", - "description": "Reason for the redirect rule." - }, - "succeed": { - "type": "boolean", - "description": "Redirect rule status." - }, - "data": { - "type": "object", - "description": "Redirect rule data.", - "required": [ - "ruleObjectID" - ], - "properties": { - "ruleObjectID": { - "type": "string" - } - } - } - }, - "required": [ - "data", - "succeed", - "reason", - "dest", - "source" - ] - } - } - } - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "serverTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "serverUsed": { - "type": "string", - "description": "Host name of the server that processed the request.", - "example": "c2-uk-3.algolia.net" - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": true, - "properties": { - "hits": { - "type": "array", - "items": { - "type": "object", - "description": "A single hit.", - "x-is-generic": true, - "additionalProperties": true, - "required": [ - "objectID" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - } - } - } - }, - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "params": { - "type": "string", - "description": "URL-encoded string of all search parameters.", - "example": "query=a&hitsPerPage=20" - } - }, - "required": [ - "hits", - "query", - "params" - ] - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "required": [ - "facetHits", - "exhaustiveFacetsCount" - ], - "x-discriminator-fields": [ - "facetHits" - ], - "properties": { - "facetHits": { - "type": "array", - "items": { - "type": "object", - "title": "facetHits", - "additionalProperties": false, - "required": [ - "value", - "highlighted", - "count" - ], - "properties": { - "value": { - "description": "Facet value.", - "example": "Mobile phone", - "type": "string" - }, - "highlighted": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "count": { - "description": "Number of records containing this facet value. This takes into account the extra search parameters specified in the query. Like for a regular search query, the [counts may not be exhaustive](https://support.algolia.com/hc/en-us/articles/4406975248145-Why-are-my-facet-and-hit-counts-not-accurate-).", - "type": "integer" - } - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - } - } - } - ] - }, - "cursor": { - "type": "object", - "additionalProperties": false, - "properties": { - "cursor": { - "type": "string", - "description": "Cursor indicating the location to resume browsing from. Must match the value returned by the previous call.\nPass this value to the subsequent browse call to get the next page of results.\nWhen the end of the index has been reached, `cursor` is absent from the response.\n", - "example": "jMDY3M2MwM2QwMWUxMmQwYWI0ZTN" - } - } - }, - "browseParamsObject": { - "allOf": [ - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "cursor": { - "type": "string", - "description": "Cursor indicating the location to resume browsing from. Must match the value returned by the previous call.\nPass this value to the subsequent browse call to get the next page of results.\nWhen the end of the index has been reached, `cursor` is absent from the response.\n", - "example": "jMDY3M2MwM2QwMWUxMmQwYWI0ZTN" - } - } - } - ] - }, - "browseParams": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "x-discriminator-fields": [ - "params" - ], - "properties": { - "params": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - } - } - }, - { - "allOf": [ - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "cursor": { - "type": "string", - "description": "Cursor indicating the location to resume browsing from. Must match the value returned by the previous call.\nPass this value to the subsequent browse call to get the next page of results.\nWhen the end of the index has been reached, `cursor` is absent from the response.\n", - "example": "jMDY3M2MwM2QwMWUxMmQwYWI0ZTN" - } - } - } - ] - } - ] - }, - "browseResponse": { - "allOf": [ - { - "type": "object", - "additionalProperties": true, - "required": [ - "nbHits", - "page", - "nbPages", - "hitsPerPage", - "processingTimeMS" - ], - "properties": { - "abTestID": { - "type": "integer", - "description": "A/B test ID. This is only included in the response for indices that are part of an A/B test." - }, - "abTestVariantID": { - "type": "integer", - "minimum": 1, - "description": "Variant ID. This is only included in the response for indices that are part of an A/B test." - }, - "aroundLatLng": { - "type": "string", - "description": "Computed geographical location.", - "example": "40.71,-74.01", - "pattern": "^(-?\\d+(\\.\\d+)?),\\s*(-?\\d+(\\.\\d+)?)$" - }, - "automaticRadius": { - "type": "string", - "description": "Automatically-computed radius." - }, - "exhaustive": { - "type": "object", - "title": "exhaustive", - "description": "Whether certain properties of the search response are calculated exhaustive (exact) or approximated.", - "properties": { - "facetsCount": { - "type": "boolean", - "title": "facetsCount", - "description": "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-)." - }, - "facetValues": { - "type": "boolean", - "title": "facetValues", - "description": "The value is `false` if not all facet values are retrieved." - }, - "nbHits": { - "type": "boolean", - "title": "nbHits", - "description": "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." - }, - "rulesMatch": { - "type": "boolean", - "title": "rulesMatch", - "description": "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." - }, - "typo": { - "type": "boolean", - "title": "typo", - "description": "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." - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveNbHits": { - "type": "boolean", - "description": "See the `nbHits` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveTypo": { - "type": "boolean", - "description": "See the `typo` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "facets": { - "title": "facets", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "integer" - } - }, - "description": "Mapping of each facet name to the corresponding facet counts.", - "example": { - "category": { - "food": 1, - "tech": 42 - } - } - }, - "facets_stats": { - "title": "facetsStats", - "type": "object", - "description": "Statistics for numerical facets.", - "additionalProperties": { - "type": "object", - "title": "facetStats", - "properties": { - "min": { - "type": "number", - "format": "double", - "description": "Minimum value in the results." - }, - "max": { - "type": "number", - "format": "double", - "description": "Maximum value in the results." - }, - "avg": { - "type": "number", - "format": "double", - "description": "Average facet value in the results." - }, - "sum": { - "type": "number", - "format": "double", - "description": "Sum of all values in the results." - } - } - } - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "index": { - "type": "string", - "example": "indexName", - "description": "Index name used for the query." - }, - "indexUsed": { - "type": "string", - "description": "Index name used for the query. During A/B testing, the targeted index isn't always the index used by the query.", - "example": "indexNameAlt" - }, - "message": { - "type": "string", - "description": "Warnings about the query." - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - }, - "nbSortedHits": { - "type": "integer", - "description": "Number of hits selected and sorted by the relevant sort algorithm.", - "example": 20 - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "parsedQuery": { - "type": "string", - "description": "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.", - "example": "george clo" - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "processingTimingsMS": { - "type": "object", - "description": "Experimental. List of processing steps and their times, in milliseconds. You can use this list to investigate performance issues." - }, - "queryAfterRemoval": { - "type": "string", - "description": "Markup text indicating which parts of the original query have been removed to retrieve a non-empty result set." - }, - "redirect": { - "title": "redirect", - "type": "object", - "description": "[Redirect results to a URL](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/redirects/).\n", - "properties": { - "index": { - "type": "array", - "items": { - "type": "object", - "properties": { - "source": { - "type": "string", - "description": "Source index for the redirect rule." - }, - "dest": { - "type": "string", - "description": "Destination index for the redirect rule." - }, - "reason": { - "type": "string", - "description": "Reason for the redirect rule." - }, - "succeed": { - "type": "boolean", - "description": "Redirect rule status." - }, - "data": { - "type": "object", - "description": "Redirect rule data.", - "required": [ - "ruleObjectID" - ], - "properties": { - "ruleObjectID": { - "type": "string" - } - } - } - }, - "required": [ - "data", - "succeed", - "reason", - "dest", - "source" - ] - } - } - } - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "serverTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "serverUsed": { - "type": "string", - "description": "Host name of the server that processed the request.", - "example": "c2-uk-3.algolia.net" - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": true, - "properties": { - "hits": { - "type": "array", - "items": { - "type": "object", - "description": "A single hit.", - "x-is-generic": true, - "additionalProperties": true, - "required": [ - "objectID" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - } - } - } - }, - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "params": { - "type": "string", - "description": "URL-encoded string of all search parameters.", - "example": "query=a&hitsPerPage=20" - } - }, - "required": [ - "hits", - "query", - "params" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "cursor": { - "type": "string", - "description": "Cursor indicating the location to resume browsing from. Must match the value returned by the previous call.\nPass this value to the subsequent browse call to get the next page of results.\nWhen the end of the index has been reached, `cursor` is absent from the response.\n", - "example": "jMDY3M2MwM2QwMWUxMmQwYWI0ZTN" - } - } - } - ] - }, - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "deletedAt": { - "type": "string", - "example": "2023-06-27T14:42:38.831Z", - "description": "Timestamp of deletion in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "attribute": { - "type": "string", - "description": "Value of the attribute to be updated." - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "deleteByParams": { - "type": "object", - "additionalProperties": false, - "properties": { - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - } - } - }, - "builtInOperationType": { - "type": "string", - "enum": [ - "Increment", - "Decrement", - "Add", - "Remove", - "AddUnique", - "IncrementFrom", - "IncrementSet" - ], - "description": "Operation to apply to the attribute." - }, - "builtInOperation": { - "type": "object", - "description": "To update an attribute without pushing the entire record, you can use these built-in operations.", - "additionalProperties": false, - "properties": { - "_operation": { - "type": "string", - "enum": [ - "Increment", - "Decrement", - "Add", - "Remove", - "AddUnique", - "IncrementFrom", - "IncrementSet" - ], - "description": "Operation to apply to the attribute." - }, - "value": { - "type": "string", - "description": "Value that corresponds to the operation, for example an `Increment` or `Decrement` step, `Add` or `Remove` value." - } - }, - "required": [ - "_operation", - "value" - ] - }, - "attributeToUpdate": { - "oneOf": [ - { - "type": "string", - "description": "Value of the attribute to be updated." - }, - { - "type": "object", - "description": "To update an attribute without pushing the entire record, you can use these built-in operations.", - "additionalProperties": false, - "properties": { - "_operation": { - "type": "string", - "enum": [ - "Increment", - "Decrement", - "Add", - "Remove", - "AddUnique", - "IncrementFrom", - "IncrementSet" - ], - "description": "Operation to apply to the attribute." - }, - "value": { - "type": "string", - "description": "Value that corresponds to the operation, for example an `Increment` or `Decrement` step, `Add` or `Remove` value." - } - }, - "required": [ - "_operation", - "value" - ] - } - ] - }, - "action": { - "type": "string", - "enum": [ - "addObject", - "updateObject", - "partialUpdateObject", - "partialUpdateObjectNoCreate", - "deleteObject", - "delete", - "clear" - ], - "description": "Type of batch operation." - }, - "objectIDs": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "record-1", - "record-2" - ], - "description": "Unique object (record) identifiers." - }, - "baseIndexSettings": { - "type": "object", - "additionalProperties": false, - "properties": { - "replicas": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "virtual(prod_products_price_asc)", - "dev_products_replica" - ], - "description": "Creates [replicas](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/in-depth/replicas/), which are copies of a primary index with the same records but different settings.", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "paginationLimitedTo": { - "type": "integer", - "example": 20, - "description": "Maximum number of hits accessible through pagination.", - "default": 1000 - }, - "unretrievableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "popularity" - ], - "description": "Attributes that can't be retrieved at query time.", - "default": [], - "x-categories": [ - "Attributes" - ] - }, - "disableTypoToleranceOnWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "wheel", - "1X2BCD" - ], - "description": "Words for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "attributesToTransliterate": { - "description": "Attributes in your index to which [Japanese transliteration](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#japanese-transliteration-and-type-ahead) applies. This will ensure that words indexed in Katakana or Kanji can also be searched in Hiragana.", - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "name", - "description" - ], - "x-categories": [ - "Languages" - ] - }, - "camelCaseAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "Attributes on which to split [camel case](https://wikipedia.org/wiki/Camel_case) words.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundedAttributes": { - "type": "object", - "example": { - "de": [ - "name" - ] - }, - "description": "Attributes in your index to which [word segmentation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-segmentation/) (decompounding) applies.", - "default": {}, - "x-categories": [ - "Languages" - ] - }, - "indexLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "ja" - ], - "description": "Set the languages of your index, for language-specific processing steps such as [tokenization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/tokenization/) and [normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "disablePrefixOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [prefix matching](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#adjusting-prefix-search).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "allowCompressionOfIntegerArray": { - "type": "boolean", - "description": "Incidates whether the engine compresses arrays with exclusively non-negative integers.\nWhen enabled, the compressed arrays may be reordered.\n", - "default": false, - "x-categories": [ - "Performance" - ] - }, - "numericAttributesForFiltering": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Numeric attributes that can be used as [numerical filters](https://www.algolia.com/doc/guides/managing-results/rules/detecting-intent/how-to/applying-a-custom-filter-for-a-specific-query/#numerical-filters).", - "example": [ - "quantity", - "popularity" - ], - "default": [], - "x-categories": [ - "Performance" - ] - }, - "separatorsToIndex": { - "type": "string", - "example": "+#", - "description": "Controls which separators are added to an Algolia index as part of [normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/#what-does-normalization-mean). Separators are all non-letter characters except spaces and currency characters, such as $€£¥.", - "default": "", - "x-categories": [ - "Typos" - ] - }, - "searchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title,alternative_title", - "author", - "unordered(text)", - "emails.personal" - ], - "description": "[Attributes used for searching](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/), including determining [if matches at the beginning of a word are important (ordered) or not (unordered)](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/how-to/configuring-searchable-attributes-the-right-way/#understanding-word-position).\n", - "default": [], - "x-categories": [ - "Attributes" - ] - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - }, - "customNormalization": { - "description": "A list of characters and their normalized replacements to override Algolia's default [normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "type": "object", - "example": "{default: {'ä': 'ae', 'ü': 'ue'}}\n", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "x-categories": [ - "Languages" - ] - }, - "attributeForDistinct": { - "description": "Name of the deduplication attribute to be used with Algolia's [_distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature).", - "example": "url", - "type": "string" - } - } - }, - "indexSettings": { - "description": "Algolia index settings.", - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "replicas": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "virtual(prod_products_price_asc)", - "dev_products_replica" - ], - "description": "Creates [replicas](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/in-depth/replicas/), which are copies of a primary index with the same records but different settings.", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "paginationLimitedTo": { - "type": "integer", - "example": 20, - "description": "Maximum number of hits accessible through pagination.", - "default": 1000 - }, - "unretrievableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "popularity" - ], - "description": "Attributes that can't be retrieved at query time.", - "default": [], - "x-categories": [ - "Attributes" - ] - }, - "disableTypoToleranceOnWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "wheel", - "1X2BCD" - ], - "description": "Words for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "attributesToTransliterate": { - "description": "Attributes in your index to which [Japanese transliteration](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#japanese-transliteration-and-type-ahead) applies. This will ensure that words indexed in Katakana or Kanji can also be searched in Hiragana.", - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "name", - "description" - ], - "x-categories": [ - "Languages" - ] - }, - "camelCaseAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "Attributes on which to split [camel case](https://wikipedia.org/wiki/Camel_case) words.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundedAttributes": { - "type": "object", - "example": { - "de": [ - "name" - ] - }, - "description": "Attributes in your index to which [word segmentation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-segmentation/) (decompounding) applies.", - "default": {}, - "x-categories": [ - "Languages" - ] - }, - "indexLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "ja" - ], - "description": "Set the languages of your index, for language-specific processing steps such as [tokenization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/tokenization/) and [normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "disablePrefixOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [prefix matching](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#adjusting-prefix-search).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "allowCompressionOfIntegerArray": { - "type": "boolean", - "description": "Incidates whether the engine compresses arrays with exclusively non-negative integers.\nWhen enabled, the compressed arrays may be reordered.\n", - "default": false, - "x-categories": [ - "Performance" - ] - }, - "numericAttributesForFiltering": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Numeric attributes that can be used as [numerical filters](https://www.algolia.com/doc/guides/managing-results/rules/detecting-intent/how-to/applying-a-custom-filter-for-a-specific-query/#numerical-filters).", - "example": [ - "quantity", - "popularity" - ], - "default": [], - "x-categories": [ - "Performance" - ] - }, - "separatorsToIndex": { - "type": "string", - "example": "+#", - "description": "Controls which separators are added to an Algolia index as part of [normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/#what-does-normalization-mean). Separators are all non-letter characters except spaces and currency characters, such as $€£¥.", - "default": "", - "x-categories": [ - "Typos" - ] - }, - "searchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title,alternative_title", - "author", - "unordered(text)", - "emails.personal" - ], - "description": "[Attributes used for searching](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/), including determining [if matches at the beginning of a word are important (ordered) or not (unordered)](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/how-to/configuring-searchable-attributes-the-right-way/#understanding-word-position).\n", - "default": [], - "x-categories": [ - "Attributes" - ] - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - }, - "customNormalization": { - "description": "A list of characters and their normalized replacements to override Algolia's default [normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "type": "object", - "example": "{default: {'ä': 'ae', 'ü': 'ue'}}\n", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "x-categories": [ - "Languages" - ] - }, - "attributeForDistinct": { - "description": "Name of the deduplication attribute to be used with Algolia's [_distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature).", - "example": "url", - "type": "string" - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - "SynonymType": { - "type": "string", - "description": "Synonym type.", - "example": "onewaysynonym", - "enum": [ - "synonym", - "onewaysynonym", - "altcorrection1", - "altcorrection2", - "placeholder" - ] - }, - "synonymHit": { - "type": "object", - "description": "Synonym object.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier of a synonym object.", - "example": "synonymID" - }, - "type": { - "type": "string", - "description": "Synonym type.", - "example": "onewaysynonym", - "enum": [ - "synonym", - "onewaysynonym", - "altcorrection1", - "altcorrection2", - "placeholder" - ] - }, - "synonyms": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words or phrases considered equivalent.", - "example": [ - "vehicle", - "auto" - ] - }, - "input": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`onewaysynonym`s](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/one-way-synonyms/)).", - "example": "car" - }, - "word": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`altcorrection1` and `altcorrection2`](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-alternative-corrections/)).", - "example": "car" - }, - "corrections": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words to be matched in records.", - "example": [ - "vehicle", - "auto" - ] - }, - "placeholder": { - "type": "string", - "description": "[Placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/) to be put inside records.\n", - "example": "" - }, - "replacements": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Query words that will match the [placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/).", - "example": [ - "street", - "st" - ] - } - }, - "required": [ - "objectID", - "type" - ] - }, - "id": { - "type": "string", - "example": "12", - "description": "Unique identifier of a synonym object." - }, - "synonymHits": { - "type": "array", - "description": "Synonym objects.", - "items": { - "type": "object", - "description": "Synonym object.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier of a synonym object.", - "example": "synonymID" - }, - "type": { - "type": "string", - "description": "Synonym type.", - "example": "onewaysynonym", - "enum": [ - "synonym", - "onewaysynonym", - "altcorrection1", - "altcorrection2", - "placeholder" - ] - }, - "synonyms": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words or phrases considered equivalent.", - "example": [ - "vehicle", - "auto" - ] - }, - "input": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`onewaysynonym`s](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/one-way-synonyms/)).", - "example": "car" - }, - "word": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`altcorrection1` and `altcorrection2`](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-alternative-corrections/)).", - "example": "car" - }, - "corrections": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words to be matched in records.", - "example": [ - "vehicle", - "auto" - ] - }, - "placeholder": { - "type": "string", - "description": "[Placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/) to be put inside records.\n", - "example": "" - }, - "replacements": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Query words that will match the [placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/).", - "example": [ - "street", - "st" - ] - } - }, - "required": [ - "objectID", - "type" - ] - } - }, - "searchSynonymsResponse": { - "type": "object", - "additionalProperties": true, - "properties": { - "hits": { - "type": "array", - "description": "Synonym objects.", - "items": { - "type": "object", - "description": "Synonym object.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier of a synonym object.", - "example": "synonymID" - }, - "type": { - "type": "string", - "description": "Synonym type.", - "example": "onewaysynonym", - "enum": [ - "synonym", - "onewaysynonym", - "altcorrection1", - "altcorrection2", - "placeholder" - ] - }, - "synonyms": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words or phrases considered equivalent.", - "example": [ - "vehicle", - "auto" - ] - }, - "input": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`onewaysynonym`s](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/one-way-synonyms/)).", - "example": "car" - }, - "word": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`altcorrection1` and `altcorrection2`](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-alternative-corrections/)).", - "example": "car" - }, - "corrections": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words to be matched in records.", - "example": [ - "vehicle", - "auto" - ] - }, - "placeholder": { - "type": "string", - "description": "[Placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/) to be put inside records.\n", - "example": "" - }, - "replacements": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Query words that will match the [placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/).", - "example": [ - "street", - "st" - ] - } - }, - "required": [ - "objectID", - "type" - ] - } - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - } - }, - "required": [ - "hits", - "nbHits" - ] - }, - "keyString": { - "type": "string", - "description": "API key.", - "example": "13ad45b4d0a2f6ea65ecbddf6aa260f2" - }, - "createdAtTimestamp": { - "type": "integer", - "format": "int64", - "example": 1656345570000, - "description": "Timestamp of creation in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time)." - }, - "baseGetApiKeyResponse": { - "type": "object", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "API key.", - "example": "13ad45b4d0a2f6ea65ecbddf6aa260f2" - }, - "createdAt": { - "type": "integer", - "format": "int64", - "example": 1656345570000, - "description": "Timestamp of creation in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time)." - } - }, - "required": [ - "key", - "createdAt" - ] - }, - "acl": { - "description": "API key permissions:\n\n`addObject`: required to add or update records, copy or move an index.\n`analytics`: required to access the Analytics API.\n`browse`: required to view records\n`deleteIndex`: required to delete indices.\n`deleteObject`: required to delete records.\n`editSettings`: required to change index settings.\n`inference`: required to access the Inference API.\n`listIndexes`: required to list indices.\n`logs`: required to access logs of search and indexing operations.\n`recommendation`: required to access the Personalization and Recommend APIs.\n`search`: required to search records\n`seeUnretrievableAttributes`: required to retrieve [`unretrievableAttributes`](https://www.algolia.com/doc/api-reference/api-parameters/unretrievableAttributes/) for all operations that return records.\n`settings`: required to examine index settings.\n", - "type": "string", - "enum": [ - "addObject", - "analytics", - "browse", - "deleteObject", - "deleteIndex", - "editSettings", - "inference", - "listIndexes", - "logs", - "personalization", - "recommendation", - "search", - "seeUnretrievableAttributes", - "settings", - "usage" - ] - }, - "apiKey": { - "type": "object", - "description": "API key object.", - "additionalProperties": false, - "properties": { - "acl": { - "type": "array", - "description": "[Permissions](https://www.algolia.com/doc/guides/security/api-keys/#access-control-list-acl) associated with the key.\n", - "example": [ - "search", - "addObject" - ], - "default": [], - "items": { - "description": "API key permissions:\n\n`addObject`: required to add or update records, copy or move an index.\n`analytics`: required to access the Analytics API.\n`browse`: required to view records\n`deleteIndex`: required to delete indices.\n`deleteObject`: required to delete records.\n`editSettings`: required to change index settings.\n`inference`: required to access the Inference API.\n`listIndexes`: required to list indices.\n`logs`: required to access logs of search and indexing operations.\n`recommendation`: required to access the Personalization and Recommend APIs.\n`search`: required to search records\n`seeUnretrievableAttributes`: required to retrieve [`unretrievableAttributes`](https://www.algolia.com/doc/api-reference/api-parameters/unretrievableAttributes/) for all operations that return records.\n`settings`: required to examine index settings.\n", - "type": "string", - "enum": [ - "addObject", - "analytics", - "browse", - "deleteObject", - "deleteIndex", - "editSettings", - "inference", - "listIndexes", - "logs", - "personalization", - "recommendation", - "search", - "seeUnretrievableAttributes", - "settings", - "usage" - ] - } - }, - "description": { - "type": "string", - "description": "Description of an API key for you and your team members.", - "example": "Browse-restricted key", - "default": "" - }, - "indexes": { - "type": "array", - "description": "Restricts this API key to a list of indices or index patterns. If the list is empty, all indices are allowed.\nSpecify either an exact index name or a pattern with a leading or trailing wildcard character (or both). For example:\n- `dev_*` matches all indices starting with \"dev_\" - `*_dev` matches all indices ending with \"_dev\" - `*_products_*` matches all indices containing \"_products_\".\n", - "example": [ - "dev_*", - "prod_products" - ], - "default": [], - "items": { - "type": "string" - } - }, - "maxHitsPerQuery": { - "type": "integer", - "description": "Maximum number of hits this API key can retrieve in one query. If zero, no limit is enforced.\n> **Note**: Use this parameter to protect you from third-party attempts to retrieve your entire content by massively querying the index.\n", - "default": 0 - }, - "maxQueriesPerIPPerHour": { - "type": "integer", - "description": "Maximum number of API calls per hour allowed from a given IP address or [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/).\nEach time an API call is performed with this key, a check is performed. If there were more than the specified number of calls within the last hour, the API returns an error with the status code `429` (Too Many Requests).\n\n> **Note**: Use this parameter to protect you from third-party attempts to retrieve your entire content by massively querying the index.\n", - "default": 0 - }, - "queryParameters": { - "type": "string", - "description": "Force some [query parameters](https://www.algolia.com/doc/api-reference/api-parameters/) to be applied for each query made with this API key.\nIt's a URL-encoded query string.\n", - "example": "typoTolerance%3Dstrict%26ignorePlurals%3Dfalse%26filters%3Drights%3Apublic", - "default": "" - }, - "referers": { - "type": "array", - "description": "Restrict this API key to specific [referrers](https://www.algolia.com/doc/guides/security/api-keys/in-depth/api-key-restrictions/#http-referrers). If empty, all referrers are allowed.\nFor example:\n- `https://algolia.com/*` matches all referrers starting with \"https://algolia.com/\" - `*.algolia.com` matches all referrers ending with \".algolia.com\" - `*algolia.com*` allows everything in the domain \"algolia.com\".\n", - "example": [ - "*algolia.com*" - ], - "default": [], - "items": { - "type": "string" - } - }, - "validity": { - "type": "integer", - "description": "Validity duration of a key (in seconds). The key will automatically be removed after this time has expired. The default value of 0 never expires.\nShort-lived API keys are useful to grant temporary access to your data. For example, in mobile apps, you can't [control when users update your app](https://www.algolia.com/doc/guides/security/security-best-practices/#use-secured-api-keys-in-mobile-apps). So instead of encoding keys into your app as you would for a web app, you should dynamically fetch them from your mobile app's backend.\n", - "example": 86400, - "default": 0 - } - }, - "required": [ - "acl" - ] - }, - "getApiKeyResponse": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "API key.", - "example": "13ad45b4d0a2f6ea65ecbddf6aa260f2" - }, - "createdAt": { - "type": "integer", - "format": "int64", - "example": 1656345570000, - "description": "Timestamp of creation in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time)." - } - }, - "required": [ - "key", - "createdAt" - ] - }, - { - "type": "object", - "description": "API key object.", - "additionalProperties": false, - "properties": { - "acl": { - "type": "array", - "description": "[Permissions](https://www.algolia.com/doc/guides/security/api-keys/#access-control-list-acl) associated with the key.\n", - "example": [ - "search", - "addObject" - ], - "default": [], - "items": { - "description": "API key permissions:\n\n`addObject`: required to add or update records, copy or move an index.\n`analytics`: required to access the Analytics API.\n`browse`: required to view records\n`deleteIndex`: required to delete indices.\n`deleteObject`: required to delete records.\n`editSettings`: required to change index settings.\n`inference`: required to access the Inference API.\n`listIndexes`: required to list indices.\n`logs`: required to access logs of search and indexing operations.\n`recommendation`: required to access the Personalization and Recommend APIs.\n`search`: required to search records\n`seeUnretrievableAttributes`: required to retrieve [`unretrievableAttributes`](https://www.algolia.com/doc/api-reference/api-parameters/unretrievableAttributes/) for all operations that return records.\n`settings`: required to examine index settings.\n", - "type": "string", - "enum": [ - "addObject", - "analytics", - "browse", - "deleteObject", - "deleteIndex", - "editSettings", - "inference", - "listIndexes", - "logs", - "personalization", - "recommendation", - "search", - "seeUnretrievableAttributes", - "settings", - "usage" - ] - } - }, - "description": { - "type": "string", - "description": "Description of an API key for you and your team members.", - "example": "Browse-restricted key", - "default": "" - }, - "indexes": { - "type": "array", - "description": "Restricts this API key to a list of indices or index patterns. If the list is empty, all indices are allowed.\nSpecify either an exact index name or a pattern with a leading or trailing wildcard character (or both). For example:\n- `dev_*` matches all indices starting with \"dev_\" - `*_dev` matches all indices ending with \"_dev\" - `*_products_*` matches all indices containing \"_products_\".\n", - "example": [ - "dev_*", - "prod_products" - ], - "default": [], - "items": { - "type": "string" - } - }, - "maxHitsPerQuery": { - "type": "integer", - "description": "Maximum number of hits this API key can retrieve in one query. If zero, no limit is enforced.\n> **Note**: Use this parameter to protect you from third-party attempts to retrieve your entire content by massively querying the index.\n", - "default": 0 - }, - "maxQueriesPerIPPerHour": { - "type": "integer", - "description": "Maximum number of API calls per hour allowed from a given IP address or [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/).\nEach time an API call is performed with this key, a check is performed. If there were more than the specified number of calls within the last hour, the API returns an error with the status code `429` (Too Many Requests).\n\n> **Note**: Use this parameter to protect you from third-party attempts to retrieve your entire content by massively querying the index.\n", - "default": 0 - }, - "queryParameters": { - "type": "string", - "description": "Force some [query parameters](https://www.algolia.com/doc/api-reference/api-parameters/) to be applied for each query made with this API key.\nIt's a URL-encoded query string.\n", - "example": "typoTolerance%3Dstrict%26ignorePlurals%3Dfalse%26filters%3Drights%3Apublic", - "default": "" - }, - "referers": { - "type": "array", - "description": "Restrict this API key to specific [referrers](https://www.algolia.com/doc/guides/security/api-keys/in-depth/api-key-restrictions/#http-referrers). If empty, all referrers are allowed.\nFor example:\n- `https://algolia.com/*` matches all referrers starting with \"https://algolia.com/\" - `*.algolia.com` matches all referrers ending with \".algolia.com\" - `*algolia.com*` allows everything in the domain \"algolia.com\".\n", - "example": [ - "*algolia.com*" - ], - "default": [], - "items": { - "type": "string" - } - }, - "validity": { - "type": "integer", - "description": "Validity duration of a key (in seconds). The key will automatically be removed after this time has expired. The default value of 0 never expires.\nShort-lived API keys are useful to grant temporary access to your data. For example, in mobile apps, you can't [control when users update your app](https://www.algolia.com/doc/guides/security/security-best-practices/#use-secured-api-keys-in-mobile-apps). So instead of encoding keys into your app as you would for a web app, you should dynamically fetch them from your mobile app's backend.\n", - "example": 86400, - "default": 0 - } - }, - "required": [ - "acl" - ] - } - ] - }, - "createdAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of creation in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "addApiKeyResponse": { - "type": "object", - "additionalProperties": false, - "properties": { - "key": { - "type": "string", - "description": "API key.", - "example": "13ad45b4d0a2f6ea65ecbddf6aa260f2" - }, - "createdAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of creation in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format." - } - }, - "required": [ - "key", - "createdAt" - ] - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "condition": { - "type": "object", - "additionalProperties": false, - "properties": { - "pattern": { - "type": "string", - "description": "Query pattern syntax.", - "example": "{facet:brand}" - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "alternatives": { - "type": "boolean", - "description": "Whether the pattern matches on plurals, synonyms, and typos.", - "default": false - }, - "context": { - "type": "string", - "description": "Rule context format: [A-Za-z0-9_-]+).", - "example": "trackedFilters" - } - } - }, - "editType": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "edit": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - }, - "consequenceQueryObject": { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - "consequenceQuery": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilter": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "params": { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - }, - "consequenceParams": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "promotePosition": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - }, - "promoteObjectIDs": { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - "promoteObjectID": { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - }, - "promote": { - "oneOf": [ - { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - } - ] - }, - "consequence": { - "type": "object", - "description": "[Consequences](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#consequences) of a rule.\n", - "additionalProperties": false, - "properties": { - "params": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "promote": { - "type": "array", - "description": "Records to promote.", - "items": { - "oneOf": [ - { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - } - ] - } - }, - "filterPromotes": { - "type": "boolean", - "default": false, - "description": "Only use in combination with the `promote` consequence. When `true`, promoted results will be restricted to match the filters of the current search. When `false`, the promoted results will show up regardless of the filters." - }, - "hide": { - "type": "array", - "description": "Records to hide. By default, you can hide up to 50 records per rule.", - "items": { - "title": "consequenceHide", - "type": "object", - "description": "Unique identifier of the record to hide.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - }, - "required": [ - "objectID" - ] - } - }, - "userData": { - "description": "Custom JSON object that will be appended to the userData array in the response. This object isn't interpreted by the API. It's limited to 1kB of minified JSON.", - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - } - } - } - }, - "timeRange": { - "type": "object", - "additionalProperties": false, - "properties": { - "from": { - "type": "integer", - "description": "Lower bound of the time range (Unix timestamp)." - }, - "until": { - "type": "integer", - "description": "Upper bound of the time range (Unix timestamp)." - } - }, - "required": [ - "from", - "until" - ] - }, - "rule": { - "type": "object", - "description": "Rule object.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier for a rule object.", - "example": "hide-12345" - }, - "conditions": { - "type": "array", - "description": "[Conditions](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#conditions) required to activate a rule. You can use up to 25 conditions per rule.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "pattern": { - "type": "string", - "description": "Query pattern syntax.", - "example": "{facet:brand}" - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "alternatives": { - "type": "boolean", - "description": "Whether the pattern matches on plurals, synonyms, and typos.", - "default": false - }, - "context": { - "type": "string", - "description": "Rule context format: [A-Za-z0-9_-]+).", - "example": "trackedFilters" - } - } - } - }, - "consequence": { - "type": "object", - "description": "[Consequences](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#consequences) of a rule.\n", - "additionalProperties": false, - "properties": { - "params": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "promote": { - "type": "array", - "description": "Records to promote.", - "items": { - "oneOf": [ - { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - } - ] - } - }, - "filterPromotes": { - "type": "boolean", - "default": false, - "description": "Only use in combination with the `promote` consequence. When `true`, promoted results will be restricted to match the filters of the current search. When `false`, the promoted results will show up regardless of the filters." - }, - "hide": { - "type": "array", - "description": "Records to hide. By default, you can hide up to 50 records per rule.", - "items": { - "title": "consequenceHide", - "type": "object", - "description": "Unique identifier of the record to hide.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - }, - "required": [ - "objectID" - ] - } - }, - "userData": { - "description": "Custom JSON object that will be appended to the userData array in the response. This object isn't interpreted by the API. It's limited to 1kB of minified JSON.", - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - } - } - } - }, - "description": { - "type": "string", - "description": "Description of the rule's purpose. This can be helpful for display in the Algolia dashboard.", - "example": "Display a promotional banner" - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Indicates whether to enable the rule. If it isn't enabled, it isn't applied at query time." - }, - "validity": { - "type": "array", - "description": "If you specify a validity period, the rule _only_ applies only during that period. If specified, the array must not be empty.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "from": { - "type": "integer", - "description": "Lower bound of the time range (Unix timestamp)." - }, - "until": { - "type": "integer", - "description": "Upper bound of the time range (Unix timestamp)." - } - }, - "required": [ - "from", - "until" - ] - } - } - }, - "required": [ - "objectID" - ] - }, - "updatedRuleResponse": { - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - } - }, - "required": [ - "objectID", - "updatedAt", - "taskID" - ] - }, - "parameters_query": { - "type": "string", - "description": "Rule object query.", - "default": "" - }, - "parameters_page": { - "type": "integer", - "minimum": 0, - "description": "Requested page (the first page is page 0)." - }, - "parameters_hitsPerPage": { - "type": "integer", - "default": 20, - "minimum": 1, - "maximum": 1000, - "description": "Maximum number of hits per page." - }, - "dictionaryType": { - "type": "string", - "enum": [ - "plurals", - "stopwords", - "compounds" - ] - }, - "dictionaryAction": { - "type": "string", - "enum": [ - "addEntry", - "deleteEntry" - ], - "description": "Actions to perform." - }, - "dictionaryEntryState": { - "type": "string", - "enum": [ - "enabled", - "disabled" - ], - "default": "enabled", - "description": "Indicates whether a dictionary entry is active (`enabled`) or inactive (`disabled`)." - }, - "dictionaryEntry": { - "type": "object", - "description": "Dictionary entry.", - "additionalProperties": true, - "required": [ - "objectID", - "language" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier for a dictionary object.", - "example": "under" - }, - "language": { - "type": "string", - "description": "[Supported language ISO code](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/).\n", - "example": "de" - }, - "word": { - "type": "string", - "description": "Dictionary entry word. Usage depends on the type of dictionary entry.\n**`stopwordEntry`**\nThe stop word you want to add or update. If the entry already exists in Algolia's standard dictionary, you can override its behavior by adding it to the custom dictionary and setting its `state` to `disabled`.\n**`compoundEntry`**\nWhen `decomposition` is empty: adds `word` as a compound atom. For example, atom “kino” decomposes the query “kopfkino” into \"kopf\" and \"kino\".\nWhen `decomposition` isn't empty: creates a decomposition exception. For example, when decomposition is set to the [\"hund\", \"hutte\"] exception, \"hundehutte\" decomposes into “hund” and “hutte”, discarding the linking \"e\".\n", - "example": "down" - }, - "words": { - "type": "array", - "description": "Compound dictionary [word declensions](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-plurals-and-other-declensions/).\nIf the entry already exists in Algolia's standard dictionary, you can override its behavior by adding it to the custom dictionary and setting its `state` to `disabled`.\n", - "example": [ - "cheval", - "chevaux" - ], - "items": { - "type": "string" - } - }, - "decomposition": { - "type": "array", - "description": "For compound entries, governs the behavior of the `word` parameter.", - "example": [ - "kopf", - "schmerz", - "tablette" - ], - "items": { - "type": "string" - } - }, - "state": { - "type": "string", - "enum": [ - "enabled", - "disabled" - ], - "default": "enabled", - "description": "Indicates whether a dictionary entry is active (`enabled`) or inactive (`disabled`)." - } - } - }, - "language": { - "description": "[Supported language ISO code](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/).\n", - "example": "en", - "type": "string" - }, - "standardEntry": { - "description": "Key-value pair of a language ISO code and a boolean value.", - "example": "{'fr': false}\n", - "type": "object", - "nullable": true, - "additionalProperties": { - "type": "boolean" - } - }, - "standardEntries": { - "description": "Key-value pairs of [supported language ISO codes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) and boolean values.\n", - "additionalProperties": false, - "properties": { - "plurals": { - "description": "Key-value pair of a language ISO code and a boolean value.", - "example": "{'fr': false}\n", - "type": "object", - "nullable": true, - "additionalProperties": { - "type": "boolean" - } - }, - "stopwords": { - "description": "Key-value pair of a language ISO code and a boolean value.", - "example": "{'fr': false}\n", - "type": "object", - "nullable": true, - "additionalProperties": { - "type": "boolean" - } - }, - "compounds": { - "description": "Key-value pair of a language ISO code and a boolean value.", - "example": "{'fr': false}\n", - "type": "object", - "nullable": true, - "additionalProperties": { - "type": "boolean" - } - } - } - }, - "dictionaryLanguage": { - "type": "object", - "additionalProperties": false, - "nullable": true, - "description": "Custom entries for a dictionary.", - "properties": { - "nbCustomEntries": { - "description": "If `0`, the dictionary hasn't been customized and only contains standard entries provided by Algolia.\nIf `null`, that feature isn't available or isn't supported for that language.\n", - "type": "integer" - } - } - }, - "languages": { - "type": "object", - "description": "Dictionary language.", - "additionalProperties": false, - "required": [ - "plurals", - "stopwords", - "compounds" - ], - "properties": { - "plurals": { - "type": "object", - "additionalProperties": false, - "nullable": true, - "description": "Custom entries for a dictionary.", - "properties": { - "nbCustomEntries": { - "description": "If `0`, the dictionary hasn't been customized and only contains standard entries provided by Algolia.\nIf `null`, that feature isn't available or isn't supported for that language.\n", - "type": "integer" - } - } - }, - "stopwords": { - "type": "object", - "additionalProperties": false, - "nullable": true, - "description": "Custom entries for a dictionary.", - "properties": { - "nbCustomEntries": { - "description": "If `0`, the dictionary hasn't been customized and only contains standard entries provided by Algolia.\nIf `null`, that feature isn't available or isn't supported for that language.\n", - "type": "integer" - } - } - }, - "compounds": { - "type": "object", - "additionalProperties": false, - "nullable": true, - "description": "Custom entries for a dictionary.", - "properties": { - "nbCustomEntries": { - "description": "If `0`, the dictionary hasn't been customized and only contains standard entries provided by Algolia.\nIf `null`, that feature isn't available or isn't supported for that language.\n", - "type": "integer" - } - } - } - } - }, - "userID": { - "type": "string", - "pattern": "^[a-zA-Z0-9 \\-*.]+$", - "description": "userID of the user.", - "example": "user1" - }, - "userId": { - "title": "userID", - "type": "object", - "description": "Unique user ID.", - "properties": { - "userID": { - "type": "string", - "pattern": "^[a-zA-Z0-9 \\-*.]+$", - "description": "userID of the user.", - "example": "user1" - }, - "clusterName": { - "type": "string", - "description": "Cluster to which the user is assigned.", - "example": "c1-test" - }, - "nbRecords": { - "type": "integer", - "description": "Number of records belonging to the user.", - "example": 42 - }, - "dataSize": { - "type": "integer", - "description": "Data size used by the user.", - "example": 0 - } - }, - "required": [ - "userID", - "clusterName", - "nbRecords", - "dataSize" - ] - }, - "clusterName": { - "type": "string", - "description": "Cluster name.", - "example": "c11-test" - }, - "nbRecords": { - "type": "integer", - "description": "Number of records in the cluster.", - "example": 3 - }, - "dataSize": { - "type": "integer", - "description": "Data size taken by all the users assigned to the cluster.", - "example": 481 - }, - "source": { - "description": "Source.", - "required": [ - "source" - ], - "properties": { - "source": { - "description": "IP address range of the source.", - "type": "string", - "example": "10.0.0.1/32" - }, - "description": { - "description": "Source description.", - "type": "string", - "example": "Server subnet" - } - } - }, - "sources": { - "description": "Sources.", - "type": "array", - "items": { - "description": "Source.", - "required": [ - "source" - ], - "properties": { - "source": { - "description": "IP address range of the source.", - "type": "string", - "example": "10.0.0.1/32" - }, - "description": { - "description": "Source description.", - "type": "string", - "example": "Server subnet" - } - } - } - }, - "logType": { - "type": "string", - "enum": [ - "all", - "query", - "build", - "error" - ], - "default": "all" - }, - "taskStatus": { - "type": "string", - "enum": [ - "published", - "notPublished" - ], - "description": "_published_ if the task has been processed, _notPublished_ otherwise." - }, - "operationType": { - "type": "string", - "enum": [ - "move", - "copy" - ], - "example": "copy", - "description": "Operation to perform (_move_ or _copy_)." - }, - "scopeType": { - "type": "string", - "enum": [ - "settings", - "synonyms", - "rules" - ] - }, - "fetchedIndex": { - "type": "object", - "additionalProperties": false, - "properties": { - "name": { - "type": "string", - "description": "Index name.", - "example": "movies" - }, - "createdAt": { - "type": "string", - "description": "Index creation date. An empty string means that the index has no records.", - "example": "2022-09-19T16:36:44.471Z" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "entries": { - "type": "integer", - "description": "Number of records contained in the index.", - "example": 100 - }, - "dataSize": { - "type": "integer", - "description": "Number of bytes of the index in minified format.", - "example": 48450 - }, - "fileSize": { - "type": "integer", - "description": "Number of bytes of the index binary file.", - "example": 112927 - }, - "lastBuildTimeS": { - "type": "integer", - "description": "Last build time.", - "example": 3 - }, - "numberOfPendingTasks": { - "type": "integer", - "default": 0, - "description": "Number of pending indexing operations. This value is deprecated and should not be used." - }, - "pendingTask": { - "type": "boolean", - "default": false, - "description": "A boolean which says whether the index has pending tasks. This value is deprecated and should not be used." - }, - "primary": { - "type": "string", - "description": "Only present if the index is a replica. Contains the name of the related primary index.", - "example": "T02" - }, - "replicas": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Only present if the index is a primary index with replicas. Contains the names of all linked replicas.", - "example": [ - "T02_push", - "T2replica" - ] - } - }, - "required": [ - "name", - "createdAt", - "updatedAt", - "entries", - "dataSize", - "fileSize", - "lastBuildTimeS", - "pendingTask", - "numberOfPendingTasks" - ] - }, - "listIndicesResponse": { - "type": "object", - "additionalProperties": false, - "properties": { - "items": { - "type": "array", - "description": "All indices in your Algolia application.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "name": { - "type": "string", - "description": "Index name.", - "example": "movies" - }, - "createdAt": { - "type": "string", - "description": "Index creation date. An empty string means that the index has no records.", - "example": "2022-09-19T16:36:44.471Z" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "entries": { - "type": "integer", - "description": "Number of records contained in the index.", - "example": 100 - }, - "dataSize": { - "type": "integer", - "description": "Number of bytes of the index in minified format.", - "example": 48450 - }, - "fileSize": { - "type": "integer", - "description": "Number of bytes of the index binary file.", - "example": 112927 - }, - "lastBuildTimeS": { - "type": "integer", - "description": "Last build time.", - "example": 3 - }, - "numberOfPendingTasks": { - "type": "integer", - "default": 0, - "description": "Number of pending indexing operations. This value is deprecated and should not be used." - }, - "pendingTask": { - "type": "boolean", - "default": false, - "description": "A boolean which says whether the index has pending tasks. This value is deprecated and should not be used." - }, - "primary": { - "type": "string", - "description": "Only present if the index is a replica. Contains the name of the related primary index.", - "example": "T02" - }, - "replicas": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Only present if the index is a primary index with replicas. Contains the names of all linked replicas.", - "example": [ - "T02_push", - "T2replica" - ] - } - }, - "required": [ - "name", - "createdAt", - "updatedAt", - "entries", - "dataSize", - "fileSize", - "lastBuildTimeS", - "pendingTask", - "numberOfPendingTasks" - ] - } - }, - "nbPages": { - "type": "integer", - "description": "Number of pages.", - "example": 100 - } - }, - "required": [ - "items" - ] - } - }, - "responses": { - "BadRequest": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "FeatureNotEnabled": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "MethodNotAllowed": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "IndexNotFound": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "DeletedAt": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "deletedAtResponse", - "description": "Response, taskID, and deletion timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "deletedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "deletedAt": { - "type": "string", - "example": "2023-06-27T14:42:38.831Z", - "description": "Timestamp of deletion in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "UpdatedAtWithObjectId": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtWithObjectIdResponse", - "description": "Response, taskID, unique object identifier, and an update timestamp.", - "additionalProperties": false, - "type": "object", - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - } - } - } - } - }, - "UpdatedAt": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtResponse", - "description": "Response, taskID, and update timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "updatedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "CreatedAt": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "createdAtResponse", - "description": "Response and creation timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "createdAt" - ], - "properties": { - "createdAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of creation in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - } - } - }, - "servers": [ - { - "url": "https://{appId}.algolia.net", - "variables": { - "appId": { - "default": "myAppId" - } - } - }, - { - "url": "https://{appId}-1.algolianet.com", - "variables": { - "appId": { - "default": "myAppId" - } - } - }, - { - "url": "https://{appId}-2.algolianet.com", - "variables": { - "appId": { - "default": "myAppId" - } - } - }, - { - "url": "https://{appId}-3.algolianet.com", - "variables": { - "appId": { - "default": "myAppId" - } - } - }, - { - "url": "https://{appId}-dsn.algolia.net", - "variables": { - "appId": { - "default": "myAppId" - } - } - } - ], - "security": [ - { - "appId": [], - "apiKey": [] - } - ], - "tags": [ - { - "name": "Advanced", - "description": "Advanced operations." - }, - { - "name": "Api Keys", - "description": "Manage your API keys." - }, - { - "name": "Clusters", - "description": "Multi-cluster operations.\nAlgolia no longer offers [multi-cluster management](https://www.algolia.com/doc/guides/scaling/managing-multiple-clusters-mcm/).\n- If you want to partition your data per user, use facets and secured API keys instead. - If you need more data, consider upgrading to a bigger cluster to suit your needs. Contact [Algolia's support team](https://support.algolia.com/hc/en-us/requests/new) for details.\n" - }, - { - "name": "Dictionaries", - "description": "Dictionary operations allow you to customize linguistic features such as [stop words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-stop-words/), [plurals](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-plurals-and-other-declensions/), and [segmentation (compounds)](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-segmentation/)." - }, - { - "name": "Indices", - "description": "Manage indices, including listing them, checking and updating settings, deleting, copying, and renaming." - }, - { - "name": "Records", - "description": "Record operations." - }, - { - "name": "Rules", - "description": "Rules operations." - }, - { - "name": "Search", - "description": "Search operations." - }, - { - "name": "Synonyms", - "description": "Synonym operations." - }, - { - "name": "Vaults", - "description": "Vault operations.\nAlgolia Vault allows you to restrict network-level access to your cluster to a specific set of IP addresses: for non-authorized IP addresses, the cluster is invisible.\nYou should authorize the IP addresses of team members who need to access the Alglolia dashboard, as it's also affected by the restricted list you set up.\nTo access this feature, [Algolia Vault](https://www.algolia.com/doc/guides/security/algolia-vault/) must be enabled on your server. Contact [Algolia's support team](https://support.algolia.com/hc/en-us/requests/new) for details.\n> **Note**: The maximum number of allowed sources is 1,000.\n" - }, - { - "name": "_model_index_settings", - "x-displayName": "Index settings", - "description": ".\n" - } - ], - "x-tagGroups": [ - { - "name": "Search and indexing", - "tags": [ - "Indices", - "Records", - "Search" - ] - }, - { - "name": "Relevance", - "tags": [ - "Rules", - "Synonyms", - "Dictionaries" - ] - }, - { - "name": "Others", - "tags": [ - "Api Keys", - "Clusters", - "Vaults", - "Advanced" - ] - }, - { - "name": "Models", - "tags": [ - "_model_index_settings" - ] - } - ], - "paths": { - "/1{path}": { - "get": { - "operationId": "customGet", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "operationId": "customPost", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "operationId": "customPut", - "requestBody": { - "description": "Parameters to send with the custom request.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "operationId": "customDelete", - "summary": "Send requests to the Algolia REST API.", - "description": "This method allow you to send requests to the Algolia REST API.", - "parameters": [ - { - "name": "path", - "in": "path", - "description": "Path of the endpoint, anything after \"/1\" must be specified.", - "required": true, - "schema": { - "type": "string", - "example": "/keys" - } - }, - { - "name": "parameters", - "in": "query", - "description": "Query parameters to apply to the current query.", - "schema": { - "type": "object", - "additionalProperties": true - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/query": { - "post": { - "tags": [ - "Search" - ], - "operationId": "searchSingleIndex", - "x-use-read-transporter": true, - "x-cacheable": true, - "x-acl": [ - "search" - ], - "summary": "Search an index.", - "description": "Return records that match the query.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "x-discriminator-fields": [ - "params" - ], - "properties": { - "params": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - } - } - }, - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "additionalProperties": true, - "allOf": [ - { - "type": "object", - "additionalProperties": true, - "required": [ - "nbHits", - "page", - "nbPages", - "hitsPerPage", - "processingTimeMS" - ], - "properties": { - "abTestID": { - "type": "integer", - "description": "A/B test ID. This is only included in the response for indices that are part of an A/B test." - }, - "abTestVariantID": { - "type": "integer", - "minimum": 1, - "description": "Variant ID. This is only included in the response for indices that are part of an A/B test." - }, - "aroundLatLng": { - "type": "string", - "description": "Computed geographical location.", - "example": "40.71,-74.01", - "pattern": "^(-?\\d+(\\.\\d+)?),\\s*(-?\\d+(\\.\\d+)?)$" - }, - "automaticRadius": { - "type": "string", - "description": "Automatically-computed radius." - }, - "exhaustive": { - "type": "object", - "title": "exhaustive", - "description": "Whether certain properties of the search response are calculated exhaustive (exact) or approximated.", - "properties": { - "facetsCount": { - "type": "boolean", - "title": "facetsCount", - "description": "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-)." - }, - "facetValues": { - "type": "boolean", - "title": "facetValues", - "description": "The value is `false` if not all facet values are retrieved." - }, - "nbHits": { - "type": "boolean", - "title": "nbHits", - "description": "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." - }, - "rulesMatch": { - "type": "boolean", - "title": "rulesMatch", - "description": "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." - }, - "typo": { - "type": "boolean", - "title": "typo", - "description": "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." - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveNbHits": { - "type": "boolean", - "description": "See the `nbHits` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveTypo": { - "type": "boolean", - "description": "See the `typo` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "facets": { - "title": "facets", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "integer" - } - }, - "description": "Mapping of each facet name to the corresponding facet counts.", - "example": { - "category": { - "food": 1, - "tech": 42 - } - } - }, - "facets_stats": { - "title": "facetsStats", - "type": "object", - "description": "Statistics for numerical facets.", - "additionalProperties": { - "type": "object", - "title": "facetStats", - "properties": { - "min": { - "type": "number", - "format": "double", - "description": "Minimum value in the results." - }, - "max": { - "type": "number", - "format": "double", - "description": "Maximum value in the results." - }, - "avg": { - "type": "number", - "format": "double", - "description": "Average facet value in the results." - }, - "sum": { - "type": "number", - "format": "double", - "description": "Sum of all values in the results." - } - } - } - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "index": { - "type": "string", - "example": "indexName", - "description": "Index name used for the query." - }, - "indexUsed": { - "type": "string", - "description": "Index name used for the query. During A/B testing, the targeted index isn't always the index used by the query.", - "example": "indexNameAlt" - }, - "message": { - "type": "string", - "description": "Warnings about the query." - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - }, - "nbSortedHits": { - "type": "integer", - "description": "Number of hits selected and sorted by the relevant sort algorithm.", - "example": 20 - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "parsedQuery": { - "type": "string", - "description": "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.", - "example": "george clo" - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "processingTimingsMS": { - "type": "object", - "description": "Experimental. List of processing steps and their times, in milliseconds. You can use this list to investigate performance issues." - }, - "queryAfterRemoval": { - "type": "string", - "description": "Markup text indicating which parts of the original query have been removed to retrieve a non-empty result set." - }, - "redirect": { - "title": "redirect", - "type": "object", - "description": "[Redirect results to a URL](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/redirects/).\n", - "properties": { - "index": { - "type": "array", - "items": { - "type": "object", - "properties": { - "source": { - "type": "string", - "description": "Source index for the redirect rule." - }, - "dest": { - "type": "string", - "description": "Destination index for the redirect rule." - }, - "reason": { - "type": "string", - "description": "Reason for the redirect rule." - }, - "succeed": { - "type": "boolean", - "description": "Redirect rule status." - }, - "data": { - "type": "object", - "description": "Redirect rule data.", - "required": [ - "ruleObjectID" - ], - "properties": { - "ruleObjectID": { - "type": "string" - } - } - } - }, - "required": [ - "data", - "succeed", - "reason", - "dest", - "source" - ] - } - } - } - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "serverTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "serverUsed": { - "type": "string", - "description": "Host name of the server that processed the request.", - "example": "c2-uk-3.algolia.net" - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": true, - "properties": { - "hits": { - "type": "array", - "items": { - "type": "object", - "description": "A single hit.", - "x-is-generic": true, - "additionalProperties": true, - "required": [ - "objectID" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - } - } - } - }, - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "params": { - "type": "string", - "description": "URL-encoded string of all search parameters.", - "example": "query=a&hitsPerPage=20" - } - }, - "required": [ - "hits", - "query", - "params" - ] - } - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/*/queries": { - "post": { - "tags": [ - "Search" - ], - "operationId": "search", - "x-use-read-transporter": true, - "x-cacheable": true, - "x-legacy-signature": true, - "x-acl": [ - "search" - ], - "summary": "Search multiple indices.", - "description": "Send multiple search queries to one or more indices.", - "requestBody": { - "required": true, - "description": "Query requests and strategies. Results will be received in the same order as the queries.", - "content": { - "application/json": { - "schema": { - "title": "searchMethodParams", - "type": "object", - "additionalProperties": false, - "properties": { - "requests": { - "type": "array", - "items": { - "oneOf": [ - { - "allOf": [ - { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "x-discriminator-fields": [ - "params" - ], - "properties": { - "params": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - } - } - }, - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - ] - }, - { - "x-is-SearchForHitsOptions": true, - "type": "object", - "properties": { - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "type": { - "type": "string", - "enum": [ - "default" - ], - "default": "default", - "description": "- `default`: perform a search query - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).\n" - } - }, - "required": [ - "indexName" - ] - } - ] - }, - { - "allOf": [ - { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "x-discriminator-fields": [ - "params" - ], - "properties": { - "params": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - } - } - }, - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - ] - }, - { - "type": "object", - "properties": { - "facet": { - "type": "string", - "description": "Facet name." - }, - "indexName": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "facetQuery": { - "type": "string", - "description": "Text to search inside the facet's values.", - "example": "george", - "default": "" - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "type": { - "type": "string", - "enum": [ - "facet" - ], - "default": "facet", - "description": "- `default`: perform a search query - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).\n" - } - }, - "required": [ - "indexName", - "type", - "facet" - ] - } - ], - "x-discriminator-fields": [ - "facet", - "type" - ] - } - ] - } - }, - "strategy": { - "type": "string", - "enum": [ - "none", - "stopIfEnoughMatches" - ], - "description": "- `none`: executes all queries. - `stopIfEnoughMatches`: executes queries one by one, stopping further query execution as soon as a query matches at least the `hitsPerPage` number of results. \n" - } - }, - "required": [ - "requests" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "searchResponses", - "type": "object", - "additionalProperties": false, - "properties": { - "results": { - "type": "array", - "items": { - "oneOf": [ - { - "additionalProperties": true, - "allOf": [ - { - "type": "object", - "additionalProperties": true, - "required": [ - "nbHits", - "page", - "nbPages", - "hitsPerPage", - "processingTimeMS" - ], - "properties": { - "abTestID": { - "type": "integer", - "description": "A/B test ID. This is only included in the response for indices that are part of an A/B test." - }, - "abTestVariantID": { - "type": "integer", - "minimum": 1, - "description": "Variant ID. This is only included in the response for indices that are part of an A/B test." - }, - "aroundLatLng": { - "type": "string", - "description": "Computed geographical location.", - "example": "40.71,-74.01", - "pattern": "^(-?\\d+(\\.\\d+)?),\\s*(-?\\d+(\\.\\d+)?)$" - }, - "automaticRadius": { - "type": "string", - "description": "Automatically-computed radius." - }, - "exhaustive": { - "type": "object", - "title": "exhaustive", - "description": "Whether certain properties of the search response are calculated exhaustive (exact) or approximated.", - "properties": { - "facetsCount": { - "type": "boolean", - "title": "facetsCount", - "description": "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-)." - }, - "facetValues": { - "type": "boolean", - "title": "facetValues", - "description": "The value is `false` if not all facet values are retrieved." - }, - "nbHits": { - "type": "boolean", - "title": "nbHits", - "description": "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." - }, - "rulesMatch": { - "type": "boolean", - "title": "rulesMatch", - "description": "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." - }, - "typo": { - "type": "boolean", - "title": "typo", - "description": "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." - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveNbHits": { - "type": "boolean", - "description": "See the `nbHits` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveTypo": { - "type": "boolean", - "description": "See the `typo` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "facets": { - "title": "facets", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "integer" - } - }, - "description": "Mapping of each facet name to the corresponding facet counts.", - "example": { - "category": { - "food": 1, - "tech": 42 - } - } - }, - "facets_stats": { - "title": "facetsStats", - "type": "object", - "description": "Statistics for numerical facets.", - "additionalProperties": { - "type": "object", - "title": "facetStats", - "properties": { - "min": { - "type": "number", - "format": "double", - "description": "Minimum value in the results." - }, - "max": { - "type": "number", - "format": "double", - "description": "Maximum value in the results." - }, - "avg": { - "type": "number", - "format": "double", - "description": "Average facet value in the results." - }, - "sum": { - "type": "number", - "format": "double", - "description": "Sum of all values in the results." - } - } - } - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "index": { - "type": "string", - "example": "indexName", - "description": "Index name used for the query." - }, - "indexUsed": { - "type": "string", - "description": "Index name used for the query. During A/B testing, the targeted index isn't always the index used by the query.", - "example": "indexNameAlt" - }, - "message": { - "type": "string", - "description": "Warnings about the query." - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - }, - "nbSortedHits": { - "type": "integer", - "description": "Number of hits selected and sorted by the relevant sort algorithm.", - "example": 20 - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "parsedQuery": { - "type": "string", - "description": "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.", - "example": "george clo" - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "processingTimingsMS": { - "type": "object", - "description": "Experimental. List of processing steps and their times, in milliseconds. You can use this list to investigate performance issues." - }, - "queryAfterRemoval": { - "type": "string", - "description": "Markup text indicating which parts of the original query have been removed to retrieve a non-empty result set." - }, - "redirect": { - "title": "redirect", - "type": "object", - "description": "[Redirect results to a URL](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/redirects/).\n", - "properties": { - "index": { - "type": "array", - "items": { - "type": "object", - "properties": { - "source": { - "type": "string", - "description": "Source index for the redirect rule." - }, - "dest": { - "type": "string", - "description": "Destination index for the redirect rule." - }, - "reason": { - "type": "string", - "description": "Reason for the redirect rule." - }, - "succeed": { - "type": "boolean", - "description": "Redirect rule status." - }, - "data": { - "type": "object", - "description": "Redirect rule data.", - "required": [ - "ruleObjectID" - ], - "properties": { - "ruleObjectID": { - "type": "string" - } - } - } - }, - "required": [ - "data", - "succeed", - "reason", - "dest", - "source" - ] - } - } - } - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "serverTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "serverUsed": { - "type": "string", - "description": "Host name of the server that processed the request.", - "example": "c2-uk-3.algolia.net" - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": true, - "properties": { - "hits": { - "type": "array", - "items": { - "type": "object", - "description": "A single hit.", - "x-is-generic": true, - "additionalProperties": true, - "required": [ - "objectID" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - } - } - } - }, - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "params": { - "type": "string", - "description": "URL-encoded string of all search parameters.", - "example": "query=a&hitsPerPage=20" - } - }, - "required": [ - "hits", - "query", - "params" - ] - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "required": [ - "facetHits", - "exhaustiveFacetsCount" - ], - "x-discriminator-fields": [ - "facetHits" - ], - "properties": { - "facetHits": { - "type": "array", - "items": { - "type": "object", - "title": "facetHits", - "additionalProperties": false, - "required": [ - "value", - "highlighted", - "count" - ], - "properties": { - "value": { - "description": "Facet value.", - "example": "Mobile phone", - "type": "string" - }, - "highlighted": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "count": { - "description": "Number of records containing this facet value. This takes into account the extra search parameters specified in the query. Like for a regular search query, the [counts may not be exhaustive](https://support.algolia.com/hc/en-us/articles/4406975248145-Why-are-my-facet-and-hit-counts-not-accurate-).", - "type": "integer" - } - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - } - } - } - ] - } - } - }, - "required": [ - "results" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/facets/{facetName}/query": { - "post": { - "tags": [ - "Search" - ], - "operationId": "searchForFacetValues", - "x-use-read-transporter": true, - "x-cacheable": true, - "x-acl": [ - "search" - ], - "summary": "Search for facet values.", - "description": "[Search for a facet's values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values), optionally restricting the returned values to those contained in records matching other search criteria.\n> **Note**: Pagination isn't supported (`page` and `hitsPerPage` are ignored). By default, the engine returns a maximum of 10 values but you can adjust this with `maxFacetHits`.\n", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "name": "facetName", - "description": "Facet name.", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "title": "searchForFacetValuesRequest", - "type": "object", - "additionalProperties": false, - "properties": { - "params": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - }, - "facetQuery": { - "type": "string", - "description": "Text to search inside the facet's values.", - "example": "george", - "default": "" - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "facetHits", - "exhaustiveFacetsCount" - ], - "x-discriminator-fields": [ - "facetHits" - ], - "properties": { - "facetHits": { - "type": "array", - "items": { - "type": "object", - "title": "facetHits", - "additionalProperties": false, - "required": [ - "value", - "highlighted", - "count" - ], - "properties": { - "value": { - "description": "Facet value.", - "example": "Mobile phone", - "type": "string" - }, - "highlighted": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "count": { - "description": "Number of records containing this facet value. This takes into account the extra search parameters specified in the query. Like for a regular search query, the [counts may not be exhaustive](https://support.algolia.com/hc/en-us/articles/4406975248145-Why-are-my-facet-and-hit-counts-not-accurate-).", - "type": "integer" - } - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/browse": { - "post": { - "tags": [ - "Search" - ], - "operationId": "browse", - "x-acl": [ - "browse" - ], - "summary": "Get all records from an index.", - "description": "Retrieve up to 1,000 records per call.\nSupports full-text search and filters. For better performance, it doesn't support:\n- The `distinct` query parameter - Sorting by typos, proximity, words, or geographical distance.\n", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "x-discriminator-fields": [ - "params" - ], - "properties": { - "params": { - "description": "Search parameters as a URL-encoded query string.", - "example": "hitsPerPage=2&getRankingInfo=1", - "type": "string", - "default": "" - } - } - }, - { - "allOf": [ - { - "allOf": [ - { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "cursor": { - "type": "string", - "description": "Cursor indicating the location to resume browsing from. Must match the value returned by the previous call.\nPass this value to the subsequent browse call to get the next page of results.\nWhen the end of the index has been reached, `cursor` is absent from the response.\n", - "example": "jMDY3M2MwM2QwMWUxMmQwYWI0ZTN" - } - } - } - ] - } - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "allOf": [ - { - "type": "object", - "additionalProperties": true, - "required": [ - "nbHits", - "page", - "nbPages", - "hitsPerPage", - "processingTimeMS" - ], - "properties": { - "abTestID": { - "type": "integer", - "description": "A/B test ID. This is only included in the response for indices that are part of an A/B test." - }, - "abTestVariantID": { - "type": "integer", - "minimum": 1, - "description": "Variant ID. This is only included in the response for indices that are part of an A/B test." - }, - "aroundLatLng": { - "type": "string", - "description": "Computed geographical location.", - "example": "40.71,-74.01", - "pattern": "^(-?\\d+(\\.\\d+)?),\\s*(-?\\d+(\\.\\d+)?)$" - }, - "automaticRadius": { - "type": "string", - "description": "Automatically-computed radius." - }, - "exhaustive": { - "type": "object", - "title": "exhaustive", - "description": "Whether certain properties of the search response are calculated exhaustive (exact) or approximated.", - "properties": { - "facetsCount": { - "type": "boolean", - "title": "facetsCount", - "description": "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-)." - }, - "facetValues": { - "type": "boolean", - "title": "facetValues", - "description": "The value is `false` if not all facet values are retrieved." - }, - "nbHits": { - "type": "boolean", - "title": "nbHits", - "description": "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." - }, - "rulesMatch": { - "type": "boolean", - "title": "rulesMatch", - "description": "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." - }, - "typo": { - "type": "boolean", - "title": "typo", - "description": "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." - } - } - }, - "exhaustiveFacetsCount": { - "type": "boolean", - "description": "See the `facetsCount` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveNbHits": { - "type": "boolean", - "description": "See the `nbHits` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "exhaustiveTypo": { - "type": "boolean", - "description": "See the `typo` field of the `exhaustive` object in the response.", - "deprecated": true - }, - "facets": { - "title": "facets", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "integer" - } - }, - "description": "Mapping of each facet name to the corresponding facet counts.", - "example": { - "category": { - "food": 1, - "tech": 42 - } - } - }, - "facets_stats": { - "title": "facetsStats", - "type": "object", - "description": "Statistics for numerical facets.", - "additionalProperties": { - "type": "object", - "title": "facetStats", - "properties": { - "min": { - "type": "number", - "format": "double", - "description": "Minimum value in the results." - }, - "max": { - "type": "number", - "format": "double", - "description": "Maximum value in the results." - }, - "avg": { - "type": "number", - "format": "double", - "description": "Average facet value in the results." - }, - "sum": { - "type": "number", - "format": "double", - "description": "Sum of all values in the results." - } - } - } - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "index": { - "type": "string", - "example": "indexName", - "description": "Index name used for the query." - }, - "indexUsed": { - "type": "string", - "description": "Index name used for the query. During A/B testing, the targeted index isn't always the index used by the query.", - "example": "indexNameAlt" - }, - "message": { - "type": "string", - "description": "Warnings about the query." - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "nbPages": { - "type": "integer", - "description": "Number of pages of results for the current query.", - "example": 1 - }, - "nbSortedHits": { - "type": "integer", - "description": "Number of hits selected and sorted by the relevant sort algorithm.", - "example": 20 - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "parsedQuery": { - "type": "string", - "description": "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.", - "example": "george clo" - }, - "processingTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "processingTimingsMS": { - "type": "object", - "description": "Experimental. List of processing steps and their times, in milliseconds. You can use this list to investigate performance issues." - }, - "queryAfterRemoval": { - "type": "string", - "description": "Markup text indicating which parts of the original query have been removed to retrieve a non-empty result set." - }, - "redirect": { - "title": "redirect", - "type": "object", - "description": "[Redirect results to a URL](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/redirects/).\n", - "properties": { - "index": { - "type": "array", - "items": { - "type": "object", - "properties": { - "source": { - "type": "string", - "description": "Source index for the redirect rule." - }, - "dest": { - "type": "string", - "description": "Destination index for the redirect rule." - }, - "reason": { - "type": "string", - "description": "Reason for the redirect rule." - }, - "succeed": { - "type": "boolean", - "description": "Redirect rule status." - }, - "data": { - "type": "object", - "description": "Redirect rule data.", - "required": [ - "ruleObjectID" - ], - "properties": { - "ruleObjectID": { - "type": "string" - } - } - } - }, - "required": [ - "data", - "succeed", - "reason", - "dest", - "source" - ] - } - } - } - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "serverTimeMS": { - "type": "integer", - "description": "Time the server took to process the request, in milliseconds.", - "example": 20 - }, - "serverUsed": { - "type": "string", - "description": "Host name of the server that processed the request.", - "example": "c2-uk-3.algolia.net" - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": true, - "properties": { - "hits": { - "type": "array", - "items": { - "type": "object", - "description": "A single hit.", - "x-is-generic": true, - "additionalProperties": true, - "required": [ - "objectID" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "_highlightResult": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "_snippetResult": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - }, - { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - }, - { - "type": "array", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "items": { - "type": "object", - "description": "Snippeted attributes show parts of the matched attributes. Only returned when attributesToSnippet is non-empty.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - } - }, - "required": [ - "value", - "matchLevel" - ] - } - } - ] - } - }, - "_rankingInfo": { - "type": "object", - "additionalProperties": false, - "properties": { - "filters": { - "type": "integer", - "description": "This field is reserved for advanced usage." - }, - "firstMatchedWord": { - "type": "integer", - "description": "Position of the most important matched attribute in the attributes to index list." - }, - "geoDistance": { - "type": "integer", - "description": "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)." - }, - "geoPrecision": { - "type": "integer", - "description": "Precision used when computing the geo distance, in meters." - }, - "matchedGeoLocation": { - "type": "object", - "properties": { - "lat": { - "type": "number", - "format": "double", - "description": "Latitude of the matched location." - }, - "lng": { - "type": "number", - "format": "double", - "description": "Longitude of the matched location." - }, - "distance": { - "type": "integer", - "description": "Distance between the matched location and the search location (in meters)." - } - } - }, - "personalization": { - "type": "object", - "properties": { - "filtersScore": { - "type": "integer", - "description": "The score of the filters." - }, - "rankingScore": { - "type": "integer", - "description": "The score of the ranking." - }, - "score": { - "type": "integer", - "description": "The score of the event." - } - } - }, - "nbExactWords": { - "type": "integer", - "description": "Number of exactly matched words." - }, - "nbTypos": { - "type": "integer", - "description": "Number of typos encountered when matching the record." - }, - "promoted": { - "type": "boolean", - "description": "Present and set to true if a Rule promoted the hit." - }, - "proximityDistance": { - "type": "integer", - "description": "When the query contains more than one word, the sum of the distances between matched words (in meters)." - }, - "userScore": { - "type": "integer", - "description": "Custom ranking for the object, expressed as a single integer value." - }, - "words": { - "type": "integer", - "description": "Number of matched words, including prefixes and typos." - }, - "promotedByReRanking": { - "type": "boolean", - "description": "Wether the record are promoted by the re-ranking strategy." - } - }, - "required": [ - "promoted", - "nbTypos", - "firstMatchedWord", - "geoDistance", - "nbExactWords", - "words", - "filters", - "userScore" - ] - }, - "_distinctSeqID": { - "type": "integer" - } - } - } - }, - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "params": { - "type": "string", - "description": "URL-encoded string of all search parameters.", - "example": "query=a&hitsPerPage=20" - } - }, - "required": [ - "hits", - "query", - "params" - ] - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "cursor": { - "type": "string", - "description": "Cursor indicating the location to resume browsing from. Must match the value returned by the previous call.\nPass this value to the subsequent browse call to get the next page of results.\nWhen the end of the index has been reached, `cursor` is absent from the response.\n", - "example": "jMDY3M2MwM2QwMWUxMmQwYWI0ZTN" - } - } - } - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}": { - "post": { - "tags": [ - "Records" - ], - "operationId": "saveObject", - "x-acl": [ - "addObject" - ], - "description": "Add a record (object) to an index or replace it.\nIf the record doesn't contain an `objectID`, Algolia automatically adds it.\nIf you use an existing `objectID`, the existing record is replaced with the new one.\nTo add multiple records to your index in a single API request, use the [`batch` operation](#tag/Records/operation/batch).\n", - "summary": "Add or update a record.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - } - ], - "requestBody": { - "required": true, - "description": "The Algolia record.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { - "title": "saveObjectResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "createdAt": { - "type": "string", - "description": "Date of creation (ISO-8601 format).", - "example": "2023-06-29T15:15:40.747Z" - }, - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - }, - "required": [ - "taskID", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "Indices" - ], - "operationId": "deleteIndex", - "x-acl": [ - "deleteIndex" - ], - "summary": "Delete index.", - "description": "Delete an existing index.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "deletedAtResponse", - "description": "Response, taskID, and deletion timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "deletedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "deletedAt": { - "type": "string", - "example": "2023-06-27T14:42:38.831Z", - "description": "Timestamp of deletion in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/{objectID}": { - "get": { - "tags": [ - "Records" - ], - "operationId": "getObject", - "x-acl": [ - "search" - ], - "summary": "Get a record.", - "description": "To get more than one record, use the [`objects` operation](#tag/Records/operation/getObjects).", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "name": "objectID", - "in": "path", - "description": "Unique record (object) identifier.", - "required": true, - "schema": { - "type": "string", - "example": "123" - } - }, - { - "name": "attributesToRetrieve", - "in": "query", - "description": "Attributes to include with the records in the response. This is useful to reduce the size of the API response. By default, all retrievable attributes are returned.\n`objectID` is always retrieved, even when not specified.\n[`unretrievableAttributes`](https://www.algolia.com/doc/api-reference/api-parameters/unretrievableAttributes/) won't be retrieved unless the request is authenticated with the admin API key.\n", - "schema": { - "type": "array", - "items": { - "type": "string" - } - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getObjectResponse", - "type": "object", - "description": "Fetched object.", - "additionalProperties": { - "type": "string", - "description": "Value of the attribute to be updated." - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "tags": [ - "Records" - ], - "operationId": "addOrUpdateObject", - "x-acl": [ - "addObject" - ], - "summary": "Add or update a record (using objectID).", - "description": "If you use an existing `objectID`, the existing record will be replaced with the new one.\n\nTo update only some attributes of an existing record, use the [`partial` operation](#tag/Records/operation/partialUpdateObject) instead.\n\nTo add multiple records to your index in a single API request, use the [`batch` operation](#tag/Records/operation/batch).\n", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "name": "objectID", - "in": "path", - "description": "Unique record (object) identifier.", - "required": true, - "schema": { - "type": "string", - "example": "123" - } - } - ], - "requestBody": { - "required": true, - "description": "Algolia record.", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtWithObjectIdResponse", - "description": "Response, taskID, unique object identifier, and an update timestamp.", - "additionalProperties": false, - "type": "object", - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "Records" - ], - "operationId": "deleteObject", - "x-acl": [ - "deleteObject" - ], - "summary": "Delete a record.", - "description": "To delete a set of records matching a query, use the [`deleteByQuery` operation](#tag/Records/operation/deleteBy) instead.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "name": "objectID", - "in": "path", - "description": "Unique record (object) identifier.", - "required": true, - "schema": { - "type": "string", - "example": "123" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "deletedAtResponse", - "description": "Response, taskID, and deletion timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "deletedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "deletedAt": { - "type": "string", - "example": "2023-06-27T14:42:38.831Z", - "description": "Timestamp of deletion in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/deleteByQuery": { - "post": { - "tags": [ - "Records" - ], - "operationId": "deleteBy", - "x-acl": [ - "deleteIndex" - ], - "summary": "Delete all records matching a query.", - "description": "This operation doesn't support all the query options, only its filters (numeric, facet, or tag) and geo queries.\nIt doesn't accept empty filters or queries.\n", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "deletedAtResponse", - "description": "Response, taskID, and deletion timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "deletedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "deletedAt": { - "type": "string", - "example": "2023-06-27T14:42:38.831Z", - "description": "Timestamp of deletion in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/clear": { - "post": { - "tags": [ - "Records" - ], - "operationId": "clearObjects", - "x-acl": [ - "deleteIndex" - ], - "summary": "Delete all records from an index.", - "description": "Delete the records but leave settings and index-specific API keys untouched.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtResponse", - "description": "Response, taskID, and update timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "updatedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/{objectID}/partial": { - "post": { - "tags": [ - "Records" - ], - "operationId": "partialUpdateObject", - "x-acl": [ - "addObject" - ], - "summary": "Update record attributes.", - "x-codegen-request-body-name": "attributesToUpdate", - "description": "Add new attributes or update current ones in an existing record.\nYou can use any first-level attribute but not nested attributes. If you specify a [nested attribute](https://www.algolia.com/doc/guides/sending-and-managing-data/prepare-your-data/how-to/creating-and-using-nested-attributes/), the engine treats it as a replacement for its first-level ancestor.\n", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "name": "objectID", - "in": "path", - "description": "Unique record (object) identifier.", - "required": true, - "schema": { - "type": "string", - "example": "123" - } - }, - { - "name": "createIfNotExists", - "description": "Indicates whether to create a new record if it doesn't exist yet.\n", - "in": "query", - "schema": { - "type": "boolean", - "default": true - } - } - ], - "requestBody": { - "required": true, - "description": "Object with attributes to update.", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "Attributes to update.", - "additionalProperties": { - "oneOf": [ - { - "type": "string", - "description": "Value of the attribute to be updated." - }, - { - "type": "object", - "description": "To update an attribute without pushing the entire record, you can use these built-in operations.", - "additionalProperties": false, - "properties": { - "_operation": { - "type": "string", - "enum": [ - "Increment", - "Decrement", - "Add", - "Remove", - "AddUnique", - "IncrementFrom", - "IncrementSet" - ], - "description": "Operation to apply to the attribute." - }, - "value": { - "type": "string", - "description": "Value that corresponds to the operation, for example an `Increment` or `Decrement` step, `Add` or `Remove` value." - } - }, - "required": [ - "_operation", - "value" - ] - } - ] - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtWithObjectIdResponse", - "description": "Response, taskID, unique object identifier, and an update timestamp.", - "additionalProperties": false, - "type": "object", - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/batch": { - "post": { - "tags": [ - "Records" - ], - "operationId": "batch", - "summary": "Batch write operations on one index.", - "description": "To reduce the time spent on network round trips, you can perform several write actions in a single API call. Actions are applied in the order they are specified.\nThe supported `action`s are equivalent to the individual operations of the same name.\n", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "title": "batchWriteParams", - "description": "Batch parameters.", - "type": "object", - "additionalProperties": false, - "properties": { - "requests": { - "type": "array", - "items": { - "title": "batchRequest", - "type": "object", - "additionalProperties": false, - "properties": { - "action": { - "type": "string", - "enum": [ - "addObject", - "updateObject", - "partialUpdateObject", - "partialUpdateObjectNoCreate", - "deleteObject", - "delete", - "clear" - ], - "description": "Type of batch operation." - }, - "body": { - "type": "object", - "description": "Operation arguments (varies with specified `action`).", - "example": { - "name": "Betty Jane McCamey", - "company": "Vita Foods Inc.", - "email": "betty@mccamey.com" - } - } - }, - "required": [ - "action", - "body" - ] - } - } - }, - "required": [ - "requests" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "batchResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "objectIDs": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "record-1", - "record-2" - ], - "description": "Unique object (record) identifiers." - } - }, - "required": [ - "taskID", - "objectIDs" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/*/batch": { - "post": { - "tags": [ - "Records" - ], - "operationId": "multipleBatch", - "description": "To reduce the time spent on network round trips, you can perform several write actions in a single request. It's a multi-index version of the [`batch` operation](#tag/Records/operation/batch). Actions are applied in the order they are specified.\nThe supported actions are equivalent to the individual operations of the same name.\n", - "summary": "Batch write operations on multiple indices.", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "title": "batchParams", - "description": "Batch parameters.", - "type": "object", - "additionalProperties": false, - "properties": { - "requests": { - "type": "array", - "items": { - "title": "multipleBatchRequest", - "type": "object", - "additionalProperties": false, - "properties": { - "action": { - "type": "string", - "enum": [ - "addObject", - "updateObject", - "partialUpdateObject", - "partialUpdateObjectNoCreate", - "deleteObject", - "delete", - "clear" - ], - "description": "Type of batch operation." - }, - "body": { - "type": "object", - "description": "Operation arguments (varies with specified `action`).", - "example": "{'requests':[{'action':'addObject','indexName':'contacts','body':{'name':'Betty Jane McCamey','company':'Vita Foods Inc.','email':'betty@mccamey.com'}},{'action':'addObject','indexName':'public_contacts','body':{'name':'Gayla Geimer','company': \"Ortman McCain Co','email':'gayla@geimer.com'}}]}\n" - }, - "indexName": { - "type": "string", - "description": "Index to target for this operation.", - "example": "index1" - } - }, - "required": [ - "action", - "body", - "indexName" - ] - } - } - }, - "required": [ - "requests" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "multipleBatchResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "taskID": { - "type": "object", - "description": "TaskIDs per index.", - "additionalProperties": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - } - }, - "objectIDs": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "record-1", - "record-2" - ], - "description": "Unique object (record) identifiers." - } - }, - "required": [ - "taskID", - "objectIDs" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/*/objects": { - "post": { - "tags": [ - "Records" - ], - "operationId": "getObjects", - "x-use-read-transporter": true, - "x-cacheable": true, - "x-acl": [ - "search" - ], - "summary": "Get multiple records.", - "description": "Retrieve one or more records, potentially from different indices, in a single API operation. Results will be received in the same order as the requests.\n", - "requestBody": { - "required": true, - "description": "Request object.", - "content": { - "application/json": { - "schema": { - "title": "getObjectsParams", - "description": "Request parameters.", - "type": "object", - "additionalProperties": false, - "properties": { - "requests": { - "type": "array", - "items": { - "description": "Record retrieval operation.", - "title": "getObjectsRequest", - "type": "object", - "additionalProperties": false, - "required": [ - "objectID", - "indexName" - ], - "properties": { - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to retrieve. If not specified, all retrievable attributes are returned.", - "example": [ - "author", - "title", - "content" - ] - }, - "objectID": { - "type": "string", - "description": "Record's objectID.", - "example": "8b9b7619230b1950f653b962fb0dfd6b" - }, - "indexName": { - "type": "string", - "description": "Name of the index containing the required records.", - "example": "books" - } - } - } - } - }, - "required": [ - "requests" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getObjectsResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "results": { - "type": "array", - "description": "Retrieved results.", - "items": { - "type": "object", - "description": "Fetched object.", - "x-is-generic": true - } - } - }, - "required": [ - "results" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/settings": { - "get": { - "tags": [ - "Indices" - ], - "operationId": "getSettings", - "x-acl": [ - "search" - ], - "description": "Return an object containing an index's [configuration settings](https://www.algolia.com/doc/api-reference/settings-api-parameters/).", - "summary": "Get index settings.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "description": "Algolia index settings.", - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "replicas": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "virtual(prod_products_price_asc)", - "dev_products_replica" - ], - "description": "Creates [replicas](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/in-depth/replicas/), which are copies of a primary index with the same records but different settings.", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "paginationLimitedTo": { - "type": "integer", - "example": 20, - "description": "Maximum number of hits accessible through pagination.", - "default": 1000 - }, - "unretrievableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "popularity" - ], - "description": "Attributes that can't be retrieved at query time.", - "default": [], - "x-categories": [ - "Attributes" - ] - }, - "disableTypoToleranceOnWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "wheel", - "1X2BCD" - ], - "description": "Words for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "attributesToTransliterate": { - "description": "Attributes in your index to which [Japanese transliteration](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#japanese-transliteration-and-type-ahead) applies. This will ensure that words indexed in Katakana or Kanji can also be searched in Hiragana.", - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "name", - "description" - ], - "x-categories": [ - "Languages" - ] - }, - "camelCaseAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "Attributes on which to split [camel case](https://wikipedia.org/wiki/Camel_case) words.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundedAttributes": { - "type": "object", - "example": { - "de": [ - "name" - ] - }, - "description": "Attributes in your index to which [word segmentation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-segmentation/) (decompounding) applies.", - "default": {}, - "x-categories": [ - "Languages" - ] - }, - "indexLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "ja" - ], - "description": "Set the languages of your index, for language-specific processing steps such as [tokenization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/tokenization/) and [normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "disablePrefixOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [prefix matching](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#adjusting-prefix-search).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "allowCompressionOfIntegerArray": { - "type": "boolean", - "description": "Incidates whether the engine compresses arrays with exclusively non-negative integers.\nWhen enabled, the compressed arrays may be reordered.\n", - "default": false, - "x-categories": [ - "Performance" - ] - }, - "numericAttributesForFiltering": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Numeric attributes that can be used as [numerical filters](https://www.algolia.com/doc/guides/managing-results/rules/detecting-intent/how-to/applying-a-custom-filter-for-a-specific-query/#numerical-filters).", - "example": [ - "quantity", - "popularity" - ], - "default": [], - "x-categories": [ - "Performance" - ] - }, - "separatorsToIndex": { - "type": "string", - "example": "+#", - "description": "Controls which separators are added to an Algolia index as part of [normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/#what-does-normalization-mean). Separators are all non-letter characters except spaces and currency characters, such as $€£¥.", - "default": "", - "x-categories": [ - "Typos" - ] - }, - "searchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title,alternative_title", - "author", - "unordered(text)", - "emails.personal" - ], - "description": "[Attributes used for searching](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/), including determining [if matches at the beginning of a word are important (ordered) or not (unordered)](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/how-to/configuring-searchable-attributes-the-right-way/#understanding-word-position).\n", - "default": [], - "x-categories": [ - "Attributes" - ] - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - }, - "customNormalization": { - "description": "A list of characters and their normalized replacements to override Algolia's default [normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "type": "object", - "example": "{default: {'ä': 'ae', 'ü': 'ue'}}\n", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "x-categories": [ - "Languages" - ] - }, - "attributeForDistinct": { - "description": "Name of the deduplication attribute to be used with Algolia's [_distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature).", - "example": "url", - "type": "string" - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "tags": [ - "Indices" - ], - "operationId": "setSettings", - "x-acl": [ - "editSettings" - ], - "description": "Update the specified [index settings](https://www.algolia.com/doc/api-reference/settings-api-parameters/). Specifying null for a setting resets it to its default value.", - "summary": "Update index settings.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "in": "query", - "name": "forwardToReplicas", - "description": "Indicates whether changed index settings are forwarded to the replica indices.", - "schema": { - "type": "boolean" - } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "description": "Algolia index settings.", - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "replicas": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "virtual(prod_products_price_asc)", - "dev_products_replica" - ], - "description": "Creates [replicas](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/in-depth/replicas/), which are copies of a primary index with the same records but different settings.", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "paginationLimitedTo": { - "type": "integer", - "example": 20, - "description": "Maximum number of hits accessible through pagination.", - "default": 1000 - }, - "unretrievableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "popularity" - ], - "description": "Attributes that can't be retrieved at query time.", - "default": [], - "x-categories": [ - "Attributes" - ] - }, - "disableTypoToleranceOnWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "wheel", - "1X2BCD" - ], - "description": "Words for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "attributesToTransliterate": { - "description": "Attributes in your index to which [Japanese transliteration](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#japanese-transliteration-and-type-ahead) applies. This will ensure that words indexed in Katakana or Kanji can also be searched in Hiragana.", - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "name", - "description" - ], - "x-categories": [ - "Languages" - ] - }, - "camelCaseAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "Attributes on which to split [camel case](https://wikipedia.org/wiki/Camel_case) words.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundedAttributes": { - "type": "object", - "example": { - "de": [ - "name" - ] - }, - "description": "Attributes in your index to which [word segmentation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-segmentation/) (decompounding) applies.", - "default": {}, - "x-categories": [ - "Languages" - ] - }, - "indexLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "ja" - ], - "description": "Set the languages of your index, for language-specific processing steps such as [tokenization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/tokenization/) and [normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "disablePrefixOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [prefix matching](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#adjusting-prefix-search).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "allowCompressionOfIntegerArray": { - "type": "boolean", - "description": "Incidates whether the engine compresses arrays with exclusively non-negative integers.\nWhen enabled, the compressed arrays may be reordered.\n", - "default": false, - "x-categories": [ - "Performance" - ] - }, - "numericAttributesForFiltering": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Numeric attributes that can be used as [numerical filters](https://www.algolia.com/doc/guides/managing-results/rules/detecting-intent/how-to/applying-a-custom-filter-for-a-specific-query/#numerical-filters).", - "example": [ - "quantity", - "popularity" - ], - "default": [], - "x-categories": [ - "Performance" - ] - }, - "separatorsToIndex": { - "type": "string", - "example": "+#", - "description": "Controls which separators are added to an Algolia index as part of [normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/#what-does-normalization-mean). Separators are all non-letter characters except spaces and currency characters, such as $€£¥.", - "default": "", - "x-categories": [ - "Typos" - ] - }, - "searchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title,alternative_title", - "author", - "unordered(text)", - "emails.personal" - ], - "description": "[Attributes used for searching](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/), including determining [if matches at the beginning of a word are important (ordered) or not (unordered)](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/how-to/configuring-searchable-attributes-the-right-way/#understanding-word-position).\n", - "default": [], - "x-categories": [ - "Attributes" - ] - }, - "userData": { - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - }, - "description": "Lets you store custom data in your indices.", - "default": {}, - "x-categories": [ - "Advanced" - ] - }, - "customNormalization": { - "description": "A list of characters and their normalized replacements to override Algolia's default [normalization](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "type": "object", - "example": "{default: {'ä': 'ae', 'ü': 'ue'}}\n", - "additionalProperties": { - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "x-categories": [ - "Languages" - ] - }, - "attributeForDistinct": { - "description": "Name of the deduplication attribute to be used with Algolia's [_distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature).", - "example": "url", - "type": "string" - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - } - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtResponse", - "description": "Response, taskID, and update timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "updatedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/synonyms/{objectID}": { - "get": { - "tags": [ - "Synonyms" - ], - "operationId": "getSynonym", - "x-acl": [ - "settings" - ], - "summary": "Get a synonym object.", - "description": "Get a syonym by its `objectID`. To find the object IDs for your synonyms, use the [`search` operation](#tag/Synonyms/operation/searchSynonyms).", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "name": "objectID", - "in": "path", - "description": "Unique identifier of a synonym object.", - "required": true, - "schema": { - "type": "string", - "example": "synonymID" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "Synonym object.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier of a synonym object.", - "example": "synonymID" - }, - "type": { - "type": "string", - "description": "Synonym type.", - "example": "onewaysynonym", - "enum": [ - "synonym", - "onewaysynonym", - "altcorrection1", - "altcorrection2", - "placeholder" - ] - }, - "synonyms": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words or phrases considered equivalent.", - "example": [ - "vehicle", - "auto" - ] - }, - "input": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`onewaysynonym`s](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/one-way-synonyms/)).", - "example": "car" - }, - "word": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`altcorrection1` and `altcorrection2`](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-alternative-corrections/)).", - "example": "car" - }, - "corrections": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words to be matched in records.", - "example": [ - "vehicle", - "auto" - ] - }, - "placeholder": { - "type": "string", - "description": "[Placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/) to be put inside records.\n", - "example": "" - }, - "replacements": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Query words that will match the [placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/).", - "example": [ - "street", - "st" - ] - } - }, - "required": [ - "objectID", - "type" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "tags": [ - "Synonyms" - ], - "operationId": "saveSynonym", - "x-acl": [ - "editSettings" - ], - "summary": "Save a synonym.", - "description": "Add a [synonym](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/#the-different-types-of-synonyms) to an index or replace it.\nIf the synonym `objectID` doesn't exist, Algolia adds a new one.\nIf you use an existing synonym `objectID`, the existing synonym is replaced with the new one.\nTo add multiple synonyms in a single API request, use the [`batch` operation](#tag/Synonyms/operation/saveSynonyms).\n", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "name": "objectID", - "in": "path", - "description": "Unique identifier of a synonym object.", - "required": true, - "schema": { - "type": "string", - "example": "synonymID" - } - }, - { - "in": "query", - "name": "forwardToReplicas", - "description": "Indicates whether changed index settings are forwarded to the replica indices.", - "schema": { - "type": "boolean" - } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "Synonym object.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier of a synonym object.", - "example": "synonymID" - }, - "type": { - "type": "string", - "description": "Synonym type.", - "example": "onewaysynonym", - "enum": [ - "synonym", - "onewaysynonym", - "altcorrection1", - "altcorrection2", - "placeholder" - ] - }, - "synonyms": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words or phrases considered equivalent.", - "example": [ - "vehicle", - "auto" - ] - }, - "input": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`onewaysynonym`s](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/one-way-synonyms/)).", - "example": "car" - }, - "word": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`altcorrection1` and `altcorrection2`](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-alternative-corrections/)).", - "example": "car" - }, - "corrections": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words to be matched in records.", - "example": [ - "vehicle", - "auto" - ] - }, - "placeholder": { - "type": "string", - "description": "[Placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/) to be put inside records.\n", - "example": "" - }, - "replacements": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Query words that will match the [placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/).", - "example": [ - "street", - "st" - ] - } - }, - "required": [ - "objectID", - "type" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "saveSynonymResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "id": { - "type": "string", - "example": "12", - "description": "Unique identifier of a synonym object." - } - }, - "required": [ - "taskID", - "updatedAt", - "id" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "Synonyms" - ], - "operationId": "deleteSynonym", - "x-acl": [ - "editSettings" - ], - "summary": "Delete a synonym.", - "description": "Delete a synonym by its `objectID`. To find the object IDs of your synonyms, use the [`search` operation](#tag/Synonyms/operation/searchSynonyms).", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "name": "objectID", - "in": "path", - "description": "Unique identifier of a synonym object.", - "required": true, - "schema": { - "type": "string", - "example": "synonymID" - } - }, - { - "in": "query", - "name": "forwardToReplicas", - "description": "Indicates whether changed index settings are forwarded to the replica indices.", - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "deletedAtResponse", - "description": "Response, taskID, and deletion timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "deletedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "deletedAt": { - "type": "string", - "example": "2023-06-27T14:42:38.831Z", - "description": "Timestamp of deletion in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/synonyms/batch": { - "post": { - "tags": [ - "Synonyms" - ], - "operationId": "saveSynonyms", - "x-acl": [ - "editSettings" - ], - "summary": "Save a batch of synonyms.", - "description": "Create or update multiple synonyms.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "in": "query", - "name": "forwardToReplicas", - "description": "Indicates whether changed index settings are forwarded to the replica indices.", - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "replaceExistingSynonyms", - "schema": { - "type": "boolean" - }, - "description": "Indicates whether to replace all synonyms in the index with the ones sent with this request." - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "array", - "description": "Synonym objects.", - "items": { - "type": "object", - "description": "Synonym object.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier of a synonym object.", - "example": "synonymID" - }, - "type": { - "type": "string", - "description": "Synonym type.", - "example": "onewaysynonym", - "enum": [ - "synonym", - "onewaysynonym", - "altcorrection1", - "altcorrection2", - "placeholder" - ] - }, - "synonyms": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words or phrases considered equivalent.", - "example": [ - "vehicle", - "auto" - ] - }, - "input": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`onewaysynonym`s](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/one-way-synonyms/)).", - "example": "car" - }, - "word": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`altcorrection1` and `altcorrection2`](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-alternative-corrections/)).", - "example": "car" - }, - "corrections": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words to be matched in records.", - "example": [ - "vehicle", - "auto" - ] - }, - "placeholder": { - "type": "string", - "description": "[Placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/) to be put inside records.\n", - "example": "" - }, - "replacements": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Query words that will match the [placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/).", - "example": [ - "street", - "st" - ] - } - }, - "required": [ - "objectID", - "type" - ] - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtResponse", - "description": "Response, taskID, and update timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "updatedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/synonyms/clear": { - "post": { - "tags": [ - "Synonyms" - ], - "operationId": "clearSynonyms", - "x-acl": [ - "editSettings" - ], - "summary": "Delete all synonyms.", - "description": "Delete all synonyms in the index.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "in": "query", - "name": "forwardToReplicas", - "description": "Indicates whether changed index settings are forwarded to the replica indices.", - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtResponse", - "description": "Response, taskID, and update timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "updatedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/synonyms/search": { - "post": { - "tags": [ - "Synonyms" - ], - "operationId": "searchSynonyms", - "x-use-read-transporter": true, - "x-cacheable": true, - "x-acl": [ - "settings" - ], - "summary": "Search for synonyms.", - "description": "Search for synonyms in your index. You can control and filter the search with parameters. To get all synonyms, send an empty request body.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - } - ], - "requestBody": { - "description": "Body of the `searchSynonyms` operation.", - "content": { - "application/json": { - "schema": { - "title": "searchSynonymsParams", - "type": "object", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "type": { - "type": "string", - "description": "Synonym type.", - "example": "onewaysynonym", - "enum": [ - "synonym", - "onewaysynonym", - "altcorrection1", - "altcorrection2", - "placeholder" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": true, - "properties": { - "hits": { - "type": "array", - "description": "Synonym objects.", - "items": { - "type": "object", - "description": "Synonym object.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier of a synonym object.", - "example": "synonymID" - }, - "type": { - "type": "string", - "description": "Synonym type.", - "example": "onewaysynonym", - "enum": [ - "synonym", - "onewaysynonym", - "altcorrection1", - "altcorrection2", - "placeholder" - ] - }, - "synonyms": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words or phrases considered equivalent.", - "example": [ - "vehicle", - "auto" - ] - }, - "input": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`onewaysynonym`s](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/one-way-synonyms/)).", - "example": "car" - }, - "word": { - "type": "string", - "description": "Word or phrase to appear in query strings (for [`altcorrection1` and `altcorrection2`](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-alternative-corrections/)).", - "example": "car" - }, - "corrections": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Words to be matched in records.", - "example": [ - "vehicle", - "auto" - ] - }, - "placeholder": { - "type": "string", - "description": "[Placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/) to be put inside records.\n", - "example": "" - }, - "replacements": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Query words that will match the [placeholder token](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/in-depth/synonyms-placeholders/).", - "example": [ - "street", - "st" - ] - } - }, - "required": [ - "objectID", - "type" - ] - } - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - } - }, - "required": [ - "hits", - "nbHits" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/keys": { - "get": { - "tags": [ - "Api Keys" - ], - "operationId": "listApiKeys", - "x-acl": [ - "admin" - ], - "summary": "List API keys.", - "description": "List all API keys associated with your Algolia application, including their permissions and restrictions.", - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "listApiKeysResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "keys" - ], - "properties": { - "keys": { - "type": "array", - "description": "API keys.", - "items": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "API key.", - "example": "13ad45b4d0a2f6ea65ecbddf6aa260f2" - }, - "createdAt": { - "type": "integer", - "format": "int64", - "example": 1656345570000, - "description": "Timestamp of creation in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time)." - } - }, - "required": [ - "key", - "createdAt" - ] - }, - { - "type": "object", - "description": "API key object.", - "additionalProperties": false, - "properties": { - "acl": { - "type": "array", - "description": "[Permissions](https://www.algolia.com/doc/guides/security/api-keys/#access-control-list-acl) associated with the key.\n", - "example": [ - "search", - "addObject" - ], - "default": [], - "items": { - "description": "API key permissions:\n\n`addObject`: required to add or update records, copy or move an index.\n`analytics`: required to access the Analytics API.\n`browse`: required to view records\n`deleteIndex`: required to delete indices.\n`deleteObject`: required to delete records.\n`editSettings`: required to change index settings.\n`inference`: required to access the Inference API.\n`listIndexes`: required to list indices.\n`logs`: required to access logs of search and indexing operations.\n`recommendation`: required to access the Personalization and Recommend APIs.\n`search`: required to search records\n`seeUnretrievableAttributes`: required to retrieve [`unretrievableAttributes`](https://www.algolia.com/doc/api-reference/api-parameters/unretrievableAttributes/) for all operations that return records.\n`settings`: required to examine index settings.\n", - "type": "string", - "enum": [ - "addObject", - "analytics", - "browse", - "deleteObject", - "deleteIndex", - "editSettings", - "inference", - "listIndexes", - "logs", - "personalization", - "recommendation", - "search", - "seeUnretrievableAttributes", - "settings", - "usage" - ] - } - }, - "description": { - "type": "string", - "description": "Description of an API key for you and your team members.", - "example": "Browse-restricted key", - "default": "" - }, - "indexes": { - "type": "array", - "description": "Restricts this API key to a list of indices or index patterns. If the list is empty, all indices are allowed.\nSpecify either an exact index name or a pattern with a leading or trailing wildcard character (or both). For example:\n- `dev_*` matches all indices starting with \"dev_\" - `*_dev` matches all indices ending with \"_dev\" - `*_products_*` matches all indices containing \"_products_\".\n", - "example": [ - "dev_*", - "prod_products" - ], - "default": [], - "items": { - "type": "string" - } - }, - "maxHitsPerQuery": { - "type": "integer", - "description": "Maximum number of hits this API key can retrieve in one query. If zero, no limit is enforced.\n> **Note**: Use this parameter to protect you from third-party attempts to retrieve your entire content by massively querying the index.\n", - "default": 0 - }, - "maxQueriesPerIPPerHour": { - "type": "integer", - "description": "Maximum number of API calls per hour allowed from a given IP address or [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/).\nEach time an API call is performed with this key, a check is performed. If there were more than the specified number of calls within the last hour, the API returns an error with the status code `429` (Too Many Requests).\n\n> **Note**: Use this parameter to protect you from third-party attempts to retrieve your entire content by massively querying the index.\n", - "default": 0 - }, - "queryParameters": { - "type": "string", - "description": "Force some [query parameters](https://www.algolia.com/doc/api-reference/api-parameters/) to be applied for each query made with this API key.\nIt's a URL-encoded query string.\n", - "example": "typoTolerance%3Dstrict%26ignorePlurals%3Dfalse%26filters%3Drights%3Apublic", - "default": "" - }, - "referers": { - "type": "array", - "description": "Restrict this API key to specific [referrers](https://www.algolia.com/doc/guides/security/api-keys/in-depth/api-key-restrictions/#http-referrers). If empty, all referrers are allowed.\nFor example:\n- `https://algolia.com/*` matches all referrers starting with \"https://algolia.com/\" - `*.algolia.com` matches all referrers ending with \".algolia.com\" - `*algolia.com*` allows everything in the domain \"algolia.com\".\n", - "example": [ - "*algolia.com*" - ], - "default": [], - "items": { - "type": "string" - } - }, - "validity": { - "type": "integer", - "description": "Validity duration of a key (in seconds). The key will automatically be removed after this time has expired. The default value of 0 never expires.\nShort-lived API keys are useful to grant temporary access to your data. For example, in mobile apps, you can't [control when users update your app](https://www.algolia.com/doc/guides/security/security-best-practices/#use-secured-api-keys-in-mobile-apps). So instead of encoding keys into your app as you would for a web app, you should dynamically fetch them from your mobile app's backend.\n", - "example": 86400, - "default": 0 - } - }, - "required": [ - "acl" - ] - } - ] - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "post": { - "tags": [ - "Api Keys" - ], - "operationId": "addApiKey", - "x-acl": [ - "admin" - ], - "summary": "Add API key.", - "description": "Add a new API key with specific permissions and restrictions.\nThe request must be authenticated with the admin API key.\nThe response returns an API key string.\n", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "API key object.", - "additionalProperties": false, - "properties": { - "acl": { - "type": "array", - "description": "[Permissions](https://www.algolia.com/doc/guides/security/api-keys/#access-control-list-acl) associated with the key.\n", - "example": [ - "search", - "addObject" - ], - "default": [], - "items": { - "description": "API key permissions:\n\n`addObject`: required to add or update records, copy or move an index.\n`analytics`: required to access the Analytics API.\n`browse`: required to view records\n`deleteIndex`: required to delete indices.\n`deleteObject`: required to delete records.\n`editSettings`: required to change index settings.\n`inference`: required to access the Inference API.\n`listIndexes`: required to list indices.\n`logs`: required to access logs of search and indexing operations.\n`recommendation`: required to access the Personalization and Recommend APIs.\n`search`: required to search records\n`seeUnretrievableAttributes`: required to retrieve [`unretrievableAttributes`](https://www.algolia.com/doc/api-reference/api-parameters/unretrievableAttributes/) for all operations that return records.\n`settings`: required to examine index settings.\n", - "type": "string", - "enum": [ - "addObject", - "analytics", - "browse", - "deleteObject", - "deleteIndex", - "editSettings", - "inference", - "listIndexes", - "logs", - "personalization", - "recommendation", - "search", - "seeUnretrievableAttributes", - "settings", - "usage" - ] - } - }, - "description": { - "type": "string", - "description": "Description of an API key for you and your team members.", - "example": "Browse-restricted key", - "default": "" - }, - "indexes": { - "type": "array", - "description": "Restricts this API key to a list of indices or index patterns. If the list is empty, all indices are allowed.\nSpecify either an exact index name or a pattern with a leading or trailing wildcard character (or both). For example:\n- `dev_*` matches all indices starting with \"dev_\" - `*_dev` matches all indices ending with \"_dev\" - `*_products_*` matches all indices containing \"_products_\".\n", - "example": [ - "dev_*", - "prod_products" - ], - "default": [], - "items": { - "type": "string" - } - }, - "maxHitsPerQuery": { - "type": "integer", - "description": "Maximum number of hits this API key can retrieve in one query. If zero, no limit is enforced.\n> **Note**: Use this parameter to protect you from third-party attempts to retrieve your entire content by massively querying the index.\n", - "default": 0 - }, - "maxQueriesPerIPPerHour": { - "type": "integer", - "description": "Maximum number of API calls per hour allowed from a given IP address or [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/).\nEach time an API call is performed with this key, a check is performed. If there were more than the specified number of calls within the last hour, the API returns an error with the status code `429` (Too Many Requests).\n\n> **Note**: Use this parameter to protect you from third-party attempts to retrieve your entire content by massively querying the index.\n", - "default": 0 - }, - "queryParameters": { - "type": "string", - "description": "Force some [query parameters](https://www.algolia.com/doc/api-reference/api-parameters/) to be applied for each query made with this API key.\nIt's a URL-encoded query string.\n", - "example": "typoTolerance%3Dstrict%26ignorePlurals%3Dfalse%26filters%3Drights%3Apublic", - "default": "" - }, - "referers": { - "type": "array", - "description": "Restrict this API key to specific [referrers](https://www.algolia.com/doc/guides/security/api-keys/in-depth/api-key-restrictions/#http-referrers). If empty, all referrers are allowed.\nFor example:\n- `https://algolia.com/*` matches all referrers starting with \"https://algolia.com/\" - `*.algolia.com` matches all referrers ending with \".algolia.com\" - `*algolia.com*` allows everything in the domain \"algolia.com\".\n", - "example": [ - "*algolia.com*" - ], - "default": [], - "items": { - "type": "string" - } - }, - "validity": { - "type": "integer", - "description": "Validity duration of a key (in seconds). The key will automatically be removed after this time has expired. The default value of 0 never expires.\nShort-lived API keys are useful to grant temporary access to your data. For example, in mobile apps, you can't [control when users update your app](https://www.algolia.com/doc/guides/security/security-best-practices/#use-secured-api-keys-in-mobile-apps). So instead of encoding keys into your app as you would for a web app, you should dynamically fetch them from your mobile app's backend.\n", - "example": 86400, - "default": 0 - } - }, - "required": [ - "acl" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "key": { - "type": "string", - "description": "API key.", - "example": "13ad45b4d0a2f6ea65ecbddf6aa260f2" - }, - "createdAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of creation in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format." - } - }, - "required": [ - "key", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/keys/{key}": { - "get": { - "tags": [ - "Api Keys" - ], - "operationId": "getApiKey", - "summary": "Get API key permissions.", - "description": "Get the permissions and restrictions of a specific API key.\nWhen authenticating with the admin API key, you can request information for any of your application's keys. When authenticating with other API keys, you can only retrieve information for that key.\n", - "parameters": [ - { - "in": "path", - "name": "key", - "required": true, - "schema": { - "type": "string", - "example": "YourAPIKey" - }, - "description": "API key." - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "API key.", - "example": "13ad45b4d0a2f6ea65ecbddf6aa260f2" - }, - "createdAt": { - "type": "integer", - "format": "int64", - "example": 1656345570000, - "description": "Timestamp of creation in milliseconds in [Unix epoch time](https://wikipedia.org/wiki/Unix_time)." - } - }, - "required": [ - "key", - "createdAt" - ] - }, - { - "type": "object", - "description": "API key object.", - "additionalProperties": false, - "properties": { - "acl": { - "type": "array", - "description": "[Permissions](https://www.algolia.com/doc/guides/security/api-keys/#access-control-list-acl) associated with the key.\n", - "example": [ - "search", - "addObject" - ], - "default": [], - "items": { - "description": "API key permissions:\n\n`addObject`: required to add or update records, copy or move an index.\n`analytics`: required to access the Analytics API.\n`browse`: required to view records\n`deleteIndex`: required to delete indices.\n`deleteObject`: required to delete records.\n`editSettings`: required to change index settings.\n`inference`: required to access the Inference API.\n`listIndexes`: required to list indices.\n`logs`: required to access logs of search and indexing operations.\n`recommendation`: required to access the Personalization and Recommend APIs.\n`search`: required to search records\n`seeUnretrievableAttributes`: required to retrieve [`unretrievableAttributes`](https://www.algolia.com/doc/api-reference/api-parameters/unretrievableAttributes/) for all operations that return records.\n`settings`: required to examine index settings.\n", - "type": "string", - "enum": [ - "addObject", - "analytics", - "browse", - "deleteObject", - "deleteIndex", - "editSettings", - "inference", - "listIndexes", - "logs", - "personalization", - "recommendation", - "search", - "seeUnretrievableAttributes", - "settings", - "usage" - ] - } - }, - "description": { - "type": "string", - "description": "Description of an API key for you and your team members.", - "example": "Browse-restricted key", - "default": "" - }, - "indexes": { - "type": "array", - "description": "Restricts this API key to a list of indices or index patterns. If the list is empty, all indices are allowed.\nSpecify either an exact index name or a pattern with a leading or trailing wildcard character (or both). For example:\n- `dev_*` matches all indices starting with \"dev_\" - `*_dev` matches all indices ending with \"_dev\" - `*_products_*` matches all indices containing \"_products_\".\n", - "example": [ - "dev_*", - "prod_products" - ], - "default": [], - "items": { - "type": "string" - } - }, - "maxHitsPerQuery": { - "type": "integer", - "description": "Maximum number of hits this API key can retrieve in one query. If zero, no limit is enforced.\n> **Note**: Use this parameter to protect you from third-party attempts to retrieve your entire content by massively querying the index.\n", - "default": 0 - }, - "maxQueriesPerIPPerHour": { - "type": "integer", - "description": "Maximum number of API calls per hour allowed from a given IP address or [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/).\nEach time an API call is performed with this key, a check is performed. If there were more than the specified number of calls within the last hour, the API returns an error with the status code `429` (Too Many Requests).\n\n> **Note**: Use this parameter to protect you from third-party attempts to retrieve your entire content by massively querying the index.\n", - "default": 0 - }, - "queryParameters": { - "type": "string", - "description": "Force some [query parameters](https://www.algolia.com/doc/api-reference/api-parameters/) to be applied for each query made with this API key.\nIt's a URL-encoded query string.\n", - "example": "typoTolerance%3Dstrict%26ignorePlurals%3Dfalse%26filters%3Drights%3Apublic", - "default": "" - }, - "referers": { - "type": "array", - "description": "Restrict this API key to specific [referrers](https://www.algolia.com/doc/guides/security/api-keys/in-depth/api-key-restrictions/#http-referrers). If empty, all referrers are allowed.\nFor example:\n- `https://algolia.com/*` matches all referrers starting with \"https://algolia.com/\" - `*.algolia.com` matches all referrers ending with \".algolia.com\" - `*algolia.com*` allows everything in the domain \"algolia.com\".\n", - "example": [ - "*algolia.com*" - ], - "default": [], - "items": { - "type": "string" - } - }, - "validity": { - "type": "integer", - "description": "Validity duration of a key (in seconds). The key will automatically be removed after this time has expired. The default value of 0 never expires.\nShort-lived API keys are useful to grant temporary access to your data. For example, in mobile apps, you can't [control when users update your app](https://www.algolia.com/doc/guides/security/security-best-practices/#use-secured-api-keys-in-mobile-apps). So instead of encoding keys into your app as you would for a web app, you should dynamically fetch them from your mobile app's backend.\n", - "example": 86400, - "default": 0 - } - }, - "required": [ - "acl" - ] - } - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "tags": [ - "Api Keys" - ], - "operationId": "updateApiKey", - "x-acl": [ - "admin" - ], - "summary": "Update an API key.", - "description": "Replace the permissions of an existing API key.\nAny unspecified parameter resets that permission to its default value.\nThe request must be authenticated with the admin API key.\n", - "parameters": [ - { - "in": "path", - "name": "key", - "required": true, - "schema": { - "type": "string", - "example": "YourAPIKey" - }, - "description": "API key." - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "API key object.", - "additionalProperties": false, - "properties": { - "acl": { - "type": "array", - "description": "[Permissions](https://www.algolia.com/doc/guides/security/api-keys/#access-control-list-acl) associated with the key.\n", - "example": [ - "search", - "addObject" - ], - "default": [], - "items": { - "description": "API key permissions:\n\n`addObject`: required to add or update records, copy or move an index.\n`analytics`: required to access the Analytics API.\n`browse`: required to view records\n`deleteIndex`: required to delete indices.\n`deleteObject`: required to delete records.\n`editSettings`: required to change index settings.\n`inference`: required to access the Inference API.\n`listIndexes`: required to list indices.\n`logs`: required to access logs of search and indexing operations.\n`recommendation`: required to access the Personalization and Recommend APIs.\n`search`: required to search records\n`seeUnretrievableAttributes`: required to retrieve [`unretrievableAttributes`](https://www.algolia.com/doc/api-reference/api-parameters/unretrievableAttributes/) for all operations that return records.\n`settings`: required to examine index settings.\n", - "type": "string", - "enum": [ - "addObject", - "analytics", - "browse", - "deleteObject", - "deleteIndex", - "editSettings", - "inference", - "listIndexes", - "logs", - "personalization", - "recommendation", - "search", - "seeUnretrievableAttributes", - "settings", - "usage" - ] - } - }, - "description": { - "type": "string", - "description": "Description of an API key for you and your team members.", - "example": "Browse-restricted key", - "default": "" - }, - "indexes": { - "type": "array", - "description": "Restricts this API key to a list of indices or index patterns. If the list is empty, all indices are allowed.\nSpecify either an exact index name or a pattern with a leading or trailing wildcard character (or both). For example:\n- `dev_*` matches all indices starting with \"dev_\" - `*_dev` matches all indices ending with \"_dev\" - `*_products_*` matches all indices containing \"_products_\".\n", - "example": [ - "dev_*", - "prod_products" - ], - "default": [], - "items": { - "type": "string" - } - }, - "maxHitsPerQuery": { - "type": "integer", - "description": "Maximum number of hits this API key can retrieve in one query. If zero, no limit is enforced.\n> **Note**: Use this parameter to protect you from third-party attempts to retrieve your entire content by massively querying the index.\n", - "default": 0 - }, - "maxQueriesPerIPPerHour": { - "type": "integer", - "description": "Maximum number of API calls per hour allowed from a given IP address or [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/).\nEach time an API call is performed with this key, a check is performed. If there were more than the specified number of calls within the last hour, the API returns an error with the status code `429` (Too Many Requests).\n\n> **Note**: Use this parameter to protect you from third-party attempts to retrieve your entire content by massively querying the index.\n", - "default": 0 - }, - "queryParameters": { - "type": "string", - "description": "Force some [query parameters](https://www.algolia.com/doc/api-reference/api-parameters/) to be applied for each query made with this API key.\nIt's a URL-encoded query string.\n", - "example": "typoTolerance%3Dstrict%26ignorePlurals%3Dfalse%26filters%3Drights%3Apublic", - "default": "" - }, - "referers": { - "type": "array", - "description": "Restrict this API key to specific [referrers](https://www.algolia.com/doc/guides/security/api-keys/in-depth/api-key-restrictions/#http-referrers). If empty, all referrers are allowed.\nFor example:\n- `https://algolia.com/*` matches all referrers starting with \"https://algolia.com/\" - `*.algolia.com` matches all referrers ending with \".algolia.com\" - `*algolia.com*` allows everything in the domain \"algolia.com\".\n", - "example": [ - "*algolia.com*" - ], - "default": [], - "items": { - "type": "string" - } - }, - "validity": { - "type": "integer", - "description": "Validity duration of a key (in seconds). The key will automatically be removed after this time has expired. The default value of 0 never expires.\nShort-lived API keys are useful to grant temporary access to your data. For example, in mobile apps, you can't [control when users update your app](https://www.algolia.com/doc/guides/security/security-best-practices/#use-secured-api-keys-in-mobile-apps). So instead of encoding keys into your app as you would for a web app, you should dynamically fetch them from your mobile app's backend.\n", - "example": 86400, - "default": 0 - } - }, - "required": [ - "acl" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updateApiKeyResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "key", - "updatedAt" - ], - "properties": { - "key": { - "type": "string", - "description": "API key.", - "example": "13ad45b4d0a2f6ea65ecbddf6aa260f2" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "Api Keys" - ], - "operationId": "deleteApiKey", - "x-acl": [ - "admin" - ], - "summary": "Delete API key.", - "description": "Delete an existing API key.\nThe request must be authenticated with the admin API key.\n", - "parameters": [ - { - "in": "path", - "name": "key", - "required": true, - "schema": { - "type": "string", - "example": "YourAPIKey" - }, - "description": "API key." - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "deleteApiKeyResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "deletedAt" - ], - "properties": { - "deletedAt": { - "type": "string", - "example": "2023-06-27T14:42:38.831Z", - "description": "Timestamp of deletion in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/keys/{key}/restore": { - "post": { - "tags": [ - "Api Keys" - ], - "operationId": "restoreApiKey", - "x-acl": [ - "admin" - ], - "summary": "Restore API key.", - "description": "Restore a deleted API key, along with its associated permissions.\nThe request must be authenticated with the admin API key.\n", - "parameters": [ - { - "in": "path", - "name": "key", - "required": true, - "schema": { - "type": "string", - "example": "YourAPIKey" - }, - "description": "API key." - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "key": { - "type": "string", - "description": "API key.", - "example": "13ad45b4d0a2f6ea65ecbddf6aa260f2" - }, - "createdAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of creation in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format." - } - }, - "required": [ - "key", - "createdAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/rules/{objectID}": { - "get": { - "tags": [ - "Rules" - ], - "operationId": "getRule", - "x-acl": [ - "settings" - ], - "summary": "Get a rule.", - "description": "Get a rule by its `objectID`. To find the `objectID` for rules, use the [`search` operation](#tag/Rules/operation/searchRules).", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "in": "path", - "name": "objectID", - "description": "Unique identifier of a rule object.", - "example": "a-rule-id", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "Rule object.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier for a rule object.", - "example": "hide-12345" - }, - "conditions": { - "type": "array", - "description": "[Conditions](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#conditions) required to activate a rule. You can use up to 25 conditions per rule.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "pattern": { - "type": "string", - "description": "Query pattern syntax.", - "example": "{facet:brand}" - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "alternatives": { - "type": "boolean", - "description": "Whether the pattern matches on plurals, synonyms, and typos.", - "default": false - }, - "context": { - "type": "string", - "description": "Rule context format: [A-Za-z0-9_-]+).", - "example": "trackedFilters" - } - } - } - }, - "consequence": { - "type": "object", - "description": "[Consequences](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#consequences) of a rule.\n", - "additionalProperties": false, - "properties": { - "params": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "promote": { - "type": "array", - "description": "Records to promote.", - "items": { - "oneOf": [ - { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - } - ] - } - }, - "filterPromotes": { - "type": "boolean", - "default": false, - "description": "Only use in combination with the `promote` consequence. When `true`, promoted results will be restricted to match the filters of the current search. When `false`, the promoted results will show up regardless of the filters." - }, - "hide": { - "type": "array", - "description": "Records to hide. By default, you can hide up to 50 records per rule.", - "items": { - "title": "consequenceHide", - "type": "object", - "description": "Unique identifier of the record to hide.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - }, - "required": [ - "objectID" - ] - } - }, - "userData": { - "description": "Custom JSON object that will be appended to the userData array in the response. This object isn't interpreted by the API. It's limited to 1kB of minified JSON.", - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - } - } - } - }, - "description": { - "type": "string", - "description": "Description of the rule's purpose. This can be helpful for display in the Algolia dashboard.", - "example": "Display a promotional banner" - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Indicates whether to enable the rule. If it isn't enabled, it isn't applied at query time." - }, - "validity": { - "type": "array", - "description": "If you specify a validity period, the rule _only_ applies only during that period. If specified, the array must not be empty.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "from": { - "type": "integer", - "description": "Lower bound of the time range (Unix timestamp)." - }, - "until": { - "type": "integer", - "description": "Upper bound of the time range (Unix timestamp)." - } - }, - "required": [ - "from", - "until" - ] - } - } - }, - "required": [ - "objectID" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "tags": [ - "Rules" - ], - "operationId": "saveRule", - "x-acl": [ - "editSettings" - ], - "summary": "Create or update a rule.", - "description": "To create or update more than one rule, use the [`batch` operation](#tag/Rules/operation/saveRules).", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "in": "path", - "name": "objectID", - "description": "Unique identifier of a rule object.", - "example": "a-rule-id", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "forwardToReplicas", - "description": "Indicates whether changed index settings are forwarded to the replica indices.", - "schema": { - "type": "boolean" - } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "object", - "description": "Rule object.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier for a rule object.", - "example": "hide-12345" - }, - "conditions": { - "type": "array", - "description": "[Conditions](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#conditions) required to activate a rule. You can use up to 25 conditions per rule.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "pattern": { - "type": "string", - "description": "Query pattern syntax.", - "example": "{facet:brand}" - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "alternatives": { - "type": "boolean", - "description": "Whether the pattern matches on plurals, synonyms, and typos.", - "default": false - }, - "context": { - "type": "string", - "description": "Rule context format: [A-Za-z0-9_-]+).", - "example": "trackedFilters" - } - } - } - }, - "consequence": { - "type": "object", - "description": "[Consequences](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#consequences) of a rule.\n", - "additionalProperties": false, - "properties": { - "params": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "promote": { - "type": "array", - "description": "Records to promote.", - "items": { - "oneOf": [ - { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - } - ] - } - }, - "filterPromotes": { - "type": "boolean", - "default": false, - "description": "Only use in combination with the `promote` consequence. When `true`, promoted results will be restricted to match the filters of the current search. When `false`, the promoted results will show up regardless of the filters." - }, - "hide": { - "type": "array", - "description": "Records to hide. By default, you can hide up to 50 records per rule.", - "items": { - "title": "consequenceHide", - "type": "object", - "description": "Unique identifier of the record to hide.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - }, - "required": [ - "objectID" - ] - } - }, - "userData": { - "description": "Custom JSON object that will be appended to the userData array in the response. This object isn't interpreted by the API. It's limited to 1kB of minified JSON.", - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - } - } - } - }, - "description": { - "type": "string", - "description": "Description of the rule's purpose. This can be helpful for display in the Algolia dashboard.", - "example": "Display a promotional banner" - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Indicates whether to enable the rule. If it isn't enabled, it isn't applied at query time." - }, - "validity": { - "type": "array", - "description": "If you specify a validity period, the rule _only_ applies only during that period. If specified, the array must not be empty.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "from": { - "type": "integer", - "description": "Lower bound of the time range (Unix timestamp)." - }, - "until": { - "type": "integer", - "description": "Upper bound of the time range (Unix timestamp)." - } - }, - "required": [ - "from", - "until" - ] - } - } - }, - "required": [ - "objectID" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - } - }, - "required": [ - "objectID", - "updatedAt", - "taskID" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "Rules" - ], - "operationId": "deleteRule", - "x-acl": [ - "editSettings" - ], - "summary": "Delete a rule.", - "description": "Delete a rule by its `objectID`. To find the `objectID` for rules, use the [`search` operation](#tag/Rules/operation/searchRules).", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "in": "path", - "name": "objectID", - "description": "Unique identifier of a rule object.", - "example": "a-rule-id", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "forwardToReplicas", - "description": "Indicates whether changed index settings are forwarded to the replica indices.", - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtResponse", - "description": "Response, taskID, and update timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "updatedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/rules/batch": { - "post": { - "tags": [ - "Rules" - ], - "operationId": "saveRules", - "x-acl": [ - "editSettings" - ], - "summary": "Save a batch of rules.", - "description": "Create or update multiple rules.", - "x-codegen-request-body-name": "rules", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "in": "query", - "name": "forwardToReplicas", - "description": "Indicates whether changed index settings are forwarded to the replica indices.", - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "clearExistingRules", - "required": false, - "schema": { - "type": "boolean" - }, - "description": "Indicates whether existing rules should be deleted before adding this batch." - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "array", - "description": "Rules to add.", - "items": { - "type": "object", - "description": "Rule object.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier for a rule object.", - "example": "hide-12345" - }, - "conditions": { - "type": "array", - "description": "[Conditions](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#conditions) required to activate a rule. You can use up to 25 conditions per rule.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "pattern": { - "type": "string", - "description": "Query pattern syntax.", - "example": "{facet:brand}" - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "alternatives": { - "type": "boolean", - "description": "Whether the pattern matches on plurals, synonyms, and typos.", - "default": false - }, - "context": { - "type": "string", - "description": "Rule context format: [A-Za-z0-9_-]+).", - "example": "trackedFilters" - } - } - } - }, - "consequence": { - "type": "object", - "description": "[Consequences](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#consequences) of a rule.\n", - "additionalProperties": false, - "properties": { - "params": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "promote": { - "type": "array", - "description": "Records to promote.", - "items": { - "oneOf": [ - { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - } - ] - } - }, - "filterPromotes": { - "type": "boolean", - "default": false, - "description": "Only use in combination with the `promote` consequence. When `true`, promoted results will be restricted to match the filters of the current search. When `false`, the promoted results will show up regardless of the filters." - }, - "hide": { - "type": "array", - "description": "Records to hide. By default, you can hide up to 50 records per rule.", - "items": { - "title": "consequenceHide", - "type": "object", - "description": "Unique identifier of the record to hide.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - }, - "required": [ - "objectID" - ] - } - }, - "userData": { - "description": "Custom JSON object that will be appended to the userData array in the response. This object isn't interpreted by the API. It's limited to 1kB of minified JSON.", - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - } - } - } - }, - "description": { - "type": "string", - "description": "Description of the rule's purpose. This can be helpful for display in the Algolia dashboard.", - "example": "Display a promotional banner" - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Indicates whether to enable the rule. If it isn't enabled, it isn't applied at query time." - }, - "validity": { - "type": "array", - "description": "If you specify a validity period, the rule _only_ applies only during that period. If specified, the array must not be empty.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "from": { - "type": "integer", - "description": "Lower bound of the time range (Unix timestamp)." - }, - "until": { - "type": "integer", - "description": "Upper bound of the time range (Unix timestamp)." - } - }, - "required": [ - "from", - "until" - ] - } - } - }, - "required": [ - "objectID" - ] - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtResponse", - "description": "Response, taskID, and update timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "updatedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/rules/clear": { - "post": { - "tags": [ - "Rules" - ], - "operationId": "clearRules", - "x-acl": [ - "editSettings" - ], - "summary": "Delete all rules.", - "description": "Delete all rules in the index.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "in": "query", - "name": "forwardToReplicas", - "description": "Indicates whether changed index settings are forwarded to the replica indices.", - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtResponse", - "description": "Response, taskID, and update timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "updatedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/rules/search": { - "post": { - "tags": [ - "Rules" - ], - "operationId": "searchRules", - "x-use-read-transporter": true, - "x-cacheable": true, - "x-acl": [ - "settings" - ], - "summary": "Search for rules.", - "description": "Search for rules in your index. You can control the search with parameters. To list all rules, send an empty request body.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "title": "searchRulesParams", - "description": "Rules search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Rule object query.", - "default": "" - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "context": { - "type": "string", - "description": "Restricts responses to the specified [contextual rule](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#creating-contextual-rules).", - "example": "mobile" - }, - "page": { - "type": "integer", - "minimum": 0, - "description": "Requested page (the first page is page 0)." - }, - "hitsPerPage": { - "type": "integer", - "default": 20, - "minimum": 1, - "maximum": 1000, - "description": "Maximum number of hits per page." - }, - "enabled": { - "type": "boolean", - "nullable": true, - "default": null, - "description": "Restricts responses to enabled rules. When not specified (default), _all_ rules are retrieved." - }, - "requestOptions": { - "type": "array", - "description": "Request options to send with the API call.", - "example": "{timeouts:{read:20}}\n", - "items": { - "type": "object", - "description": "Request option." - } - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "searchRulesResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "hits", - "nbHits", - "page", - "nbPages" - ], - "properties": { - "hits": { - "type": "array", - "description": "Fetched rules.", - "items": { - "type": "object", - "description": "Rule object.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier for a rule object.", - "example": "hide-12345" - }, - "conditions": { - "type": "array", - "description": "[Conditions](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#conditions) required to activate a rule. You can use up to 25 conditions per rule.\n", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "pattern": { - "type": "string", - "description": "Query pattern syntax.", - "example": "{facet:brand}" - }, - "anchoring": { - "type": "string", - "description": "Whether the pattern parameter matches the beginning (`startsWith`) or end (`endsWith`) of the query string, is an exact match (`is`), or a partial match (`contains`).", - "enum": [ - "is", - "startsWith", - "endsWith", - "contains" - ] - }, - "alternatives": { - "type": "boolean", - "description": "Whether the pattern matches on plurals, synonyms, and typos.", - "default": false - }, - "context": { - "type": "string", - "description": "Rule context format: [A-Za-z0-9_-]+).", - "example": "trackedFilters" - } - } - } - }, - "consequence": { - "type": "object", - "description": "[Consequences](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/#consequences) of a rule.\n", - "additionalProperties": false, - "properties": { - "params": { - "allOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "similarQuery": { - "type": "string", - "description": "Overrides the query parameter and performs a more generic search.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "filters": { - "type": "string", - "description": "[Filter](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) the query with numeric, facet, or tag filters.\n", - "example": "(category:Book OR category:Ebook) AND _tags:published", - "default": "", - "x-categories": [ - "Filtering" - ] - }, - "facetFilters": { - "description": "[Filter hits by facet value](https://www.algolia.com/doc/api-reference/api-parameters/facetFilters/).\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "optionalFilters": { - "description": "Create filters to boost or demote records. \n\nRecords that match the filter are ranked higher for positive and lower for negative optional filters. In contrast to regular filters, records that don't match the optional filter are still included in the results, only their ranking is affected.\n", - "example": [ - "category:Book", - "author:John Doe" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "numericFilters": { - "description": "[Filter on numeric attributes](https://www.algolia.com/doc/api-reference/api-parameters/numericFilters/).\n", - "example": [ - [ - "inStock = 1", - "deliveryDate < 1441755506" - ], - "price < 1000" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "tagFilters": { - "description": "[Filter hits by tags](https://www.algolia.com/doc/api-reference/api-parameters/tagFilters/).\n", - "example": [ - [ - "Book", - "Movie" - ], - "SciFi" - ], - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string" - } - ], - "x-categories": [ - "Filtering" - ] - }, - "sumOrFiltersScores": { - "type": "boolean", - "description": "Determines how to calculate [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulating-scores-with-sumorfiltersscores).\nIf `false`, maximum score is kept.\nIf `true`, score is summed.\n", - "default": false, - "x-categories": [ - "Filtering" - ] - }, - "restrictSearchableAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "title", - "author" - ], - "description": "Restricts a query to only look at a subset of your [searchable attributes](https://www.algolia.com/doc/guides/managing-results/must-do/searchable-attributes/).", - "default": [], - "x-categories": [ - "Filtering" - ] - }, - "facets": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Returns [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts), their facet values, and the number of matching facet values.", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "facetingAfterDistinct": { - "type": "boolean", - "description": "Forces faceting to be applied after [de-duplication](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/) (with the distinct feature). Alternatively, the `afterDistinct` [modifier](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) of `attributesForFaceting` allows for more granular control.\n", - "default": false, - "x-categories": [ - "Faceting" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "offset": { - "type": "integer", - "description": "Specifies the offset of the first hit to return.\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "x-categories": [ - "Pagination" - ] - }, - "length": { - "type": "integer", - "description": "Sets the number of hits to retrieve (for use with `offset`).\n> **Note**: Using `page` and `hitsPerPage` is the recommended method for [paging results](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/). However, you can use `offset` and `length` to implement [an alternative approach to paging](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/pagination/js/#retrieving-a-subset-of-records-with-offset-and-length).\n", - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "aroundLatLng": { - "type": "string", - "description": "Search for entries [around a central location](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filter-around-a-central-point), enabling a geographical search within a circular area.", - "example": "40.71,-74.01", - "default": "", - "x-categories": [ - "Geo-Search" - ] - }, - "aroundLatLngViaIP": { - "type": "boolean", - "description": "Search for entries around a location. The location is automatically computed from the requester's IP address.", - "default": false, - "x-categories": [ - "Geo-Search" - ] - }, - "aroundRadius": { - "description": "[Maximum radius](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#increase-the-search-radius) for a geographical search (in meters).\n", - "oneOf": [ - { - "type": "integer", - "minimum": 1 - }, - { - "type": "string", - "enum": [ - "all" - ] - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "aroundPrecision": { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "oneOf": [ - { - "type": "integer", - "default": 10 - }, - { - "description": "Precision of a geographical search (in meters), to [group results that are more or less the same distance from a central point](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/in-depth/geo-ranking-precision/).", - "type": "array", - "items": { - "type": "object", - "properties": { - "from": { - "type": "integer" - }, - "value": { - "type": "integer" - } - } - } - } - ], - "x-categories": [ - "Geo-Search" - ] - }, - "minimumAroundRadius": { - "type": "integer", - "description": "Minimum radius (in meters) used for a geographical search when `aroundRadius` isn't set.", - "minimum": 1, - "x-categories": [ - "Geo-Search" - ] - }, - "insideBoundingBox": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [rectangular area](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "insidePolygon": { - "type": "array", - "items": { - "type": "array", - "items": { - "type": "number", - "format": "double" - } - }, - "description": "Search inside a [polygon](https://www.algolia.com/doc/guides/managing-results/refine-results/geolocation/#filtering-inside-rectangular-or-polygonal-areas) (in geographical coordinates).", - "example": [ - [ - 47.3165, - 4.9665, - 47.3424, - 5.0201, - 47.32, - 4.9 - ], - [ - 40.9234, - 2.1185, - 38.643, - 1.9916, - 39.2587, - 2.0104 - ] - ], - "x-categories": [ - "Geo-Search" - ] - }, - "naturalLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Changes the default values of parameters that work best for a natural language query, such as `ignorePlurals`, `removeStopWords`, `removeWordsIfNoResults`, `analyticsTags`, and `ruleContexts`. These parameters work well together when the query consists of fuller natural language strings instead of keywords, for example when processing voice search queries.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "ruleContexts": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Assigns [rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#whats-a-context) to search queries.", - "default": [], - "x-categories": [ - "Rules" - ] - }, - "personalizationImpact": { - "type": "integer", - "description": "Defines how much [Personalization affects results](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).", - "default": 100, - "x-categories": [ - "Personalization" - ] - }, - "userToken": { - "type": "string", - "description": "Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.", - "example": "123456", - "x-categories": [ - "Personalization" - ] - }, - "getRankingInfo": { - "type": "boolean", - "description": "Incidates whether the search response includes [detailed ranking information](https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/understanding-the-api-response/#ranking-information).", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "explain": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Enriches the API's response with information about how the query was processed.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "synonyms": { - "type": "boolean", - "description": "Whether to take into account an index's synonyms for a particular search.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "clickAnalytics": { - "type": "boolean", - "description": "Indicates whether a query ID parameter is included in the search response. This is required for [tracking click and conversion events](https://www.algolia.com/doc/guides/sending-events/concepts/event-types/#events-related-to-algolia-requests).", - "default": false, - "x-categories": [ - "Analytics" - ] - }, - "analytics": { - "type": "boolean", - "description": "Indicates whether this query will be included in [analytics](https://www.algolia.com/doc/guides/search-analytics/guides/exclude-queries/).", - "default": true, - "x-categories": [ - "Analytics" - ] - }, - "analyticsTags": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Tags to apply to the query for [segmenting analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).", - "default": [], - "x-categories": [ - "Analytics" - ] - }, - "percentileComputation": { - "type": "boolean", - "description": "Whether to include or exclude a query from the processing-time percentile computation.", - "default": true, - "x-categories": [ - "Advanced" - ] - }, - "enableABTest": { - "type": "boolean", - "description": "Incidates whether this search will be considered in A/B testing.", - "default": true, - "x-categories": [ - "Advanced" - ] - } - } - }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "attributesForFaceting": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "filterOnly(isbn)", - "searchable(edition)", - "afterDistinct(category)", - "afterDistinct(searchable(publisher))" - ], - "description": "Attributes used for [faceting](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/) and the [modifiers](https://www.algolia.com/doc/api-reference/api-parameters/attributesForFaceting/#modifiers) that can be applied: `filterOnly`, `searchable`, and `afterDistinct`.\n", - "default": [], - "x-categories": [ - "Faceting" - ] - }, - "attributesToRetrieve": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. By default, the response includes all attributes.", - "default": [ - "*" - ], - "x-categories": [ - "Attributes" - ] - }, - "ranking": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Determines the order in which Algolia [returns your results](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/).", - "default": [ - "typo", - "geo", - "words", - "filters", - "proximity", - "attribute", - "exact", - "custom" - ], - "x-categories": [ - "Ranking" - ] - }, - "customRanking": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "desc(popularity)", - "asc(price)" - ], - "description": "Specifies the [Custom ranking criterion](https://www.algolia.com/doc/guides/managing-results/must-do/custom-ranking/). Use the `asc` and `desc` modifiers to specify the ranking order: ascending or descending.\n", - "default": [], - "x-categories": [ - "Ranking" - ] - }, - "relevancyStrictness": { - "type": "integer", - "example": 90, - "description": "Relevancy threshold below which less relevant results aren't included in the results.", - "default": 100, - "x-categories": [ - "Ranking" - ] - }, - "attributesToHighlight": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "author", - "title", - "content" - ], - "description": "Attributes to highlight. Strings that match the search query in the attributes are highlighted by surrounding them with HTML tags (`highlightPreTag` and `highlightPostTag`).", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "attributesToSnippet": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "content:80", - "description" - ], - "description": "Attributes to _snippet_. 'Snippeting' is shortening the attribute to a certain number of words. If not specified, the attribute is shortened to the 10 words around the matching string but you can specify the number. For example: `body:20`.\n", - "default": [], - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPreTag": { - "type": "string", - "description": "HTML string to insert before the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "highlightPostTag": { - "type": "string", - "description": "HTML string to insert after the highlighted parts in all highlight and snippet results.", - "default": "", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "snippetEllipsisText": { - "type": "string", - "description": "String used as an ellipsis indicator when a snippet is truncated.", - "default": "…", - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "restrictHighlightAndSnippetArrays": { - "type": "boolean", - "description": "Restrict highlighting and snippeting to items that matched the query.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "minWordSizefor1Typo": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 4, - "x-categories": [ - "Typos" - ] - }, - "minWordSizefor2Typos": { - "type": "integer", - "description": "Minimum number of characters a word in the query string 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).", - "default": 8, - "x-categories": [ - "Typos" - ] - }, - "typoTolerance": { - "description": "Controls whether [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) is enabled and how it is applied.", - "oneOf": [ - { - "type": "boolean", - "default": true - }, - { - "type": "string", - "enum": [ - "min", - "strict" - ] - } - ], - "x-categories": [ - "Typos" - ] - }, - "allowTyposOnNumericTokens": { - "type": "boolean", - "description": "Whether to allow typos on numbers (\"numeric tokens\") in the query string.", - "default": true, - "x-categories": [ - "Typos" - ] - }, - "disableTypoToleranceOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "sku" - ], - "description": "Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/).", - "default": [], - "x-categories": [ - "Typos" - ] - }, - "ignorePlurals": { - "description": "Treats singular, plurals, and other forms of declensions as matching terms.\n`ignorePlurals` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which ignoring plurals should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the ignore plurals feature, where singulars and plurals are considered equivalent (\"foot\" = \"feet\"). The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the ignore plurals feature, so that singulars and plurals aren't considered to be the same (\"foot\" will not find \"feet\").\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "removeStopWords": { - "description": "Removes stop (common) words from the query before executing it.\n`removeStopWords` is used in conjunction with the `queryLanguages` setting.\n_list_: language ISO codes for which stop words should be enabled. This list will override any values that you may have set in `queryLanguages`. _true_: enables the stop words feature, ensuring that stop words are removed from consideration in a search. The languages supported here are either [every language](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) (this is the default) or those set by `queryLanguages`. _false_: turns off the stop words feature, allowing stop words to be taken into account in a search.\n", - "example": [ - "ca", - "es" - ], - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "boolean", - "default": false - } - ], - "x-categories": [ - "Languages" - ] - }, - "keepDiacriticsOnCharacters": { - "type": "string", - "example": "øé", - "description": "Characters that the engine shouldn't automatically [normalize](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/normalization/).", - "default": "", - "x-categories": [ - "Languages" - ] - }, - "queryLanguages": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "es" - ], - "description": "Sets your user's search language. This adjusts language-specific settings and features such as `ignorePlurals`, `removeStopWords`, and [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) word detection.", - "default": [], - "x-categories": [ - "Languages" - ] - }, - "decompoundQuery": { - "type": "boolean", - "description": "[Splits compound words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words) into their component word parts in the query.\n", - "default": true, - "x-categories": [ - "Languages" - ] - }, - "enableRules": { - "type": "boolean", - "description": "Incidates whether [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/) are enabled.", - "default": true, - "x-categories": [ - "Rules" - ] - }, - "enablePersonalization": { - "type": "boolean", - "description": "Incidates whether [Personalization](https://www.algolia.com/doc/guides/personalization/what-is-personalization/) is enabled.", - "default": false, - "x-categories": [ - "Personalization" - ] - }, - "queryType": { - "type": "string", - "enum": [ - "prefixLast", - "prefixAll", - "prefixNone" - ], - "description": "Determines how query words are [interpreted as prefixes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/in-depth/prefix-searching/).", - "default": "prefixLast", - "x-categories": [ - "Query strategy" - ] - }, - "removeWordsIfNoResults": { - "type": "string", - "enum": [ - "none", - "lastWords", - "firstWords", - "allOptional" - ], - "example": "firstWords", - "description": "Strategy to [remove words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/in-depth/why-use-remove-words-if-no-results/) from the query when it doesn't match any hits.", - "default": "none", - "x-categories": [ - "Query strategy" - ] - }, - "mode": { - "type": "string", - "enum": [ - "neuralSearch", - "keywordSearch" - ], - "description": "Search mode the index will use to query for results.", - "default": "keywordSearch", - "x-categories": [ - "Query strategy" - ] - }, - "semanticSearch": { - "type": "object", - "description": "Settings for the semantic search part of NeuralSearch. Only used when `mode` is _neuralSearch_.\n", - "properties": { - "eventSources": { - "description": "Indices from which to collect click and conversion events. If null, the current index and replica group will be used as the event source.", - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "advancedSyntax": { - "type": "boolean", - "description": "Enables the [advanced query syntax](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#advanced-syntax).", - "default": false, - "x-categories": [ - "Query strategy" - ] - }, - "optionalWords": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "blue", - "iphone case" - ], - "description": "Words which should be considered [optional](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#creating-a-list-of-optional-words) when found in a query.", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "disableExactOnAttributes": { - "type": "array", - "items": { - "type": "string" - }, - "example": [ - "description" - ], - "description": "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).", - "default": [], - "x-categories": [ - "Query strategy" - ] - }, - "exactOnSingleWordQuery": { - "type": "string", - "enum": [ - "attribute", - "none", - "word" - ], - "description": "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 query contains only one word.", - "default": "attribute", - "x-categories": [ - "Query strategy" - ] - }, - "alternativesAsExact": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "ignorePlurals", - "singleWordSynonym", - "multiWordsSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Alternatives that should be considered an exact match by [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).", - "default": [ - "ignorePlurals", - "singleWordSynonym" - ], - "x-categories": [ - "Query strategy" - ] - }, - "advancedSyntaxFeatures": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "description": "Allows you to specify which advanced syntax features are active when `advancedSyntax` is enabled.", - "default": [ - "exactPhrase", - "excludeWords" - ], - "x-categories": [ - "Query strategy" - ] - }, - "distinct": { - "description": "Enables [deduplication or grouping of results (Algolia's _distinct_ feature](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#introducing-algolias-distinct-feature)).", - "example": 1, - "oneOf": [ - { - "type": "boolean" - }, - { - "type": "integer", - "minimum": 0, - "maximum": 4, - "default": 0 - } - ], - "x-categories": [ - "Advanced" - ] - }, - "replaceSynonymsInHighlight": { - "type": "boolean", - "description": "Whether to highlight and snippet the original word that matches the synonym or the synonym itself.", - "default": false, - "x-categories": [ - "Highlighting and Snippeting" - ] - }, - "minProximity": { - "type": "integer", - "minimum": 1, - "maximum": 7, - "description": "Precision of the [proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity).", - "default": 1, - "x-categories": [ - "Advanced" - ] - }, - "responseFields": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Attributes to include in the API response for search and browse queries.", - "default": [], - "x-categories": [ - "Advanced" - ] - }, - "maxFacetHits": { - "type": "integer", - "description": "Maximum number of facet hits to return when [searching for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).", - "maximum": 100, - "default": 10, - "x-categories": [ - "Advanced" - ] - }, - "maxValuesPerFacet": { - "type": "integer", - "description": "Maximum number of facet values to return for each facet.", - "default": 100, - "x-categories": [ - "Faceting" - ] - }, - "sortFacetValuesBy": { - "type": "string", - "description": "Controls how facet values are fetched.", - "default": "count", - "x-categories": [ - "Faceting" - ] - }, - "attributeCriteriaComputedByMinProximity": { - "type": "boolean", - "description": "When the [Attribute criterion is ranked above Proximity](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#attribute-and-proximity-combinations) in your ranking formula, Proximity is used to select which searchable attribute is matched in the Attribute ranking stage.", - "default": false, - "x-categories": [ - "Advanced" - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - }, - "enableReRanking": { - "type": "boolean", - "description": "Indicates whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/).", - "default": true, - "x-categories": [ - "Filtering" - ] - }, - "reRankingApplyFilter": { - "description": "When [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking/) is enabled, only records that match these filters will be affected by Dynamic Re-Ranking.", - "nullable": true, - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "type": "array", - "items": { - "type": "string" - } - }, - { - "type": "string" - } - ] - } - }, - { - "type": "string", - "x-categories": [ - "Filtering" - ] - } - ] - } - } - }, - { - "type": "object", - "description": "Additional search parameters.", - "additionalProperties": false, - "properties": { - "query": { - "description": "When providing a string, it replaces the entire query string. When providing an object, it describes incremental edits to be made to the query string (but you can't do both).", - "oneOf": [ - { - "type": "object", - "additionalProperties": false, - "properties": { - "remove": { - "description": "Words to remove.", - "type": "array", - "items": { - "type": "string" - } - }, - "edits": { - "description": "Edits to apply.", - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "type": { - "description": "Type of edit.", - "type": "string", - "enum": [ - "remove", - "replace" - ] - }, - "delete": { - "description": "Text or patterns to remove from the query string.", - "type": "string" - }, - "insert": { - "description": "Text that should be inserted in place of the removed text inside the query string.", - "type": "string" - } - } - } - } - } - }, - { - "type": "string" - } - ] - }, - "automaticFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "automaticOptionalFacetFilters": { - "description": "Names of facets to which automatic filtering must be applied; they must match the facet name of a facet value placeholder in the query pattern.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "description": "Automatic facet Filter.", - "additionalProperties": false, - "properties": { - "facet": { - "type": "string", - "description": "Attribute to filter on. This must match a facet placeholder in the Rule's pattern." - }, - "score": { - "type": "integer", - "default": 1, - "description": "Score for the filter. Typically used for optional or disjunctive filters." - }, - "disjunctive": { - "type": "boolean", - "default": false, - "description": "Whether the filter is disjunctive (true) or conjunctive (false)." - } - }, - "required": [ - "facet" - ] - } - }, - { - "type": "array", - "items": { - "type": "string" - } - } - ] - }, - "renderingContent": { - "description": "Extra content for the search UI, for example, to control the [ordering and display of facets](https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/merchandising-facets/#merchandise-facets-and-their-values-in-the-manual-editor). You can set a default value and dynamically override it with [Rules](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/).", - "type": "object", - "additionalProperties": false, - "properties": { - "facetOrdering": { - "description": "Defines the ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "facets": { - "description": "Ordering of facets (widgets).", - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "values": { - "description": "Ordering of facet values within an individual facet.", - "type": "object", - "additionalProperties": { - "type": "object", - "additionalProperties": false, - "properties": { - "order": { - "description": "Pinned order of facet lists.", - "type": "array", - "items": { - "type": "string" - } - }, - "sortRemainingBy": { - "description": "How to display the remaining items:\n\n - `count`: facet count (descending).\n - `alpha`: alphabetical (ascending).\n - `hidden`: show only pinned values.\n", - "type": "string", - "enum": [ - "count", - "alpha", - "hidden" - ] - } - } - } - } - } - } - }, - "x-categories": [ - "Advanced" - ] - } - } - } - ] - }, - "promote": { - "type": "array", - "description": "Records to promote.", - "items": { - "oneOf": [ - { - "description": "Records to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectIDs": { - "type": "array", - "description": "Unique identifiers of the records to promote.", - "example": [ - "3f31c087763a2ceec359b318fc3edef3", - "63c3c871e31a152d67df7720192fd752" - ], - "items": { - "type": "string" - } - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectIDs" - ] - }, - { - "description": "Record to promote.", - "type": "object", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "example": "2b642cf64c587f50388eb1b8d047bf56", - "description": "Unique identifier of the record to promote." - }, - "position": { - "type": "integer", - "description": "The position to promote the records to. If you pass objectIDs, the records are placed at this position as a group. For example, if you pronmote four objectIDs to position 0, the records take the first four positions.", - "example": 0 - } - }, - "required": [ - "position", - "objectID" - ] - } - ] - } - }, - "filterPromotes": { - "type": "boolean", - "default": false, - "description": "Only use in combination with the `promote` consequence. When `true`, promoted results will be restricted to match the filters of the current search. When `false`, the promoted results will show up regardless of the filters." - }, - "hide": { - "type": "array", - "description": "Records to hide. By default, you can hide up to 50 records per rule.", - "items": { - "title": "consequenceHide", - "type": "object", - "description": "Unique identifier of the record to hide.", - "additionalProperties": false, - "properties": { - "objectID": { - "type": "string", - "description": "Unique object identifier.", - "example": "product-1" - } - }, - "required": [ - "objectID" - ] - } - }, - "userData": { - "description": "Custom JSON object that will be appended to the userData array in the response. This object isn't interpreted by the API. It's limited to 1kB of minified JSON.", - "example": { - "settingID": "f2a7b51e3503acc6a39b3784ffb84300", - "pluginVersion": "1.6.0" - } - } - } - }, - "description": { - "type": "string", - "description": "Description of the rule's purpose. This can be helpful for display in the Algolia dashboard.", - "example": "Display a promotional banner" - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Indicates whether to enable the rule. If it isn't enabled, it isn't applied at query time." - }, - "validity": { - "type": "array", - "description": "If you specify a validity period, the rule _only_ applies only during that period. If specified, the array must not be empty.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "from": { - "type": "integer", - "description": "Lower bound of the time range (Unix timestamp)." - }, - "until": { - "type": "integer", - "description": "Upper bound of the time range (Unix timestamp)." - } - }, - "required": [ - "from", - "until" - ] - } - } - }, - "required": [ - "objectID" - ] - } - }, - "nbHits": { - "type": "integer", - "description": "Number of fetched rules." - }, - "page": { - "type": "integer", - "description": "Current page." - }, - "nbPages": { - "type": "integer", - "description": "Number of pages." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/dictionaries/{dictionaryName}/batch": { - "post": { - "tags": [ - "Dictionaries" - ], - "operationId": "batchDictionaryEntries", - "x-acl": [ - "editSettings" - ], - "description": "Add or remove a batch of dictionary entries.", - "summary": "Batch dictionary entries.", - "parameters": [ - { - "in": "path", - "name": "dictionaryName", - "description": "Dictionary to search in.", - "required": true, - "schema": { - "type": "string", - "enum": [ - "plurals", - "stopwords", - "compounds" - ] - } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "title": "batchDictionaryEntriesParams", - "description": "`batchDictionaryEntries` parameters.\n", - "type": "object", - "required": [ - "requests" - ], - "additionalProperties": false, - "properties": { - "clearExistingDictionaryEntries": { - "type": "boolean", - "default": false, - "description": "Incidates whether to replace all custom entries in the dictionary with the ones sent with this request." - }, - "requests": { - "type": "array", - "description": "Operations to batch.", - "items": { - "title": "batchDictionaryEntriesRequest", - "type": "object", - "additionalProperties": false, - "required": [ - "action", - "body" - ], - "properties": { - "action": { - "type": "string", - "enum": [ - "addEntry", - "deleteEntry" - ], - "description": "Actions to perform." - }, - "body": { - "type": "object", - "description": "Dictionary entry.", - "additionalProperties": true, - "required": [ - "objectID", - "language" - ], - "properties": { - "objectID": { - "type": "string", - "description": "Unique identifier for a dictionary object.", - "example": "under" - }, - "language": { - "type": "string", - "description": "[Supported language ISO code](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/).\n", - "example": "de" - }, - "word": { - "type": "string", - "description": "Dictionary entry word. Usage depends on the type of dictionary entry.\n**`stopwordEntry`**\nThe stop word you want to add or update. If the entry already exists in Algolia's standard dictionary, you can override its behavior by adding it to the custom dictionary and setting its `state` to `disabled`.\n**`compoundEntry`**\nWhen `decomposition` is empty: adds `word` as a compound atom. For example, atom “kino” decomposes the query “kopfkino” into \"kopf\" and \"kino\".\nWhen `decomposition` isn't empty: creates a decomposition exception. For example, when decomposition is set to the [\"hund\", \"hutte\"] exception, \"hundehutte\" decomposes into “hund” and “hutte”, discarding the linking \"e\".\n", - "example": "down" - }, - "words": { - "type": "array", - "description": "Compound dictionary [word declensions](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-plurals-and-other-declensions/).\nIf the entry already exists in Algolia's standard dictionary, you can override its behavior by adding it to the custom dictionary and setting its `state` to `disabled`.\n", - "example": [ - "cheval", - "chevaux" - ], - "items": { - "type": "string" - } - }, - "decomposition": { - "type": "array", - "description": "For compound entries, governs the behavior of the `word` parameter.", - "example": [ - "kopf", - "schmerz", - "tablette" - ], - "items": { - "type": "string" - } - }, - "state": { - "type": "string", - "enum": [ - "enabled", - "disabled" - ], - "default": "enabled", - "description": "Indicates whether a dictionary entry is active (`enabled`) or inactive (`disabled`)." - } - } - } - } - } - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtResponse", - "description": "Response, taskID, and update timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "updatedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/dictionaries/{dictionaryName}/search": { - "post": { - "tags": [ - "Dictionaries" - ], - "operationId": "searchDictionaryEntries", - "x-use-read-transporter": true, - "x-cacheable": true, - "x-acl": [ - "settings" - ], - "description": "Search for standard and [custom](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-stop-words/) entries in the [stop words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-stop-words/), [plurals](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-plurals-and-other-declensions/), or [segmentation (compounds)](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-segmentation/) dictionaries.", - "summary": "Search dictionary entries.", - "parameters": [ - { - "in": "path", - "name": "dictionaryName", - "description": "Dictionary to search in.", - "required": true, - "schema": { - "type": "string", - "enum": [ - "plurals", - "stopwords", - "compounds" - ] - } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "title": "searchDictionaryEntriesParams", - "description": "`searchDictionaryEntries` parameters.\n", - "type": "object", - "required": [ - "query" - ], - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Text to search for in an index.", - "default": "", - "x-categories": [ - "Search" - ] - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - }, - "language": { - "description": "[Supported language ISO code](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/).\n", - "example": "en", - "type": "string" - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtResponse", - "description": "Response, taskID, and update timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "updatedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/dictionaries/*/settings": { - "get": { - "tags": [ - "Dictionaries" - ], - "operationId": "getDictionarySettings", - "x-acl": [ - "settings" - ], - "description": "Get the languages for which [stop words are turned off](#tag/Dictionaries/operation/setDictionarySettings).", - "summary": "Get stop word settings.", - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getDictionarySettingsResponse", - "additionalProperties": false, - "type": "object", - "required": [ - "disableStandardEntries" - ], - "properties": { - "disableStandardEntries": { - "description": "Key-value pairs of [supported language ISO codes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) and boolean values.\n", - "additionalProperties": false, - "properties": { - "plurals": { - "description": "Key-value pair of a language ISO code and a boolean value.", - "example": "{'fr': false}\n", - "type": "object", - "nullable": true, - "additionalProperties": { - "type": "boolean" - } - }, - "stopwords": { - "description": "Key-value pair of a language ISO code and a boolean value.", - "example": "{'fr': false}\n", - "type": "object", - "nullable": true, - "additionalProperties": { - "type": "boolean" - } - }, - "compounds": { - "description": "Key-value pair of a language ISO code and a boolean value.", - "example": "{'fr': false}\n", - "type": "object", - "nullable": true, - "additionalProperties": { - "type": "boolean" - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "tags": [ - "Dictionaries" - ], - "operationId": "setDictionarySettings", - "x-acl": [ - "editSettings" - ], - "description": "Set stop word settings for a specific language.", - "summary": "Set stop word settings.", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "title": "dictionarySettingsParams", - "type": "object", - "additionalProperties": false, - "description": "Enable or turn off the built-in Algolia stop words for a specific language.", - "required": [ - "disableStandardEntries" - ], - "properties": { - "disableStandardEntries": { - "description": "Key-value pairs of [supported language ISO codes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) and boolean values.\n", - "additionalProperties": false, - "properties": { - "plurals": { - "description": "Key-value pair of a language ISO code and a boolean value.", - "example": "{'fr': false}\n", - "type": "object", - "nullable": true, - "additionalProperties": { - "type": "boolean" - } - }, - "stopwords": { - "description": "Key-value pair of a language ISO code and a boolean value.", - "example": "{'fr': false}\n", - "type": "object", - "nullable": true, - "additionalProperties": { - "type": "boolean" - } - }, - "compounds": { - "description": "Key-value pair of a language ISO code and a boolean value.", - "example": "{'fr': false}\n", - "type": "object", - "nullable": true, - "additionalProperties": { - "type": "boolean" - } - } - } - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtResponse", - "description": "Response, taskID, and update timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "updatedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/dictionaries/*/languages": { - "get": { - "tags": [ - "Dictionaries" - ], - "operationId": "getDictionaryLanguages", - "x-acl": [ - "settings" - ], - "description": "Lists Algolia's [supported languages](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) and any customizations applied to each language's [stop word](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-stop-words/), [plural](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-plurals-and-other-declensions/), and [segmentation (compound)](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-segmentation/) features.", - "summary": "List available languages.", - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getDictionaryLanguagesResponse", - "type": "object", - "additionalProperties": { - "type": "object", - "description": "Dictionary language.", - "additionalProperties": false, - "required": [ - "plurals", - "stopwords", - "compounds" - ], - "properties": { - "plurals": { - "type": "object", - "additionalProperties": false, - "nullable": true, - "description": "Custom entries for a dictionary.", - "properties": { - "nbCustomEntries": { - "description": "If `0`, the dictionary hasn't been customized and only contains standard entries provided by Algolia.\nIf `null`, that feature isn't available or isn't supported for that language.\n", - "type": "integer" - } - } - }, - "stopwords": { - "type": "object", - "additionalProperties": false, - "nullable": true, - "description": "Custom entries for a dictionary.", - "properties": { - "nbCustomEntries": { - "description": "If `0`, the dictionary hasn't been customized and only contains standard entries provided by Algolia.\nIf `null`, that feature isn't available or isn't supported for that language.\n", - "type": "integer" - } - } - }, - "compounds": { - "type": "object", - "additionalProperties": false, - "nullable": true, - "description": "Custom entries for a dictionary.", - "properties": { - "nbCustomEntries": { - "description": "If `0`, the dictionary hasn't been customized and only contains standard entries provided by Algolia.\nIf `null`, that feature isn't available or isn't supported for that language.\n", - "type": "integer" - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/clusters/mapping": { - "post": { - "tags": [ - "Clusters" - ], - "operationId": "assignUserId", - "x-acl": [ - "admin" - ], - "summary": "Assign or move a user ID.", - "description": "Assign or move a user ID to a cluster.\nThe time it takes to move a user is proportional to the amount of data linked to the user ID.\n", - "parameters": [ - { - "name": "X-Algolia-User-ID", - "description": "userID to assign.", - "in": "header", - "required": true, - "schema": { - "type": "string", - "pattern": "^[a-zA-Z0-9 \\-*.]+$" - } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "title": "assignUserIdParams", - "type": "object", - "description": "Assign userID parameters.", - "additionalProperties": false, - "properties": { - "cluster": { - "type": "string", - "description": "Cluster name.", - "example": "c11-test" - } - }, - "required": [ - "cluster" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "createdAtResponse", - "description": "Response and creation timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "createdAt" - ], - "properties": { - "createdAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of creation in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "get": { - "tags": [ - "Clusters" - ], - "operationId": "listUserIds", - "x-acl": [ - "admin" - ], - "summary": "List userIDs.", - "description": "List the userIDs assigned to a multi-cluster application.\nSince it can take up to a few seconds to get the data from the different clusters, the response isn't real-time.\n", - "parameters": [ - { - "in": "query", - "name": "page", - "description": "Returns the requested page number. The page size is determined by the `hitsPerPage` parameter. You can see the number of available pages in the `nbPages` response attribute. When `page` is null, the API response is not paginated.\n", - "schema": { - "type": "integer", - "minimum": 0, - "nullable": true, - "default": null - } - }, - { - "in": "query", - "name": "hitsPerPage", - "description": "Maximum number of hits per page.", - "schema": { - "type": "integer", - "default": 100 - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "listUserIdsResponse", - "type": "object", - "description": "User ID data.", - "properties": { - "userIDs": { - "type": "array", - "description": "User IDs.", - "items": { - "title": "userID", - "type": "object", - "description": "Unique user ID.", - "properties": { - "userID": { - "type": "string", - "pattern": "^[a-zA-Z0-9 \\-*.]+$", - "description": "userID of the user.", - "example": "user1" - }, - "clusterName": { - "type": "string", - "description": "Cluster to which the user is assigned.", - "example": "c1-test" - }, - "nbRecords": { - "type": "integer", - "description": "Number of records belonging to the user.", - "example": 42 - }, - "dataSize": { - "type": "integer", - "description": "Data size used by the user.", - "example": 0 - } - }, - "required": [ - "userID", - "clusterName", - "nbRecords", - "dataSize" - ] - } - } - }, - "required": [ - "userIDs" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/clusters/mapping/batch": { - "post": { - "tags": [ - "Clusters" - ], - "operationId": "batchAssignUserIds", - "x-acl": [ - "admin" - ], - "summary": "Batch assign userIDs.", - "description": "Assign multiple user IDs to a cluster.\n**You can't _move_ users with this operation.**.\n", - "parameters": [ - { - "name": "X-Algolia-User-ID", - "description": "userID to assign.", - "in": "header", - "required": true, - "schema": { - "type": "string", - "pattern": "^[a-zA-Z0-9 \\-*.]+$" - } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "title": "batchAssignUserIdsParams", - "type": "object", - "description": "Assign userID parameters.", - "additionalProperties": false, - "properties": { - "cluster": { - "type": "string", - "description": "Cluster name.", - "example": "c11-test" - }, - "users": { - "type": "array", - "description": "User IDs to assign.", - "example": [ - "einstein", - "bohr", - "feynman" - ], - "items": { - "type": "string" - } - } - }, - "required": [ - "cluster", - "users" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "createdAtResponse", - "description": "Response and creation timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "createdAt" - ], - "properties": { - "createdAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of creation in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/clusters/mapping/top": { - "get": { - "tags": [ - "Clusters" - ], - "operationId": "getTopUserIds", - "x-acl": [ - "admin" - ], - "summary": "Get top userID.", - "description": "Get the IDs of the 10 users with the highest number of records per cluster.\nSince it can take up to a few seconds to get the data from the different clusters, the response isn't real-time.\n", - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getTopUserIdsResponse", - "type": "object", - "description": "User IDs and clusters.", - "properties": { - "topUsers": { - "type": "array", - "description": "Key-value pairs with cluster names as keys and lists of users with the highest number of records per cluster as values.", - "items": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": { - "title": "userID", - "type": "object", - "description": "Unique user ID.", - "properties": { - "userID": { - "type": "string", - "pattern": "^[a-zA-Z0-9 \\-*.]+$", - "description": "userID of the user.", - "example": "user1" - }, - "clusterName": { - "type": "string", - "description": "Cluster to which the user is assigned.", - "example": "c1-test" - }, - "nbRecords": { - "type": "integer", - "description": "Number of records belonging to the user.", - "example": 42 - }, - "dataSize": { - "type": "integer", - "description": "Data size used by the user.", - "example": 0 - } - }, - "required": [ - "userID", - "clusterName", - "nbRecords", - "dataSize" - ] - } - } - } - } - }, - "required": [ - "topUsers" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/clusters/mapping/{userID}": { - "get": { - "tags": [ - "Clusters" - ], - "operationId": "getUserId", - "x-acl": [ - "admin" - ], - "summary": "Get userID.", - "description": "Returns the userID data stored in the mapping.\nSince it can take up to a few seconds to get the data from the different clusters, the response isn't real-time.\n", - "parameters": [ - { - "name": "userID", - "description": "userID to assign.", - "in": "path", - "required": true, - "schema": { - "type": "string", - "pattern": "^[a-zA-Z0-9 \\-*.]+$" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "userID", - "type": "object", - "description": "Unique user ID.", - "properties": { - "userID": { - "type": "string", - "pattern": "^[a-zA-Z0-9 \\-*.]+$", - "description": "userID of the user.", - "example": "user1" - }, - "clusterName": { - "type": "string", - "description": "Cluster to which the user is assigned.", - "example": "c1-test" - }, - "nbRecords": { - "type": "integer", - "description": "Number of records belonging to the user.", - "example": 42 - }, - "dataSize": { - "type": "integer", - "description": "Data size used by the user.", - "example": 0 - } - }, - "required": [ - "userID", - "clusterName", - "nbRecords", - "dataSize" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "delete": { - "tags": [ - "Clusters" - ], - "operationId": "removeUserId", - "x-acl": [ - "admin" - ], - "summary": "Remove userID.", - "description": "Remove a userID and its associated data from the multi-clusters.", - "parameters": [ - { - "name": "userID", - "description": "userID to assign.", - "in": "path", - "required": true, - "schema": { - "type": "string", - "pattern": "^[a-zA-Z0-9 \\-*.]+$" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "removeUserIdResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "deletedAt": { - "type": "string", - "example": "2023-06-27T14:42:38.831Z", - "description": "Timestamp of deletion in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - }, - "required": [ - "deletedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/clusters": { - "get": { - "tags": [ - "Clusters" - ], - "operationId": "listClusters", - "x-acl": [ - "admin" - ], - "summary": "List clusters.", - "description": "List the available clusters in a multi-cluster setup.", - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "listClustersResponse", - "type": "object", - "description": "Clusters.", - "properties": { - "topUsers": { - "type": "array", - "description": "Key-value pairs with cluster names as keys and lists of users with the highest number of records per cluster as values.", - "items": { - "type": "string", - "description": "Cluster name.", - "example": "c11-test" - } - } - }, - "required": [ - "topUsers" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/clusters/mapping/search": { - "post": { - "tags": [ - "Clusters" - ], - "operationId": "searchUserIds", - "x-use-read-transporter": true, - "x-cacheable": true, - "x-acl": [ - "admin" - ], - "summary": "Search for a user ID.", - "description": "Since it can take up to a few seconds to get the data from the different clusters, the response isn't real-time.\nTo ensure rapid updates, the user IDs index isn't built at the same time as the mapping. Instead, it's built every 12 hours, at the same time as the update of user ID usage. For example, if you add or move a user ID, the search will show an old value until the next time the mapping is rebuilt (every 12 hours).\n", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "title": "searchUserIdsParams", - "type": "object", - "description": "OK", - "additionalProperties": false, - "properties": { - "query": { - "type": "string", - "description": "Query to search. The search is a prefix search with [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/) enabled. An empty query will retrieve all users." - }, - "clusterName": { - "type": "string", - "description": "Cluster name.", - "example": "c11-test" - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "hitsPerPage": { - "type": "integer", - "description": "Number of hits per page.", - "default": 20, - "minimum": 1, - "maximum": 1000, - "x-categories": [ - "Pagination" - ] - } - }, - "required": [ - "query" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "searchUserIdsResponse", - "type": "object", - "description": "userIDs data.", - "properties": { - "hits": { - "type": "array", - "description": "User objects that match the query.", - "items": { - "title": "userHit", - "type": "object", - "properties": { - "userID": { - "type": "string", - "pattern": "^[a-zA-Z0-9 \\-*.]+$", - "description": "userID of the user.", - "example": "user1" - }, - "clusterName": { - "type": "string", - "description": "Cluster name.", - "example": "c11-test" - }, - "nbRecords": { - "type": "integer", - "description": "Number of records in the cluster.", - "example": 3 - }, - "dataSize": { - "type": "integer", - "description": "Data size taken by all the users assigned to the cluster.", - "example": 481 - }, - "objectID": { - "type": "string", - "description": "userID of the requested user. Same as userID." - }, - "_highlightResult": { - "title": "userHighlightResult", - "type": "object", - "properties": { - "userID": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - }, - "clusterName": { - "oneOf": [ - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - }, - { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - }, - { - "type": "array", - "description": "Show highlighted section and words matched on a query.", - "items": { - "type": "object", - "description": "Show highlighted section and words matched on a query.", - "additionalProperties": false, - "properties": { - "value": { - "type": "string", - "description": "Markup text with `facetQuery` matches highlighted.", - "example": "George Clooney" - }, - "matchLevel": { - "type": "string", - "description": "Indicates how well the attribute matched the search query.", - "enum": [ - "none", - "partial", - "full" - ] - }, - "matchedWords": { - "type": "array", - "description": "List of words from the query that matched the object.", - "example": [ - "action" - ], - "items": { - "type": "string" - } - }, - "fullyHighlighted": { - "type": "boolean", - "description": "Whether the entire attribute value is highlighted." - } - }, - "required": [ - "value", - "matchLevel", - "matchedWords" - ] - } - } - ] - } - }, - "required": [ - "userID", - "clusterName" - ] - } - }, - "required": [ - "userID", - "clusterName", - "nbRecords", - "dataSize", - "objectID", - "_highlightResult" - ] - } - }, - "nbHits": { - "type": "integer", - "description": "Number of hits the search query matched.", - "example": 20 - }, - "page": { - "type": "integer", - "description": "Page to retrieve (the first page is `0`, not `1`).", - "default": 0, - "x-categories": [ - "Pagination" - ] - }, - "hitsPerPage": { - "type": "integer", - "default": 20, - "minimum": 1, - "maximum": 1000, - "description": "Maximum number of hits per page." - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - }, - "required": [ - "hits", - "nbHits", - "page", - "hitsPerPage", - "updatedAt" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/clusters/mapping/pending": { - "get": { - "tags": [ - "Clusters" - ], - "operationId": "hasPendingMappings", - "x-acl": [ - "admin" - ], - "summary": "Get migration and user mapping status.", - "description": "To determine when the time-consuming process of creating a large batch of users or migrating users from one cluster to another is complete, this operation retrieves the status of the process.\n", - "parameters": [ - { - "in": "query", - "name": "getClusters", - "description": "Indicates whether to include the cluster's pending mapping state in the response.", - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "hasPendingMappingsResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "pending": { - "description": "Indicates whether there are clusters undergoing migration, creation, or deletion.", - "type": "boolean" - }, - "clusters": { - "description": "Cluster pending mapping state: migrating, creating, deleting.\n", - "type": "object", - "additionalProperties": { - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "required": [ - "pending" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/security/sources": { - "get": { - "tags": [ - "Vaults" - ], - "operationId": "getSources", - "x-acl": [ - "admin" - ], - "description": "Get all allowed sources (IP addresses).", - "summary": "Get all allowed IP addresses.", - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "description": "Sources.", - "type": "array", - "items": { - "description": "Source.", - "required": [ - "source" - ], - "properties": { - "source": { - "description": "IP address range of the source.", - "type": "string", - "example": "10.0.0.1/32" - }, - "description": { - "description": "Source description.", - "type": "string", - "example": "Server subnet" - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - }, - "put": { - "tags": [ - "Vaults" - ], - "operationId": "replaceSources", - "x-acl": [ - "admin" - ], - "description": "Replace all allowed sources.", - "summary": "Replace all sources.", - "requestBody": { - "required": true, - "description": "Allowed sources.", - "content": { - "application/json": { - "schema": { - "description": "Sources.", - "type": "array", - "items": { - "description": "Source.", - "required": [ - "source" - ], - "properties": { - "source": { - "description": "IP address range of the source.", - "type": "string", - "example": "10.0.0.1/32" - }, - "description": { - "description": "Source description.", - "type": "string", - "example": "Server subnet" - } - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "replaceSourceResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "updatedAt" - ], - "properties": { - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/security/sources/append": { - "post": { - "tags": [ - "Vaults" - ], - "operationId": "appendSource", - "x-acl": [ - "admin" - ], - "description": "Add a source to the list of allowed sources.", - "summary": "Add a source.", - "requestBody": { - "required": true, - "description": "Source to add.", - "content": { - "application/json": { - "schema": { - "description": "Source.", - "required": [ - "source" - ], - "properties": { - "source": { - "description": "IP address range of the source.", - "type": "string", - "example": "10.0.0.1/32" - }, - "description": { - "description": "Source description.", - "type": "string", - "example": "Server subnet" - } - } - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "createdAtResponse", - "description": "Response and creation timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "createdAt" - ], - "properties": { - "createdAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of creation in [ISO-8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/security/sources/{source}": { - "delete": { - "tags": [ - "Vaults" - ], - "operationId": "deleteSource", - "x-acl": [ - "admin" - ], - "description": "Remove a source from the list of allowed sources.", - "summary": "Remove a source.", - "parameters": [ - { - "name": "source", - "in": "path", - "required": true, - "description": "IP address range of the source.", - "schema": { - "type": "string", - "example": "10.0.0.1/32" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "deleteSourceResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "deletedAt" - ], - "properties": { - "deletedAt": { - "type": "string", - "example": "2023-06-27T14:42:38.831Z", - "description": "Timestamp of deletion in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/logs": { - "get": { - "tags": [ - "Advanced" - ], - "operationId": "getLogs", - "x-acl": [ - "logs" - ], - "description": "The request must be authenticated by an API key with the [`logs` ACL](https://www.algolia.com/doc/guides/security/api-keys/#access-control-list-acl).\nLogs are held for the last seven days. There's also a logging limit of 1,000 API calls per server.\nThis request counts towards your [operations quota](https://support.algolia.com/hc/en-us/articles/4406981829777-How-does-Algolia-count-records-and-operations-) but doesn't appear in the logs itself.\n> **Note**: To fetch the logs for a Distributed Search Network (DSN) cluster, target the [DSN's endpoint](https://www.algolia.com/doc/guides/scaling/distributed-search-network-dsn/#accessing-dsn-servers).\n", - "summary": "Return the latest log entries.", - "parameters": [ - { - "name": "offset", - "in": "query", - "description": "First log entry to retrieve. Sorted by decreasing date with 0 being the most recent.", - "schema": { - "type": "integer", - "default": 0 - } - }, - { - "name": "length", - "in": "query", - "description": "Maximum number of entries to retrieve.", - "schema": { - "type": "integer", - "default": 10, - "maximum": 1000 - } - }, - { - "name": "indexName", - "in": "query", - "description": "Index for which log entries should be retrieved. When omitted, log entries are retrieved for all indices.", - "example": "products", - "schema": { - "type": "string", - "nullable": true - } - }, - { - "name": "type", - "in": "query", - "description": "Type of log entries to retrieve. When omitted, all log entries are retrieved.", - "schema": { - "type": "string", - "enum": [ - "all", - "query", - "build", - "error" - ], - "default": "all" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getLogsResponse", - "type": "object", - "additionalProperties": false, - "required": [ - "logs" - ], - "properties": { - "logs": { - "type": "array", - "items": { - "title": "log", - "type": "object", - "properties": { - "timestamp": { - "type": "string", - "description": "Timestamp in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format.", - "example": "2023-03-08T12:34:56Z" - }, - "method": { - "type": "string", - "description": "HTTP method of the performed request.", - "example": "GET" - }, - "answer_code": { - "type": "string", - "description": "HTTP response code.", - "example": "200" - }, - "query_body": { - "type": "string", - "description": "Request body. Truncated after 1,000 characters.", - "example": "\\n{\\n \\\"requests\\\": [\\n {\\n \\\"indexName\\\": \\\"best_buy\\\",\\n \\\"params\\\": \\\"query=&hitsPerPage=10&page=0&attributesToRetrieve=*&highlightPreTag=%3Cais-highlight-0000000000%3E&highlightPostTag=%3C%2Fais-highlight-0000000000%3E&getRankingInfo=1&facets=%5B%22brand%22%2C%22categories%22%2C%22free_shipping%22%2C%22type%22%5D&tagFilters=\\\"\\n }\\n ]\\n}\\n" - }, - "answer": { - "type": "string", - "description": "Answer body. Truncated after 1,000 characters.", - "example": "'n{\\n \\\"results\\\": [\\n {\\n \\\"hits\\\": [\\n {\\n \\\"name\\\": \\\"Amazon - Fire TV Stick\\\",\\n \\\"description\\\": \\\"Amazon Fire TV Stick connects to your TV's HDMI port. Just grab and go to enjoy Netflix, Prime Instant Video, Hulu Plus, YouTube.com, music, and much more.\\\",\\n \\\"brand\\\": \\\"Amazon\\\",\\n \\\"categories\\\": [\\n \\\"TV & Home Theater\\\",\\n \\\"Streaming Media Players\\\"\\n ],\\n \\\"hierarchicalCategories\\\": {\\n \\\"lvl0\\\": \\\"TV & Home Theater\\\",\\n \\\"lvl1\\\": \\\"TV & Home Theater > Streaming Media Players\\\"\\n },\\n \\\"type\\\": \\\"Streaming media plyr\\\",\\n \\\"price\\\": 39.99,\\n \\\"price_range\\\": \\\"1 - 50\\\",\\n \\\"image\\\": \\\"https:\\/\\/cdn-demo.algolia.com\\/bestbuy\\/9999119_sb.jpg\\\",\\n \\\"url\\\": \\\"http:\\/\\/www.bestbuy.com\\/site\\/amazon-fire-tv-stick\\/9999119.p?id=1219460752591&skuId=9999119&cmp=RMX&ky=1uWSHMdQqBeVJB9cXgEke60s5EjfS6M1W\\\",\\n \\\"free_shipping\\\": false,\\n \\\"popularity\\\": 9843,\\n \\\"rating\\\": 4,\\n \\\"objectID\\\": \\\"9999119\\\"\\n'\n" - }, - "url": { - "type": "string", - "description": "Request URL.", - "example": "/1/indexes" - }, - "ip": { - "type": "string", - "description": "IP address of the client that performed the request.", - "example": "127.0.0.1" - }, - "query_headers": { - "type": "string", - "description": "Request headers (API key is obfuscated).", - "example": "User-Agent: curl/7.24.0 (x86_64-apple-darwin12.0) libcurl/7.24.0 OpenSSL/0.9.8x zlib/1.2.5\\nHost: localhost.algolia.com:8080\\nAccept: */*\\nContent-Type: application/json; charset=utf-8\\nX-Algolia-API-Key: 20f***************************\\nX-Algolia-Application-Id: MyApplicationID\\n" - }, - "sha1": { - "type": "string", - "description": "SHA1 signature of the log entry.", - "example": "26c53bd7e38ca71f4741b71994cd94a600b7ac68" - }, - "nb_api_calls": { - "type": "string", - "description": "Number of API calls.", - "example": "1" - }, - "processing_time_ms": { - "type": "string", - "description": "Processing time for the query. Doesn't include network time.", - "example": "2" - }, - "index": { - "type": "string", - "description": "Index targeted by the query.", - "example": "best_buy" - }, - "query_params": { - "type": "string", - "description": "Query parameters sent with the request.", - "example": "query=georgia&attributesToRetrieve=name,city,country" - }, - "query_nb_hits": { - "type": "string", - "description": "Number of hits returned for the query.", - "example": "1" - }, - "inner_queries": { - "type": "array", - "description": "Performed queries for the given request.", - "items": { - "type": "object", - "title": "logQuery", - "properties": { - "index_name": { - "type": "string", - "description": "Index targeted by the query.", - "example": "best_buy" - }, - "user_token": { - "type": "string", - "description": "User identifier.", - "example": "93.189.166.128" - }, - "query_id": { - "type": "string", - "description": "Unique query identifier.", - "example": "313453231" - } - } - } - } - }, - "required": [ - "timestamp", - "method", - "answer_code", - "query_body", - "answer", - "url", - "ip", - "query_headers", - "sha1", - "nb_api_calls", - "processing_time_ms" - ] - } - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/task/{taskID}": { - "get": { - "tags": [ - "Indices" - ], - "operationId": "getTask", - "x-acl": [ - "addObject" - ], - "description": "Some operations, such as copying an index, will respond with a `taskID` value. Use this value here to check the status of that task.", - "summary": "Check a task's status.", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - }, - { - "name": "taskID", - "in": "path", - "description": "Unique task identifier.", - "required": true, - "schema": { - "type": "integer", - "format": "int64", - "example": 1506303845001 - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "getTaskResponse", - "type": "object", - "additionalProperties": false, - "properties": { - "status": { - "type": "string", - "enum": [ - "published", - "notPublished" - ], - "description": "_published_ if the task has been processed, _notPublished_ otherwise." - } - }, - "required": [ - "status" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes/{indexName}/operation": { - "post": { - "tags": [ - "Indices" - ], - "operationId": "operationIndex", - "x-acl": [ - "addObject" - ], - "summary": "Copy, move, or rename an index.", - "description": "This `operation`, _copy_ or _move_, will copy or move a source index's (`IndexName`) records, settings, synonyms, and rules to a `destination` index.\nIf the destination index exists, it will be replaced, except for index-specific API keys and analytics data.\nIf the destination index doesn't exist, it will be created.\n\nThe choice between moving or copying an index depends on your needs. Choose:\n\n- **Move** to rename an index.\n- **Copy** to create a new index with the same records and configuration as an existing one.\n\n> **Note**: When considering copying or moving, be aware of the [rate limitations](https://www.algolia.com/doc/guides/scaling/algolia-service-limits/#application-record-and-index-limits) on these processes and the [impact on your analytics data](https://www.algolia.com/doc/guides/sending-and-managing-data/manage-indices-and-apps/manage-indices/concepts/indices-analytics/).", - "parameters": [ - { - "name": "indexName", - "in": "path", - "description": "Index on which to perform the request.", - "required": true, - "schema": { - "type": "string", - "example": "myIndexName" - } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "title": "operationIndexParams", - "type": "object", - "additionalProperties": false, - "properties": { - "operation": { - "type": "string", - "enum": [ - "move", - "copy" - ], - "example": "copy", - "description": "Operation to perform (_move_ or _copy_)." - }, - "destination": { - "type": "string", - "example": "products", - "description": "Algolia index name." - }, - "scope": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "settings", - "synonyms", - "rules" - ] - }, - "description": "**This only applies to the _copy_ operation.**\n\nIf you omit `scope`, the copy command copies all records, settings, synonyms, and rules.\n\nIf you specify `scope`, only the specified scopes are copied." - } - }, - "required": [ - "operation", - "destination" - ] - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "title": "updatedAtResponse", - "description": "Response, taskID, and update timestamp.", - "additionalProperties": false, - "type": "object", - "required": [ - "taskID", - "updatedAt" - ], - "properties": { - "taskID": { - "type": "integer", - "format": "int64", - "example": 1514562690001, - "description": "Unique identifier of a task.\nA 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 and this `taskID`.\n" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - } - } - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - }, - "/1/indexes": { - "get": { - "tags": [ - "Indices" - ], - "operationId": "listIndices", - "x-acl": [ - "listIndexes" - ], - "summary": "List indices.", - "description": "List indices in an Algolia application.", - "parameters": [ - { - "in": "query", - "name": "page", - "description": "Returns the requested page number. The page size is determined by the `hitsPerPage` parameter. You can see the number of available pages in the `nbPages` response attribute. When `page` is null, the API response is not paginated.\n", - "schema": { - "type": "integer", - "minimum": 0, - "nullable": true, - "default": null - } - }, - { - "in": "query", - "name": "hitsPerPage", - "description": "Maximum number of hits per page.", - "schema": { - "type": "integer", - "default": 100 - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "items": { - "type": "array", - "description": "All indices in your Algolia application.", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "name": { - "type": "string", - "description": "Index name.", - "example": "movies" - }, - "createdAt": { - "type": "string", - "description": "Index creation date. An empty string means that the index has no records.", - "example": "2022-09-19T16:36:44.471Z" - }, - "updatedAt": { - "type": "string", - "example": "2023-07-04T12:49:15Z", - "description": "Timestamp of the last update in [ISO 8601](https://wikipedia.org/wiki/ISO_8601) format." - }, - "entries": { - "type": "integer", - "description": "Number of records contained in the index.", - "example": 100 - }, - "dataSize": { - "type": "integer", - "description": "Number of bytes of the index in minified format.", - "example": 48450 - }, - "fileSize": { - "type": "integer", - "description": "Number of bytes of the index binary file.", - "example": 112927 - }, - "lastBuildTimeS": { - "type": "integer", - "description": "Last build time.", - "example": 3 - }, - "numberOfPendingTasks": { - "type": "integer", - "default": 0, - "description": "Number of pending indexing operations. This value is deprecated and should not be used." - }, - "pendingTask": { - "type": "boolean", - "default": false, - "description": "A boolean which says whether the index has pending tasks. This value is deprecated and should not be used." - }, - "primary": { - "type": "string", - "description": "Only present if the index is a replica. Contains the name of the related primary index.", - "example": "T02" - }, - "replicas": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Only present if the index is a primary index with replicas. Contains the names of all linked replicas.", - "example": [ - "T02_push", - "T2replica" - ] - } - }, - "required": [ - "name", - "createdAt", - "updatedAt", - "entries", - "dataSize", - "fileSize", - "lastBuildTimeS", - "pendingTask", - "numberOfPendingTasks" - ] - } - }, - "nbPages": { - "type": "integer", - "description": "Number of pages.", - "example": 100 - } - }, - "required": [ - "items" - ] - } - } - } - }, - "400": { - "description": "Bad request or request arguments.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "402": { - "description": "This feature is not enabled on your Algolia account.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "403": { - "description": "Method not allowed with this API key.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - }, - "404": { - "description": "Index not found.", - "content": { - "application/json": { - "schema": { - "description": "Error.", - "type": "object", - "additionalProperties": true, - "properties": { - "message": { - "type": "string", - "example": "Invalid Application-Id or API-Key" - } - } - } - } - } - } - } - } - } - } -} \ No newline at end of file diff --git a/specs/bundled/usage.json b/specs/bundled/usage.json deleted file mode 100644 index 6f7d72c4fc..0000000000 --- a/specs/bundled/usage.json +++ /dev/null @@ -1,748 +0,0 @@ -{ - "openapi": "3.0.2", - "info": { - "title": "Usage API", - "description": "API to retrieve usage statistics for HTTP requests made to Algolia applications.\n\nUse the [Usage API key](https://dashboard.algolia.com/account/api-keys/) for authentication.\n", - "version": "1.0.0", - "contact": { - "name": "Algolia Usage API", - "url": "https://www.algolia.com/doc/rest-api/usage/" - } - }, - "components": { - "securitySchemes": { - "BasicAuth": { - "type": "http", - "scheme": "basic" - } - }, - "parameters": { - "statisticParameter": { - "name": "statistic", - "in": "path", - "required": true, - "schema": { - "type": "string", - "example": "records,max_qps,region_max_qps" - }, - "description": "The [statistics](#statistics) to retrieve.\nTo retrieve several queries, separate them with commas.\n\n### Statistics\n\nThe usage statistics cover several sets of operations: [search](#search-operations), [access control lists](#acl-operations), [indexing](#indexing-operations), [records](#record-operations), [synonyms](#synonym-operations), [Rules](#rule-operations), and [Insights](#insights-operations).\nThey also return metrics on: [total operations](#total-operations), [total Query Suggestions operations](#total-query-suggestions-operations), [processing time](#processing-time), [indices](#indices), [queries per second](#maximum-qps-query-per-second), [search capacity](#used-search-capacity), and [degraded queries](#degraded-queries).\n\nTo avoid unnecessary calls, you can request all or some of the following sets of statistics with a [grouping](#grouping) option.\n\n#### Search operations\n\n- `queries_operations`: number of [single queries](https://www.algolia.com/doc/rest-api/search/#search-index-post)\n- `multi_queries_operations`: number of [multiple queries](https://www.algolia.com/doc/rest-api/search/#search-multiple-indices) (batched queries)\n\n#### ACL operations\n\n- `get_api_key_operations`: number of [get API key](https://www.algolia.com/doc/rest-api/search/#get-api-key-permissions) operations\n- `get_api_keys_operations`: number of [list API keys](https://www.algolia.com/doc/rest-api/search/#list-api-keys) operations\n- `add_api_key_operations`: number of [add API key](https://www.algolia.com/doc//rest-api/search/#add-api-key) operations\n- `update_api_key_operations`: number of [update API key](https://www.algolia.com/doc/rest-api/search/#update-api-key) operations\n- `delete_api_key_operations`: number of [delete API key](https://www.algolia.com/doc/rest-api/search/#delete-api-key) operations\n- `list_api_key_operations`: number of [list index API keys](https://www.algolia.com/doc/rest-api/search/#list-index-api-keys-for-all-indices) operations\n\n#### Indexing operations\n\n- `browse_operations`: number of [browse index](https://www.algolia.com/doc/rest-api/search/#browse-index-post) operations\n- `clear_index_operations`: number of [clear records](https://www.algolia.com/doc/rest-api/search/#clear-objects) operations\n- `copy_move_operations`: number of [copy or move index](https://www.algolia.com/doc/rest-api/search/#copymove-index) operations\n- `delete_index_operations`: number of [delete index](https://www.algolia.com/doc/rest-api/search/#delete-index) operations\n- `get_log_operations`: number of [get logs](https://www.algolia.com/doc/rest-api/search/#get-logs) operations\n- `get_settings_operations`: number of [get settings](https://www.algolia.com/doc/rest-api/search/#get-settings) operations\n- `set_settings_operations`: number of [set settings](https://www.algolia.com/doc/rest-api/search/#set-settings) operations\n- `list_indices_operations`: number of [list indices](https://www.algolia.com/doc/rest-api/search/#list-indices) operations\n- `wait_task_operations`: number of [wait](https://www.algolia.com/doc/api-reference/api-methods/wait-task/) operations\n\n#### Record operations\n\n- `add_record_operations`: number of [add or replace record](https://www.algolia.com/doc/rest-api/search/#add-or-replace-object) operations\n- `batch_operations`: number of [batch update](https://www.algolia.com/doc/rest-api/search/#batch-write-operations) operations\n- `delete_by_query_operations`: number of [delete by query](https://www.algolia.com/doc/rest-api/search/#delete-by) operations\n- `delete_record_operations`: number of [delete record](https://www.algolia.com/doc/rest-api/search/#delete-object) operations\n- `get_record_operations`: number of [get record](https://www.algolia.com/doc/rest-api/search/#get-object) operations\n- `partial_update_record_operations`: number of [partially update records](https://www.algolia.com/doc/rest-api/search/#partially-update-objects) operations\n- `update_record_operations`: number of [add or replace record by objectID](https://www.algolia.com/doc/rest-api/search/#add-or-replace-object-by-id) operations\n\n#### Synonym operations\n\n- `batch_synonym_operations`: number of [save all synonyms](https://www.algolia.com/doc/rest-api/search/#save-synonyms) operations\n- `clear_synonym_operations`: number of [clear synonyms](https://www.algolia.com/doc/rest-api/search/#clear-all-synonyms) operations\n- `delete_synonym_operations`: number of [delete synonym](https://www.algolia.com/doc/rest-api/search/#delete-synonym) operations\n- `get_synonym_operations`: number of [get synonym](https://www.algolia.com/doc/rest-api/search/#get-synonym) operations\n- `query_synonym_operations`: number of [search synonyms](https://www.algolia.com/doc/rest-api/search/#search-synonyms) operations\n- `update_synonym_operations`: number of [save a synonym](https://www.algolia.com/doc/rest-api/search/#save-synonym) operations\n\n#### Rule operations\n\n- `batch_rules_operations`: number of [batch rules](https://www.algolia.com/doc/rest-api/search/#batch-rules) operations\n- `clear_rules_operations`: number of [delete rule](https://www.algolia.com/doc/rest-api/search/#delete-rule) operations\n- `delete_rules_operations`: number of [clear rules](https://www.algolia.com/doc/rest-api/search/#clear-rules) operations\n- `get_rules_operations`: number of [get rule](https://www.algolia.com/doc/rest-api/search/#get-rule) operations\n- `save_rules_operations`: number of [save rule](https://www.algolia.com/doc/rest-api/search/#save-rule) operations\n- `search_rules_operations`: number of [search rules](https://www.algolia.com/doc/rest-api/search/#search-rules) operations\n\n#### Insights operations\n\n- `insights_operations`: number of operations on the Insights API.\n\n#### Total operations\n\n- `total_search_operations`: sum of all [search operations](#search-operations)\n- `total_search_requests`: number of [search requests](https://support.algolia.com/hc/en-us/articles/4406981829777-How-does-Algolia-count-records-and-operations-). The number of billed search requests is equal to this value minus `querysuggestions_total_search_requests`\n- `total_recommend_requests`: number of [Recommend requests](https://www.algolia.com/doc/guides/algolia-ai/recommend/)\n- `total_acl_operations`: sum of all [ACL operations](#acl-operations)\n- `total_indexing_operations`: sum of all [indexing operations](#indexing-operations)\n- `total_records_operations`: sum of all [record operations](#record-operations)\n- `total_synonym_operations`: sum of all [synonym operations](#synonym-operations)\n- `total_rules_operations`: sum of all [Rule operations](#rule-operations)\n- `total_write_operations`: number of Write operations\n- `total_read_operations`: number of Read operations\n- `total_operations`: sum of all operations\n\n#### Total Query Suggestions operations\n\n[Query Suggestions](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/query-suggestions/js/) operations are a subset of `total_search_operations`.\n\n- `querysuggestions_total_search_operations`: number of Query Suggestions search operations\n- `querysuggestions_total_search_requests`: number of Query Suggestions [search requests](https://support.algolia.com/hc/en-us/articles/4406981829777-How-does-Algolia-count-records-and-operations-)\n- `querysuggestions_total_acl_operations`: sum of all Query Suggestions [ACL operations](#acl-operations)\n- `querysuggestions_total_indexing_operations`: number of Query Suggestions [indexing operations](#indexing-operations)\n- `querysuggestions_total_records_operations`: number of Query Suggestions [record operations](#record-operations)\n- `querysuggestions_total_synonym_operations`: number of Query Suggestions [synonym operations](#synonym-operations)\n- `querysuggestions_total_rules_operations`: number of Query Suggestions [Rule operations](#rule-operations)\n- `querysuggestions_total_write_operations`: number of Query Suggestions Write operations\n- `querysuggestions_total_read_operations`: number of Query Suggestions Read operations\n- `querysuggestions_total_operations`: sum of all Query Suggestions operations\n\n#### Processing time\n\n- `avg_processing_time`: average processing time (in milliseconds)\n- `90p_processing_time`: 90th percentile of processing time (in milliseconds)\n- `99p_processing_time`: 99th percentile of processing time (in milliseconds)\n- `queries_above_last_ms_processing_time`: number of queries that take one or more seconds to process\n\n#### Indices\n\n- `records`: number of records\n- `data_size`: the size of the indices' records (in bytes)\n- `file_size`: the size of the indices' records _and_ metadata (in bytes)\n\n#### Maximum QPS (query per second)\n\n- `max_qps`: [maximum queries per second](https://support.algolia.com/hc/en-us/articles/4406975224721) over the time range (per server)\n- `region_max_qps`: maximum queries per second over the time range (per region)\n- `total_max_qps`: maximum queries per second across all servers\n\n#### Used search capacity\n\n- `used_search_capacity`: maximum search capacity used (in percentage per server)\n- `avg_used_search_capacity`: average search capacity used (in percentage per server)\n- `region_used_search_capacity`: maximum search capacity used (in percentage per region)\n- `region_avg_used_search_capacity`: average search capacity used (in percentage per region)\n- `total_used_search_capacity`: maximum search capacity used (in percentage for all servers)\n- `total_avg_used_search_capacity`: average used search capacity (in percentage for all servers)\n\n#### Degraded queries\n\nUse these statistics to monitor the impact of [degraded queries](https://support.algolia.com/hc/en-us/articles/4406981934481).\n\n- `degraded_queries_ssd_used_queries_impacted`: percentage of queries that made the Algolia search engine read from the server's SSD.\n- `degraded_queries_ssd_used_seconds_impacted`: percentage of seconds affected by a `ssd_used` degradation.\n- `degraded_queries_max_capacity_queries_impacted`: percentage of queries degraded because all search threads were used.\n- `degraded_queries_max_capacity_seconds_impacted`: percentage of seconds affected by a `max_capacity` degradation.\n\nSome statistics provide information about the percentage of time when queries were degraded during the specified period.\nFor example, if `degraded_queries_max_capacity_seconds_impacted` shows 50%, there were `max_capacity` problems half of the time.\nThese issues might not happen continuously but at different times during the specified period.\n\n### Grouping\n\n- `*`: return all the usage statistics in the same response\n- `search_operations`: return all [search operations](#search-operations)\n- `acl_operations`: return all [ACL operations](#acl-operations)\n- `indexing_operations`: return all [indexing operations](#indexing-operations)\n- `record_operations`: return all [record operations](#record-operations)\n- `synonym_operations`: returns all [synonym operations](#synonym-operations)\n- `rule_operations`: returns all [Rule operations](#rule-operations).\n" - }, - "startDateParameter": { - "name": "startDate", - "in": "query", - "description": "Start date in [ISO-8601 format](https://wikipedia.org/wiki/ISO_8601).", - "required": true, - "schema": { - "type": "string", - "example": "2023-08-12T14:30:00Z" - } - }, - "endDateParameter": { - "name": "endDate", - "in": "query", - "description": "End date in [ISO-8601 format](https://wikipedia.org/wiki/ISO_8601).", - "required": true, - "schema": { - "type": "string", - "example": "2023-08-19T16:45:00Z" - } - }, - "granularityParameter": { - "name": "granularity", - "in": "query", - "description": "Return hourly or daily statistics.\n\n- `hourly`: the maximum time range for this granularity is 7 days\n- `daily`: the maximum time range for this granularity is 365 days.\n", - "schema": { - "type": "string", - "enum": [ - "hourly", - "daily" - ], - "default": "daily" - } - }, - "indexParameter": { - "name": "index", - "in": "path", - "description": "Index name.", - "required": true, - "schema": { - "type": "string", - "example": "YOUR_INDEX_NAME" - } - } - }, - "schemas": { - "granularity": { - "type": "string", - "enum": [ - "hourly", - "daily" - ], - "default": "daily" - }, - "statisticValue": { - "oneOf": [ - { - "type": "integer" - }, - { - "type": "object", - "properties": { - "serverName": { - "type": "string" - }, - "value": { - "type": "integer" - } - } - }, - { - "type": "string" - } - ] - } - }, - "responses": { - "Success": { - "description": "Success.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "statistics": { - "type": "array", - "items": { - "type": "object", - "properties": { - "t": { - "type": "integer", - "description": "[Unix timestamp](https://www.unixtimestamp.com/) (in milliseconds).\n", - "example": 1455451200000 - }, - "v": { - "description": "Depending on the statistic, the type of this value (`v`) differs.\nMost statistics return integer values.\n\n`degraded_queries_*`, `max_qps`, and `used_search_capacity` are returned as maps of server name strings to integers.\n\n`region_*` statistics return strings (regions).\n", - "oneOf": [ - { - "type": "integer" - }, - { - "type": "object", - "properties": { - "serverName": { - "type": "string" - }, - "value": { - "type": "integer" - } - } - }, - { - "type": "string" - } - ] - } - } - } - } - } - } - } - } - }, - "InvalidRequest": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "MissingAuthorization": { - "description": "Authorization information is missing or invalid." - }, - "Forbidden": { - "description": "Invalid credentials.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "IndexNotFound": { - "description": "Index not found.\n\nIf `index` has been correctly defined, this error message means that no data was found in the given time range.\nThe time range may lie outside the [data retention period](https://support.algolia.com/hc/en-us/articles/4406975230993-Can-I-extend-the-retention-period-of-the-analytics-data-).\n" - }, - "StatisticNotFound": { - "description": "Metric not found." - } - } - }, - "servers": [ - { - "url": "https://usage.algolia.com/1/usage" - }, - { - "url": "https://usage-dev.algolia.com/1/usage" - }, - { - "url": "http://localhost:8000/1/usage" - } - ], - "security": [ - { - "BasicAuth": [] - } - ], - "paths": { - "/{statistic}": { - "get": { - "operationId": "getUsage", - "summary": "Get usage.", - "description": "Returns usage statistics over a specified period.\n\nThe specified period must be within the last 90 days.\nHowever, the period of [data retention can be extended](https://support.algolia.com/hc/en-us/articles/4406975230993-Can-I-extend-the-retention-period-of-the-analytics-data-) to a maximum of 365 days.\n", - "parameters": [ - { - "name": "statistic", - "in": "path", - "required": true, - "schema": { - "type": "string", - "example": "records,max_qps,region_max_qps" - }, - "description": "The [statistics](#statistics) to retrieve.\nTo retrieve several queries, separate them with commas.\n\n### Statistics\n\nThe usage statistics cover several sets of operations: [search](#search-operations), [access control lists](#acl-operations), [indexing](#indexing-operations), [records](#record-operations), [synonyms](#synonym-operations), [Rules](#rule-operations), and [Insights](#insights-operations).\nThey also return metrics on: [total operations](#total-operations), [total Query Suggestions operations](#total-query-suggestions-operations), [processing time](#processing-time), [indices](#indices), [queries per second](#maximum-qps-query-per-second), [search capacity](#used-search-capacity), and [degraded queries](#degraded-queries).\n\nTo avoid unnecessary calls, you can request all or some of the following sets of statistics with a [grouping](#grouping) option.\n\n#### Search operations\n\n- `queries_operations`: number of [single queries](https://www.algolia.com/doc/rest-api/search/#search-index-post)\n- `multi_queries_operations`: number of [multiple queries](https://www.algolia.com/doc/rest-api/search/#search-multiple-indices) (batched queries)\n\n#### ACL operations\n\n- `get_api_key_operations`: number of [get API key](https://www.algolia.com/doc/rest-api/search/#get-api-key-permissions) operations\n- `get_api_keys_operations`: number of [list API keys](https://www.algolia.com/doc/rest-api/search/#list-api-keys) operations\n- `add_api_key_operations`: number of [add API key](https://www.algolia.com/doc//rest-api/search/#add-api-key) operations\n- `update_api_key_operations`: number of [update API key](https://www.algolia.com/doc/rest-api/search/#update-api-key) operations\n- `delete_api_key_operations`: number of [delete API key](https://www.algolia.com/doc/rest-api/search/#delete-api-key) operations\n- `list_api_key_operations`: number of [list index API keys](https://www.algolia.com/doc/rest-api/search/#list-index-api-keys-for-all-indices) operations\n\n#### Indexing operations\n\n- `browse_operations`: number of [browse index](https://www.algolia.com/doc/rest-api/search/#browse-index-post) operations\n- `clear_index_operations`: number of [clear records](https://www.algolia.com/doc/rest-api/search/#clear-objects) operations\n- `copy_move_operations`: number of [copy or move index](https://www.algolia.com/doc/rest-api/search/#copymove-index) operations\n- `delete_index_operations`: number of [delete index](https://www.algolia.com/doc/rest-api/search/#delete-index) operations\n- `get_log_operations`: number of [get logs](https://www.algolia.com/doc/rest-api/search/#get-logs) operations\n- `get_settings_operations`: number of [get settings](https://www.algolia.com/doc/rest-api/search/#get-settings) operations\n- `set_settings_operations`: number of [set settings](https://www.algolia.com/doc/rest-api/search/#set-settings) operations\n- `list_indices_operations`: number of [list indices](https://www.algolia.com/doc/rest-api/search/#list-indices) operations\n- `wait_task_operations`: number of [wait](https://www.algolia.com/doc/api-reference/api-methods/wait-task/) operations\n\n#### Record operations\n\n- `add_record_operations`: number of [add or replace record](https://www.algolia.com/doc/rest-api/search/#add-or-replace-object) operations\n- `batch_operations`: number of [batch update](https://www.algolia.com/doc/rest-api/search/#batch-write-operations) operations\n- `delete_by_query_operations`: number of [delete by query](https://www.algolia.com/doc/rest-api/search/#delete-by) operations\n- `delete_record_operations`: number of [delete record](https://www.algolia.com/doc/rest-api/search/#delete-object) operations\n- `get_record_operations`: number of [get record](https://www.algolia.com/doc/rest-api/search/#get-object) operations\n- `partial_update_record_operations`: number of [partially update records](https://www.algolia.com/doc/rest-api/search/#partially-update-objects) operations\n- `update_record_operations`: number of [add or replace record by objectID](https://www.algolia.com/doc/rest-api/search/#add-or-replace-object-by-id) operations\n\n#### Synonym operations\n\n- `batch_synonym_operations`: number of [save all synonyms](https://www.algolia.com/doc/rest-api/search/#save-synonyms) operations\n- `clear_synonym_operations`: number of [clear synonyms](https://www.algolia.com/doc/rest-api/search/#clear-all-synonyms) operations\n- `delete_synonym_operations`: number of [delete synonym](https://www.algolia.com/doc/rest-api/search/#delete-synonym) operations\n- `get_synonym_operations`: number of [get synonym](https://www.algolia.com/doc/rest-api/search/#get-synonym) operations\n- `query_synonym_operations`: number of [search synonyms](https://www.algolia.com/doc/rest-api/search/#search-synonyms) operations\n- `update_synonym_operations`: number of [save a synonym](https://www.algolia.com/doc/rest-api/search/#save-synonym) operations\n\n#### Rule operations\n\n- `batch_rules_operations`: number of [batch rules](https://www.algolia.com/doc/rest-api/search/#batch-rules) operations\n- `clear_rules_operations`: number of [delete rule](https://www.algolia.com/doc/rest-api/search/#delete-rule) operations\n- `delete_rules_operations`: number of [clear rules](https://www.algolia.com/doc/rest-api/search/#clear-rules) operations\n- `get_rules_operations`: number of [get rule](https://www.algolia.com/doc/rest-api/search/#get-rule) operations\n- `save_rules_operations`: number of [save rule](https://www.algolia.com/doc/rest-api/search/#save-rule) operations\n- `search_rules_operations`: number of [search rules](https://www.algolia.com/doc/rest-api/search/#search-rules) operations\n\n#### Insights operations\n\n- `insights_operations`: number of operations on the Insights API.\n\n#### Total operations\n\n- `total_search_operations`: sum of all [search operations](#search-operations)\n- `total_search_requests`: number of [search requests](https://support.algolia.com/hc/en-us/articles/4406981829777-How-does-Algolia-count-records-and-operations-). The number of billed search requests is equal to this value minus `querysuggestions_total_search_requests`\n- `total_recommend_requests`: number of [Recommend requests](https://www.algolia.com/doc/guides/algolia-ai/recommend/)\n- `total_acl_operations`: sum of all [ACL operations](#acl-operations)\n- `total_indexing_operations`: sum of all [indexing operations](#indexing-operations)\n- `total_records_operations`: sum of all [record operations](#record-operations)\n- `total_synonym_operations`: sum of all [synonym operations](#synonym-operations)\n- `total_rules_operations`: sum of all [Rule operations](#rule-operations)\n- `total_write_operations`: number of Write operations\n- `total_read_operations`: number of Read operations\n- `total_operations`: sum of all operations\n\n#### Total Query Suggestions operations\n\n[Query Suggestions](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/query-suggestions/js/) operations are a subset of `total_search_operations`.\n\n- `querysuggestions_total_search_operations`: number of Query Suggestions search operations\n- `querysuggestions_total_search_requests`: number of Query Suggestions [search requests](https://support.algolia.com/hc/en-us/articles/4406981829777-How-does-Algolia-count-records-and-operations-)\n- `querysuggestions_total_acl_operations`: sum of all Query Suggestions [ACL operations](#acl-operations)\n- `querysuggestions_total_indexing_operations`: number of Query Suggestions [indexing operations](#indexing-operations)\n- `querysuggestions_total_records_operations`: number of Query Suggestions [record operations](#record-operations)\n- `querysuggestions_total_synonym_operations`: number of Query Suggestions [synonym operations](#synonym-operations)\n- `querysuggestions_total_rules_operations`: number of Query Suggestions [Rule operations](#rule-operations)\n- `querysuggestions_total_write_operations`: number of Query Suggestions Write operations\n- `querysuggestions_total_read_operations`: number of Query Suggestions Read operations\n- `querysuggestions_total_operations`: sum of all Query Suggestions operations\n\n#### Processing time\n\n- `avg_processing_time`: average processing time (in milliseconds)\n- `90p_processing_time`: 90th percentile of processing time (in milliseconds)\n- `99p_processing_time`: 99th percentile of processing time (in milliseconds)\n- `queries_above_last_ms_processing_time`: number of queries that take one or more seconds to process\n\n#### Indices\n\n- `records`: number of records\n- `data_size`: the size of the indices' records (in bytes)\n- `file_size`: the size of the indices' records _and_ metadata (in bytes)\n\n#### Maximum QPS (query per second)\n\n- `max_qps`: [maximum queries per second](https://support.algolia.com/hc/en-us/articles/4406975224721) over the time range (per server)\n- `region_max_qps`: maximum queries per second over the time range (per region)\n- `total_max_qps`: maximum queries per second across all servers\n\n#### Used search capacity\n\n- `used_search_capacity`: maximum search capacity used (in percentage per server)\n- `avg_used_search_capacity`: average search capacity used (in percentage per server)\n- `region_used_search_capacity`: maximum search capacity used (in percentage per region)\n- `region_avg_used_search_capacity`: average search capacity used (in percentage per region)\n- `total_used_search_capacity`: maximum search capacity used (in percentage for all servers)\n- `total_avg_used_search_capacity`: average used search capacity (in percentage for all servers)\n\n#### Degraded queries\n\nUse these statistics to monitor the impact of [degraded queries](https://support.algolia.com/hc/en-us/articles/4406981934481).\n\n- `degraded_queries_ssd_used_queries_impacted`: percentage of queries that made the Algolia search engine read from the server's SSD.\n- `degraded_queries_ssd_used_seconds_impacted`: percentage of seconds affected by a `ssd_used` degradation.\n- `degraded_queries_max_capacity_queries_impacted`: percentage of queries degraded because all search threads were used.\n- `degraded_queries_max_capacity_seconds_impacted`: percentage of seconds affected by a `max_capacity` degradation.\n\nSome statistics provide information about the percentage of time when queries were degraded during the specified period.\nFor example, if `degraded_queries_max_capacity_seconds_impacted` shows 50%, there were `max_capacity` problems half of the time.\nThese issues might not happen continuously but at different times during the specified period.\n\n### Grouping\n\n- `*`: return all the usage statistics in the same response\n- `search_operations`: return all [search operations](#search-operations)\n- `acl_operations`: return all [ACL operations](#acl-operations)\n- `indexing_operations`: return all [indexing operations](#indexing-operations)\n- `record_operations`: return all [record operations](#record-operations)\n- `synonym_operations`: returns all [synonym operations](#synonym-operations)\n- `rule_operations`: returns all [Rule operations](#rule-operations).\n" - }, - { - "name": "startDate", - "in": "query", - "description": "Start date in [ISO-8601 format](https://wikipedia.org/wiki/ISO_8601).", - "required": true, - "schema": { - "type": "string", - "example": "2023-08-12T14:30:00Z" - } - }, - { - "name": "endDate", - "in": "query", - "description": "End date in [ISO-8601 format](https://wikipedia.org/wiki/ISO_8601).", - "required": true, - "schema": { - "type": "string", - "example": "2023-08-19T16:45:00Z" - } - }, - { - "name": "granularity", - "in": "query", - "description": "Return hourly or daily statistics.\n\n- `hourly`: the maximum time range for this granularity is 7 days\n- `daily`: the maximum time range for this granularity is 365 days.\n", - "schema": { - "type": "string", - "enum": [ - "hourly", - "daily" - ], - "default": "daily" - } - } - ], - "responses": { - "200": { - "description": "Success.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "statistics": { - "type": "array", - "items": { - "type": "object", - "properties": { - "t": { - "type": "integer", - "description": "[Unix timestamp](https://www.unixtimestamp.com/) (in milliseconds).\n", - "example": 1455451200000 - }, - "v": { - "description": "Depending on the statistic, the type of this value (`v`) differs.\nMost statistics return integer values.\n\n`degraded_queries_*`, `max_qps`, and `used_search_capacity` are returned as maps of server name strings to integers.\n\n`region_*` statistics return strings (regions).\n", - "oneOf": [ - { - "type": "integer" - }, - { - "type": "object", - "properties": { - "serverName": { - "type": "string" - }, - "value": { - "type": "integer" - } - } - }, - { - "type": "string" - } - ] - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "Invalid credentials.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "404": { - "description": "Index not found.\n\nIf `index` has been correctly defined, this error message means that no data was found in the given time range.\nThe time range may lie outside the [data retention period](https://support.algolia.com/hc/en-us/articles/4406975230993-Can-I-extend-the-retention-period-of-the-analytics-data-).\n" - }, - "422": { - "description": "Metric not found." - } - } - } - }, - "/{statistic}/{index}": { - "get": { - "operationId": "getIndexUsage", - "summary": "Get usage for an index.", - "description": "Returns index usage statistics over a specified period.\n\nThe specified period must be within the last 90 days.\nHowever, the period of [data retention can be extended](https://support.algolia.com/hc/en-us/articles/4406975230993-Can-I-extend-the-retention-period-of-the-analytics-data-) to a maximum of 365 days.\n", - "parameters": [ - { - "name": "statistic", - "in": "path", - "required": true, - "schema": { - "type": "string", - "example": "records,max_qps,region_max_qps" - }, - "description": "The [statistics](#statistics) to retrieve.\nTo retrieve several queries, separate them with commas.\n\n### Statistics\n\nThe usage statistics cover several sets of operations: [search](#search-operations), [access control lists](#acl-operations), [indexing](#indexing-operations), [records](#record-operations), [synonyms](#synonym-operations), [Rules](#rule-operations), and [Insights](#insights-operations).\nThey also return metrics on: [total operations](#total-operations), [total Query Suggestions operations](#total-query-suggestions-operations), [processing time](#processing-time), [indices](#indices), [queries per second](#maximum-qps-query-per-second), [search capacity](#used-search-capacity), and [degraded queries](#degraded-queries).\n\nTo avoid unnecessary calls, you can request all or some of the following sets of statistics with a [grouping](#grouping) option.\n\n#### Search operations\n\n- `queries_operations`: number of [single queries](https://www.algolia.com/doc/rest-api/search/#search-index-post)\n- `multi_queries_operations`: number of [multiple queries](https://www.algolia.com/doc/rest-api/search/#search-multiple-indices) (batched queries)\n\n#### ACL operations\n\n- `get_api_key_operations`: number of [get API key](https://www.algolia.com/doc/rest-api/search/#get-api-key-permissions) operations\n- `get_api_keys_operations`: number of [list API keys](https://www.algolia.com/doc/rest-api/search/#list-api-keys) operations\n- `add_api_key_operations`: number of [add API key](https://www.algolia.com/doc//rest-api/search/#add-api-key) operations\n- `update_api_key_operations`: number of [update API key](https://www.algolia.com/doc/rest-api/search/#update-api-key) operations\n- `delete_api_key_operations`: number of [delete API key](https://www.algolia.com/doc/rest-api/search/#delete-api-key) operations\n- `list_api_key_operations`: number of [list index API keys](https://www.algolia.com/doc/rest-api/search/#list-index-api-keys-for-all-indices) operations\n\n#### Indexing operations\n\n- `browse_operations`: number of [browse index](https://www.algolia.com/doc/rest-api/search/#browse-index-post) operations\n- `clear_index_operations`: number of [clear records](https://www.algolia.com/doc/rest-api/search/#clear-objects) operations\n- `copy_move_operations`: number of [copy or move index](https://www.algolia.com/doc/rest-api/search/#copymove-index) operations\n- `delete_index_operations`: number of [delete index](https://www.algolia.com/doc/rest-api/search/#delete-index) operations\n- `get_log_operations`: number of [get logs](https://www.algolia.com/doc/rest-api/search/#get-logs) operations\n- `get_settings_operations`: number of [get settings](https://www.algolia.com/doc/rest-api/search/#get-settings) operations\n- `set_settings_operations`: number of [set settings](https://www.algolia.com/doc/rest-api/search/#set-settings) operations\n- `list_indices_operations`: number of [list indices](https://www.algolia.com/doc/rest-api/search/#list-indices) operations\n- `wait_task_operations`: number of [wait](https://www.algolia.com/doc/api-reference/api-methods/wait-task/) operations\n\n#### Record operations\n\n- `add_record_operations`: number of [add or replace record](https://www.algolia.com/doc/rest-api/search/#add-or-replace-object) operations\n- `batch_operations`: number of [batch update](https://www.algolia.com/doc/rest-api/search/#batch-write-operations) operations\n- `delete_by_query_operations`: number of [delete by query](https://www.algolia.com/doc/rest-api/search/#delete-by) operations\n- `delete_record_operations`: number of [delete record](https://www.algolia.com/doc/rest-api/search/#delete-object) operations\n- `get_record_operations`: number of [get record](https://www.algolia.com/doc/rest-api/search/#get-object) operations\n- `partial_update_record_operations`: number of [partially update records](https://www.algolia.com/doc/rest-api/search/#partially-update-objects) operations\n- `update_record_operations`: number of [add or replace record by objectID](https://www.algolia.com/doc/rest-api/search/#add-or-replace-object-by-id) operations\n\n#### Synonym operations\n\n- `batch_synonym_operations`: number of [save all synonyms](https://www.algolia.com/doc/rest-api/search/#save-synonyms) operations\n- `clear_synonym_operations`: number of [clear synonyms](https://www.algolia.com/doc/rest-api/search/#clear-all-synonyms) operations\n- `delete_synonym_operations`: number of [delete synonym](https://www.algolia.com/doc/rest-api/search/#delete-synonym) operations\n- `get_synonym_operations`: number of [get synonym](https://www.algolia.com/doc/rest-api/search/#get-synonym) operations\n- `query_synonym_operations`: number of [search synonyms](https://www.algolia.com/doc/rest-api/search/#search-synonyms) operations\n- `update_synonym_operations`: number of [save a synonym](https://www.algolia.com/doc/rest-api/search/#save-synonym) operations\n\n#### Rule operations\n\n- `batch_rules_operations`: number of [batch rules](https://www.algolia.com/doc/rest-api/search/#batch-rules) operations\n- `clear_rules_operations`: number of [delete rule](https://www.algolia.com/doc/rest-api/search/#delete-rule) operations\n- `delete_rules_operations`: number of [clear rules](https://www.algolia.com/doc/rest-api/search/#clear-rules) operations\n- `get_rules_operations`: number of [get rule](https://www.algolia.com/doc/rest-api/search/#get-rule) operations\n- `save_rules_operations`: number of [save rule](https://www.algolia.com/doc/rest-api/search/#save-rule) operations\n- `search_rules_operations`: number of [search rules](https://www.algolia.com/doc/rest-api/search/#search-rules) operations\n\n#### Insights operations\n\n- `insights_operations`: number of operations on the Insights API.\n\n#### Total operations\n\n- `total_search_operations`: sum of all [search operations](#search-operations)\n- `total_search_requests`: number of [search requests](https://support.algolia.com/hc/en-us/articles/4406981829777-How-does-Algolia-count-records-and-operations-). The number of billed search requests is equal to this value minus `querysuggestions_total_search_requests`\n- `total_recommend_requests`: number of [Recommend requests](https://www.algolia.com/doc/guides/algolia-ai/recommend/)\n- `total_acl_operations`: sum of all [ACL operations](#acl-operations)\n- `total_indexing_operations`: sum of all [indexing operations](#indexing-operations)\n- `total_records_operations`: sum of all [record operations](#record-operations)\n- `total_synonym_operations`: sum of all [synonym operations](#synonym-operations)\n- `total_rules_operations`: sum of all [Rule operations](#rule-operations)\n- `total_write_operations`: number of Write operations\n- `total_read_operations`: number of Read operations\n- `total_operations`: sum of all operations\n\n#### Total Query Suggestions operations\n\n[Query Suggestions](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/query-suggestions/js/) operations are a subset of `total_search_operations`.\n\n- `querysuggestions_total_search_operations`: number of Query Suggestions search operations\n- `querysuggestions_total_search_requests`: number of Query Suggestions [search requests](https://support.algolia.com/hc/en-us/articles/4406981829777-How-does-Algolia-count-records-and-operations-)\n- `querysuggestions_total_acl_operations`: sum of all Query Suggestions [ACL operations](#acl-operations)\n- `querysuggestions_total_indexing_operations`: number of Query Suggestions [indexing operations](#indexing-operations)\n- `querysuggestions_total_records_operations`: number of Query Suggestions [record operations](#record-operations)\n- `querysuggestions_total_synonym_operations`: number of Query Suggestions [synonym operations](#synonym-operations)\n- `querysuggestions_total_rules_operations`: number of Query Suggestions [Rule operations](#rule-operations)\n- `querysuggestions_total_write_operations`: number of Query Suggestions Write operations\n- `querysuggestions_total_read_operations`: number of Query Suggestions Read operations\n- `querysuggestions_total_operations`: sum of all Query Suggestions operations\n\n#### Processing time\n\n- `avg_processing_time`: average processing time (in milliseconds)\n- `90p_processing_time`: 90th percentile of processing time (in milliseconds)\n- `99p_processing_time`: 99th percentile of processing time (in milliseconds)\n- `queries_above_last_ms_processing_time`: number of queries that take one or more seconds to process\n\n#### Indices\n\n- `records`: number of records\n- `data_size`: the size of the indices' records (in bytes)\n- `file_size`: the size of the indices' records _and_ metadata (in bytes)\n\n#### Maximum QPS (query per second)\n\n- `max_qps`: [maximum queries per second](https://support.algolia.com/hc/en-us/articles/4406975224721) over the time range (per server)\n- `region_max_qps`: maximum queries per second over the time range (per region)\n- `total_max_qps`: maximum queries per second across all servers\n\n#### Used search capacity\n\n- `used_search_capacity`: maximum search capacity used (in percentage per server)\n- `avg_used_search_capacity`: average search capacity used (in percentage per server)\n- `region_used_search_capacity`: maximum search capacity used (in percentage per region)\n- `region_avg_used_search_capacity`: average search capacity used (in percentage per region)\n- `total_used_search_capacity`: maximum search capacity used (in percentage for all servers)\n- `total_avg_used_search_capacity`: average used search capacity (in percentage for all servers)\n\n#### Degraded queries\n\nUse these statistics to monitor the impact of [degraded queries](https://support.algolia.com/hc/en-us/articles/4406981934481).\n\n- `degraded_queries_ssd_used_queries_impacted`: percentage of queries that made the Algolia search engine read from the server's SSD.\n- `degraded_queries_ssd_used_seconds_impacted`: percentage of seconds affected by a `ssd_used` degradation.\n- `degraded_queries_max_capacity_queries_impacted`: percentage of queries degraded because all search threads were used.\n- `degraded_queries_max_capacity_seconds_impacted`: percentage of seconds affected by a `max_capacity` degradation.\n\nSome statistics provide information about the percentage of time when queries were degraded during the specified period.\nFor example, if `degraded_queries_max_capacity_seconds_impacted` shows 50%, there were `max_capacity` problems half of the time.\nThese issues might not happen continuously but at different times during the specified period.\n\n### Grouping\n\n- `*`: return all the usage statistics in the same response\n- `search_operations`: return all [search operations](#search-operations)\n- `acl_operations`: return all [ACL operations](#acl-operations)\n- `indexing_operations`: return all [indexing operations](#indexing-operations)\n- `record_operations`: return all [record operations](#record-operations)\n- `synonym_operations`: returns all [synonym operations](#synonym-operations)\n- `rule_operations`: returns all [Rule operations](#rule-operations).\n" - }, - { - "name": "index", - "in": "path", - "description": "Index name.", - "required": true, - "schema": { - "type": "string", - "example": "YOUR_INDEX_NAME" - } - }, - { - "name": "startDate", - "in": "query", - "description": "Start date in [ISO-8601 format](https://wikipedia.org/wiki/ISO_8601).", - "required": true, - "schema": { - "type": "string", - "example": "2023-08-12T14:30:00Z" - } - }, - { - "name": "endDate", - "in": "query", - "description": "End date in [ISO-8601 format](https://wikipedia.org/wiki/ISO_8601).", - "required": true, - "schema": { - "type": "string", - "example": "2023-08-19T16:45:00Z" - } - }, - { - "name": "granularity", - "in": "query", - "description": "Return hourly or daily statistics.\n\n- `hourly`: the maximum time range for this granularity is 7 days\n- `daily`: the maximum time range for this granularity is 365 days.\n", - "schema": { - "type": "string", - "enum": [ - "hourly", - "daily" - ], - "default": "daily" - } - } - ], - "responses": { - "200": { - "description": "Success.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "statistics": { - "type": "array", - "items": { - "type": "object", - "properties": { - "t": { - "type": "integer", - "description": "[Unix timestamp](https://www.unixtimestamp.com/) (in milliseconds).\n", - "example": 1455451200000 - }, - "v": { - "description": "Depending on the statistic, the type of this value (`v`) differs.\nMost statistics return integer values.\n\n`degraded_queries_*`, `max_qps`, and `used_search_capacity` are returned as maps of server name strings to integers.\n\n`region_*` statistics return strings (regions).\n", - "oneOf": [ - { - "type": "integer" - }, - { - "type": "object", - "properties": { - "serverName": { - "type": "string" - }, - "value": { - "type": "integer" - } - } - }, - { - "type": "string" - } - ] - } - } - } - } - } - } - } - } - }, - "400": { - "description": "Invalid request.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "401": { - "description": "Authorization information is missing or invalid." - }, - "403": { - "description": "Invalid credentials.", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "error": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "errors": { - "type": "array", - "items": { - "type": "object", - "properties": { - "code": { - "type": "string" - }, - "message": { - "type": "string" - }, - "line": { - "type": "integer" - }, - "position": { - "type": "integer" - } - }, - "required": [ - "message" - ], - "example": { - "message": "url is not defined", - "line": 5 - } - } - } - }, - "example": { - "code": "malformed_id" - } - } - }, - "required": [ - "error" - ] - } - } - } - }, - "404": { - "description": "Index not found.\n\nIf `index` has been correctly defined, this error message means that no data was found in the given time range.\nThe time range may lie outside the [data retention period](https://support.algolia.com/hc/en-us/articles/4406975230993-Can-I-extend-the-retention-period-of-the-analytics-data-).\n" - }, - "422": { - "description": "Metric not found." - } - } - } - } - } -} \ No newline at end of file