CLI

Environment Commands

Commands for managing environment variables and secrets

The env commands allow you to manage environment variables and secrets for your Agentuity projects.

env set

Sets environment variables or secrets for a project.

Usage

$
agentuity env set [key] [value] [flags]

Aliases: put, add

Flags:

  • -d, --dir string - The directory to the project to deploy (default ".")
  • -f, --file string - The path to a file containing environment variables to set
  • --force - Don't prompt for confirmation
  • -h, --help - help for set -s, --secret Force the value(s) to be treated as a secret

Examples

Set a single environment variable:

$
agentuity env set API_KEY your-api-key

✓ Environment variable saved

Set a secret:

$
agentuity env set --secret DB_PASSWORD your-password

✓ Secret saved

Set environment variables from a file:

$
agentuity env set --file .env

✓ Environment variables and secrets saved

All environment and secret values are encrypted at rest and in transit.

Secrets are like passwords. They should be treated as such. Never share them with anyone. Never store them in a source code repository. Never store them in a file that is not encrypted.

env list

Lists all environment variables and secrets for a project.

Usage

$
agentuity env list [flags]

Aliases: ls, show, print

Flags:

  • -d, --dir string - The directory to the project to deploy (default ".")
  • --format string - The format to use for the output. Can be either 'text' or 'json' (default "text")
  • -h, --help - help for list

Examples

$
agentuity env list

API_KEY=your-api-key DB_PASSWORD=********

env get

Gets the value of an environment variable or secret.

Usage

$
agentuity env get [key] [flags]

Flags:

  • -d, --dir string - The directory to the project to deploy (default ".")
  • --format string - The format to use for the output. Can be either 'text' or 'json' (default "text")
  • -h, --help - help for list

Examples

$
agentuity env get API_KEY

your-api-key

env delete

Deletes environment variables or secrets.

Usage

$
agentuity env delete

Aliases: rm, del

Flags:

  • -d, --dir string - The directory to the project to deploy (default ".")
  • --force - Don't prompt for confirmation
  • -h, --help - help for delete

Examples

Delete a single environment variable:

$
agentuity env delete API_KEY

✓ Environment variable deleted

Delete multiple environment variables:

$
agentuity env delete API_KEY DB_PASSWORD

✓ Environment variables and secrets deleted

You can also manage your environment variables and secrets in the Console.

Need Help?

Join our DiscordCommunity for assistance or just to hang with other humans building agents.

Send us an email at hi@agentuity.com if you'd like to get in touch.

Please Follow us on

If you haven't already, please Signup for your free account now and start building your first agent!

On this page