-
Notifications
You must be signed in to change notification settings - Fork 3
RESTful Service Endpoints
Georges Mourant edited this page Oct 31, 2019
·
10 revisions
Once credentials are approved and the new tutor proceeds to the login page, they will either login with an existing account or have to create one.
- Functionality: GET
- Parameters: email, password
- Operation: checks if parameters match a user, and Returns TutorDTO
- URL:
/user/
- Functionality: POST
- Parameters: name, password, email
- Operation: adds to User database, returns a User DTO
- URL:
/user/
Tutor must submit an application to the company manager for each subject they would like to teach.
- Functionality: POST
- Parameters:
- Operation: adds hours to Tutor's profile, returns Tutor DTO
- URL:
/profile/hours/
Once the tutor has been approved for a subject, tutor gets to set rate and retrieve the commission rate.
- Functionality: POST
- Parameters: hourly rate
- Operation: adds hourly_rate to Tutor entry in Tutor database, returns Tutor DTO
- URL:
/profile/rate/
- Functionality: GET
- Parameters: none
- Operation: returns Companydto
- URL:
/company_info/commission_rate/
(Backend needs to send email for every new entry in database too)
- Functionality: GET
- Parameters: none
- Operation: returns Session DTOs where isRejected=false
- URL:
/sessions/
- Functionality: GET
- Parameters: student ID
- Operation: where does it returns a Student review DTO ???
- URL:
/reviews/
- Functionality: GET
- Parameters: student_id
- Operation: returns a list of session DTOs where studentID=student_id
- URL:
/sessions/student_id
After the tutoring session has finished, the tutor can login on the website and review the student and the system.
- Functionality: POST
- Parameters: session ID, rating, text review
- Operation: adds tutor review to session (review of student from tutor), returns Session DTO
- URL:
/session/session_id/student_id/
- Functionality: POST
- Parameters: session ID, feedback paragraph
- Operation: adds feedback to session, returns Session DTO
- URL:
/session/session_id/tutor_id/
- Functionality: PUT
- Parameters: name, password, email
- Operation: update User profile information, return UserDTO
- URL:
/profile/
- Functionality: PUT
- Parameters:
- Operation: adds hours to Tutor's profile, returns TutorDTO
- URL:
/profile/hours/
- Functionality: PUT
- Parameters: hourly rate
- Operation: updates hourly_rate to Tutor entry in Tutor database, returns TutorDTO
- URL:
/profile/rate/