Table of Contents

Class GoogleMaps

Namespace
Google.GenAI.Types
Assembly
Google.GenAI.dll

Tool to retrieve knowledge from Google Maps.

public record GoogleMaps : IEquatable<GoogleMaps>
Inheritance
GoogleMaps
Implements
Inherited Members

Properties

AuthConfig

The authentication config to access the API. Only API key is supported. This field is not supported in Gemini API.

[JsonPropertyName("authConfig")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public AuthConfig? AuthConfig { get; set; }

Property Value

AuthConfig

EnableWidget

Deprecated. The Google Maps contextual widget behavior in Grounding with Google Maps is being deprecated; this field is planned for removal and no longer has any effect once removed. Optional. Whether to return a widget context token in the GroundingMetadata of the response.

[JsonPropertyName("enableWidget")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public bool? EnableWidget { get; set; }

Property Value

bool?

Methods

FromJson(string, JsonSerializerOptions?)

Deserializes a JSON string to a GoogleMaps object.

public static GoogleMaps? FromJson(string jsonString, JsonSerializerOptions? options = null)

Parameters

jsonString string

The JSON string to deserialize.

options JsonSerializerOptions

Optional JsonSerializerOptions.

Returns

GoogleMaps

The deserialized GoogleMaps object, or null if deserialization fails.