# Can I update existing dashboard using UPDATE api?

**URL:** <https://discuss.elastic.co/t/can-i-update-existing-dashboard-using-update-api/257682>\
**Category:** Kibana\
**Created:** [December 4, 2020, 5:12pm UTC](https://discuss.elastic.co/t/can-i-update-existing-dashboard-using-update-api/257682 "2020-12-04T17:12:10Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![jhagen92](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jhagen92/32/80458_2.png) [@jhagen92](https://discuss.elastic.co/u/jhagen92)\
**Post date:** [December 4, 2020, 5:12pm UTC](https://discuss.elastic.co/t/can-i-update-existing-dashboard-using-update-api/257682/1 "2020-12-04T17:12:10Z")

</div>

Hi,

I am wondering if I can update existing dashboard using UPDATE api with saved json file. I am trying to see if I can revert my old changes back on dashboard back to Kibana. I am designing a way to have version control using provided APIs from elastic ([https://www.elastic.co/guide/en/kibana/master/saved-objects-api.html](https://www.elastic.co/guide/en/kibana/master/saved-objects-api.html))

---

<div class="post-metadata">

**Author:** ![wylie](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/wylie/32/81794_2.png) [@wylie](https://discuss.elastic.co/u/wylie)\
**Post date:** [December 4, 2020, 5:15pm UTC](https://discuss.elastic.co/t/can-i-update-existing-dashboard-using-update-api/257682/2 "2020-12-04T17:15:42Z")

</div>

Yes, this is why we have those APIs. Just be sure to have backups before doing it, because the JSON approach has very few safeguards to prevent the dashboard from breaking. Also keep in mind that a dashboard is usually composed of multiple visualizations, so you may need to update the dashboard _and_ all of its visualizations _and_ all of its index patterns at the same time. This is possible with the bulk API.

---

<div class="post-metadata">

**Author:** ![jhagen92](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jhagen92/32/80458_2.png) [@jhagen92](https://discuss.elastic.co/u/jhagen92)\
**Post date:** [December 4, 2020, 5:18pm UTC](https://discuss.elastic.co/t/can-i-update-existing-dashboard-using-update-api/257682/3 "2020-12-04T17:18:43Z")

</div>

Awesome. thanks for the reply. Just one quick question.

I will use UPDATE api, that means it will be something like this:

```auto
curl -X PUT api/saved_objects/<dashbaord or visualization>/<id> <some actual json>

```

is this right? In the example, I only see index.

---

<div class="post-metadata">

**Author:** ![wylie](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/wylie/32/81794_2.png) [@wylie](https://discuss.elastic.co/u/wylie)\
**Post date:** [December 4, 2020, 5:39pm UTC](https://discuss.elastic.co/t/can-i-update-existing-dashboard-using-update-api/257682/4 "2020-12-04T17:39:09Z")

</div>

That would work, but it might be easier to use the dashboard REST API. It lets you import/export the dashboard and everything it depends on: [https://www.elastic.co/guide/en/kibana/current/dashboard-api.html](https://www.elastic.co/guide/en/kibana/current/dashboard-api.html)

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [January 1, 2021, 5:39pm UTC](https://discuss.elastic.co/t/can-i-update-existing-dashboard-using-update-api/257682/5 "2021-01-01T17:39:25Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
