Skip to content

Add userRatingCount support#3

Merged
steipete merged 2 commits into
openclaw:mainfrom
aligurelli:feat/user-rating-count
Feb 14, 2026
Merged

Add userRatingCount support#3
steipete merged 2 commits into
openclaw:mainfrom
aligurelli:feat/user-rating-count

Conversation

@aligurelli

@aligurelli aligurelli commented Jan 27, 2026

Copy link
Copy Markdown
Contributor

Hey! I needed to filter places by number of reviews (e.g. show me cafes with 500+ ratings) and noticed userRatingCount wasn't being requested from the API.

Turns out the field is available in Places API (New) but wasn't included in the field masks. This PR adds it to search, nearby, and details.

What changed

  • Request userRatingCount in search/nearby/details field masks
  • Expose it in PlaceSummary and PlaceDetails structs
  • Show it in CLI output next to rating: Rating: 4.5 (532)
  • Include as user_rating_count in JSON output

Example

$ goplaces search "coffee Beşiktaş" --limit 3
1. Espressolab Beşiktaş Meydan — ...
   Rating: 4.5 (532) · $2

2. Just Coffee & Roastery — ...
   Rating: 4.0 (913)

Pretty small change, happy to adjust if needed.

Add the userRatingCount field from the Google Places API (New) to
PlaceSummary and PlaceDetails types. This allows consumers to see
the total number of user ratings for each place.

Changes:
- Add userRatingCount to search, nearby, and details field masks
- Add UserRatingCount field to placeItem payload struct
- Add UserRatingCount to PlaceSummary and PlaceDetails types
- Map the field in mapPlaceSummary and mapPlaceDetails
- Display rating count in CLI output as 'Rating: 4.5 (532)'
- Include as 'user_rating_count' in JSON output
@aligurelli aligurelli changed the title feat: add userRatingCount to search, nearby, and details Add userRatingCount support Jan 27, 2026
@aligurelli

Copy link
Copy Markdown
Contributor Author

@steipete fyi

@steipete

Copy link
Copy Markdown
Collaborator

merci!

@steipete
steipete merged commit 17728ba into openclaw:main Feb 14, 2026
2 checks passed
steipete added a commit that referenced this pull request Feb 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants