-
Notifications
You must be signed in to change notification settings - Fork 1
RESTful API Documentation
Visiting this link will show the routes that can be accessed to get all students, all employers, etc.
- Route:
https://ecse321-group17.herokuapp.com/
Returns a single student with the specified email.
- Route:
https://ecse321-group17.herokuapp.com/student/{email}
- Example:
https://ecse321-group17.herokuapp.com/student/student@mail.mcgill.ca
Returns a single employer with the specified email.
- Route:
https://ecse321-group17.herokuapp.com/employer/{email}
- Example:
https://ecse321-group17.herokuapp.com/employer/employer@company.ca
Returns a single administrator with the specified email.
- Route:
https://ecse321-group17.herokuapp.com/admin/{email}
- Example:
https://ecse321-group17.herokuapp.com/admin/admin@mcgill.ca
Returns a single co-op term with the specified ID.
- Route:
https://ecse321-group17.herokuapp.com/coop/{id}
- Example:
https://ecse321-group17.herokuapp.com/coop/12345
Returns all students in the database.
- Route:
https://ecse321-group17.herokuapp.com/students
Returns all employers in the database.
- Route:
https://ecse321-group17.herokuapp.com/employers
Returns all co-op administrators in the database.
- Route:
https://ecse321-group17.herokuapp.com/admins
Returns all co-op terms in the database.
- Route:
https://ecse321-group17.herokuapp.com/coops
Returns the status, start and end dates, and all report information for the specified co-op.
- Route:
https://ecse321-group17.herokuapp.com/progress/coop/{id}
- Example:
https://ecse321-group17.herokuapp.com/progress/coop/12345
Returns relevant statistics for co-op terms that can be filtered by a specified range and co-op number, i.e. a co-op number of 2 would return the 2nd co-op terms of all students. StartTerm and EndTerm must be of the form Winter2019.
- Route:
https://ecse321-group17.herokuapp.com/statistics/coop/{startTerm}/{endTerm}/{coopNumber}
- Example:
https://ecse321-group17.herokuapp.com/statistics/coop/Summer2018/Summer2019/1
Returns relevant report statistics for co-op terms that can be filtered by a specified range and co-op number, i.e. a co-op number of 2 would return the 2nd co-op terms of all students. StartTerm and EndTerm must be of the form Winter2019.
- Route:
https://ecse321-group17.herokuapp.com/statistics/report/{startTerm}/{endTerm}/{coopNumber}
- Example:
https://ecse321-group17.herokuapp.com/statistics/report/Winter2018/Winter2019/2
Returns all reports across all co-ops done by the specified student.
- Route:
https://ecse321-group17.herokuapp.com/reports/student/{email}
- Example:
https://ecse321-group17.herokuapp.com/reports/student/student@mail.mcgill.ca
Returns all reports submitted for the specified co-op.
- Route:
https://ecse321-group17.herokuapp.com/reports/coop/{id}
- Example:
https://ecse321-group17.herokuapp.com/reports/coop/12345
Creates a new student in the database. First and last name must be separated by an underscore.
- Route:
https://ecse321-group17.herokuapp.com/student/create/{email}/{password}/{name}/{phone}/{studentId}
- Example:
https://ecse321-group17.herokuapp.com/student/create/student@mail.mcgill.ca/pw/Albert_Kragl/6041231231/260722322
Creates a new employer in the database. First and last name must be separated by an underscore.
- Route:
https://ecse321-group17.herokuapp.com/employer/create/{email}/{password}/{name}/{phone}/{emplId}
- Example:
https://ecse321-group17.herokuapp.com/employer/create/employer@company.ca/pw/Employer_Person/6041231233/123
Creates a new co-op administrator in the database. First and last name must be separated by an underscore.
- Route:
https://ecse321-group17.herokuapp.com/admin/create/{email}/{password}/{name}/{phone}/{adminId}
- Example:
https://ecse321-group17.herokuapp.com/admin/create/admin@mcgill.ca/pw/Admin_Person/6041231232/321
Creates a new co-op term in the database. Words in the co-op title and in the address must be separated by underscore. Dates must be formatted as yyyy-mm-dd.
- Route:
https://ecse321-group17.herokuapp.com/coop/create/{id}/{title}/{stuEmail}/{empEmail}/{start}/{end}/{status}/{salaryPerHour}/{hoursPerWeek}/{address}
- Example:
https://ecse321-group17.herokuapp.com/coop/create/1/Software_Intern/student@mail.mcgill.ca/employer@company.ca/2019-05-20/2019-08-09/NotStarted/20/40/Montreal
Creates a new notification object in the database. Words in the notification message must be separated by underscore.
- Route:
https://ecse321-group17.herokuapp.com/notification/create/{id}/{text}/{senderEmail}/{stuEmail}/{empEmail}
- Example:
https://ecse321-group17.herokuapp.com/notification/create/1/Hello_World/admin@mcgill.ca/student@mail.mcgill.ca/employer@company.ca
Creates a new report object in the database. The date must be formatted as yyyy-mm-dd.
Status refers to Report Status, which can have the following values:
Unsubmitted, Submitted, Late, Reviewed
Type refers to Report Type, which can have the following values:
Contract, Technical, StudentEval, EmployerEval, TwoWeek
- Route:
https://ecse321-group17.herokuapp.com/report/create/{id}/{coopID}/{date}/{status}/{type}
- Example:
https://ecse321-group17.herokuapp.com/report/create/1/123/2019-02-29/Late/Contract