[ELK]-使用API自动创建kibana索引

官网地址

https://www.elastic.co/guide/en/kibana/current/saved-objects-api-delete.html
https://www.elastic.co/guide/en/kibana/current/saved-objects-api-create.html

添加索引

curl -X POST "10.0.0.51:5601/api/saved_objects/index-pattern/twitter" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d'
{
  "attributes": {
    "title": "twitter"
  }
}
'

删除索引

curl -X DELETE "10.0.0.51:5601/api/saved_objects/index-pattern/twitter" -H 'kbn-xsrf: true'
原文地址:https://www.cnblogs.com/alaska/p/12860182.html