Add doc string for the `auth token` command (#2302)

## Changes
The intent of this PR is to clarify that the `databricks auth token`
command is not supported for M2M auth. Fixes:
https://github.com/databricks/cli/issues/1939

## Tests
Manually.
This commit is contained in:
shreyas-goenka 2025-02-07 17:21:37 +05:30 committed by GitHub
parent 54e16d5f62
commit 65ac9a336a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 0 deletions

View File

@ -46,6 +46,10 @@ func newTokenCommand(persistentAuth *auth.PersistentAuth) *cobra.Command {
cmd := &cobra.Command{ cmd := &cobra.Command{
Use: "token [HOST]", Use: "token [HOST]",
Short: "Get authentication token", Short: "Get authentication token",
Long: `Get authentication token from the local cache in ~/.databricks/token-cache.json.
Refresh the access token if it is expired. Note: This command only works with
U2M authentication (using the 'databricks auth login' command). M2M authentication
using a client ID and secret is not supported.`,
} }
var tokenTimeout time.Duration var tokenTimeout time.Duration