Hi,
It looks like there is a bug in the documentation for Create saved objects API.
If you click on the "Copy as cURL" the copied example has a couple of issues:
- Missing closing quatation marks after "my-pattern"
- Duplicate and misplaced headers
- Escape character at the end of the code
curl -X POST "localhost:5601/api/saved_objects/index-pattern/my-pattern -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d '" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d'
{
"attributes": {
"title": "my-pattern-*"
}
}\u0027
'