docs
// Tools

erectl platform ops

Eight command groups that bring the CLI to parity with the dashboard: maintenance windows, project membership, settings, usage rollups, exports, health, workspaces, and chats. Every verb resolves the active deployment; override with --context when you need to cross deployments.

Overview

Every subcommand resolves the active deployment via config use and issues bearer-authenticated requests against the InferenceRouter. No browser required.

All platform commands read the active deployment for base URL and API key (the project id is derived from base_url). Override any single invocation with --context, --base-url, or --api-key.

CommandVerbsRouter pathRequired scope
maintenance6/v1/management/maintenance/*management
project8/v1/management/project/* (delegation create/revoke is handled via approvals)management
settings3/v1/settings/*management
usage4/v1/usage/*inference
exports5/v1/exports/*management
health2/v1/health/dashboardmanagement
workspaces9/v1/workspaces/*inference
chats10/v1/chats/*inference

Scope mismatch: calling a management-scoped route with an API key that only carries inference scope returns a 403 with error.code = scope_insufficient. Issue a management-scope key via erectl keys create --scope management before running these commands.

maintenance

// 6 verbs list schedule update cancel complete purge

Schedule, update, cancel, complete, and purge maintenance windows for the active project. Severity values: info, warning, critical.

Subcommands

bash
erectl maintenance list # List all windows erectl maintenance list --status scheduled # Filter by status erectl maintenance schedule \ # Schedule a new window --title "Patching worker-7" \ --description "Routine kernel update" \ --starts-at 2026-05-01T02:00:00Z \ --ends-at 2026-05-01T04:00:00Z \ --severity warning erectl maintenance update <id> --ends-at ... # Patch a window erectl maintenance cancel <id> # Cancel a scheduled window erectl maintenance complete <id> # Mark a window complete erectl maintenance purge <id> # Hard-delete a cancelled window

When to use each

  • cancel, window has not started yet and needs to be called off.
  • complete, window finished naturally; closes the notification period.
  • purge, window was cancelled and you want it out of the list. Requires window status to be cancelled.

project

// 8 verbs across 3 groups members: list add update remove · invitations: list resend revoke · delegations: list

Manage project team members, invitations, and role delegations.

members

bash
erectl project members list # List members erectl project members add --email user@example.com \ # Invite a member --role member erectl project members update <id> --role owner # Change role erectl project members remove <id> # Remove a member

invitations

bash
erectl project invitations list # List open invitations erectl project invitations resend <id> # Resend the email erectl project invitations revoke <id> # Revoke an unaccepted invitation

delegations

bash
erectl project delegations list # List role delegations

Delegation grants (creating / revoking destructive-approval delegations) are managed through the approvals command group.

settings

// 3 verbs get update delete

Read, update, or delete project-level settings. Excludes 2FA (stays browser-only by design).

bash
erectl settings get # Show the active project's settings erectl settings update \ # Patch one or more fields --name "Platform Ops" \ --description "Owns router + agent infrastructure" erectl settings delete --confirm "Platform Ops" # Soft-delete (typed confirmation)

Typed confirmation: --confirm takes the project's authoritative name as its value. The server re-reads the name and rejects mismatched values with 400 confirmation_mismatch. Deletion is soft; restore is performed from the browser settings panel.

usage

// 4 verbs events logs endpoints uptime

Query usage events, request logs, per-endpoint rollups, and uptime snapshots.

bash
erectl usage events # Latest usage events erectl usage events --since 2026-04-01T00:00:00Z --until 2026-04-30T23:59:59Z erectl usage logs # Request-level logs erectl usage logs --q /v1/chat/completions --limit 100 erectl usage endpoints # Per-endpoint rollups erectl usage uptime # Uptime / SLO summary

Common options

OptionDescriptionSubcommands
--since <ts>ISO 8601 lower boundevents, logs, endpoints
--until <ts>ISO 8601 upper boundevents, logs, endpoints
--limit <n>Max rows returned (router clamps to 500)events, logs
--q <substring>Case-sensitive substring match on the request pathlogs

exports

// 5 verbs create status download cancel + types logs metrics usage executions

Create, monitor, download, and cancel data exports.

bash
erectl exports create --type logs \ --since 2026-04-01T00:00:00Z --until 2026-04-30T23:59:59Z erectl exports create --type metrics \ --since 2026-04-24T00:00:00Z --until 2026-04-30T23:59:59Z --format jsonl erectl exports create --type usage \ --since 2026-04-01T00:00:00Z --until 2026-04-30T23:59:59Z erectl exports status <id> # Check export status erectl exports download <id> --output-file out.ndjson # Download completed export erectl exports cancel <id> # Cancel a queued or running export

Both bounds required: --since and --until are validated client-side; the router rejects bodies missing either bound. Recognised --type values are logs, metrics, usage, and executions. Valid --format values are json (default), csv, and jsonl.

Execution exports: erectl exports create --type executions returns 202 Accepted with the export job id; poll erectl exports status <id> until status=completed and then download the NDJSON bundle with erectl exports download <id> --output-file <path>.ndjson. The router serves application/x-ndjson.

health

// 2 verbs dashboard services

Summary views onto router and agent health for the active project.

bash
erectl health dashboard # Overall project health erectl health services # Per-service breakdown

Both subcommands call the per-project GET /v1/health/dashboard route and render a project-filtered summary; services reformats the same payload into a per-service breakdown. Platform-wide status belongs on the public /status page and is not exposed here.

workspaces

// 9 verbs across 3 groups crud+search: list create show update delete search · memories: list create delete · files: list

Full workspace CRUD, semantic search, memory management, and file listing.

CRUD + search

bash
erectl workspaces list # List workspaces erectl workspaces create --name "ops" \ # Create a workspace --description "Operational scratchpad" erectl workspaces show <id> # Detailed view erectl workspaces update <id> --name "ops-v2" # Rename erectl workspaces update <id> \ # Set generative routing --inference-routing-mode semantic erectl workspaces delete <id> # Delete a workspace erectl workspaces search <id> \ # Semantic search --query "kernel panic on worker-7" \ --k 20 # Top-K result count

Generative routing

--inference-routing-mode records how a workspace picks the model for a generative turn. It takes semantic (route each turn through the Semantic Router), concrete (deterministic auto-selection), or default (clear the choice and follow the workspace's cohort default). erectl workspaces show always prints the row, reading default when no explicit choice has been recorded -- that is a real state, not a missing value.

Choosing semantic, or clearing back to default, also drops the workspace's pinned inference endpoint. A pin outranks the routing mode wherever the two meet, so leaving one behind would store a choice that could never take effect.

This is the recorded choice, not the resolved answer for a given turn. A chat- or workspace-level pin, the project's semantic-router switch, and the project's endpoint mix can all still outrank it. See How a turn is routed.

Intelligence reconciliation

bash
erectl workspaces update <id> \ # Toggle the periodic pass --intelligence-reconciliation true|false erectl workspaces revalidate-intelligence <id> # Queue one pass now

A pass over what the workspace has recorded -- memories, decisions, milestones, and relations. The trigger is asynchronous and rate limited to one accepted call per workspace per hour, shared with the dashboard's equivalent control. This is not the self-evolution loop, which refines prompt text on its own schedule. Both are covered in erectl evolution.

memories

bash
erectl workspaces memories list <id> # List memories erectl workspaces memories create <id> --content "..." \ # Add a memory [--source-type user|chat|tool] [--category <str>] \ [--source-chat-id <cid>] [--source-message-id <mid>] erectl workspaces memories delete <id> <memory-id> # Delete a memory

files

bash
erectl workspaces files list <id> # List workspace files

Use erectl uploads for file uploads and the workspace revalidation commands. The workspaces files list command shown here provides a read-only inventory.

chats

// 10 verbs across 5 groups crud: list create show update delete · branches: list fork · messages: list · memories: list · context: (positional)

Chat ecosystem commands covering CRUD, branches, messages, memories, and per-chat context retrieval.

CRUD

bash
erectl chats list # List chats (scoped by the active API key) erectl chats list --limit 50 # Cap row count erectl chats create --title "Triage" \ # Create a chat [--system-prompt "..."] [--model-id <mid>] [--visibility private|shared] erectl chats show <id> # Detailed view erectl chats update <id> --title "New title" erectl chats delete <id> # Delete a chat

branches

bash
erectl chats branches list <id> # List branches erectl chats branches fork <id> \ # Fork a branch --from-message <msg-id> --name "hypothesis-b"

messages

bash
erectl chats messages list <id> # List messages on the default branch erectl chats messages list <id> --branch <bid> --limit 50

memories

bash
erectl chats memories list <id> # List chat memories

context

bash
erectl chats context <id>

context takes only the positional chat id and returns the semantic-search bundle used by pre-dispatch retrieval. On deployments where workspace retrieval is not enabled, the command returns an empty bundle ({"items": [], "reranker_latency_ms": 0}) so scripted callers can handle both configurations uniformly.

Examples

Schedule an outage window

bash
erectl maintenance schedule \ --title "Router restart for config rollout" \ --description "Rolling restart across us-east" \ --starts-at 2026-05-02T06:00:00Z \ --ends-at 2026-05-02T06:30:00Z \ --severity info \ --affected-services router,frontend

Onboard a new team member

bash
erectl project members add --email new-hire@example.com --role member erectl project invitations list # Confirm the invite is pending # ... they accept the email ... erectl project members list # Confirm they appear

Audit usage for the last 30 days

bash
SINCE=2026-04-20T00:00:00Z UNTIL=2026-05-20T00:00:00Z erectl usage endpoints --since "$SINCE" --until "$UNTIL" erectl usage uptime erectl exports create --type usage --since "$SINCE" --until "$UNTIL"

Set up a workspace + triage chat

bash
WS_ID=$(erectl workspaces create --name "incident-2026-04-14" -o json | jq -r .id) CHAT_ID=$(erectl chats create --title "Triage" -o json | jq -r .id) erectl chats context "$CHAT_ID" erectl workspaces search "$WS_ID" --query "known degradation patterns" --k 20