Embeds
Rename an embed
Change the name and description of a dashboard embed, and optionally of its dashboard.
PUT
curl --request PUT https://api.usedatabrain.com/api/v2/data-app/embeds/rename \ --header "Authorization: Bearer $DATABRAIN_API_TOKEN" \ --header "Content-Type: application/json" \ --data '{ "embedId": "sales-overview", "name": "Sales at a glance", "isRenameDashboard": true }'Auth
A data app API token. See Authentication.
DataAppApiTokenheader
AuthorizationBearer <token>A data app API token. A service token is refused.
Body
A dashboard embed of the data app.
The new name. Cannot be empty.
embedDescriptionstring
The new description. "" does not clear it.
isRenameDashboardboolean
Also rename the dashboard. Every embed of that dashboard shows the new name. Send a JSON boolean.
Default:
falseResponse
{ "id": "sales-overview", "name": "Sales at a glance", "embedDescription": null }Errors
| Status | error.code | Why |
|---|---|---|
| 400 | INVALID_REQUEST_BODY | embedId or name is missing or empty |
| 400 | INVALID_DATA_APP_API_KEY | You used a service token |
| 400 | INVALID_EMBED_ID | No dashboard embed of this data app has this id |
| 500 | INTERNAL_SERVER_ERROR | The rename failed |
For errors that every endpoint returns, see Authentication.
curl -X PUT 'https://api.usedatabrain.com/api/v2/data-app/embeds/rename' \ -H 'Content-Type: application/json' \ -d '{ "embedId": "sales-overview", "name": "Sales at a glance", "isRenameDashboard": true}'Example Response
{ "id": "sales-overview", "name": "Sales at a glance", "embedDescription": null}