Table of Contents

Class PrebuiltVoiceConfig

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

Configuration for a prebuilt voice.

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

Properties

VoiceName

The name of the prebuilt voice to use.

[JsonPropertyName("voiceName")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public string? VoiceName { get; set; }

Property Value

string

Methods

FromJson(string, JsonSerializerOptions?)

Deserializes a JSON string to a PrebuiltVoiceConfig object.

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

Parameters

jsonString string

The JSON string to deserialize.

options JsonSerializerOptions

Optional JsonSerializerOptions.

Returns

PrebuiltVoiceConfig

The deserialized PrebuiltVoiceConfig object, or null if deserialization fails.