Docs

zitadel variable get

Get one variable from the project.

Usage

npx @zitadel/cli@latest variable get <name> [flags]

Arguments

ArgumentDescription
<name>Variable name to read. Required.

Flags

FlagDescription
--previewRead the preview value instead of the primary one.
-e, --env <value>Environment to run against, e.g. production. Defaults to ZITADEL_ENV, then the hosting platform's build (VERCEL_ENV, or Netlify's CONTEXT), then development.
--env-file <value>Read ZITADEL_* values from this file ahead of the process environment. A relative path is read from the current directory, not from --cwd. Cannot be combined with --env.

It also takes the global flags.

Examples

npx @zitadel/cli@latest variable get GOOGLE_CLIENT_ID
npx @zitadel/cli@latest variable get API_URL --preview
npx @zitadel/cli@latest variable get GOOGLE_CLIENT_ID --json

API

It calls Get a variable, GET /variables/{variable_name}, in the Variables API.

Was this helpful?