Expand description
Shared, wasm-compatible serde DTOs for the prospero API surface.
Depends only on serde/serde_json, so both the native server
(prospero-core/prospero-api) and the WASM dashboard (prospero #97) can
share these exact types — no client/server drift. Behavior-bearing types
(the fleet manager, stores, k8s backend, …) stay in prospero-core, which
re-exports each type here from its original path for source compatibility.
Structs§
- AddWorkspace
Body - Body for
POST /api/workspaces. - Agent
- Prospero’s view of a single agent (projected from a caliban
AgentRecord). - AgentId
- Stable identifier for a running agent (caliband’s agent id).
- Agent
Input Body - Body for
POST /api/agents/{id}/input. - Capabilities
- Backend capability signal for the dashboard (
GET /api/capabilities). - Credentials
Ref - A by-name reference to a key within an existing Secret.
- Fleet
Event - A normalized, sequenced fleet event.
- Fleet
Snapshot - A point-in-time view of the whole fleet on one host.
- GapSignal
- Payload of a
gapSSE event onGET /api/agents/{id}/stream. - Isolation
Config - Isolation defaults for agents launched against a workspace.
- Outcome
Counts - How many agents reached each terminal state.
- Provider
Info - A provider as surfaced on the read side (
GET /api/workspaces): enough for the dashboard’s launch-modal provider picker and a “has credentials” pill, without exposing the Secret reference itself. - Provider
Spec - A named model provider within a workspace. Each agent binds one by name.
- Readiness
- Aggregate readiness of prosperod, distinct from mere liveness.
- Repo
Provider Config - Per-repo provider/environment configuration applied to its caliband daemon.
- Respawned
Response - Response for
POST /api/agents/{id}/respawn. - SetConfig
Body - Body for
PUT /api/workspaces/{name}/config. - Source
- One source checkout within a workspace. (The
discover_sourcesfilesystem logic stays inprospero-core; only this struct is shared.) - Spawn
Body - Body for
POST /api/workspaces/{repo}/agents. - Spawned
Response - Response for a successful spawn.
- Usage
Bucket - One day’s usage within a workspace — the unit the fleet charts plot.
- Usage
Group - One workspace’s totals over the whole window, plus its daily series.
- Usage
Report GET /api/usage— aggregated spend and outcomes per workspace.- Workspace
- A managed workspace (root + its source checkouts) and the agents running under its single caliband.
- Workspace
Config - Backend-neutral workspace configuration accepted at the API boundary
(
POST /api/workspaces,PUT /api/workspaces/{name}/config). - Workspace
Info - A workspace as seen by the config plane’s read side: the persisted
configuration plus reconciliation status. Returned by
FleetAdmin::list_workspacesand merged intoGET /api/workspacesso a configured-but-agentless workspace is still visible with its status. - Workspace
Source Spec - A source checkout spec for a workspace: a git remote and where to mount it.
Used by the k8s config plane to build a
WorkspaceCR’ssources[]. - Workspace
Status Info - Reconciliation status of a workspace, surfaced for the dashboard’s status
pill + failure tooltip. Backend-neutral (local workspaces report
None). - Workspace
Summary - A workspace summary (no agents) for
GET /api/workspaces.
Enums§
- Agent
Status - Lifecycle state of an agent. Mirrors caliban’s
AgentStatuswire enum exactly so the same value round-trips through both protocols. - Event
Kind - The semantic payload of a fleet event.
- Output
Stream - Which textual stream a chunk of output came from.
- Workspace
Health - Connectivity of a managed workspace’s caliband daemon.
Functions§
- stream_
key_ for - The ordered stream a
(repo, agent_id)pair belongs to. Agent events key on the agent id; repo-level events (no agent) onrepo:<name>; fleet-level events (neither) on the singletonfleetstream.seqis monotonic within the returned key.