MyTimetable can be monitored, for example by using monitoring tools such as Nagios. A Health API is available at
/health, and a status URL is available at
/status. Both will be discussed in more detail below.
Using the Health API, it is possible to retrieve a JSON representation of the MyTimetable status. The following URL's are available at the root of the MyTimetable instance using a HTTP GET request:
- tatus of a detail ("OK", "WARNING" or "ERROR").
/health/<component id>/<detail id>/value: Value of a detail (format depending on the type of the detail).
/value calls, it is possible to include
?single=true in the query string to unwrap the containing object.
Warning and error statuses can be defined using query parameters. The available parameters are in the format
<component id>/<details id>/<threshold name>=<value>.
As an example, a request to the URL:
Will lead to a warning for the detail is the number of ews_FAILED_PERMANENTLY syncs is more than 5.
Possible threshold names are:
timestamp values, a negative value means 'seconds before the current time'.
Please note the
/status URL is an older endpoint and we strongly recommend building new integrations on the
The status controller returns a text representation of the MyTimetable status, and is available at the URLThe output looks something like:
There are four possible return states:
- 'MyTimetable OK' if all data sources have been updated in the last 36 hours and all components work as expected.
- 'MyTimetable WARNING' followed by last update times for all data sources, if one or more data sources have not been updated within the last 36 hours. (In Scientia Syllabus Plus Enterprise Reporting Database 3.2.0, the last update time is not present. MyTimetable will always return WARNING in older MyTimetable versions, and always return OK in MyTimetable 2.4+)
- 'MyTimetable ERROR' + exception message, if MyTimetable can not connect to one or more data sources, or if something else went wrong. This will also set the HTTP status to '503 Service Unavailable'.
- HTTP '404 Not Found status', if the application did not load correctly.
Please note that the exact text format will be different and less extensive for pre-3.0 MyTimetable instances.