v53

latestOpenAPI 3.0.3raw.githubusercontent.com2026-08-076771,7565.2 MB
spaces

Copy saved objects between spaces

It also allows you to automatically copy related objects, so when you copy a dashboard, this can automatically copy over the associated visualizations, data views, and saved Discover sessions, as required. You can request to overwrite any objects that already exist in the target space if they share an identifier or you can use the resolve copy saved objects conflicts API to do this on a per-object basis.<br/><br/>[Required authorization] Route required privileges: copySavedObjectsToSpaces.

post/api/spaces/_copy_saved_objects

Headers

kbn-xsrfstring required
Example:true

A required header to protect against CSRF attacks

Request body

compatibilityModeboolean

Apply various adjustments to the saved objects that are being copied to maintain compatibility between different Kibana versions. Use this option only if you encounter issues with copied saved objects. This option cannot be used with the createNewCopies option.

createNewCopiesboolean

Create new copies of saved objects, regenerate each object identifier, and reset the origin. When used, potential conflict errors are avoided. This option cannot be used with the overwrite and compatibilityMode options.

includeReferencesboolean

When set to true, all saved objects related to the specified saved objects will also be copied into the target spaces.

overwriteboolean

When set to true, all conflicts are automatically overridden. When a saved object with a matching type and identifier exists in the target space, that version is replaced with the version from the source space. This option cannot be used with the createNewCopies option.

spacesstring[] required

Response

OK: A successful request.