REST API: Patrols and tours
This page belongs to the REST API reference, which covers the address, authentication, scopes, pagination and errors. Every path is appended to https://api.litelog.de/api. In the examples $KEY stands for your API key; the example values are made up.
Overview
| Call | Purpose | Scope |
|---|---|---|
GET /v1/patrols |
List patrol runs (planned routes + free patrols + tour runs) | patrols:read |
GET /v1/patrols/checkpoint-coverage |
Checkpoint coverage per property and day | patrols:read |
GET /v1/patrols/{kind}/{id} |
Patrol run detail incl. the device-reported event stream (or the stop timeline of a tour run) | patrols:read |
GET /v1/routes |
List patrol route configurations (catalogue) | patrols:read |
POST /v1/routes |
Create a patrol route (configuration + schedule + checkpoints) | routes:write |
GET /v1/routes/{id} |
Route detail incl. schedule series and checkpoint list | patrols:read |
PATCH /v1/routes/{id} |
Edit a patrol route (portal semantics) | routes:write |
POST /v1/routes/{id}/archive |
End a patrol route series | routes:write |
POST /v1/routes/{id}/copy |
Copy a patrol route: control points, order, time windows and rhythm | routes:write |
GET /v1/tours |
List tours (cross-property rounds with stops) | tours:read |
POST /v1/tours |
Create a tour (head + stops + schedule series) | tours:write |
GET /v1/tours/{id} |
Tour detail incl. stops and schedule series | tours:read |
PATCH /v1/tours/{id} |
Edit a tour (partial update; stops and schedules replace as a whole) | tours:write |
POST /v1/tours/{id}/archive |
Archive a tour (active = false) | tours:write |
POST /v1/tours/{id}/unarchive |
Reactivate a tour (active = true) | tours:write |
POST /v1/tours/{id}/copy |
Copy a tour: stops, order, time windows and rhythm | tours:write |
GET /v1/scans |
Scan trail of a chip, control point, account or property | patrols:read |
Notes
A tour is visible only when all of its stop properties lie inside the key's property restriction; otherwise it is absent from the list and answers 404. A stop property outside the restriction on create or edit → 403. PATCH changes head fields one by one; when stops or schedules are sent, they replace the previous list completely. When an edit or the archiving drops future runs, the call needs a reason (change_reason in the body or the header X-Change-Reason), otherwise 422 with errorCode: REASON_REQUIRED. Tours are not subject to change approval: changes take effect immediately and are written to the change history; there is no delete, archived tours stay readable.
GET /v1/patrols?kind=tour · GET /v1/patrols/tour/{uuid}: List tour runs (additional fields uuid, tour_uuid, tour_name, status, stops_total, stops_done; property_id is null) / read one run with its stop timeline (stops[]: arrival, departure, source, skip reason, route_log_id of the stop's patrol run)
GET /v1/patrols
List runs — planned patrol routes (kind=planned), free patrols (kind=free) and tour runs (kind=tour, see Tours) (filters: property_id, kind, done, outcome = missed/incomplete/overdue for planned routes only, from/to). Archived free patrols are left out of the list; the single fetch still returns them.
Scope: patrols:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | no | Default: 1; at least 1. |
pageSize |
query | integer | no | Default: 50; 1 – 100. |
property_id |
query | integer | no | — |
kind |
query | string | no | Values: planned, free, tour. |
done |
query | boolean | no | — |
outcome |
query | string | no | Only planned runs with this outcome (combined with kind=free or kind=tour → 422). missed = window over, no round finished; incomplete = some but not all rounds finished; overdue = window over and not done (includes missed). Values: missed, incomplete, overdue. |
from |
query | string (date-time) | no | — |
to |
query | string (date-time) | no | — |
Example call
curl "https://api.litelog.de/api/v1/patrols?property_id=123&from=2026-12-01T00:00:00Z&to=2026-12-02T00:00:00Z" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"kind": "planned",
"id": 9001,
"property_id": 123,
"property_name": "Filiale Nord",
"route_id": 87,
"route_name": "Abendrunde",
"start_ts": "2026-12-01T21:00:00.000Z",
"end_ts": "2026-12-01T22:00:00.000Z",
"done": true,
"attempts_finished": 1,
"attempts_total": 1
},
{
"kind": "free",
"id": 412,
"property_id": 123,
"property_name": "Filiale Nord",
"route_id": null,
"route_name": null,
"start_ts": "2026-12-01T14:05:12.000Z",
"end_ts": "2026-12-01T14:32:40.000Z",
"done": true,
"attempts_finished": null,
"attempts_total": null
}
],
"total": 2,
"page": 1,
"pageSize": 50
}
GET /v1/patrols/checkpoint-coverage
Checkpoint coverage per property and day: which points were scanned and which were not (from/to, at most 14 days, an end after today is cut to today; only_missed, default true). Each row carries target (scans needed per checkpoint) and reached_count (checkpoints that reached it), like coverage in the portal.
Scope: patrols:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | no | Default: 1; at least 1. |
pageSize |
query | integer | no | Default: 50; 1 – 100. |
from |
query | string (date) | yes | — |
to |
query | string (date) | yes | — |
property_id |
query | integer | no | — |
only_missed |
query | boolean | no | true (default) = points lists only the points below their target (scan_count < target); with the default target of 1 these are the points without a scan. Default: true. |
Example call
curl "https://api.litelog.de/api/v1/patrols/checkpoint-coverage?from=2026-12-02&to=2026-12-02&property_id=123&only_missed=false" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"date": "2026-12-02",
"property_id": 123,
"property_name": "Filiale Nord",
"scanned_count": 1,
"missed_count": 1,
"total_count": 2,
"target": 1,
"reached_count": 1,
"points": [
{
"tag_id": 501,
"name": "Haupteingang",
"scan_count": 1,
"reached": true,
"last_scan_at": "2026-12-02T21:04:18.000Z",
"last_scanned_by_name": "Erika Musterfrau"
},
{
"tag_id": 502,
"name": "Technikraum UG",
"scan_count": 0,
"reached": false,
"last_scan_at": null,
"last_scanned_by_name": null
}
]
}
],
"total": 1,
"page": 1,
"pageSize": 50,
"summary": {
"scan_count": 1,
"point_count": 2,
"reached_count": 1,
"property_day_count": 1,
"days": [
{
"date": "2026-12-02",
"scan_count": 1,
"point_count": 2,
"reached_count": 1,
"property_count": 1
}
]
}
}
GET /v1/patrols/{kind}/{id}
Run detail including the device-reported event stream (checkpoint scans).
Scope: patrols:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
kind |
path | string | yes | Values: planned, free, tour. |
id |
path | string | yes | Numeric run id for planned/free; the run uuid for tour. |
Example call
curl "https://api.litelog.de/api/v1/patrols/planned/9001" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": {
"kind": "planned",
"id": 9001,
"property_id": 123,
"property_name": "Filiale Nord",
"route_id": 87,
"route_name": "Abendrunde",
"start_ts": "2026-12-01T21:00:00.000Z",
"end_ts": "2026-12-01T22:00:00.000Z",
"done": true,
"attempts_finished": 1,
"attempts_total": 1,
"events": [
{
"type": "STARTED",
"timestamp": "2026-12-01T21:02:10.000Z",
"account_id": 41,
"account_name": "Erika Musterfrau",
"msg": null,
"latitude": "48.137154",
"longitude": "11.576124",
"source": "device"
},
{
"type": "TAG_SCAN_TAG",
"timestamp": "2026-12-01T21:03:41.000Z",
"account_id": 41,
"account_name": "Erika Musterfrau",
"msg": "Haupteingang",
"latitude": "48.137160",
"longitude": "11.576131",
"source": "device"
},
{
"type": "TAG_SCAN_QR",
"timestamp": "2026-12-01T21:14:09.000Z",
"account_id": 41,
"account_name": "Erika Musterfrau",
"msg": "Technikraum UG",
"latitude": "48.137098",
"longitude": "11.576240",
"source": "device"
},
{
"type": "DONE",
"timestamp": "2026-12-01T21:15:02.000Z",
"account_id": 41,
"account_name": "Erika Musterfrau",
"msg": null,
"latitude": "48.137149",
"longitude": "11.576119",
"source": "device"
}
]
}
}
GET /v1/routes
Patrol route configurations of a property (catalogue; filters: property_id, archived) — the cross-property tour lives under /v1/tours.
Scope: patrols:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | no | Default: 1; at least 1. |
pageSize |
query | integer | no | Default: 50; 1 – 100. |
property_id |
query | integer | no | — |
archived |
query | boolean | no | — |
Example call
curl "https://api.litelog.de/api/v1/routes?property_id=123&archived=false" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"route_id": 87,
"name": "Abendrunde",
"property_id": 123,
"property_name": "Filiale Nord",
"archived": false,
"parent_id": null,
"checkpoints_total": 2
}
],
"total": 1,
"page": 1,
"pageSize": 50
}
POST /v1/routes
Create a patrol route: property, name, checkpoints with order and duty flag, schedule (schedule: start date, time, duration in seconds, repetition, weekdays) — runs are generated immediately.
Scope: routes:write
Body fields (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
property_id |
integer | yes | — |
name |
string | yes | At most 200 characters. |
notes_user |
string or null | no | At most 1000 characters. |
notes_intern |
string or null | no | At most 1000 characters. |
task_uuid |
string (uuid) or null | no | Library task linked to the route (ROUTE binding). |
violation_rule_id |
string (uuid) or null | no | — |
ignore_start_date |
boolean | no | — |
checkpoints |
array (object) | yes | At most 200 items. |
schedule |
object (RouteSchedule) |
yes | One schedule series of a patrol route (public write contract). Times are wall-clock values of the route's property timezone. |
change_reason |
string | no | Reason for the change approval (alternatively header X-Change-Reason). At most 2000 characters. |
Example call
curl -X POST "https://api.litelog.de/api/v1/routes" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"property_id": 123,
"name": "Abendrunde",
"notes_user": "Alle Außentüren auf Verschluss prüfen.",
"checkpoints": [
{
"tag_id": 501,
"sequence": 1,
"duty": true
},
{
"tag_id": 502,
"sequence": 2,
"duty": false
}
],
"schedule": {
"start_date": "2026-12-01",
"start_time": "22:00",
"duration_seconds": 3600,
"frequency": 1,
"repeat_type": "daily"
}
}'
Example response (201)
{
"data": {
"route_id": 87,
"name": "Abendrunde",
"property_id": 123,
"property_name": "Filiale Nord",
"archived": false,
"parent_id": null,
"checkpoints_total": 2,
"configs": [
{
"time_id": 214,
"name": "Abendrunde",
"first_run": "2026-12-01T22:00:00.000Z",
"last_run": null,
"start_time": "22:00:00",
"duration_run": 3600,
"frequency": 1,
"repeat_type": "daily",
"repeat_frequency": 1,
"weekdays": [],
"monthdays": [],
"type_freedays": "none",
"anchor_mode": "fixed",
"violation_rule_id": null,
"notes_user": "Alle Außentüren auf Verschluss prüfen."
}
],
"checkpoints": [
{
"sequence": 1,
"duty": true,
"tag_id": 501,
"name": "Haupteingang",
"uuid": "3f2b8c1e-7a4d-4e9b-9c35-1d6f0a8b2e47",
"archived": false,
"area_id": 31,
"area_name": "Erdgeschoss"
},
{
"sequence": 2,
"duty": false,
"tag_id": 502,
"name": "Technikraum UG",
"uuid": "b81d4f60-2c3e-4a7f-8d19-5e0c9a7b3f12",
"archived": false,
"area_id": 32,
"area_name": "Untergeschoss"
}
]
}
}
GET /v1/routes/{id}
Route detail including schedule series and checkpoint list.
Scope: patrols:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | integer | yes | — |
Example call
curl "https://api.litelog.de/api/v1/routes/87" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": {
"route_id": 87,
"name": "Abendrunde",
"property_id": 123,
"property_name": "Filiale Nord",
"archived": false,
"parent_id": null,
"checkpoints_total": 2,
"configs": [
{
"time_id": 214,
"name": "Abendrunde",
"first_run": "2026-12-01T22:00:00.000Z",
"last_run": null,
"start_time": "22:00:00",
"duration_run": 3600,
"frequency": 1,
"repeat_type": "daily",
"repeat_frequency": 1,
"weekdays": [],
"monthdays": [],
"type_freedays": "none",
"anchor_mode": "fixed",
"violation_rule_id": null,
"notes_user": "Alle Außentüren auf Verschluss prüfen."
}
],
"checkpoints": [
{
"sequence": 1,
"duty": true,
"tag_id": 501,
"name": "Haupteingang",
"uuid": "3f2b8c1e-7a4d-4e9b-9c35-1d6f0a8b2e47",
"archived": false,
"area_id": 31,
"area_name": "Erdgeschoss"
},
{
"sequence": 2,
"duty": false,
"tag_id": 502,
"name": "Technikraum UG",
"uuid": "b81d4f60-2c3e-4a7f-8d19-5e0c9a7b3f12",
"archived": false,
"area_id": 32,
"area_name": "Untergeschoss"
}
]
}
}
PATCH /v1/routes/{id}
Edit a route like the portal: "from now" creates a new version with a new route_id (returned in the response), effective_from starts the new version on a date, a patch with only schedule.last_run moves the end date without a new version; an end date before the earliest possible end (today or the first run) → 422 ROUTE_LAST_RUN_TOO_EARLY.
Scope: routes:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | integer | yes | — |
Body fields (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
name |
string | no | At most 200 characters. |
notes_user |
string or null | no | At most 1000 characters. |
notes_intern |
string or null | no | At most 1000 characters. |
task_uuid |
string (uuid) or null | no | — |
violation_rule_id |
string (uuid) or null | no | — |
checkpoints |
array (object) | no | At most 200 items. |
schedule |
object (RouteSchedule) |
no | One schedule series of a patrol route (public write contract). Times are wall-clock values of the route's property timezone. |
effective_from |
string (date) | no | — |
change_reason |
string | no | Reason for the change approval (alternatively header X-Change-Reason). At most 2000 characters. |
Example call
curl -X PATCH "https://api.litelog.de/api/v1/routes/87" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"schedule": {
"start_time": "23:00"
},
"effective_from": "2026-12-15",
"change_reason": "Schichtwechsel ab Mitte Dezember"
}'
Example response (200)
{
"data": {
"route_id": 88,
"name": "Abendrunde",
"property_id": 123,
"property_name": "Filiale Nord",
"archived": false,
"parent_id": 87,
"checkpoints_total": 2,
"configs": [
{
"time_id": 231,
"name": "Abendrunde",
"first_run": "2026-12-15T23:00:00.000Z",
"last_run": null,
"start_time": "23:00:00",
"duration_run": 3600,
"frequency": 1,
"repeat_type": "daily",
"repeat_frequency": 1,
"weekdays": [],
"monthdays": [],
"type_freedays": "none",
"anchor_mode": "fixed",
"violation_rule_id": null,
"notes_user": "Alle Außentüren auf Verschluss prüfen."
}
],
"checkpoints": [
{
"sequence": 1,
"duty": true,
"tag_id": 501,
"name": "Haupteingang",
"uuid": "3f2b8c1e-7a4d-4e9b-9c35-1d6f0a8b2e47",
"archived": false,
"area_id": 31,
"area_name": "Erdgeschoss"
},
{
"sequence": 2,
"duty": false,
"tag_id": 502,
"name": "Technikraum UG",
"uuid": "b81d4f60-2c3e-4a7f-8d19-5e0c9a7b3f12",
"archived": false,
"area_id": 32,
"area_name": "Untergeschoss"
}
]
}
}
POST /v1/routes/{id}/archive
End a route (last_run, default today) — future runs are dropped, past runs stay in the log book.
Scope: routes:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | integer | yes | — |
Body fields (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
last_run |
string (date) | no | — |
change_reason |
string | no | Reason for the change approval (alternatively header X-Change-Reason). At most 2000 characters. |
Example call
curl -X POST "https://api.litelog.de/api/v1/routes/87/archive" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"last_run": "2026-12-31",
"change_reason": "Vertrag endet zum Jahresende"
}'
Example response (200)
{
"data": {
"route_id": 87,
"name": "Abendrunde",
"property_id": 123,
"property_name": "Filiale Nord",
"archived": false,
"parent_id": null,
"checkpoints_total": 2,
"configs": [
{
"time_id": 214,
"name": "Abendrunde",
"first_run": "2026-12-01T22:00:00.000Z",
"last_run": "2026-12-31T22:00:00.000Z",
"start_time": "22:00:00",
"duration_run": 3600,
"frequency": 1,
"repeat_type": "daily",
"repeat_frequency": 1,
"weekdays": [],
"monthdays": [],
"type_freedays": "none",
"anchor_mode": "fixed",
"violation_rule_id": null,
"notes_user": "Alle Außentüren auf Verschluss prüfen."
}
],
"checkpoints": [
{
"sequence": 1,
"duty": true,
"tag_id": 501,
"name": "Haupteingang",
"uuid": "3f2b8c1e-7a4d-4e9b-9c35-1d6f0a8b2e47",
"archived": false,
"area_id": 31,
"area_name": "Erdgeschoss"
},
{
"sequence": 2,
"duty": false,
"tag_id": 502,
"name": "Technikraum UG",
"uuid": "b81d4f60-2c3e-4a7f-8d19-5e0c9a7b3f12",
"archived": false,
"area_id": 32,
"area_name": "Untergeschoss"
}
]
}
}
POST /v1/routes/{id}/copy
Copy a patrol route within the same property. Copied: name (with "(Kopie)", shortened to 50 characters, unless name is given), notes, the control points with order and duty flag, every time window, the rhythm and the reaction rule. The control points are the same points: no point, no NFC chip and no QR code is created. Never copied: runs, scans, history, the task linked to the original and a series end. Every time window starts on start_date. If a tour stop uses the route, that stays as it is; only the route's own time windows are copied. Without a time window of its own: 422 ROUTE_WITHOUT_TIME_WINDOW. The original is only read.
The copy is created the same way as POST /v1/routes: under change approval a request is filed and the answer is 200 with approval_pending: true; where the company requires a change reason, a call without one answers 422 CHANGE_REASON_REQUIRED and writes nothing. Foreign or hidden route: 404.
Scope: routes:write
The key also needs the read scope patrols:read: the answer carries the values of the original.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | integer | yes | The route to copy (route_id). |
Idempotency-Key |
header | string (uuid) | no | Idempotency key as a header, an alternative to the body field uuid. The same key with the same body answers 200 with duplicate: true and creates nothing twice. The same key with a different body answers 422 IDEMPOTENCY_KEY_PAYLOAD_MISMATCH; while the first call is still running, 409 IDEMPOTENCY_KEY_IN_PROGRESS. A call that failed releases its key. |
Body fields (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
uuid |
string (uuid) | no | Idempotency key (alternatively header Idempotency-Key). |
name |
string | no | Default: name of the original with "(Kopie)", shortened to 50 characters. At most 200 characters. |
start_date |
string (date) | no | Day on which every copied time window starts (YYYY-MM-DD, not in the past). Default: tomorrow in the time zone of the property. |
change_reason |
string | no | Reason for the audit trail and the change approval (alternatively header X-Change-Reason). |
Example call
curl -X POST "https://api.litelog.de/api/v1/routes/300/copy" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-H "Idempotency-Key: 5a8e2f17-93c4-4d6b-b0a2-6e1f7c3d9a48" \
-d '{
"name": "Nachtrunde Ost",
"start_date": "2026-12-07"
}'
Example response (201)
{
"data": {
"route_id": 412,
"name": "Nachtrunde Ost",
"property_id": 124,
"archived": false,
"checkpoints_total": 8,
"source_route_id": 300
},
"created": true
}
GET /v1/tours
List tours (filters: search, property_id = at least one stop at that property, archived).
Scope: tours:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | no | Default: 1; at least 1. |
pageSize |
query | integer | no | Default: 50; 1 – 100. |
search |
query | string | no | At most 200 characters. |
property_id |
query | integer | no | — |
archived |
query | boolean | no | — |
Example call
curl "https://api.litelog.de/api/v1/tours?property_id=123&archived=false" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"uuid": "9a6e2d14-5b3c-4f8a-a1d7-c04e8b5f6a39",
"name": "Revierfahrt Nord",
"description": "Nächtliche Revierfahrt über beide Objekte.",
"order_mode": "enforced",
"active": true,
"esignature_mode": null,
"stops_total": 2,
"property_ids": [
123,
124
],
"created_at": "2026-11-30T14:22:07.531Z"
}
],
"total": 1,
"page": 1,
"pageSize": 50
}
POST /v1/tours
Create a tour: name, order_mode (enforced = stops in fixed order, free = any order), stops (property_id, sort_order, stop_mode = tasks/route/checkin, offset_min/window_min), schedule series as for patrol routes (weekdays 0 = Sunday, duration_seconds) — runs are generated immediately.
Scope: tours:write
Body fields (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
name |
string | yes | At most 255 characters. |
description |
string or null | no | At most 2000 characters. |
order_mode |
string | no | enforced = stops in the given order, free = any order. Values: enforced, free; Default: free. |
esignature_mode |
string or null | no | null = the tenant default applies. Values: required, off, null. |
active |
boolean | no | Default: true. |
stops |
array (object) | yes | At most 200 items. |
schedules |
array (object) | no | At most 20 items. |
change_reason |
string | no | Optional on create; stored with the audit row (alternatively header X-Change-Reason). At most 2000 characters. |
Example call
curl -X POST "https://api.litelog.de/api/v1/tours" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"name": "Revierfahrt Nord",
"description": "Nächtliche Revierfahrt über beide Objekte.",
"order_mode": "enforced",
"stops": [
{
"property_id": 123,
"sort_order": 0,
"stop_mode": "route",
"route_id": 87,
"offset_min": 0,
"window_min": 30,
"note": "Schlüssel am Empfang abholen."
},
{
"property_id": 124,
"sort_order": 1,
"stop_mode": "tasks",
"offset_min": 45,
"window_min": 30
}
],
"schedules": [
{
"start_date": "2026-12-01",
"start_time": "21:30",
"duration_seconds": 10800,
"repeat_type": "weekly",
"weekdays": [
1,
2,
3,
4,
5
]
}
]
}'
Example response (201)
{
"data": {
"uuid": "9a6e2d14-5b3c-4f8a-a1d7-c04e8b5f6a39",
"name": "Revierfahrt Nord",
"description": "Nächtliche Revierfahrt über beide Objekte.",
"order_mode": "enforced",
"active": true,
"esignature_mode": null,
"stops_total": 2,
"property_ids": [
123,
124
],
"created_at": "2026-11-30T14:22:07.531Z",
"stops": [
{
"sort_order": 0,
"property_id": 123,
"property_name": "Filiale Nord",
"stop_mode": "route",
"route_id": 87,
"route_name": "Abendrunde",
"offset_min": 0,
"window_min": 30,
"note": "Schlüssel am Empfang abholen."
},
{
"sort_order": 1,
"property_id": 124,
"property_name": "Haus Seeblick — Wohnung 3",
"stop_mode": "tasks",
"route_id": null,
"route_name": null,
"offset_min": 45,
"window_min": 30,
"note": null
}
],
"schedules": [
{
"name": "Revierfahrt Nord",
"start_date": "2026-12-01",
"last_run": null,
"start_time": "21:30",
"duration_seconds": 10800,
"frequency": 1,
"repeat_type": "weekly",
"repeat_frequency": 1,
"weekdays": [
1,
2,
3,
4,
5
],
"monthdays": [],
"type_freedays": "none",
"violation_rule_id": null
}
]
}
}
GET /v1/tours/{id}
Tour detail: head, stops in order (stops), schedule series (schedules).
Scope: tours:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | string (uuid) | yes | — |
Example call
curl "https://api.litelog.de/api/v1/tours/9a6e2d14-5b3c-4f8a-a1d7-c04e8b5f6a39" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": {
"uuid": "9a6e2d14-5b3c-4f8a-a1d7-c04e8b5f6a39",
"name": "Revierfahrt Nord",
"description": "Nächtliche Revierfahrt über beide Objekte.",
"order_mode": "enforced",
"active": true,
"esignature_mode": null,
"stops_total": 2,
"property_ids": [
123,
124
],
"created_at": "2026-11-30T14:22:07.531Z",
"stops": [
{
"sort_order": 0,
"property_id": 123,
"property_name": "Filiale Nord",
"stop_mode": "route",
"route_id": 87,
"route_name": "Abendrunde",
"offset_min": 0,
"window_min": 30,
"note": "Schlüssel am Empfang abholen."
},
{
"sort_order": 1,
"property_id": 124,
"property_name": "Haus Seeblick — Wohnung 3",
"stop_mode": "tasks",
"route_id": null,
"route_name": null,
"offset_min": 45,
"window_min": 30,
"note": null
}
],
"schedules": [
{
"name": "Revierfahrt Nord",
"start_date": "2026-12-01",
"last_run": null,
"start_time": "21:30",
"duration_seconds": 10800,
"frequency": 1,
"repeat_type": "weekly",
"repeat_frequency": 1,
"weekdays": [
1,
2,
3,
4,
5
],
"monthdays": [],
"type_freedays": "none",
"violation_rule_id": null
}
]
}
}
PATCH /v1/tours/{id}
Edit a tour (partial update of the head fields; stops and schedules replace the whole list).
Scope: tours:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | string (uuid) | yes | — |
X-Change-Reason |
header | string | no | Alternative to change_reason in the body. At most 2000 characters. |
Body fields (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
name |
string | no | At most 255 characters. |
description |
string or null | no | At most 2000 characters. |
order_mode |
string | no | Values: enforced, free. |
esignature_mode |
string or null | no | Values: required, off, null. |
active |
boolean | no | — |
stops |
array (object) | no | Full replacement of the stop list. At most 200 items. |
schedules |
array (object) | no | Full replacement of the schedule series; [] removes every series. At most 20 items. |
change_reason |
string | no | Required when future runs are dropped (alternatively header X-Change-Reason). At most 2000 characters. |
Example call
curl -X PATCH "https://api.litelog.de/api/v1/tours/9a6e2d14-5b3c-4f8a-a1d7-c04e8b5f6a39" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"description": "Nächtliche Revierfahrt, Reihenfolge der Objekte frei.",
"order_mode": "free",
"change_reason": "Reihenfolge wird den Fahrern freigestellt"
}'
Example response (200)
{
"data": {
"uuid": "9a6e2d14-5b3c-4f8a-a1d7-c04e8b5f6a39",
"name": "Revierfahrt Nord",
"description": "Nächtliche Revierfahrt, Reihenfolge der Objekte frei.",
"order_mode": "free",
"active": true,
"esignature_mode": null,
"stops_total": 2,
"property_ids": [
123,
124
],
"created_at": "2026-11-30T14:22:07.531Z",
"stops": [
{
"sort_order": 0,
"property_id": 123,
"property_name": "Filiale Nord",
"stop_mode": "route",
"route_id": 87,
"route_name": "Abendrunde",
"offset_min": 0,
"window_min": 30,
"note": "Schlüssel am Empfang abholen."
},
{
"sort_order": 1,
"property_id": 124,
"property_name": "Haus Seeblick — Wohnung 3",
"stop_mode": "tasks",
"route_id": null,
"route_name": null,
"offset_min": 45,
"window_min": 30,
"note": null
}
],
"schedules": [
{
"name": "Revierfahrt Nord",
"start_date": "2026-12-01",
"last_run": null,
"start_time": "21:30",
"duration_seconds": 10800,
"frequency": 1,
"repeat_type": "weekly",
"repeat_frequency": 1,
"weekdays": [
1,
2,
3,
4,
5
],
"monthdays": [],
"type_freedays": "none",
"violation_rule_id": null
}
]
}
}
POST /v1/tours/{id}/archive
Archive a tour (active: false) — no new runs, past runs stay in the log book.
Scope: tours:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | string (uuid) | yes | — |
X-Change-Reason |
header | string | no | At most 2000 characters. |
Body fields (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
change_reason |
string | no | At most 2000 characters. |
Example call
curl -X POST "https://api.litelog.de/api/v1/tours/9a6e2d14-5b3c-4f8a-a1d7-c04e8b5f6a39/archive" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"change_reason": "Auftrag zum Jahresende gekündigt"
}'
Example response (200)
{
"data": {
"uuid": "9a6e2d14-5b3c-4f8a-a1d7-c04e8b5f6a39",
"name": "Revierfahrt Nord",
"description": "Nächtliche Revierfahrt über beide Objekte.",
"order_mode": "enforced",
"active": false,
"esignature_mode": null,
"stops_total": 2,
"property_ids": [
123,
124
],
"created_at": "2026-11-30T14:22:07.531Z",
"stops": [
{
"sort_order": 0,
"property_id": 123,
"property_name": "Filiale Nord",
"stop_mode": "route",
"route_id": 87,
"route_name": "Abendrunde",
"offset_min": 0,
"window_min": 30,
"note": "Schlüssel am Empfang abholen."
},
{
"sort_order": 1,
"property_id": 124,
"property_name": "Haus Seeblick — Wohnung 3",
"stop_mode": "tasks",
"route_id": null,
"route_name": null,
"offset_min": 45,
"window_min": 30,
"note": null
}
],
"schedules": [
{
"name": "Revierfahrt Nord",
"start_date": "2026-12-01",
"last_run": null,
"start_time": "21:30",
"duration_seconds": 10800,
"frequency": 1,
"repeat_type": "weekly",
"repeat_frequency": 1,
"weekdays": [
1,
2,
3,
4,
5
],
"monthdays": [],
"type_freedays": "none",
"violation_rule_id": null
}
]
}
}
POST /v1/tours/{id}/unarchive
Reactivate a tour (active: true) — runs are generated from today on.
Scope: tours:write
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | string (uuid) | yes | — |
X-Change-Reason |
header | string | no | At most 2000 characters. |
Body fields (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
change_reason |
string | no | At most 2000 characters. |
Example call
curl -X POST "https://api.litelog.de/api/v1/tours/9a6e2d14-5b3c-4f8a-a1d7-c04e8b5f6a39/unarchive" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-d '{
"change_reason": "Auftrag wurde verlängert"
}'
Example response (200)
{
"data": {
"uuid": "9a6e2d14-5b3c-4f8a-a1d7-c04e8b5f6a39",
"name": "Revierfahrt Nord",
"description": "Nächtliche Revierfahrt über beide Objekte.",
"order_mode": "enforced",
"active": true,
"esignature_mode": null,
"stops_total": 2,
"property_ids": [
123,
124
],
"created_at": "2026-11-30T14:22:07.531Z",
"stops": [
{
"sort_order": 0,
"property_id": 123,
"property_name": "Filiale Nord",
"stop_mode": "route",
"route_id": 87,
"route_name": "Abendrunde",
"offset_min": 0,
"window_min": 30,
"note": "Schlüssel am Empfang abholen."
},
{
"sort_order": 1,
"property_id": 124,
"property_name": "Haus Seeblick — Wohnung 3",
"stop_mode": "tasks",
"route_id": null,
"route_name": null,
"offset_min": 45,
"window_min": 30,
"note": null
}
],
"schedules": [
{
"name": "Revierfahrt Nord",
"start_date": "2026-12-01",
"last_run": null,
"start_time": "21:30",
"duration_seconds": 10800,
"frequency": 1,
"repeat_type": "weekly",
"repeat_frequency": 1,
"weekdays": [
1,
2,
3,
4,
5
],
"monthdays": [],
"type_freedays": "none",
"violation_rule_id": null
}
]
}
}
POST /v1/tours/{id}/copy
Copy a tour. Copied: name (with "(Kopie)" unless name is given), description, order mode, signature requirement, every stop in its order (property, what is done there, patrol route, arrival offset, tolerance, note) and every time window with its rhythm. Never copied: runs, arrivals and history. Every time window starts on start_date; a series end is not taken over. The copy is active, also when the original is archived. The original is only read.
Needs the same rights as creating and is created the same way as POST /v1/tours: a stop with a patrol route needs a non-archived route of its property (otherwise 422), and the runs are generated as for a new tour. Tours know no change approval; no change reason is needed. Foreign tour, unknown tour or a stop at a property the key cannot see: 404.
Scope: tours:write
The key also needs the read scope tours:read: the answer carries the values of the original.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id |
path | string (uuid) | yes | The tour to copy (its uuid). |
Idempotency-Key |
header | string (uuid) | no | Idempotency key as a header, an alternative to the body field uuid. The same key with the same body answers 200 with duplicate: true and creates nothing twice. The same key with a different body answers 422 IDEMPOTENCY_KEY_PAYLOAD_MISMATCH; while the first call is still running, 409 IDEMPOTENCY_KEY_IN_PROGRESS. A call that failed releases its key. |
Body fields (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
uuid |
string (uuid) | no | Idempotency key (alternatively header Idempotency-Key). |
name |
string | no | Default: name of the original with "(Kopie)", shortened to 255 characters. At most 255 characters. |
start_date |
string (date) | no | Day on which every copied time window starts (YYYY-MM-DD, not in the past). Default: tomorrow in the time zone of the first stop's property. |
Example call
curl -X POST "https://api.litelog.de/api/v1/tours/9d2f6c1a-4b7e-4a3d-8f10-2c5e7b9a1d34/copy" \
-H "X-Api-Key: $KEY" -H "Content-Type: application/json" \
-H "Idempotency-Key: 1e7a4c92-5d3b-4f8e-a6c1-0b9d2e4f7a53" \
-d '{
"name": "Revier Süd",
"start_date": "2026-12-07"
}'
Example response (201)
{
"data": {
"uuid": "c4b8e2d6-1a9f-4c3e-b7d5-8e0f2a6c4b19",
"name": "Revier Süd",
"description": "Nachtfahrt",
"order_mode": "enforced",
"active": true,
"stops_total": 2,
"property_ids": [
124,
131
],
"stops": [
{
"sort_order": 0,
"property_id": 124,
"stop_mode": "route",
"route_id": 300,
"offset_min": 0,
"window_min": 30,
"note": "Tor 2"
},
{
"sort_order": 1,
"property_id": 131,
"stop_mode": "tasks",
"route_id": null,
"offset_min": 45,
"window_min": null,
"note": null
}
],
"schedules": [
{
"name": "Revier Süd",
"start_date": "2026-12-07",
"last_run": null,
"start_time": "22:00",
"duration_seconds": 7200,
"repeat_type": "weekly",
"weekdays": [
1,
3
]
}
],
"source_tour_uuid": "9d2f6c1a-4b7e-4a3d-8f10-2c5e7b9a1d34"
},
"created": true
}
GET /v1/scans
Scan trail (patrols:read): every read of a control point in planned and free patrols (kind: checkpoint, method nfc/qr/beacon/photo/gps, with device, account, run, location status) and every chip or QR read the server rejected (kind: rejected with reason). At least one anchor: chip_id, tag_id, account_id or property_id (else 422); chip_id also finds earlier bindings of the chip. Property-restricted keys only see runs of their properties. Range 7 days by default, 31 at most. Scans from archived free patrols are not included. For support: “was this chip ever read, where, by which phone?”.
Scope: patrols:read
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | no | Default: 1; at least 1. |
pageSize |
query | integer | no | Default: 50; 1 – 100. |
chip_id |
query | string | no | Chip UID as the app scans it; separators and case are normalised. At most 64 characters. |
tag_id |
query | integer | no | Control point id (from GET /v1/control-points). |
account_id |
query | integer | no | — |
property_id |
query | integer | no | — |
device_unique_id |
query | string | no | Phone id as reported by the app (unique_id in GET /v1/devices). At most 128 characters. |
kind |
query | string | no | Values: checkpoint, rejected. |
method |
query | string | no | Values: nfc, qr, beacon, photo, gps. |
from |
query | string (date-time) | no | — |
to |
query | string (date-time) | no | — |
Example call
curl "https://api.litelog.de/api/v1/scans?chip_id=04A1B2C3D4E5F6&from=2026-12-01T00:00:00Z&to=2026-12-02T00:00:00Z" \
-H "X-Api-Key: $KEY"
Example response (200)
{
"data": [
{
"id": "rlt:90412",
"scanned_at": "2026-12-01T21:03:41.000Z",
"received_at": "2026-12-01T21:03:43.512Z",
"kind": "checkpoint",
"method": "nfc",
"tag_id": 501,
"tag_name": "Haupteingang",
"chip_id": "04A1B2C3D4E5F6",
"property_id": 123,
"account_id": 41,
"account_name": "Erika Musterfrau",
"device_unique_id": "8f3c2a1b9d4e7f60",
"device_id": 17,
"run_id": 9001,
"run_kind": "route",
"location_status": "ONSITE",
"impossible_travel": false,
"mock_location": false,
"source": "device",
"sync_source": "v3",
"reason": null
},
{
"id": "ve:3312",
"scanned_at": "2026-12-01T20:47:33.208Z",
"received_at": "2026-12-01T20:47:33.208Z",
"kind": "rejected",
"method": "nfc",
"tag_id": null,
"tag_name": null,
"chip_id": "04A1B2C3D4E5F6",
"property_id": 123,
"account_id": 42,
"account_name": "Max Mustermann",
"device_unique_id": "2d7e5b9c0a1f4e83",
"device_id": 18,
"run_id": null,
"run_kind": null,
"location_status": null,
"impossible_travel": null,
"mock_location": null,
"source": null,
"sync_source": null,
"reason": "no_property_access"
}
],
"total": 2,
"page": 1,
"pageSize": 50,
"from": "2026-12-01T00:00:00.000Z",
"to": "2026-12-02T00:00:00.000Z"
}
