diff --git a/README.md b/README.md index 00d6dae..a1e6dee 100644 --- a/README.md +++ b/README.md @@ -65,10 +65,10 @@ To use Conduktor CLI, you need to: **Define 2 environment variables for Console**: - The URL of Conduktor Console - - Your API token (either a User Token or Application Token). You can generate an API token on `/settings/public-api-keys` page of your Console instance, or create one through the [CLI](https://docs.conduktor.io/platform/reference/cli-reference/#admin-api-key). + - Your API token (an Admin token, an Application token — scoped to a self-serve Application — or an Application Instance token). You can generate an API token on `/settings/public-api-keys` page of your Console instance, or create one through the [CLI](https://docs.conduktor.io/platform/reference/cli-reference/#admin-api-key). ```bash CDK_BASE_URL=http://localhost:8080 -CDK_API_KEY= +CDK_API_KEY= ``` **Define 3 environment variables for Gateway**: diff --git a/cmd/root.go b/cmd/root.go index 39ba83c..31bc85d 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -39,7 +39,7 @@ func gatewayAPIClient() *client.GatewayClient { var rootCmd = &cobra.Command{ Use: "conduktor", Short: "Command line tools for conduktor", - Long: `Make sure you've set the environment variables CDK_USER/CDK_PASSWORD or CDK_API_KEY (generated from Console) and CDK_BASE_URL. + Long: `Make sure you've set the environment variables CDK_USER/CDK_PASSWORD or CDK_API_KEY (an Admin, Application or Application Instance token generated from Console) and CDK_BASE_URL. Additionally, you can configure client TLS authentication by providing your certificate paths in CDK_KEY and CDK_CERT. For server TLS authentication, you can ignore the certificate by setting CDK_INSECURE=true, or provide a certificate authority using CDK_CACERT.`, PersistentPreRun: func(cmd *cobra.Command, args []string) { diff --git a/cmd/token.go b/cmd/token.go index 8705d04..8cbf036 100644 --- a/cmd/token.go +++ b/cmd/token.go @@ -26,7 +26,7 @@ func validateExpiresAt(expiresAt string) { var tokenCmd = &cobra.Command{ Use: "token", - Short: "Manage Admin and Application Instance tokens", + Short: "Manage Admin, Application and Application Instance tokens", Run: func(cmd *cobra.Command, args []string) { _ = cmd.Help() os.Exit(1) @@ -114,7 +114,7 @@ var createAdminTokenCmd = &cobra.Command{ Use: "admin ", Args: cobra.ExactArgs(1), Short: "Create an admin token", - Long: "You can use CDK_USER and CDK_PASSWORD environment variables to authenticate instead of CDK_TOKEN, in order to create your first token", + Long: "You can use CDK_USER and CDK_PASSWORD environment variables to authenticate instead of CDK_API_KEY, in order to create your first token", Run: func(cmd *cobra.Command, args []string) { username := os.Getenv("CDK_USER") password := os.Getenv("CDK_PASSWORD") diff --git a/docs/env-var-config.md b/docs/env-var-config.md index bf3117f..885cc19 100644 --- a/docs/env-var-config.md +++ b/docs/env-var-config.md @@ -11,7 +11,7 @@ These variables are required for managing Console resources (topics, users, grou #### Authentication (choose one method) **Method 1: API Key (Recommended)** -- **CDK_API_KEY**: API key generated from Console +- **CDK_API_KEY**: API key generated from Console (an Admin, Application or Application Instance token) **Method 2: Username/Password** - **CDK_USER**: Username for authentication