POST /api/saved_objects/{type}

Spaces method and path for this operation:

post /s/{space_id}/api/saved_objects/{type}

Refer to Spaces for more information.

WARNING: This API is deprecated. This is a legacy Saved Objects API and may be removed in a future version of Kibana.

Creates a Kibana saved object; if an ID is provided it is used, otherwise Kibana generates one.

For transferring or backing up saved objects, prefer the import and export APIs (POST /api/saved_objects/_import and POST /api/saved_objects/_export).

Headers

  • kbn-xsrf string Required

    A required header to protect against CSRF attacks

Path parameters

  • type string Required

    The saved object type.

Query parameters

  • overwrite boolean

    Overwrite an existing saved object.

    Default value is false.

application/json

Body

  • attributes object Required
  • coreMigrationVersion string
  • initialNamespaces array[string]

    At least 1 but not more than 100 elements.

  • migrationVersion object
    Hide migrationVersion attribute Show migrationVersion attribute object
    • * string Additional properties
  • references array[object]

    Not more than 1000 elements.

    Hide references attributes Show references attributes object
    • id string Required
    • name string Required
    • type string Required
  • typeMigrationVersion string

Responses

  • 200 application/json

    A successful create response.

  • 409 application/json

    A conflict error.

POST /api/saved_objects/{type}
curl \
  -X POST "${KIBANA_URL}/api/saved_objects/dashboard/example-dashboard-id?overwrite=false" \
  -H "Authorization: ApiKey ${API_KEY}" \
  -H "kbn-xsrf: true" \
  -H "Content-Type: application/json" \
  -d '{"attributes":{"title":"Example dashboard"},"references":[]}'
POST kbn://api/saved_objects/dashboard/example-dashboard-id?overwrite=false
{"attributes":{"title":"Example dashboard"},"references":[]}
Request example
{
  "attributes": {
    "title": "Example dashboard"
  },
  "references": []
}
Response examples (200)
{
  "attributes": {
    "title": "Example dashboard"
  },
  "id": "example-dashboard-id",
  "managed": false,
  "namespaces": [
    "default"
  ],
  "references": [],
  "type": "dashboard",
  "updated_at": "2026-04-17T12:00:00.000Z",
  "version": "WzEsMV0="
}
Response examples (409)
{
  "error": "Conflict",
  "message": "Saved object [dashboard/example-dashboard-id] conflict",
  "statusCode": 409
}