Copy Settings
editSettings
ACL
$client->copySettings( string indexNameSrc, string indexNameDest );
About this method
You are currently reading the JavaScript API client v4 documentation. Check our migration guide to learn how to upgrade from v3 to v4. You can still access the v3 documentation.
You are currently reading the Ruby API client v2 documentation. Check our migration guide to learn how to upgrade from v1 to v2. You can still access the v1 documentation.
Copy the settings of an index to another index on the same app.
When creating a new index (for example, a temporary testing index or a new replica), you may need to copy the settings from a source of truth.
Note that this removes all settings currently present in the destination index, and replaces them with the settings from the source.
If the destination index you’ve named doesn’t exist, the method creates it. The newly created index has the settings of the source index, but not the records, Rules, or synonyms.
This method only copies index settings, not Rules and synonyms. You can use the copyIndex
method to copy Rules, synonyms, settings or records.
Examples
Copy settings
1
$client->copySettings('indexNameSrc', 'indexNameDest');
Parameters
indexNameSrc
|
type: string
Required
Name of the source index to copy. |
indexNameDest
|
type: string
Required
Name of the destination index. |
Response
No response