Add a certification to an associate
POST/associates/:id/certifications
Adds a named qualification (e.g. "pack", "hazmat", "pick") to an already-started AssociateShift, raising AssociateCertified. An associate untrained on a path cannot be assigned to it (see POST /associates/{id}/assignments). Adding a certification the associate already holds is a no-op on state (set semantics) but still re-raises the event and returns 204 — certifications are not independently addressable sub-resources, so this returns 204 rather than 201.
Request
Responses
- 204
- 400
- 404
- 409
- 500
Certification added. No response body.
Response Headers
"true" when this answer is the stored replay of an earlier request with the same Idempotency-Key and fingerprint; absent on the first execution.
Malformed JSON body, or a required field was missing/empty (empty-associate-id, empty-path-id, empty-certification, missing-building-id -- neither siteCode nor its deprecated alias buildingId was sent --, missing-shift-id, missing-charge, unknown-path-id -- a pathId the process-path catalogue does not declare --, or malformed-request-body). The two staffing-gap list routes also answer 400 for a bad paging query: invalid-limit (not an integer 1-500, empty or repeated), invalid-cursor (undecodable or repeated) and unknown-query-parameter (any query parameter other than limit, cursor and, on the deprecated route, siteCode). On every POST a missing Idempotency-Key header is also a 400 (idempotency-key-required) and a malformed one (not 1-128 printable ASCII starting and ending with a visible character) a 400 (idempotency-key-invalid).
The referenced associate has no started shift (resource-not-found).
Conflict — the associate's shift has already ended (associate-shift-ended), or this associate's roster entry was concurrently modified by another request between when it was read and when this write was attempted (concurrent-modification, ADR 0021); reload and retry. Also returned (idempotency-key-reused) when the Idempotency-Key was already used with a different request (method, path or body).
Unclassified failure (e.g. a persistence or event-publish error) — internal-error.