Skip to content

ironflow platform

Manage the Ironflow platform: users, tenants, roles, and audit log.

Requires platform credentials (via ironflow platform login) or IRONFLOW_API_KEY.

Terminal window
ironflow platform <subcommand> [flags]

Bootstrap the first platform admin user. Refuses if any platform user already exists. Uses IRONFLOW_API_KEY for authentication (bootstrap runs before platform login is available).

Terminal window
ironflow platform create-admin --email <email> --name <name> [flags]
FlagShortTypeDefaultDescription
--emailstringAdmin email (required)
--namestringAdmin display name (required)
--server-sstringServer URL override

Password is read interactively from the terminal.

Examples:

Terminal window
ironflow platform create-admin --email admin@example.com --name "Admin"

Authenticate with email and password to obtain a platform JWT token. The token is stored in ~/.config/ironflow/credentials.json (or $IRONFLOW_CONFIG_DIR/credentials.json).

Terminal window
ironflow platform login --email <email> [flags]
FlagShortTypeDefaultDescription
--emailstringPlatform user email (required)
--server-sstringServer URL override

Examples:

Terminal window
ironflow platform login --email admin@example.com
ironflow platform login --email admin@example.com --server http://localhost:9000

Manage platform users.

Terminal window
ironflow platform users <subcommand> [flags]

List all platform users with their IDs, emails, names, and active status.

Terminal window
ironflow platform users list [flags]
FlagShortTypeDefaultDescription
--jsonboolfalseOutput as JSON
--server-sstringServer URL override

Examples:

Terminal window
ironflow platform users list
ironflow platform users list --json

Create a new platform user with email, name, and password.

Terminal window
ironflow platform users create --email <email> --name <name> [flags]
FlagShortTypeDefaultDescription
--emailstringUser email (required)
--namestringUser display name (required)
--role-ids[]stringRole IDs to assign
--server-sstringServer URL override

Password is read interactively from the terminal.

Examples:

Terminal window
ironflow platform users create --email user@example.com --name "User"
ironflow platform users create --email user@example.com --name "User" --role-ids role_abc

Delete a platform user by ID.

Terminal window
ironflow platform users delete <id> [flags]
FlagShortTypeDefaultDescription
--server-sstringServer URL override

Examples:

Terminal window
ironflow platform users delete usr_abc123

Platform API keys are managed through the unified ironflow apikey command with the --platform flag. See ironflow apikey.

Terminal window
# Create a platform key
ironflow apikey create my-platform-key --platform
# List platform keys
ironflow apikey list --platform
# Rotate a platform key
ironflow apikey rotate ak_abc123
# Delete a platform key
ironflow apikey delete ak_abc123

Manage tenants.

Terminal window
ironflow platform tenants <subcommand> [flags]

List all tenants with their IDs, names, and creation dates.

Terminal window
ironflow platform tenants list [flags]
FlagShortTypeDefaultDescription
--jsonboolfalseOutput as JSON
--server-sstringServer URL override

Examples:

Terminal window
ironflow platform tenants list
ironflow platform tenants list --json

Provision a new tenant.

Terminal window
ironflow platform tenants provision --name <name> [flags]
FlagShortTypeDefaultDescription
--namestringTenant name (required)
--server-sstringServer URL override

Examples:

Terminal window
ironflow platform tenants provision --name my-tenant

Delete a tenant by ID.

Terminal window
ironflow platform tenants delete <id> [flags]
FlagShortTypeDefaultDescription
--server-sstringServer URL override

Examples:

Terminal window
ironflow platform tenants delete tnt_abc123

Manage platform roles.

Terminal window
ironflow platform roles <subcommand> [flags]

List all platform roles with their IDs, names, and default status.

Terminal window
ironflow platform roles list [flags]
FlagShortTypeDefaultDescription
--jsonboolfalseOutput as JSON
--server-sstringServer URL override

Examples:

Terminal window
ironflow platform roles list
ironflow platform roles list --json

Create a new platform role with the given name.

Terminal window
ironflow platform roles create <name> [flags]
FlagShortTypeDefaultDescription
--policy-ids[]stringPolicy IDs to attach
--server-sstringServer URL override

Examples:

Terminal window
ironflow platform roles create my-role
ironflow platform roles create my-role --policy-ids pol_abc

Delete a platform role by ID.

Terminal window
ironflow platform roles delete <id> [flags]
FlagShortTypeDefaultDescription
--server-sstringServer URL override

Examples:

Terminal window
ironflow platform roles delete role_abc123

Query the platform audit log with optional filters.

Terminal window
ironflow platform audit [flags]
FlagShortTypeDefaultDescription
--event-typestringFilter by event type
--fromstringFilter events from this date or RFC3339 timestamp (inclusive)
--tostringFilter events up to this date or RFC3339 timestamp; a bare date means its midnight, so it excludes the named day
--cursorstringPagination cursor
--limitint0Maximum number of events to return
--jsonboolfalseOutput as JSON
--server-sstringServer URL override

Examples:

Terminal window
ironflow platform audit
ironflow platform audit --event-type user.created --limit 50
ironflow platform audit --from 2024-01-01 --to 2024-12-31 --json