Class GoogleMapsPlacesV1AutocompletePlacesRequest
Request proto for AutocompletePlaces.
Implements
Inherited Members
Namespace: Google.Apis.MapsPlaces.v1.Data
Assembly: Google.Apis.MapsPlaces.v1.dll
Syntax
public class GoogleMapsPlacesV1AutocompletePlacesRequest : IDirectResponseSchema
Properties
ETag
The ETag of the item.
Declaration
public virtual string ETag { get; set; }
Property Value
Type | Description |
---|---|
string |
IncludeQueryPredictions
Optional. If true, the response will include both Place and query predictions. Otherwise the response will only return Place predictions.
Declaration
[JsonProperty("includeQueryPredictions")]
public virtual bool? IncludeQueryPredictions { get; set; }
Property Value
Type | Description |
---|---|
bool? |
IncludedPrimaryTypes
Optional. Included primary Place type (for example, "restaurant" or "gas_station") in Place Types
(https://developers.google.com/maps/documentation/places/web-service/place-types), or only (regions)
, or
only (cities)
. A Place is only returned if its primary type is included in this list. Up to 5 values can
be specified. If no types are specified, all Place types are returned.
Declaration
[JsonProperty("includedPrimaryTypes")]
public virtual IList<string> IncludedPrimaryTypes { get; set; }
Property Value
Type | Description |
---|---|
IList<string> |
IncludedRegionCodes
Optional. Only include results in the specified regions, specified as up to 15 CLDR two-character region
codes. An empty set will not restrict the results. If both location_restriction
and
included_region_codes
are set, the results will be located in the area of intersection.
Declaration
[JsonProperty("includedRegionCodes")]
public virtual IList<string> IncludedRegionCodes { get; set; }
Property Value
Type | Description |
---|---|
IList<string> |
Input
Required. The text string on which to search.
Declaration
[JsonProperty("input")]
public virtual string Input { get; set; }
Property Value
Type | Description |
---|---|
string |
InputOffset
Optional. A zero-based Unicode character offset of input
indicating the cursor position in input
. The
cursor position may influence what predictions are returned. If empty, defaults to the length of input
.
Declaration
[JsonProperty("inputOffset")]
public virtual int? InputOffset { get; set; }
Property Value
Type | Description |
---|---|
int? |
LanguageCode
Optional. The language in which to return results. Defaults to en-US. The results may be in mixed languages
if the language used in input
is different from language_code
or if the returned Place does not have a
translation from the local language to language_code
.
Declaration
[JsonProperty("languageCode")]
public virtual string LanguageCode { get; set; }
Property Value
Type | Description |
---|---|
string |
LocationBias
Optional. Bias results to a specified location. At most one of location_bias
or location_restriction
should be set. If neither are set, the results will be biased by IP address, meaning the IP address will be
mapped to an imprecise location and used as a biasing signal.
Declaration
[JsonProperty("locationBias")]
public virtual GoogleMapsPlacesV1AutocompletePlacesRequestLocationBias LocationBias { get; set; }
Property Value
Type | Description |
---|---|
GoogleMapsPlacesV1AutocompletePlacesRequestLocationBias |
LocationRestriction
Optional. Restrict results to a specified location. At most one of location_bias
or location_restriction
should be set. If neither are set, the results will be biased by IP address, meaning the IP address will be
mapped to an imprecise location and used as a biasing signal.
Declaration
[JsonProperty("locationRestriction")]
public virtual GoogleMapsPlacesV1AutocompletePlacesRequestLocationRestriction LocationRestriction { get; set; }
Property Value
Type | Description |
---|---|
GoogleMapsPlacesV1AutocompletePlacesRequestLocationRestriction |
Origin
Optional. The origin point from which to calculate geodesic distance to the destination (returned as
distance_meters
). If this value is omitted, geodesic distance will not be returned.
Declaration
[JsonProperty("origin")]
public virtual GoogleTypeLatLng Origin { get; set; }
Property Value
Type | Description |
---|---|
GoogleTypeLatLng |
RegionCode
Optional. The region code, specified as a CLDR two-character region code. This affects address formatting,
result ranking, and may influence what results are returned. This does not restrict results to the specified
region. To restrict results to a region, use region_code_restriction
.
Declaration
[JsonProperty("regionCode")]
public virtual string RegionCode { get; set; }
Property Value
Type | Description |
---|---|
string |
SessionToken
Optional. A string which identifies an Autocomplete session for billing purposes. Must be a URL and filename
safe base64 string with at most 36 ASCII characters in length. Otherwise an INVALID_ARGUMENT error is
returned. The session begins when the user starts typing a query, and concludes when they select a place and
a call to Place Details or Address Validation is made. Each session can have multiple queries, followed by
one Place Details or Address Validation request. The credentials used for each request within a session must
belong to the same Google Cloud Console project. Once a session has concluded, the token is no longer valid;
your app must generate a fresh token for each session. If the session_token
parameter is omitted, or if
you reuse a session token, the session is charged as if no session token was provided (each request is
billed separately). We recommend the following guidelines: * Use session tokens for all Place Autocomplete
calls. * Generate a fresh token for each session. Using a version 4 UUID is recommended. * Ensure that the
credentials used for all Place Autocomplete, Place Details, and Address Validation requests within a session
belong to the same Cloud Console project. * Be sure to pass a unique session token for each new session.
Using the same token for more than one session will result in each request being billed individually.
Declaration
[JsonProperty("sessionToken")]
public virtual string SessionToken { get; set; }
Property Value
Type | Description |
---|---|
string |