Department Endpoints¶
Get Department Names¶
1 |
|
Get request for getting all the department names. Example response body:
1 2 3 4 5 6 7 8 9 10 11 12 |
|
Possible status code responses are 200 Success and 404 Not Found.
Create a Department¶
1 |
|
Create a new department. It is only necessary to supply the departments name. Request body required for this POST request:
1 2 3 4 5 6 7 8 9 10 11 12 |
|
Possible status code responses are 200 Success, 400 Bad Request, 403 Forbidden, 404 Not Found and 500 Server Error.
Get Given Department¶
1 |
|
Get the department with the specified id. Example response body:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 |
|
Possible status code responses are 200 Success, 403 Forbidden and 404 Not Found.
Get Citizen Names¶
1 |
|
Gets the citizen names. Example response body:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
|
Possible status code responses are 200 Success, 403 Forbidden and 404 Not Found.
Add User to a Department¶
1 |
|
Add an existing user, that does not have a department, to the given department. Requires role Department, Guardian or SuperUser. Possible status code responses are 200 Success, 400 Bad Request, 401 Unauthorized, 403 Forbidden and 409 Conflict.
Change Department Name¶
1 |
|
Handles changing name of a Department. Request body required for this PUT request:
1 2 3 4 |
|
Possible status code responses are 200 Success, 400 Bad Request, 403 Forbidden and 404 Not Found.
Delete Department¶
1 |
|
Endpoint for deleting the GirafRest.Models.Department with the given id. Possible status code responses are 200 Success, 403 Forbidden and 404 Not Found.