Skip to content

User Logs

Don Cato edited this page Sep 14, 2021 · 1 revision

Info

Every time something related to a user happens (like a status updated either manually or automatically due to timeout for example) it will be logged in a file with the user-id as the name. The appropriate log file can be sent within the final notification sent by the server (e.g. as file in an email).

Format / Interpretation

The Logs are formatted the following way:

<Date> <Time> UTC <Transmitting time> - <Location>; <Other Information>

Example:

This Request sent on 1631650000 and received on 1631650004 Epoch Time:

POST / HTTP/1.1
Host: example.com
Content-Type: application/json

Auth: 000000000000000000000000000000000000
Notification-Type: 1
---
{
   "T": 1631653454,
   "Tp": 10,
   "Td": 5,
   "L": ["0°N", "0°E"],
   "O": {
      "WIFI": ["Home-WLAN"],
      "BT": ["Smart-Watch"],
      "NET": ["LTE-1", "LTE-3"],
      "BPM": ["98"],
      "O2": ["95%"],
      "BATT": ["20%"]
   }

}

would produce this line in the log file:
2021-09-14 09:03:41.000000000 UTC 4 - ["0°N", "0°E"]; {"WIFI": ["Home-WLAN"], "BT": ["Smart-Watch"], "NET" ["LTE-1", "LTE-3"], "BPM": ["98"], "O2": ["95%"], "BATT": ["20%"]}

Notes

Sometimes the system itself will append messages to the log files automatically. In that case (and only the case of system messages!) the transmitting time will be -1.
The log files have a maximum length of 250 lines, when the limit is reached, the oldest lines are deleted first.

Clone this wiki locally