Check a worker or robot into a station
POST/stations/:stationId/check-ins
Assigns an occupant to a station — the Station aggregate's CheckIn invariant enforced through the application layer: one occupant at a time. This is operational state, not a labor-performance domain event in its own right (see ADR-0014): no domain event is published by this endpoint. The checked-in occupant is instead surfaced, best-effort, as associateId on the TaskCompleted Kafka event when a task claimed by this station is later completed.
Request
Responses
- 200
- 400
- 404
- 409
- 500
Station checked in.
Response Headers
Present, with the value true, ONLY when this answer is the stored replay of an earlier request that used the same Idempotency-Key (the handler did not run again). The first execution never carries it.
The Idempotency-Key header is missing (idempotency-key-required) or not 1-128 printable ASCII characters (idempotency-key-invalid) on a POST, or the request body could not be read or contains a NUL character (malformed-request-body), or the request body is malformed JSON, a required field is missing or empty, or a field value is invalid (e.g. a task type outside the TaskType enum).
No station is registered with this stationId.
The station already has an occupant checked in. The same Idempotency-Key reused with a different method, path or body is also a 409, problem type idempotency-key-reused.
An unexpected server-side failure (e.g. a repository or event-publisher error).