Update a configuration

Updates a QuerySuggestions configuration.

Usage

Required ACL: editSettings
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
import { algoliasearch } from 'algoliasearch';

// Replace 'us' with your Algolia Application Region
const client = algoliasearch('ALGOLIA_APPLICATION_ID', 'ALGOLIA_API_KEY').initQuerySuggestions({ region: 'us' });

const response = await client.updateConfig({
  indexName: 'theIndexName',
  configuration: {
    sourceIndices: [
      { indexName: 'testIndex', facets: [{ attribute: 'test' }], generate: [['facetA', 'facetB'], ['facetC']] },
    ],
    languages: ['french'],
    exclude: ['test'],
  },
});
Did you find this page helpful?