Suggests places that match partially typed text, such as a street address or business name, using the Google Maps Places service. Pass a suggestion's place id to placeDetails for its address and coordinates, for example to define a physical Location.
Response
Returns a PlaceAutocompletePayload!
Arguments
| Name | Description |
|---|---|
input - String!
|
The search string. |
Example
Query
query placeAutocomplete($input: String!) {
placeAutocomplete(input: $input) {
predictions {
description
placeId
}
}
}
Variables
{"input": "xyz789"}
Response
{
"data": {
"placeAutocomplete": {
"predictions": [PlacePrediction]
}
}
}