Skip to main content

Control Plane Server

ish-server is an optional HTTP service that can stream updates to clients and a command-line tool for inspecting SQLite data. Agents, tools, workflows, context, and persistence run in your application without the server. Start it when you need shared operational APIs, authentication, metrics, or a central view of saved data.

Use the public health route to check that the optional server is reachable:

from urllib.request import urlopen

with urlopen("http://127.0.0.1:8080/health") as response:
print(response.status, response.read().decode())

Start the server​

Set a strong administrator key before binding beyond loopback. The server refuses an unsafe non-loopback configuration.

export ISH_ADMIN_API_KEY="replace-with-a-strong-secret"
export ISH_STUDIO_HOST="127.0.0.1"
export ISH_STUDIO_PORT="8080"
export ISH_DB_PATH="./data/traces.sqlite3"

cargo run -p ish-server --release -- serve

The serve command is also the default when no subcommand is supplied. Options can be passed directly:

cargo run -p ish-server --release -- serve \
--host 127.0.0.1 --port 8080 --db ./data/traces.sqlite3 \
--workspace ./workspace --ui-dir ./public

--ui-dir <dir> and ISH_STUDIO_UI_DIR point to an optional directory of static web assets. The server validates resolved asset paths and serves a headless status response at / when no directory is configured. API access does not require a frontend or a JavaScript runtime.

Operational API​

The server exposes authenticated routes under /api/. Common route groups include:

AreaRoutesPurpose
Status and observabilityGET /api/status, GET /api/analytics, GET /metricsHealth, aggregate usage, and Prometheus metrics. /metrics requires system-admin access.
TracesGET /api/traces, GET /api/traces/:trace_id, `GETPOST /api/traces/:trace_id/scores`
Work and state/api/workflows, /api/checkpoints, /api/side-effects, /api/evaluations, /api/approvalsInspect durable workflow, checkpoint, side-effect, evaluation, and approval records; resolve or reconcile supported records.
Context and sessions/api/blackboard, /api/sessions, /api/blobs, /api/chat, /api/sandboxOperate shared context, sessions, stored blobs, chat runs, and sandbox status.
Skills and keys/api/skills, /api/auth/keys, /api/tenants/quotasManage tenant-scoped skills and administrator-controlled API keys and quotas.
AuditGET /api/auditRead the persisted audit history.
OpenTelemetry trace ingestPOST /api/otel/v1/traces, POST /api/public/otel/v1/tracesAccept authenticated trace data in the common OpenTelemetry HTTP/JSON format. The /public/ route is an SDK path alias, not an unauthenticated endpoint.

Authentication accepts a bearer token or X-Ish-Key. Keys map to a tenant and a role (admin, developer, or auditor); administrative routes require the system administrator identity. The server applies tenant request-rate limits and records supported administrative changes in its audit log.

The audit records are SHA-256 hash-linked in sequence and verified before new entries are appended. The SQLite table retains the historical name audit_merkle_chain, but the current implementation is a linear hash chain, not a Merkle tree.

GET /metrics returns Prometheus text metrics for server status, trace and span totals, active Blackboard entries, and audit event totals. It is restricted to system administrators.

SQLite inspection CLI​

The same binary can inspect the database without starting the HTTP service:

ish-server logs --db ./data/traces.sqlite3 --limit 20
ish-server inspect <trace_id> --db ./data/traces.sqlite3
ish-server workflows --db ./data/traces.sqlite3 --limit 20
ish-server inspect-workflow <workflow_id> --db ./data/traces.sqlite3
ish-server memories --db ./data/traces.sqlite3

logs lists recent traces; inspect lists spans for a trace; workflows lists workflow snapshots; and inspect-workflow prints a workflow's steps. The memories command inspects the server's memory records; it does not enumerate namespaced MemoryStore or ContextStore app records. Those SDK stores use the same persistence backend but have separate collections and APIs. ISH_DB_PATH supplies the default database when --db is omitted.

Persist SDK telemetry​

Configure SDK SQLite persistence to use the same database path as ISH_DB_PATH. For example, the Python SDK writes agent traces and spans to the configured file:

from ish import Agent, OpenAICompatibleModel, SQLiteLogger

logger = SQLiteLogger(db_path="./data/traces.sqlite3")
agent = Agent(
name="release_review",
model=OpenAICompatibleModel(model="gpt-4o-mini"),
instructions="Summarize release readiness.",
persistence=logger,
)

Rust, Python, TypeScript, Go, C#, and Java can all write to the shared persistence contract. The server reads those records from SQLite; it does not need to host agent execution.

Security notes​

  • Keep the administrator key secret and use TLS termination when exposing the service outside a trusted network.
  • Non-loopback binds require a strong ISH_ADMIN_API_KEY.
  • Add allowed browser origins with ISH_CORS_ORIGIN when a separately hosted client must call the API cross-origin.
  • API requests, trace ingestion, and /metrics use the server's authentication and authorization checks.
  • Static serving is optional. Use --ui-dir <dir> only for a directory of assets you intend the server to expose.