AI-generated Key Takeaways
-
FetchPlaceRequestis a struct used to request information about a specific place using its placeID. -
It allows specifying desired place properties to be included in the response for efficient data retrieval.
-
Optionally, a session token can be provided to associate the request with a billing session for usage tracking.
-
Developers can utilize
FetchPlaceRequestwithPlacesClientto retrieve Place details, leveraging available Place Data Fields.
FetchPlaceRequest
struct FetchPlaceRequestextension FetchPlaceRequest : SendableThe request for a specific placeID and place properties to include in the Place response.
-
Request object to use with
PlacesClientto fetch a place.Read more about Place Data Fields.
Declaration
Swift
init(placeID: String, placeProperties: [PlaceProperty], sessionToken: AutocompleteSessionToken? = nil)Parameters
placeIDThe ID of the place to be requested.
placePropertiesThe properties of the place to be requested. Must not be empty. An empty list will result in an error when trying to send the request.
sessionTokenThe ‘AutocompleteSessionToken’ to associate the request with a billing session.
-
Place ID of the place being requested.
Declaration
Swift
var placeID: String { get } -
Place properties to include in the Place response.
Declaration
Swift
var placeProperties: [PlaceProperty] { get } -
Session token to associate the request to a billing session.
Declaration
Swift
var sessionToken: AutocompleteSessionToken? { get }