Databricks CLI

Note

Databricks CLI use is subject to the Databricks License and Databricks Privacy Notice, including any Usage Data provisions.

The Databricks CLI (command-line interface) allows you to interact with the Azure Databricks platform from your local terminal or automation scripts. You can also run Databricks CLI commands from within a Databricks workspace using web terminal. See Run shell commands in Azure Databricks web terminal.

To install and configure authentication for the Databricks CLI, see Install or update the Databricks CLI and Authentication for the Databricks CLI.

Tip

The Databricks CLI source is publicly available in the databricks/cli GitHub repository.

How does the Databricks CLI work?

The CLI wraps the Databricks REST API, which provides endpoints for modifying or requesting information about Azure Databricks account and workspace objects. See the Azure Databricks REST API reference.

For example, to print information about an individual cluster in a workspace:

databricks clusters get 1234-567890-a12bcde3

With curl, the equivalent operation is as follows:

curl --request GET "https://${DATABRICKS_HOST}/api/2.0/clusters/get" \
     --header "Authorization: Bearer ${DATABRICKS_TOKEN}" \
     --data '{ "cluster_id": "1234-567890-a12bcde3" }'

Databricks CLI version release types

The release type of the Databricks CLI corresponds to the version:

  • Versions 1.0.0 and above are generally available (GA).
  • Versions 0.205 through 0.299 are Public Preview.
  • Versions 0.18 and below are legacy CLI.

Legacy CLI

The legacy Databricks CLI is versions 0.18 and below.

  • Databricks plans no support or new feature work for the legacy Databricks CLI.
  • For more information about the legacy Databricks CLI, see Legacy Databricks CLI.
  • To migrate from Databricks CLI version 0.18 or below to Databricks CLI version 0.205 or above, see Databricks CLI migration.

Next steps