delete-index-template.asciidoc 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. [[indices-delete-template]]
  2. === Delete index template API
  3. ++++
  4. <titleabbrev>Delete index template</titleabbrev>
  5. ++++
  6. Deletes an <<index-templates,index template>>.
  7. ////
  8. [source,console]
  9. ----
  10. PUT /_index_template/my-index-template
  11. {
  12. "index_patterns" : ["te*"],
  13. "template": {
  14. "settings": {
  15. "number_of_shards": 1
  16. }
  17. }
  18. }
  19. ----
  20. // TESTSETUP
  21. ////
  22. [source,console]
  23. ----
  24. DELETE /_index_template/my-index-template
  25. ----
  26. [[delete-template-api-request]]
  27. ==== {api-request-title}
  28. `DELETE /_index_template/<index-template>`
  29. The provided <index-template> may contain multiple template names separated by a comma.
  30. If multiple template names are specified then there is no wildcard support and the
  31. provided names should match completely with existing templates.
  32. [[delete-template-api-prereqs]]
  33. ==== {api-prereq-title}
  34. * If the {es} {security-features} are enabled, you must have the
  35. `manage_index_templates` or `manage` <<privileges-list-cluster,cluster
  36. privilege>> to use this API.
  37. [[delete-template-api-desc]]
  38. ==== {api-description-title}
  39. Use the delete index template API to delete one or more index templates.
  40. Index templates define <<index-modules-settings,settings>>, <<mapping,mappings>>,
  41. and <<aliases,aliases>> that can be applied automatically to new indices.
  42. [[delete-template-api-path-params]]
  43. ==== {api-path-parms-title}
  44. include::{es-repo-dir}/rest-api/common-parms.asciidoc[tag=index-template]
  45. [[delete-template-api-query-params]]
  46. ==== {api-query-parms-title}
  47. include::{es-repo-dir}/rest-api/common-parms.asciidoc[tag=timeoutparms]