Skip to main content

Orbis Studio CLI

The Orbis Studio command line interface is the main interface for managing and running the Orbis Studio server.

The Orbis Studio CLI is automatically installed when you install the Orbis Studio package. It isn't available for Orbis Studio Desktop.

How to use the CLI​

The Orbis Studio CLI can be invoked in several ways, depending on your installation method and environment.

The recommended approach is to run the CLI with uv run from within a virtual environment where Orbis Studio is installed.

For example, to start Orbis Studio on the default port, run the following command:


_10
uv run langflow run

If Orbis Studio is installed globally or added to your PATH, you can execute the CLI directly with langflow.


_10
langflow run

Precedence​

Orbis Studio CLI options override the values of environment variables set in your terminal or primary .env file.

For example, if you have ORBISAGENTS_PORT=7860 defined as an environment variable, and you run the CLI with --port 7880, then Orbis Studio sets the port to 7880 because the CLI option overrides the environment variable.

This also applies to Boolean environment variables. For example, if you set ORBISAGENTS_REMOVE_API_KEYS=True in your .env file, you can change it to False at runtime by running the CLI with --no-remove-api-keys.

Orbis Studio CLI options​

All Orbis Studio CLI commands support options that modify the command's behavior or set environment variables.

To set values for options, you can use either of the following syntax styles:

  • --option value
  • --option=value

Values with spaces must be surrounded by quotation marks:

  • --option 'Value with Spaces'
  • --option="Value with Spaces"

Boolean options​

Boolean options enable and disable settings. They have a true (enabled) and false (disabled) form:

  • Enabled (true): --option
  • Disabled (false): --no-option

The following examples compare Boolean option forms for REMOVE_API_KEYS.

--remove-api-keys is equivalent to setting ORBISAGENTS_REMOVE_API_KEYS=True in .env:


_10
uv run langflow run --remove-api-keys

In the following command references, default values for Booleans include both the CLI flag and the equivalent Boolean evaluation, such as "--option (true)" and "--no-option (false)".

Universal options​

The following options are available for all Orbis Studio CLI commands:

  • --version, -v: Show the version and exit.
  • --install-completion: Install auto-completion for the current shell.
  • --show-completion: Show the location of the auto-completion config file, if installed.
  • --help: Print information about command usage, options, and arguments.

CLI commands​

The following sections describe the available CLI commands and any additional options (beyond the universal options) available for each command.

langflow​

Running the CLI without any arguments prints a list of available options and commands.


_10
uv run langflow

langflow api-key​

Creates an Orbis Studio API key.

You must be a superuser to create API keys with the CLI. For more information, see Orbis Studio API keys.


_10
uv run langflow api-key

Options​

OptionDefaultTypeDescription
--log-levelerrorStringThe logging level. One of debug, info, warning, error, or critical.

langflow copy-db​

Copies the Orbis Studio database files from the cache directory to the current Orbis Studio installation directory, which is the directory containing __main__.py. You can find the copy target directory by running which langflow.

The following files are copied if they exist in the cache directory:

  • langflow.db: The main Orbis Studio database, stored in the user cache directory
  • langflow-pre.db: The pre-release database, if it exists

_10
uv run langflow copy-db

langflow migration​

Manages Orbis Studio database schema changes using Alembic, a database migration tool for SQLAlchemy.

The migration command has two modes:

  • Test mode (default): Checks if migrations can be applied safely without actually running the migrations. Use this mode to previews the changes that would be made to the database schema before proceeding with the migrations.

  • Fix mode: Applies the migrations to update the database schema.

    warning

    langflow migration --fix is a destructive operation that can delete data. Always run langflow migration first to preview the changes.

  1. Run test mode:

_10
uv run langflow migration

  1. Preview the changes returned by the test to determine if it's safe to proceed with the migration.

  2. Run fix mode to apply the changes:


_10
uv run langflow migration --fix

langflow run​

Starts the Orbis Studio server.


_10
uv run langflow run [OPTIONS]

Options​

This command supports some common and non-sensitive configuration options for your Orbis Studio server. Other options must be set in the .env or your terminal. For more information Orbis Studio configuration options, see Orbis Studio environment variables.

OptionDefaultTypeDescription
--auto-saving--auto-saving (true)BooleanWhether to enable flow auto-saving in the visual editor. Use --no-auto-saving to disable flow auto-saving.
--auto-saving-interval1000IntegerThe interval for flow auto-saving in milliseconds.
--backend-only--no-backend-only (false)BooleanWhether to run Orbis Studio's backend service only (no frontend). Omit or use --no-backend-only to start both the frontend and backend. See Start Orbis Studio in headless mode.
--cacheasyncStringThe type of cache storage to use. One of async, redis, memory, or disk.
--components-pathNot setStringThe path to the directory containing your custom components.
--dev--no-dev (false)BooleanWhether to run in development mode (may contain bugs).
--env-fileNot setStringThe path to the .env file containing Orbis Studio environment variables. See Start Orbis Studio with a specific .env file.
--frontend-pathNot setStringThe path to the frontend directory containing build files. This is only used when contributing to the Orbis Studio codebase or developing a custom Orbis Studio image that includes customized frontend code.
--health-check-max-retries5IntegerThe maximum number of retries for your Orbis Studio server's health check.
--hostlocalhostStringThe host on which the Orbis Studio server will run.
--log-filelogs/langflow.logStringThe path to the log file for Orbis Studio.
--log-levelcriticalStringThe logging level as one of debug, info, warning, error, or critical.
--log-rotationNot setStringThe log rotation interval, either a time duration or file size.
--max-file-size-upload1024IntegerThe maximum size in megabytes for file uploads.
--open-browser--no-open-browser (false)BooleanWhether to open the system web browser on startup. Use --open-browser to open the system's default web browser when Orbis Studio starts.
--port7860IntegerThe port on which the Orbis Studio server will run. The server automatically selects a free port if the specified port is in use.
--remove-api-keys--no-remove-api-keys (false)BooleanWhether to remove API keys and tokens from flows saved in the Orbis Studio database.
--ssl-cert-file-pathNot setStringThe path to the SSL certificate file on the local system for SSL-encrypted connections.
--ssl-key-file-pathNot setStringThe path to the SSL key file on the local system for SSL-encrypted connections.
--worker-timeout300IntegerThe Orbis Studio server worker timeout in seconds.
--workers1IntegerThe number of Orbis Studio server worker processes.

Start Orbis Studio with a specific .env file​

The --env-file option starts Orbis Studio using the configuration defined in the given .env file. Additional options appended to this command override the values in the .env file if there are duplicates.

If --env-file is omitted or doesn't include all required variables, Orbis Studio uses the default values for those variables.


_10
uv run langflow run --env-file PATH/TO/LANGFLOW/.env

Start Orbis Studio in headless mode​

The --backend-only option starts Orbis Studio's backend service only. This headless mode has no frontend (visual editor), and you can only access the server programmatically with the Orbis Studio API and CLI.


_10
uv run langflow run --backend-only

langflow superuser​

Creates a superuser account with the given username and password.


_10
uv run langflow superuser --username [NAME] --password [PASSWORD] [OPTIONS]

Options​

OptionDefaultTypeDescription
--log-levelerrorStringThe logging level. One of debug, info, warning, error, or critical.

For this command, --username and --password aren't optional, and they have no default value. The command fails if you don't provide these arguments. For more information, see ORBISAGENTS_SUPERUSER and ORBISAGENTS_SUPERUSER_PASSWORD.

Disable CLI superuser creation​

The langflow superuser command is controlled by the ORBISAGENTS_ENABLE_SUPERUSER_CLI environment variable:

  • ORBISAGENTS_ENABLE_SUPERUSER_CLI=True (default): The langflow superuser command is available, and superuser creation is unrestricted.
  • ORBISAGENTS_ENABLE_SUPERUSER_CLI=False (recommended): Disables the langflow superuser command. For security reasons, this is recommended to prevent unauthorized superuser creation, especially in production environments.

To disable the langflow superuser command, you must set ORBISAGENTS_ENABLE_SUPERUSER_CLI=False in your Orbis Studio .env file, and then start Orbis Studio with your .env file.