Skip to content

Profiles & configuration

A profile is your saved connection to an Alteryx One workspace (and, optionally, Alteryx Server). ayx keeps profiles in a central config home, so you can switch environments without editing files by hand.

Platform Config home
macOS / Linux ~/.config/ayx
Windows %AppData%\ayx

Override it with the AYX_CONFIG_HOME environment variable.

ayx onboard creates a profile, saves it under the name you give it, and makes it active. Run it again with a different name to keep several — one per workspace or environment:

Terminal window
ayx profile list # every stored profile
ayx profile current # the active one
ayx profile use <name> # change the active profile

Run a single command against a different profile without changing your default:

Terminal window
ayx whoami --profile staging

Import a legacy YAML file into the central store and give it a name:

Terminal window
ayx profile migrate --profile /path/to/old.yaml --name my-profile

After onboarding and signing in, a One profile is small — the connection details plus a reference to the stored token:

profile_name: my-profile
alteryx_one:
account_email: admin@example.com
base_url: https://us1.alteryxcloud.com
workspace_gid: 01ARZ3NDEKTSV4RRFFQ69G5FAV
access_token_ref: keyring:my-profile/alteryx_one.access_token

You don’t write the token in by hand — ayx one login obtains it and stores it for you (in your OS keyring where available; see Connecting). base_url and workspace_gid come from the workspace URL you paste during onboarding.

Any secret can be a reference instead of a literal, so nothing sensitive sits in plaintext:

  • keyring:<account> — resolved from the OS keyring (the default once a keyring backend is available).
  • env:VARNAME — read from an environment variable at run time, the usual choice for CI.
alteryx_one:
account_email: admin@example.com
base_url: https://us1.alteryxcloud.com
access_token_ref: env:AYX_ONE_API_ACCESS_TOKEN

A single profile can carry a separate token per workspace under workspace_credentials, keyed by workspace id. Bind a login to a workspace, then switch which one is active:

Terminal window
ayx one login --workspace-id <id> # store that workspace's token
ayx one workspace switch <id> # make it active

The active workspace’s token is used for every One command until you switch again. expected_workspace_id guards mutating commands against running on the wrong workspace.

environments.yaml holds several named environments in one file — workspace_name, active_environment, and an environments map. Switch for a single run:

Terminal window
ayx --environment prod one flows list

Like --output, --environment is a global flag, so it can appear before or after the subcommand.

Credentials can come from environment variables instead of the profile — handy for CI:

Variable Sets
AYX_ONE_API_ACCESS_TOKEN Access token
AYX_ONE_API_REFRESH_TOKEN Refresh token
AYX_ONE_OAUTH_CLIENT_ID OAuth client ID for the --browser/--device flows (alias: AYX_ONE_CLIENT_ID)
AYX_ONE_CLIENT_SECRET OAuth client secret (advanced flows)

The full resolution order — flags, then environment, then profile, then defaults — is in the runtime config contract.