Class VoiceConfig
The configuration for the voice to use.
public record VoiceConfig : IEquatable<VoiceConfig>
- Inheritance
-
VoiceConfig
- Implements
- Inherited Members
Properties
PrebuiltVoiceConfig
The configuration for a prebuilt voice.
[JsonPropertyName("prebuiltVoiceConfig")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public PrebuiltVoiceConfig? PrebuiltVoiceConfig { get; set; }
Property Value
ReplicatedVoiceConfig
The configuration for a replicated voice, which is a clone of a user's voice that can be used for speech synthesis. If this is unset, a default voice is used.
[JsonPropertyName("replicatedVoiceConfig")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public ReplicatedVoiceConfig? ReplicatedVoiceConfig { get; set; }
Property Value
Methods
FromJson(string, JsonSerializerOptions?)
Deserializes a JSON string to a VoiceConfig object.
public static VoiceConfig? FromJson(string jsonString, JsonSerializerOptions? options = null)
Parameters
jsonStringstringThe JSON string to deserialize.
optionsJsonSerializerOptionsOptional JsonSerializerOptions.
Returns
- VoiceConfig
The deserialized VoiceConfig object, or null if deserialization fails.