Dashboard exportation workflow broken

Hi all,

We’re running into an issue with the dashboard export workflow in Grafana (v13.0.2).

Our setup:

We manage dashboards as code via a Git repository. Our Grafana instance does not allow developers to save dashboards directly — they make their changes in the UI, export the JSON, and commit it to the repo. A CI pipeline validates the JSON (checking for required fields like uid, unique titles, etc.) and deploys it.

The problem:

There are two export paths available:

Export → Export as code — This requires the dashboard to be saved first, which makes sense. It has the “Export for sharing externally” toggle that includes the uid and full metadata. But since our devs don’t have save permissions on the grafana production instance, this path is unavailable to them.

Export → Save to file (classic) — This path works without save permissions and lets you select Classic model, but it does not have the “Export for sharing externally” toggle. The resulting JSON is missing the top-level uid field which is required for the flow to work.

So for users without save permissions, there’s no way to get a complete JSON export that includes the dashboard uid.

Expected behavior:

The classic export path (Export → Save to file) should include the “Export for sharing externally” toggle (or simply always include the uid in the export). This is a read-only operation and shouldn’t depend on whether the user can save the dashboard.

Environment: Prod

Grafana version: 13.0.2

Thanks!

This looks like a current limitation of Grafana’s export workflow rather than a permission configuration issue.

If using the UI isn’t a hard requirement, a workaround is to retrieve the dashboard definition via the Dashboard HTTP API:

GET /api/dashboards/uid/:uid
Authorization: Bearer <token>

That returns the dashboard definition (including its uid), provided the token has permission to read the dashboard.

If your requirement is specifically to export the full dashboard JSON from the UI without save permissions, I couldn’t find a supported way to do that in the current documentation.

Hi @ccareau just wanted to check if you got the solution . Happy to help further if you are facing any issues .

Hi thanks for the feedback! Yeah, we have considered two path. So the current quick fix is to use the grafana dev instance where devs are editers on dashboards so they can export the json and make the PR in the centralised dashboard repo which deploys the dashboard to prod. The other way is we are using team folders with team sync where devs are admins on their folders directly on the prod instance, which allows for the same workflow but from the prod instance. We are not investigating git sync in order to get rid of all these fastidious processs and make everything happen from the prod instance

Yes, that makes sense. Git Sync seems like the better fit for the workflow you’re aiming for → developers can create and edit dashboards directly in Grafana, save them to a Git Sync–managed folder, and have the changes committed to Git or submitted as a PR without the export → commit → deploy workflow. Folder level permissions can also give developers edit/admin access only to their team’s synced folders.

That should address the main limitation described in the original post while keeping Git as the source of truth.

One thing worth testing before wider rollout → Git Sync is GA as of 13.0.0 but still shipping changes fast, so it’s probably worth piloting on a single folder first.

So you would not recommand the approach of having our specific team folders defined physically in the grafana-dashboard repo, and having our grafana repo fetch those folders and manage their permissions with terraform (give each team admin in their folders), and assign each teams their synced folders to their specific team folders? That was our original goal. Having one folder with sync is also possible but it’s not the ideal model for us as we want team separation for our folders, especially since we already have team sync enabled