Last Updated: 2026-03-06
Status: BASELINE
Base path: services/room-13-fastapi-coordinator
Core service contracts:
GET /healthGET /readyGET /versionGET /metrics
Task contracts:
POST /api/tasksGET /api/tasksGET /api/tasks/{task_id}POST /api/tasks/claim-nextPUT /api/tasks/{task_id}/assignPUT /api/tasks/{task_id}/startPUT /api/tasks/{task_id}/completeDELETE /api/tasks/{task_id}
Worker contracts:
POST /api/workersGET /api/workersGET /api/workers/{worker_id}PUT /api/workers/{worker_id}POST /api/workers/{worker_id}/heartbeatPOST /api/workers/{worker_id}/claimPOST /api/workers/{worker_id}/checkpointPOST /api/workers/{worker_id}/resumePOST /api/workers/{worker_id}/releasePOST /api/workers/{worker_id}/task/completeDELETE /api/workers/{worker_id}
Additional coordinator groups:
/api/services/api/credentials/api/gateway/api/captcha/api/webhooks/api/workflows/api/n8n/api/steel
Base path: services/solver-18-survey-worker
Observed operational routes include:
GET /healthGET /readyGET /metricsGET /telemetry/eventsGET /telemetry/summaryGET /telemetry/audit-report- runtime status routes under the runtime-v2 reporting surface
healthshould indicate overall status and degraded mode when relevant.readyshould be suitable for automation and return non-200 when the service is not ready.metricsshould return Prometheus-compatible plaintext where implemented.- task and worker payloads should remain additive so old consumers do not break when new diagnostics are introduced.
Representative Room-13 task fields:
idnametypestatusprioritypayloadmetadataassigned_workerplatform_idlane_idtask_keypolicyexpected_outcomeattemptmax_attemptsrun_idlease_epochhistory
Representative Room-13 worker fields:
idnametypestatuscapabilitiesmetadataworker_identitypersona_idplatformcurrent_run_idclaimed_task_idlease_epochlease_ttl_seclease_expires_atcurrent_stepcheckpoint_countlast_checkpoint_atlast_checkpointapproval_stateresume_count
Frozen alpha scope for the first durable migration path:
- pilot flow:
task.create -> claim-next -> worker checkpoint/resume -> complete/fail - source ingress remains Room-13
- workflow truth moves to Restate
- transport/replay moves to JetStream
- projections/policies/auth grants/memory metadata live in SIN-Supabase
- Redis remains lease/cache/dedupe only and is never authoritative for pilot state
Canonical envelope fields required across the pilot backbone:
idtenant_idteam_idworkflow_idrun_ididempotency_keycausation_idcorrelation_idcreated_atupdated_atauthority_owner
Pilot contract objects:
Command: ingress intent accepted by Room-13 before workflow startEvent: immutable transport/replay record published to JetStreamRun: durable workflow instance owned by RestateCheckpoint: resumable worker progress record tied torun_idApproval: pause/resume gate with SLA, actor, and audit trailArtifactRef: metadata pointer to external blob/object outputCapability: machine-readable executor/tool/agent ability recordMemoryReference: pointer to semantic memory items used during execution
Pilot event types:
task.createdtask.claimedtask.checkpointedtask.completedtask.failedapproval.requestedapproval.resolved
Required alpha proof semantics:
- duplicate
task.createdevents must not create duplicate side effects - worker death must resume from the latest durable checkpoint under the same
run_id - approval pause/resume must stop and restart real execution, not only metadata
- degraded Redis mode must never become the source of truth for pilot workflow state
HF executor reference contract:
services/workers/hf_executor_contract.jsondefines the machine-readable alpha executor contractservices/workers/hf_executor_reference.pydefines the Python reference envelope builders for checkpoint and terminal events
Whenever a new long-lived API surface is introduced, add it here and document its health, ready, version, and metrics behavior.
Gesture-aware approvals must preserve the existing approval lifecycle and response model:
- request created
- pending
- approved / rejected / timeout
If gesture input degrades (for example low confidence or camera unavailable), the provider must fall back to an existing manual approval lane instead of silently auto-approving.
__init__(cdp_port: int): Initializes agent with CDP connection.start(target_url: str): Connects to browser, injects fingerprinting, calibrates viewport, and starts the automation loop._run_loop(): Executes the autonomous Ponder & Press iteration._humanized_click(x: int, y: int): Performs human-like mouse movement using Bezier paths followed by click and focus/blur.
Legacy operator reference imported from Docs/API-Reference.md so the repo remains compliant with the Top-20 root-doc registry.
Base URL (local dev): http://localhost:8000
GET /Root endpoint (API info)GET /healthOverall API healthGET /api/v1/health/roomsRoom status snapshot
POST /api/v1/auth/loginAuthenticate and get tokenPOST /api/v1/auth/logoutInvalidate token
POST /api/v1/solve/captchaSubmit CAPTCHA image for solvingGET /api/v1/solve/status/{task_id}Check solving task status
POST /api/v2/enterprise/consensusSubmit task for multi-model consensus
Room Status Object:
{
"id": "string",
"name": "string",
"host": "string",
"port": "integer",
"address": "string",
"status": "UP | DOWN"
}Health Status Object:
{
"status": "healthy | degraded",
"models": {
"gemini": "available | unavailable",
"mistral": "available | unavailable",
"yolo": "available | unavailable",
"consensus": "available | unavailable"
}
}