Preview swap references
Base URL
https://{kibana_url}
POST
/api/data_views/swap_references/_preview
Auth
Preview the effect of swapping saved object references from one data view to another. Returns the list of affected saved objects without making any changes.
Expand all
Cross-site request forgery protection
{
}
delete
boolean
Deletes referenced saved object if all references are removed.
forId
union string | string []
Limit the affected saved objects to one or more by identifier.
forType
string
Limit the affected saved objects by type.
fromId
string
required
The saved object reference to change.
fromType
string
Specify the type of the saved object reference to alter. The default value is index-pattern for data views.
toId
string
required
New saved object reference value to replace the old value.
200
Indicates a successful call.
application/json
result
object []
+
Show 2 properties
id
string
A saved object identifier.
type
string
The saved object type.
Thank you for your feedback.
Base URL
https://{kibana_url}
Examples
Request
Console
1 / 2 languages
‹
›
Preview the saved objects that would be affected by swapping references from one data view to another.
Show more
1
2
POST kbn://api/data_views/swap_references/_preview
{"fromId":"abcd-efg","toId":"xyz-123"}
1
2
3
4
5
6
curl \
-X POST "${KIBANA_URL}/api/data_views/swap_references/_preview" \
-H "Authorization: ApiKey ${API_KEY}" \
-H "kbn-xsrf: true" \
-H "Content-Type: application/json" \
-d '{"fromId":"abcd-efg","toId":"xyz-123"}'
Response
The result array lists every saved object that references the source data view. No saved objects are modified by the preview endpoint.
Show more
1
2
3
4
5
6
7
8
9
10
11
12
{
"result": [
{
"id": "8963ca30-bca7-11e8-aa00-0123456789ab",
"type": "visualization"
},
{
"id": "edf84fe0-e1a0-11e7-b6d5-4dc382ef7f5b",
"type": "dashboard"
}
]
}