delete-index.asciidoc 725 B

12345678910111213141516171819
  1. [[indices-delete-index]]
  2. == Delete Index
  3. The delete index API allows to delete an existing index.
  4. [source,js]
  5. --------------------------------------------------
  6. $ curl -XDELETE 'http://localhost:9200/twitter/'
  7. --------------------------------------------------
  8. The above example deletes an index called `twitter`. Specifying an index,
  9. alias or wildcard expression is required.
  10. The delete index API can also be applied to more than one index, or on
  11. all indices (be careful!) by using `_all` or `*` as index.
  12. In order to disable allowing to delete indices via wildcards or `_all`,
  13. set `action.destructive_requires_name` setting in the config to `true`.
  14. This setting can also be changed via the cluster update settings api.