details method
Future<PlaceDetailsResponse>
details({
- required String placeId,
- PlaceDetailsRequestOptions? options,
Once you have a place_id from a Place Search, you can request more details about a particular establishment or point of interest by initiating a Place Details request. A Place Details request returns more comprehensive information about the indicated place such as its complete address, phone number, user rating and reviews.
Usage example:
final googleMapsApi = GoogleMapsApi(apiKey: "MY_API_KEY");
PlacesDetailsResponse response =
await googleMapsApi.places.details(
placeId: "ChIJN1t_tDeuEmsRUsoyG83frY4",
);
Find the official Google Maps Places details API documentation here
Implementation
Future<PlaceDetailsResponse> details({
required String placeId,
PlaceDetailsRequestOptions? options,
}) async {
return _detailsService.details(placeId: placeId, options: options);
}