Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Note
This information applies to Databricks CLI versions 0.205 and above. The Databricks CLI is in Public Preview.
Databricks CLI use is subject to the Databricks License and Databricks Privacy Notice, including any Usage Data provisions.
Note
The databricks dashboards
command group is for legacy dashboards. For AI/BI dashboards, use databricks lakeview commands.
The dashboards
command group within the Databricks CLI allows you to manage legacy dashboard objects.
databricks dashboards create
Create a dashboard object.
databricks dashboards create [flags]
Arguments
None
Options
--json JSON
The inline JSON string or the @path to the JSON file with the request body.
Examples
The following example creates a dashboard using a JSON file:
databricks dashboards create --json @dashboard-config.json
databricks dashboards delete
Remove a dashboard to the trash. Trashed dashboards do not appear in list views or searches, and cannot be shared.
databricks dashboards delete DASHBOARD_ID [flags]
Arguments
DASHBOARD_ID
The ID of the dashboard to delete.
Options
Examples
The following example deletes a dashboard:
databricks dashboards delete 12345
databricks dashboards get
Retrieve a JSON representation of a dashboard object, including its visualization and query objects.
databricks dashboards get DASHBOARD_ID [flags]
Arguments
DASHBOARD_ID
The ID of the dashboard to retrieve.
Options
Examples
The following example retrieves a dashboard definition:
databricks dashboards get 12345
databricks dashboards list
Fetch a paginated list of dashboard objects.
Important
Running this command concurrently 10 or more times could result in throttling, service degradation, or a temporary ban.
databricks dashboards list [flags]
Arguments
None
Options
--order ListOrder
Name of dashboard attribute to order by. Supported values: created_at
, name
.
--page int
Page number to retrieve.
--page-size int
Number of dashboards to return per page.
--q string
Full text search term.
Examples
The following example lists all dashboards:
databricks dashboards list
The following example lists dashboards with pagination:
databricks dashboards list --page 2 --page-size 10
The following example lists dashboards ordered by creation date:
databricks dashboards list --order created_at
The following example searches for dashboards by name:
databricks dashboards list --q "Sales Dashboard"
databricks dashboards restore
Restore a dashboard.
A restored dashboard appears in list views and searches and can be shared.
databricks dashboards restore DASHBOARD_ID [flags]
Arguments
DASHBOARD_ID
The ID of the dashboard to restore.
Options
Examples
The following example restores a dashboard:
databricks dashboards restore 12345
databricks dashboards update
Change a dashboard definition. This operation only affects attributes of the dashboard object. It does not add, modify, or remove widgets.
Note: You cannot undo this operation.
databricks dashboards update DASHBOARD_ID [flags]
Arguments
DASHBOARD_ID
The ID of the dashboard to update.
Options
--json JSON
The inline JSON string or the @path to the JSON file with the request body.
--name string
The title of this dashboard that appears in list views and at the top of the dashboard page.
--run-as-role RunAsRole
Sets the Run as role for the object. Supported values: owner
, viewer
.
Examples
The following example updates a dashboard's name:
databricks dashboards update 12345 --name "Updated Dashboard Name"
The following example updates a dashboard's run-as role:
databricks dashboards update 12345 --run-as-role viewer
Global flags
--debug
Whether to enable debug logging.
-h
or --help
Display help for the Databricks CLI or the related command group or the related command.
--log-file
string
A string representing the file to write output logs to. If this flag is not specified then the default is to write output logs to stderr.
--log-format
format
The log format type, text
or json
. The default value is text
.
--log-level
string
A string representing the log format level. If not specified then the log format level is disabled.
-o, --output
type
The command output type, text
or json
. The default value is text
.
-p, --profile
string
The name of the profile in the ~/.databrickscfg
file to use to run the command. If this flag is not specified then if it exists, the profile named DEFAULT
is used.
--progress-format
format
The format to display progress logs: default
, append
, inplace
, or json
-t, --target
string
If applicable, the bundle target to use