Dashboard is not in its original folder


I am developing a bash script to change dashboard thresholds.

I import the dashboard with curl, and change the threshold values inside json, and I export the dashboard back to graphana, but when I export, it is not properly overwriting the dashboard, because it is not in its original folder. A folder called general is created and the dashboard is included there, and the previous version disappears from the original folder.

I don’t have much experience in graphana, and that was the only way I have found to change the thresholds externally.

I add overwrite = true to the dashboard, but the same thing keeps happening.

Export method:
curl -X POST -i -H Content-Type:application/json -H “Authorization: Bearer *******************************” -d @test.json http://admin:admin@localhost:3000/api/dashboards/db

Meta json:
“meta”: {
“type”: “db”,
“canSave”: true,
“canEdit”: true,
“canAdmin”: true,
“canStar”: true,
“overwrite”: true,
“slug”: “visao-geral”,
“expires”: “0001-01-01T00:00:00Z”,
“created”: “2019-10-22T15:55:50-03:00”,
“updated”: “2019-11-01T10:37:18-03:00”,
“updatedBy”: “admin”,
“createdBy”: “admin”,
“version”: 121,
“hasAcl”: false,
“isFolder”: false,
“folderId”: 12,
“folderTitle”: “MYfolderTitle”,
“folderUrl”: “/dashboards/f/MYfolderUrl”,
“provisioned”: false,
“provisionedExternalId”: “”

Grafana v6.4

Sorry for my english, it’s not my native language