Watch
0
0
Fork
You've already forked hyperhive
0
hyperhive/swarm-controller-api
Repository files (latest commit first)
Filename Latest commit message Latest commit date
atlas 1edeb5c55d agents get a per-agent repo limit in their permissions record, orgs are locked
max_repos (default 0, 0..=100) lives in the agent's agent-permissions record and is edited on its permissions panel. The controller applies each agent's own value as max_repo_creation at CreateForgeUser and to existing accounts on change, restart and every five minutes; agent accounts may not create organizations.
2026-11-16 01:21:25 +01:00
..
src agents get a per-agent repo limit in their permissions record, orgs are locked 2026-11-16 01:21:25 +01:00
Cargo.toml swarmctl shares the create-agent, inference and permissions shapes with the controller 2026-10-19 18:58:00 +02:00
README.md swarmctl shares the create-agent, inference and permissions shapes with the controller 2026-10-19 18:58:00 +02:00

swarm-controller-api

Wire types for swarm-controller's HTTP API, the request and response bodies both swarm-controller (server) and swarmctl (client) import. Serde only: no server or client logic, no tokio, no axum.

Why it's its own crate

swarmctl doesn't link swarm-controller, for the same reason hivectl doesn't link hive-c0re. The two still share one contract, the same way hivectl and hive-c0re share hive-host-sock: a field renamed on one side is a compile error on the other, not a 400 the operator finds at runtime.

The schema feature derives utoipa's ToSchema on every type, for the controller's OpenAPI spec. swarmctl leaves it off.

What's here

One module per endpoint family: agents (POST /api/agents, request and response, and POST /api/agents/{name}/forge-token), agents_md (/api/agents/{name}/agents-md), forge (POST /api/forge/users/{name}/admin), schedules (/api/schedules), and inference, limits and permissions, the settings bodies that POST /api/agents also carries.

The types inside those bodies live in other serde-only crates: Effort, Source and ArchetypeRef in swarm-wire, Permission in hive-types. This crate still links no tokio and no axum.