Routes - Ratings
File Name : rating.js
File Path : /server/routes/rating.js
Ratings route contains saveRating . These functionalities are included in Coupons Controller.
Create Rating Route
- API Path: api/ratings/giveRating
- Method: GET
- Description: This is a protected route which gets the user details through JWT access token which is provided in the header.
Parameters:
- Name: req
- Type: Object
Name Type orderId string driverId string cusId string ratingNo number - Name: jwtAccessToken
- In: Header
- Type: String
- Description: JWT access token is used to check the authenticity of the user.
Name: res
- Type: Object
- Description: res is nothing but the response object which gets you the rating details to the user.
Response:
- Http Code: 200
- Name: returnObj
- Type: Object
Name Type success boolean message string data array