Ratings

Scores and comments users leave on listings and on the service.

Base URL
https://api.reportauto.eu

Ratings

Ratings a user leaves on a listing or on the service itself. Each rating carries a score, a category and an optional comment.

Create a rating

POST/api/requests/self/rating

Records a rating against a target such as a listing.

Authentication Bearer token

Parameters

target_idstringRequired

ID of the thing being rated.

target_typestringRequired

What kind of thing it is, e.g. listing.

ratingintegerRequired

Score from 1 to 5.

categorystring

Aspect being rated, e.g. quality.

commentsstring

Free-text feedback.

cURL
1curl -X POST "https://api.reportauto.eu/api/requests/self/rating/" \
2  -H "Authorization: Bearer $CAROOM_ACCESS_TOKEN" \
3  -H "Content-Type: application/json" \
4  -d '{
5    "target_id": "149",
6    "target_type": "listing",
7    "rating": 5,
8    "comments": "Straightforward from start to finish",
9    "category": "quality"
10  }'

List your ratings

GET/api/requests/self/rating

Returns every rating the authenticated user has left.

Authentication Bearer token

cURL
1curl "https://api.reportauto.eu/api/requests/self/rating/" \
2  -H "Authorization: Bearer $CAROOM_ACCESS_TOKEN"

Retrieve a rating

GET/api/requests/self/rating/:rating_id

Returns one rating.

Authentication Bearer token

Path parameters

rating_idintegerRequired

ID of the rating.

cURL
1curl "https://api.reportauto.eu/api/requests/self/rating/1" \
2  -H "Authorization: Bearer $CAROOM_ACCESS_TOKEN"

Update a rating

PATCH/api/requests/self/rating/:rating_id

Edits the score or the comment on an existing rating.

Authentication Bearer token

Path parameters

rating_idintegerRequired

ID of the rating.

Parameters

ratinginteger

New score.

commentsstring

New comment.

cURL
1curl -X PATCH "https://api.reportauto.eu/api/requests/self/rating/5" \
2  -H "Authorization: Bearer $CAROOM_ACCESS_TOKEN" \
3  -H "Content-Type: application/json" \
4  -d '{ "comments": "Updated feedback" }'

Delete a rating

DELETE/api/requests/self/rating/:rating_id

Removes a rating the caller left.

Authentication Bearer token

Path parameters

rating_idintegerRequired

ID of the rating.

cURL
1curl -X DELETE "https://api.reportauto.eu/api/requests/self/rating/4" \
2  -H "Authorization: Bearer $CAROOM_ACCESS_TOKEN"