Skip to main content

Configuration reference

CLI and SDK share remote transport configuration, but only the CLI automatically reads the API address from .env.local in the current directory.

ConfigurationCLISDKMeaning
ENVLOOP_BASE_URLEnvironment or .env.localEnvironment onlyPlatform address, production https://api.envloop.ai
ENVPLATFORM_API_URLCompatibility fallbackCompatibility fallbackLegacy address variable
ENVLOOP_API_KEYEnvironment onlyEnvironment or api_key=Bearer Key; no CLI --api-key
ENVLOOP_WORKSPACE_IDEnvironment or --workspace-idEnvironment or workspace_id=Optional authorized workspace
ENVLOOP_LOG_LEVELEnvironmentEnvironmentApplication logging level; importing the SDK does not install a global handler

Address precedence​

CLI: --api-url → system environment → current directory .env.local. Within the same source, ENVLOOP_BASE_URL takes precedence over the legacy variable. The file supports quoted values, end-of-line comments, and an export prefix; Keys and other variables in the file are not loaded.

SDK: Client.remote(api_url=...) → system ENVLOOP_BASE_URL → system legacy variable. Missing or invalid addresses raise errors without silently switching to local execution. Explicit api_key / workspace_id overrides the corresponding environment variables.

Without any configured address, the CLI uses the in-process local backend; explicit repository / work-dir options or Profile operations skip the file's address. If the shell environment specifies a remote address, combining it with local options causes an argument error; clear address variables first.

URL rules​

  • Production: https://api.envloop.ai. The transport supports an existing /v1 suffix.
  • Full local platform: http://127.0.0.1:5173/api/, retaining the /api prefix.
  • Trusted local JobMaster: for example, http://127.0.0.1:8000; use the actual service port.
  • Public HTTP, credentials in URLs, query / fragment components, and automatic redirects are rejected.

Production clients should not send Bearer Keys to the old workers.dev web address. Adjust ports when development configuration changes them.

Local storage and lifecycle​

Parameter / pathBehavior
work_dir / --work-dirLocal task execution and artifact directory; does not change the log directory
repository_root / --repository-rootExplicit repository binding; top-level paths are not currently discovered automatically
repository_commit / --repository-commitSpecify a fixed commit; omission resolves local main, not current HEAD
logs/trials/<trial_id>/Local stdout/stderr logs and manifest under the current directory at startup

The repository supports Dataset / Profile and completed receipts; without binding, state is held in instance memory and does not persist across processes. Closing a local client waits for accepted execution; closing a remote client does not cancel platform work.