Record checkpoint
const url = 'https://api.aerandil.com/v1/actions/hospitality.action.record_checkpoint/apply';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"branch":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","params":{"completed_at":"2026-04-15T12:00:00Z","items":[{"code":"example","ok":true,"text":"example","value":"example"}],"observations":"example","position":1,"raise_fault":{"area_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","category":"hvac","description":"example","room_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","severity":"cosmetic","title":"example"},"result_id":"example","started_at":"2026-04-15T12:00:00Z"},"return_modified":false,"target":{"id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","object_type":"hospitality.inspection_round"}}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.aerandil.com/v1/actions/hospitality.action.record_checkpoint/apply \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "branch": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "params": { "completed_at": "2026-04-15T12:00:00Z", "items": [ { "code": "example", "ok": true, "text": "example", "value": "example" } ], "observations": "example", "position": 1, "raise_fault": { "area_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "category": "hvac", "description": "example", "room_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "severity": "cosmetic", "title": "example" }, "result_id": "example", "started_at": "2026-04-15T12:00:00Z" }, "return_modified": false, "target": { "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "object_type": "hospitality.inspection_round" } }'Record one checkpoint of an open round — hubOS’s ‘submit checkpoint’. position names the checkpoint in the round’s own list; items answer its items by code (each at most once; a code it does not have refuses): a check needs ok, a reading its value, a text its text, a photo nothing (its photo attaches to the result), a section heading takes no answer, and any item may say ok: false. A reading with limits that the walker does not judge is judged by them: ok within min / max, an anomaly outside; the walker’s own ok always stands. result_id is the result’s id when the walker mints it (a v4 or v7 UUID — a handset with no signal queues the checkpoint’s photo against it): the same id again is this result, an id another result holds is refused as a duplicate, and a checkpoint recorded already under another id is refused naming it. anomalies is derived — the items answered not ok — and the round’s totals are re-folded from its results. The result is linked to the checkpoint’s room or asset and to the staff member behind the session. One write per checkpoint: recording it again replaces the result in place while the round is open, and an identical repeat writes nothing (even after the round has closed). raise_fault raises a work order through create_work_order’s own path — in the public area raise_fault.area_id names (never with a room_id), else against raise_fault.room_id, else the checkpoint’s room, else the room its asset stands in, and for the checkpoint’s asset — linked to the round (work_order_from_round) and the checkpoint (work_order_from_checkpoint) and counted on both; a fault with the title of one already raised from this checkpoint is that fault, not another. Photos attach to the result (host_kind = checkpoint_result). Emits inspection_round.checkpoint_recorded.
Effects: create hospitality.checkpoint_result; modify hospitality.checkpoint_result; modify hospitality.inspection_round; link hospitality.link.checkpoint_result_in_round; link hospitality.link.checkpoint_result_for_room; link hospitality.link.checkpoint_result_for_asset; link hospitality.link.checkpoint_result_recorded_by; unlink hospitality.link.checkpoint_result_recorded_by; link hospitality.link.work_order_from_round; link hospitality.link.work_order_from_checkpoint; create hospitality.work_order; link hospitality.link.work_order_from_triage; link hospitality.link.work_order_for_room; link hospitality.link.work_order_assigned_to; create hospitality.room_status_block; link hospitality.link.room_status_block_for_room; link hospitality.link.work_order_holds_block; modify hospitality.availability_day; link hospitality.link.work_order_for_asset; link hospitality.link.work_order_reported_by_stay; link hospitality.link.work_order_of_fault_type; link hospitality.link.work_order_for_area.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”object
Apply against an open branch’s overlay view instead of the canonical (main) plane. The action’s writes land in the branch’s copy-on-first-write overlay, its events in the branch’s own stream, and the invocation is journaled for merge-by-replay. Branch writes are action-only, so this is the write-side entry point to a branch (POST /v1/branches forks one).
object
object
object
When true, the response carries modified_objects and modified_links projections — the engine reads the event log inside the same transaction so the projection observes the handler’s own writes.
object
Responses
Section titled “Responses”Action applied. modified_objects and modified_links populated when return_modified: true was supplied.
Envelope returned by the Aerandil action engine. correlation_id ties every event emitted by this invocation; modified_objects and modified_links project the events the handler emitted (per the action’s declared effects); warnings carries any non-blocking soft-validator observations.
object
Per-invocation correlation id; matches events.correlation_id for every event this action appended.
Links established or removed by this invocation. Empty when the caller did not request return_modified.
object
Objects created, modified, or soft-deleted by this invocation. Empty when the caller did not request return_modified.
object
Non-blocking soft-validator observations emitted during this invocation (e.g. comp-authority over-limit, recipe pour-cost over sell-price). Absent when no warnings were emitted.
object
Human-readable summary, suitable for logging or operator-UI surfacing.
Object type the warning was raised against.
Property the warning anchors to, when a single field is the locus. Absent for multi-field rules.
Stable kebab-case rule identifier (e.g. comp-authority-over-limit).
Example
{ "modified_links": [ { "kind": "linked", "link_type": "hospitality.link.checkpoint_result_in_round" } ], "modified_objects": [ { "kind": "created", "object_type": "hospitality.checkpoint_result" } ]}Conflict — concurrent modification or unique constraint violation.
Validation error — parameter validation or business-rule violation.