Dashboard API - Create a dashboard object doesn't work
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-14-2023 04:35 AM
I am trying to copy a dashboard object from one workspace to another using API.
I am using Get dashboard objects (/api/2.0/preview/sql/dashboards GET method), then Retrieve a definition (/api/2.0/preview/sql/dashboards/{dashboard_id} GET method) and after retrieving a definition. Until this step, everything seems fine, but the last step in my opinion is somehow broken. I am trying to restore the dashboard using Create a dashboard object (/api/2.0/preview/sql/dashboards POST method). The engine will return 200 and the object created but the widgets are equal to None, so the object is created and visible on Dashboards screen but in fact, it is quite empty.
Can you help me?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-09-2023 08:09 AM
@Mariusz Czak :
Here are a few things you can check:
- Make sure that you are passing all the required parameters to the Create a dashboard object API endpoint. Check the API documentation to see if there are any parameters that you might have missed.
- Verify that the widget IDs in the original dashboard are unique and that they are not used in any other dashboards or widgets in the new workspace. If the IDs are not unique, it could cause conflicts during the copying process.
- Check if the widgets in the original dashboard are using any resources or connections that are not available in the new workspace. If so, you may need to create those resources or connections in the new workspace before you can successfully copy the dashboard.
- Try creating a new dashboard manually in the new workspace and add a few widgets to it. Then, retrieve the definition of the new dashboard and compare it to the definition of the original dashboard to see if there are any differences. This may give you some clues as to what might be causing the issue.
Let me know if any of the above suggestions work for you, if not we can try and figure out more.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-20-2023 02:23 AM
Hi @Mariusz Czak
Thank you for posting your question in our community! We are happy to assist you.
To help us provide you with the most accurate information, could you please take a moment to review the responses and select the one that best answers your question?
This will also help other community members who may have similar questions in the future. Thank you for your participation and let us know if you need any further assistance!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-30-2023 01:41 AM
Any updates on this? I'm facing the same issue. I deleted the original dashboard and tried to recreate it with the template which at least would map the dashboard to the original resoureces. The result was the same that @Mist3 had.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-02-2024 08:36 AM
I'm facing the same issue. I'm even trying to duplicate a dashboard on the same environment, which would rule out any issue of missing resources. The dashboard is created empty; no widgets. Either the API is broken or the documentation is misleading. From the docs:
"Other fields can be included when duplicating dashboards with this API"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-05-2024 07:02 AM - edited 02-05-2024 07:02 AM
Hi there -
We recommend using the export/import API for moving Lakeview dashboards between workspaces. Documentation of the capability here.
We'll take a look at the current DBSQL dashboard GET/CREATE/UPDATE API and improve clarity there.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-16-2024 12:53 PM
Hi @miranda_luna_db , unfortunately, when it comes to Lakeview dashboards, the workspace API documentation is equally confusing: check out my thread.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-17-2024 03:02 PM
Will reply on that thread.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-27-2024 12:55 AM
Hey @miranda_luna_db, is there any update or suggestions for the SQL dashboards (so not Lakeview).
I am experiencing exactly same behaviour when attempting to deploy dashboards through the API. I have first fetched an existing definition and I am attempting to create a new dashboard. Creating a dashboard succeeds but the "widgets" property is always null and thus the dashboards end up empty. I feel like my attempt is aligned with the create dashboard API documentation:
"Other fields can be included when duplicating dashboards with this API. Databricks does not recommend designing dashboards exclusively using this API."
The lakeview dashboards are not really an option at the moment for my team as they do not support query parameters.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-29-2024 10:05 AM
Hi @markusk, unfortunately the issue you're running into is a limitation of the outgoing SQL dashboard APIs. You can create blank dashboards, but you cannot programmatically insert existing definitions.
The good news is we're currently running a preview for import/export APIs that addresses precisely this. The import/export APIs allow you to create new or override existing dashboards with an existing definition. If you'd like access, please work with your account team to get set up.
On the Lakeview front, parameter support is top of mind for us!

