diff --git a/docs/api/saved-objects/create.asciidoc b/docs/api/saved-objects/create.asciidoc index 2f35740c0f9d..5f83513d58fe 100644 --- a/docs/api/saved-objects/create.asciidoc +++ b/docs/api/saved-objects/create.asciidoc @@ -59,12 +59,12 @@ any data that you send to the API is properly formed. [source,sh] -------------------------------------------------- -$ curl -X POST "localhost:5601/api/saved_objects/index-pattern/my-pattern" +$ curl -X POST "localhost:5601/api/saved_objects/index-pattern/my-pattern" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d ' { "attributes": { "title": "my-pattern-*" } -} +}' -------------------------------------------------- // KIBANA diff --git a/docs/api/saved-objects/export.asciidoc b/docs/api/saved-objects/export.asciidoc index e8c762b9543a..a992d13ed9b9 100644 --- a/docs/api/saved-objects/export.asciidoc +++ b/docs/api/saved-objects/export.asciidoc @@ -68,10 +68,10 @@ Export all index pattern saved objects: [source,sh] -------------------------------------------------- -$ curl -X POST "localhost:5601/api/saved_objects/_export" +$ curl -X POST "localhost:5601/api/saved_objects/_export" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d ' { "type": "index-pattern" -} +}' -------------------------------------------------- // KIBANA @@ -79,11 +79,11 @@ Export all index pattern saved objects and exclude the export summary from the s [source,sh] -------------------------------------------------- -$ curl -X POST "localhost:5601/api/saved_objects/_export" +$ curl -X POST "localhost:5601/api/saved_objects/_export" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d ' { "type": "index-pattern", "excludeExportDetails": true -} +}' -------------------------------------------------- // KIBANA @@ -91,7 +91,7 @@ Export a specific saved object: [source,sh] -------------------------------------------------- -$ curl -X POST "localhost:5601/api/saved_objects/_export" +$ curl -X POST "localhost:5601/api/saved_objects/_export" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d ' { "objects": [ { @@ -99,7 +99,7 @@ $ curl -X POST "localhost:5601/api/saved_objects/_export" "id": "be3733a0-9efe-11e7-acb3-3dab96693fab" } ] -} +}' -------------------------------------------------- // KIBANA @@ -107,7 +107,7 @@ Export a specific saved object and it's related objects : [source,sh] -------------------------------------------------- -$ curl -X POST "localhost:5601/api/saved_objects/_export" +$ curl -X POST "localhost:5601/api/saved_objects/_export" -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d ' { "objects": [ { @@ -116,6 +116,6 @@ $ curl -X POST "localhost:5601/api/saved_objects/_export" } ], "includeReferencesDeep": true -} +}' -------------------------------------------------- // KIBANA