Validate required environment variables with the local `agentenv` CLI. Use when an agent workflow needs a startup check, deployment validation, or a machine-readable report of missing or empty variables.
Use agentenv to check environment prerequisites before running a model, sync task, or automation step.
Prefer the installed binary when it exists:
agentenv OPENAI_API_KEY HOME
If working inside this repository or the binary is not installed, run:
go run ./cmd/agentenv -- OPENAI_API_KEY HOME
-file required-env.txt to load names from a file.-allow-empty only when blank values are acceptable.-show-values only when exposing raw values is safe.-format json or -format yaml for automation.-format text for human review.-strict=true for CI, startup checks, and agent preflight.-show-values unless the environment is trusted and the output will not be logged.Validate a known set:
go run ./cmd/agentenv -- OPENAI_API_KEY AGENT_HOME MODEL_NAME
Load from file:
go run ./cmd/agentenv -- -file required-env.txt -format json