Dashboards Instance
Dashboards
Plotly API allows users to store their Plotly dashboards The dashboards appear in the user's profile, and can be shared with others just like Plotly Plots.
Reference
Authorization
Any user with or without a Plotly account may view public dashboards. For private dashboards, see authentication.
Actions
create
You can create new dashboards here. The only required field is content
Example:
//POST https://api.plotly.com/v2/dashboards ---> 200 OK
{
"content": "{ "version": 2, "settings": {"title": "Dashboard"}}"
}
list
The list of the dashboards owned by a user can be retrieved by making the
GET request to the dashboards
endpoint, without supplying any
parameters. Users can only access their own dashboards using this
endpoint.
Example:
// GET https://api.plotly.com/v2/dashboards/
{
"results": [
{
"fid": "abc:123",
"world_readable":true..
},
{
"fid": "abc:456",
"world_readable":true..
},
]
}
retrieve
A single dashboard can be retrieved by a GET Request to the
dashboards
endpoint, along with the
fid of the required presentation,
as shown below
Example:
// GET https://api.plotly.com/v2/dashboards/{fid}
{
"fid": "abc:123",
"world_readable":true,
"content": "{ "version": 2, "settings": {"title": "Dashboard"}}"
},
update
To completely replace the writable meta information of an existing
dashboard, you make a PUT request to the dashboards
endpoint and include the fid
for the dashboard.
Note, only the writable meta information may be updated.
This includes content
, filename
, parent
(or parent_path
),
and world_readable
.
Note that parent_path
may be specified in place of the parent
field.
Unlike parent
, the parent_path
field is not an integer id, but rather
the complete path of the parent folder from your root folder
(e.g., '/folder_nested_off_root/parent_folder/'
).
A successful PUT response will have a status code of 200 OK.
Example:
// PUT https://api.plotly.com/v2/dashboards/bob:45 --> 200 OK
{
"parent": -1,
"world_readable": true,
"filename": "my_new_filename",
"content": "{ "version": 2, "settings": {"title": "Dashboard"}}"
}
partial update
To partially update an existing dashboard, you make a PATCH request to the
dashboards
endpoint and include the
fid for the dashboard.
Note, only the writable meta information may be updated.
This includes content
, filename
, parent
(or parent_path
),
and world_readable
.
A successful PATCH response will have a status code of 200 OK.
Example:
// PATCH https://api.plotly.com/v2/dashboards/bob:45 --> 200 OK
{
"world_readable": true,
"filename": "my_new_filename"
}
trash
This endpoint allows for the recoverable trashing of the dashboard specified in the endpoint detail.
A successful trash response will have a status code of 200 OK.
Example:
// POST https://api.plotly.com/v2/dashboards/plotlvr:9/trash ---> 200 OK
This request is idempotent. Trashing a dashboard that is already trashed will also succeed and return 200 OK.
permanent_delete
This endpoint allows for the permanent deletion of the dashboard specified in the endpoint detail.
A successful deletion response will have a status code of 204 No Content.
Example:
// DELETE https://api.plotly.com/v2/dashboards/plotlvr:9/permanent_delete ---> 204 No Content
schema
Return the JSON schema that defines the structure of a dashboard.
Example:
// GET https://api.plotly.com/v2/dashboards/schema ---> 200 OK
GET /v2/dashboards/swhanly:19?format=api
https://chart-studio.plotly.com/dashboard/swhanly:19/embed", "fid": "swhanly:19", "filename": "RoadLoad Example", "filetype": "dashboard", "img_url": "https://api.plotly.com/v2/files/swhanly:19/image?image_name=list-thumb", "image_urls": { "default": "https://api.plotly.com/v2/files/swhanly:19/image?image_name=default", "block-thumb": "https://api.plotly.com/v2/files/swhanly:19/image?image_name=block-thumb", "list-thumb": "https://api.plotly.com/v2/files/swhanly:19/image?image_name=list-thumb" }, "api_urls": { "files": "https://api.plotly.com/v2/files/swhanly:19", "dashboards": "https://api.plotly.com/v2/dashboards/swhanly:19", "parent": "https://api.plotly.com/v2/folders/home?user=swhanly" }, "owner": "swhanly", "parent": -1, "preview": "", "referencers": [], "references": [], "share_key": null, "share_key_enabled": null, "title": "Dashboard", "views": 109, "web_url": "https://chart-studio.plotly.com/~swhanly/19/dashboard/", "world_readable": true, "date_modified": "2020-12-29T01:17:02.044Z", "stars": { "results": [], "count": 0 }, "collaborators": { "results": [], "count": 0 }, "subfolder_count": null, "refresh_interval": null, "organize_view_url": "https://chart-studio.plotly.com/~swhanly/19/", "current_user_permission": "read", "is_theme": null, "is_template": null, "content": "{\"layout\": {\"size\": 708, \"type\": \"split\", \"first\": {\"type\": \"box\", \"title\": \"Example Dashboard for enDAQ Cloud\", \"fileId\": \"swhanly:31\", \"boxType\": \"plot\", \"shareKey\": null}, \"second\": {\"type\": \"box\", \"boxType\": \"empty\"}, \"sizeUnit\": \"px\", \"direction\": \"vertical\"}, \"version\": 2, \"settings\": {\"links\": [], \"title\": \"Dashboard\", \"logoUrl\": \"https://info.endaq.com/hubfs/endaq-logo-color-4.svg\", \"fontFamily\": \"inherit\", \"pageLayout\": \"dashboard\", \"boxBorderColor\": \"#DFE8F3\", \"headerFontSize\": \"1.2em\", \"backgroundColor\": \"#F3F6FA\", \"foregroundColor\": \"#506784\", \"textBoxFontSize\": \"1.6rem\", \"headerFontWeight\": \"400\", \"showControlPanel\": false, \"textBoxFontColor\": \"#444\", \"enableCrossfilter\": false, \"boxBackgroundColor\": \"#F3F6FA\", \"boxHeaderFontColor\": \"#506784\", \"headerBackgroundColor\": \"#FFFFFF\", \"headerForegroundColor\": \"#506784\", \"textBoxBackgroundColor\": \"#F3F6FA\", \"boxHeaderBackgroundColor\": \"#EBF0F8\"}}" }{ "creation_time": "2020-12-28T15:55:57.013998Z", "comments": null, "deleted": null, "parented": true, "embed_url": "