Open
Description
How does one go about deleting a virtual replica index?
Looking at the published documentation at
- https://www.algolia.com/doc/api-client/methods/indexing/#creating-indices
- https://www.algolia.com/doc/api-reference/api-methods/delete-index/
- https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/how-to/deleting-replicas/#using-the-api
It seems as though this should work, assuming a "main" index named "main" and a virtual replica named "virtual":
const client = algoliaSearch(ID, KEY);
const main = client.initIndex('main');
await main.setSettings({
replicas: []
});
const virtualIndex = client.initIndex('virtual');
await virtualIndex.delete();
However, the call to initIndex
for 'virtual'
yields this error response:
{
name: 'ApiError',
message: 'cannot apply a add object request on a replica index',
status: 403,
}
Is there some way other than initIndex
that I'm supposed to be getting a reference to a virtual replica index?
Metadata
Metadata
Assignees
Labels
No labels