„API Documentaion“ ändern

Hannes Braun 2021-10-26 18:08:51 +02:00
parent d9953a810b
commit 90d640f208
1 changed files with 11 additions and 9 deletions

@ -2,7 +2,7 @@
This section contains all needed infromation to access the TheCitadelofRicks API. It also contains the API specification.
### /courseList
/courseList returns a Array "courses" of all currently available courses at the HS Offenburg with their name and link to the timetable (current/first week).
/courseList returns an array "courses" of all currently available courses at the HS Offenburg with their name and link to the timetable (current/first week).
``` json
{
@ -29,24 +29,26 @@ This section contains all needed infromation to access the TheCitadelofRicks API
```
### /timetable?course={coursename}&week={week}
/timetable returns a ArrayList "timetable" which contains a Array of 6 days, each day contains a Array of 6 ArrayLists which contain 0..n lessons. The meta part contains course-name, the actual timetable link, the last update-time and the week index (starting with 0 for the current week)
/timetable returns an ArrayList "timetable" which contains an Array of 6 days, each day contains an Array of 6 ArrayLists which contain 0..n lessons. The meta part contains course name, the actual timetable link, the last update-time, the week index (starting with 0 for the current week), the calendar week and the year.
Each lesson has the following values:
* lessonID: formate: DAY.TIMESLOT.LESSON, range: 0.0.0 to 5.5.x (0.0.0 = Monday.firstTimeslot.firstLesson, 5.6.x = Saturday.lastTimeslot.lastLesson)
* subject: the lesson subject
* teacher: the lesson teacher
* room: the room in which the lesson takes place
* remark: additional info
* remark: additional info
``` json
{
"meta":{
"updateTime":1552690660,
"courseName":"AI4",
"week":0,
"weekIndex":0,
"weekNumberYear":11,
"year":2019,
"link":"https://www.hs-offenburg.de/index.php?id=6627&class=class&iddV=5D255C23-BC03-4AA0-9F36-DC6767F3E05D&week=0"
},
"currentWeek":{
"timetable":{
"days":[
{
"timeslots":[
@ -92,7 +94,7 @@ Each lesson has the following values:
```
### /subjectList?course={coursename}&week={week}
/lessonSubjectList returns a HashSet with all unique lesson subjects of the given course and week.
/subjectList returns a HashSet with all unique lesson subjects of the given course and week.
``` json
[
"Softw. Engin. 2",
@ -114,7 +116,7 @@ Each lesson has the following values:
* subject: the lesson subject
* teacher: the lesson teacher
* room: the room in which the lesson takes place
* remark: additional info
* remark: additional info
``` json
[
@ -144,7 +146,7 @@ Each lesson has the following values:
```
### /mensamenu
/mensamenu returns two Arrays containing this and next weeks mensa menus. The respones contains an Array "days" of the type Meals for each day of the week (Monday to Sunday), meals therefor contains a ArrayList of n meals.
/mensamenu returns two arrays containing this and next weeks mensa menus. The response contains an array "days" of the type Meals for each day of the week (Monday to Sunday), meals therefore contains an ArrayList of n meals.
Each meal (element of meals) has the following values:
* day: the day on which this meal is served
@ -209,7 +211,7 @@ Each meal (element of meals) has the following values:
```
### /health
/health return 200 as Number. It can be used for health checks of the API service.
/health returns 200 as number. It can be used for health checks of the API service.
``` json
200