Configure Figena CLI profiles
Keep separate settings and credentials for each workspace or environment, and choose one per command.
Overview
A profile is a named set of settings with its own credentials. Use one profile per environment or workspace, for example production and staging, so a command never runs against the wrong place by accident. The CLI starts with a profile named default.
Settings you can store
apiBaseUrl: the Figena API address, for examplehttps://api.figena.com/api.orgId: the default workspace ID for commands that otherwise need--org.workspaceId: stored with the profile for your reference. Current commands read the workspace fromorgId.output: the default output format,table,json, orndjson.authType: the credential type recorded for the profile,userorservice.
Any other key is rejected with “unsupported config key”, and an invalid output format or credential type is rejected as well.
Create and switch profiles
# Create a profile and make it activefigena config init --profile production --api-base-url https://api.figena.com/api# Add a second profile without switching to itfigena profile create staging --api-base-url <staging-api-url># List profiles; the active one is markedfigena profile list# Switch the active profilefigena profile use stagingRead and change settings
figena config set orgId <workspace-id>figena config set output jsonfigena config get orgIdfigena config showconfig set and config get work on the profile selected for the command. config show prints the active profile name, the profile in use, and its settings.
Choose a profile for one command
Add --profile <name> to run a single command with another profile, and --api-base-url <url> to override the API address for that command without saving it. Global options can appear before or after the command name.
figena --profile staging auth statusfigena runs list --profile production --output jsonFind your workspace ID
Commands such as agents list, runs list, and knowledge list need a workspace ID from --org or the profile’s orgId. With an Agent Key, figena openport workspaces lists the workspaces the key can reach; otherwise ask your workspace administrator. Without an ID, these commands stop with a message such as “agents list requires --org or profile orgId”.