Skip to content

Client Module

The Fluidize Client is the primary interface to create and edit projects. There are two interfaces for this, with more on the way.

  • Local Mode: Works with your local device, uses Docker to sequentially execute nodes.

  • API Mode: Runs on Fluidize API to manage projects and workflows in the cloud.

FluidizeClient(mode: Literal['local', 'api', 'auto'] = 'auto', base_path: Optional[Path] = None)

High-level client for interacting with Fluidize.

This client provides an intuitive interface for managing projects, nodes, and running simulation flows. It supports two modes:

  • API mode: Connects to the Fluidize cloud API
  • Local mode: Works with local Fluidize engine installation

Configuration is handled automatically through environment variables and the FluidizeConfig class.

Parameters:

Name Type Description Default
mode Literal['local', 'api', 'auto']

Operation mode - "local", "api", or "auto" for environment detection

'auto'
base_path Optional[Path]

Optional custom base path for local mode. If None, uses ~/.fluidize Config will handle all other settings via environment variables

None

mode: str property

Get the current operation mode.

Returns:

Name Type Description
str str

The current operation mode

projects = RegistryManager(self._adapter) instance-attribute

FluidizeConfig(mode: Literal['local', 'api', 'auto'] = 'auto', base_path: Optional[Path] = None)

Lightweight configuration for fluidize library.

Handles mode switching between local and API operations, and manages paths and settings for both modes.

Initialize configuration with specified mode.

Parameters:

Name Type Description Default
mode Literal['local', 'api', 'auto']

Operation mode - "local", "api", or "auto" for environment detection

'auto'
base_path Optional[Path]

Optional custom base path for local mode. If None, uses ~/.fluidize

None

is_local_mode() -> bool

Check if running in local mode.

is_api_mode() -> bool

Check if running in API mode.