Skip to content

Commit

Permalink
feat: Generate Google.Apis.Texttospeech.v1beta1 version 1.68.0.3568
Browse files Browse the repository at this point in the history
  • Loading branch information
amanda-tarafa committed Oct 16, 2024
1 parent e97487c commit 5296bc7
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 264 deletions.
119 changes: 1 addition & 118 deletions DiscoveryJson/texttospeech.v1beta1.json
Original file line number Diff line number Diff line change
Expand Up @@ -237,24 +237,6 @@
},
"voices": {
"methods": {
"generateVoiceCloningKey": {
"description": "Generates voice clone key given a short voice prompt. This method validates the voice prompts with a series of checks against the voice talent statement to verify the voice clone is safe to generate.",
"flatPath": "v1beta1/voices:generateVoiceCloningKey",
"httpMethod": "POST",
"id": "texttospeech.voices.generateVoiceCloningKey",
"parameterOrder": [],
"parameters": {},
"path": "v1beta1/voices:generateVoiceCloningKey",
"request": {
"$ref": "GenerateVoiceCloningKeyRequest"
},
"response": {
"$ref": "GenerateVoiceCloningKeyResponse"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform"
]
},
"list": {
"description": "Returns a list of Voice supported for synthesis.",
"flatPath": "v1beta1/voices",
Expand All @@ -279,7 +261,7 @@
}
}
},
"revision": "20241001",
"revision": "20241008",
"rootUrl": "https://texttospeech.googleapis.com/",
"schemas": {
"AdvancedVoiceOptions": {
Expand Down Expand Up @@ -418,40 +400,6 @@
},
"type": "object"
},
"GenerateVoiceCloningKeyRequest": {
"description": "Request message for the `GenerateVoiceCloningKey` method.",
"id": "GenerateVoiceCloningKeyRequest",
"properties": {
"consentScript": {
"description": "Required. The script used for the voice talent statement. The script will be provided to the caller through other channels. It must be returned unchanged in this field.",
"type": "string"
},
"languageCode": {
"description": "Required. The language of the supplied audio as a [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. Example: \"en-US\". See [Language Support](https://cloud.google.com/speech-to-text/docs/languages) for a list of the currently supported language codes.",
"type": "string"
},
"referenceAudio": {
"$ref": "InputAudio",
"description": "Required. The training audio used to create voice clone. This is currently limited to LINEAR16 PCM WAV files mono audio with 24khz sample rate. This needs to be specified in [InputAudio.audio_config], other values will be explicitly rejected."
},
"voiceTalentConsent": {
"$ref": "InputAudio",
"description": "Required. The voice talent audio used to verify consent to voice clone."
}
},
"type": "object"
},
"GenerateVoiceCloningKeyResponse": {
"description": "Response message for the `GenerateVoiceCloningKey` method.",
"id": "GenerateVoiceCloningKeyResponse",
"properties": {
"voiceCloningKey": {
"description": "The voice clone key. Use it in the SynthesizeSpeechRequest by setting [voice.voice_clone.voice_cloning_key].",
"type": "string"
}
},
"type": "object"
},
"GoogleCloudTexttospeechV1beta1SynthesizeLongAudioMetadata": {
"description": "Metadata for response returned by the `SynthesizeLongAudio` method.",
"id": "GoogleCloudTexttospeechV1beta1SynthesizeLongAudioMetadata",
Expand All @@ -475,56 +423,6 @@
},
"type": "object"
},
"InputAudio": {
"description": "Holds audio content and config.",
"id": "InputAudio",
"properties": {
"audioConfig": {
"$ref": "InputAudioConfig",
"description": "Required. Provides information that specifies how to process content."
},
"content": {
"description": "Required. The audio data bytes encoded as specified in `InputAudioConfig`. Note: as with all bytes fields, proto buffers use a pure binary representation, whereas JSON representations use base64. Audio samples should be between 5-25 seconds in length.",
"format": "byte",
"type": "string"
}
},
"type": "object"
},
"InputAudioConfig": {
"description": "Description of inputted audio data.",
"id": "InputAudioConfig",
"properties": {
"audioEncoding": {
"description": "Required. The format of the audio byte stream.",
"enum": [
"AUDIO_ENCODING_UNSPECIFIED",
"LINEAR16",
"MP3",
"MP3_64_KBPS",
"OGG_OPUS",
"MULAW",
"ALAW"
],
"enumDescriptions": [
"Not specified. Will return result google.rpc.Code.INVALID_ARGUMENT.",
"Uncompressed 16-bit signed little-endian samples (Linear PCM). Audio content returned as LINEAR16 also contains a WAV header.",
"MP3 audio at 32kbps.",
"MP3 at 64kbps.",
"Opus encoded audio wrapped in an ogg container. The result will be a file which can be played natively on Android, and in browsers (at least Chrome and Firefox). The quality of the encoding is considerably higher than MP3 while using approximately the same bitrate.",
"8-bit samples that compand 14-bit audio samples using G.711 PCMU/mu-law. Audio content returned as MULAW also contains a WAV header.",
"8-bit samples that compand 14-bit audio samples using G.711 PCMU/A-law. Audio content returned as ALAW also contains a WAV header."
],
"type": "string"
},
"sampleRateHertz": {
"description": "Required. The sample rate (in hertz) for this audio.",
"format": "int32",
"type": "integer"
}
},
"type": "object"
},
"ListOperationsResponse": {
"description": "The response message for Operations.ListOperations.",
"id": "ListOperationsResponse",
Expand Down Expand Up @@ -800,17 +698,6 @@
},
"type": "object"
},
"VoiceCloneParams": {
"description": "The configuration of Voice Clone feature.",
"id": "VoiceCloneParams",
"properties": {
"voiceCloningKey": {
"description": "Required. Created by GenerateVoiceCloningKey.",
"type": "string"
}
},
"type": "object"
},
"VoiceSelectionParams": {
"description": "Description of which voice to use for a synthesis request.",
"id": "VoiceSelectionParams",
Expand Down Expand Up @@ -842,10 +729,6 @@
"A gender-neutral voice. This voice is not yet supported."
],
"type": "string"
},
"voiceClone": {
"$ref": "VoiceCloneParams",
"description": "Optional. The configuration for a voice clone. If [VoiceCloneParams.voice_clone_key] is set, the service will choose the voice clone matching the specified configuration."
}
},
"type": "object"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -586,51 +586,6 @@ public VoicesResource(Google.Apis.Services.IClientService service)
this.service = service;
}

/// <summary>
/// Generates voice clone key given a short voice prompt. This method validates the voice prompts with a series
/// of checks against the voice talent statement to verify the voice clone is safe to generate.
/// </summary>
/// <param name="body">The body of the request.</param>
public virtual GenerateVoiceCloningKeyRequest GenerateVoiceCloningKey(Google.Apis.Texttospeech.v1beta1.Data.GenerateVoiceCloningKeyRequest body)
{
return new GenerateVoiceCloningKeyRequest(this.service, body);
}

/// <summary>
/// Generates voice clone key given a short voice prompt. This method validates the voice prompts with a series
/// of checks against the voice talent statement to verify the voice clone is safe to generate.
/// </summary>
public class GenerateVoiceCloningKeyRequest : TexttospeechBaseServiceRequest<Google.Apis.Texttospeech.v1beta1.Data.GenerateVoiceCloningKeyResponse>
{
/// <summary>Constructs a new GenerateVoiceCloningKey request.</summary>
public GenerateVoiceCloningKeyRequest(Google.Apis.Services.IClientService service, Google.Apis.Texttospeech.v1beta1.Data.GenerateVoiceCloningKeyRequest body) : base(service)
{
Body = body;
InitParameters();
}

/// <summary>Gets or sets the body of this request.</summary>
Google.Apis.Texttospeech.v1beta1.Data.GenerateVoiceCloningKeyRequest Body { get; set; }

/// <summary>Returns the body of the request.</summary>
protected override object GetBody() => Body;

/// <summary>Gets the method name.</summary>
public override string MethodName => "generateVoiceCloningKey";

/// <summary>Gets the HTTP method.</summary>
public override string HttpMethod => "POST";

/// <summary>Gets the REST path.</summary>
public override string RestPath => "v1beta1/voices:generateVoiceCloningKey";

/// <summary>Initializes GenerateVoiceCloningKey parameter list.</summary>
protected override void InitParameters()
{
base.InitParameters();
}
}

/// <summary>Returns a list of Voice supported for synthesis.</summary>
public virtual ListRequest List()
{
Expand Down Expand Up @@ -800,54 +755,6 @@ public class CustomVoiceParams : Google.Apis.Requests.IDirectResponseSchema
public virtual string ETag { get; set; }
}

/// <summary>Request message for the `GenerateVoiceCloningKey` method.</summary>
public class GenerateVoiceCloningKeyRequest : Google.Apis.Requests.IDirectResponseSchema
{
/// <summary>
/// Required. The script used for the voice talent statement. The script will be provided to the caller through
/// other channels. It must be returned unchanged in this field.
/// </summary>
[Newtonsoft.Json.JsonPropertyAttribute("consentScript")]
public virtual string ConsentScript { get; set; }

/// <summary>
/// Required. The language of the supplied audio as a [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt)
/// language tag. Example: "en-US". See [Language
/// Support](https://cloud.google.com/speech-to-text/docs/languages) for a list of the currently supported
/// language codes.
/// </summary>
[Newtonsoft.Json.JsonPropertyAttribute("languageCode")]
public virtual string LanguageCode { get; set; }

/// <summary>
/// Required. The training audio used to create voice clone. This is currently limited to LINEAR16 PCM WAV files
/// mono audio with 24khz sample rate. This needs to be specified in [InputAudio.audio_config], other values
/// will be explicitly rejected.
/// </summary>
[Newtonsoft.Json.JsonPropertyAttribute("referenceAudio")]
public virtual InputAudio ReferenceAudio { get; set; }

/// <summary>Required. The voice talent audio used to verify consent to voice clone.</summary>
[Newtonsoft.Json.JsonPropertyAttribute("voiceTalentConsent")]
public virtual InputAudio VoiceTalentConsent { get; set; }

/// <summary>The ETag of the item.</summary>
public virtual string ETag { get; set; }
}

/// <summary>Response message for the `GenerateVoiceCloningKey` method.</summary>
public class GenerateVoiceCloningKeyResponse : Google.Apis.Requests.IDirectResponseSchema
{
/// <summary>
/// The voice clone key. Use it in the SynthesizeSpeechRequest by setting [voice.voice_clone.voice_cloning_key].
/// </summary>
[Newtonsoft.Json.JsonPropertyAttribute("voiceCloningKey")]
public virtual string VoiceCloningKey { get; set; }

/// <summary>The ETag of the item.</summary>
public virtual string ETag { get; set; }
}

/// <summary>Metadata for response returned by the `SynthesizeLongAudio` method.</summary>
public class GoogleCloudTexttospeechV1beta1SynthesizeLongAudioMetadata : Google.Apis.Requests.IDirectResponseSchema
{
Expand Down Expand Up @@ -935,40 +842,6 @@ public virtual System.DateTimeOffset? StartTimeDateTimeOffset
public virtual string ETag { get; set; }
}

/// <summary>Holds audio content and config.</summary>
public class InputAudio : Google.Apis.Requests.IDirectResponseSchema
{
/// <summary>Required. Provides information that specifies how to process content.</summary>
[Newtonsoft.Json.JsonPropertyAttribute("audioConfig")]
public virtual InputAudioConfig AudioConfig { get; set; }

/// <summary>
/// Required. The audio data bytes encoded as specified in `InputAudioConfig`. Note: as with all bytes fields,
/// proto buffers use a pure binary representation, whereas JSON representations use base64. Audio samples
/// should be between 5-25 seconds in length.
/// </summary>
[Newtonsoft.Json.JsonPropertyAttribute("content")]
public virtual string Content { get; set; }

/// <summary>The ETag of the item.</summary>
public virtual string ETag { get; set; }
}

/// <summary>Description of inputted audio data.</summary>
public class InputAudioConfig : Google.Apis.Requests.IDirectResponseSchema
{
/// <summary>Required. The format of the audio byte stream.</summary>
[Newtonsoft.Json.JsonPropertyAttribute("audioEncoding")]
public virtual string AudioEncoding { get; set; }

/// <summary>Required. The sample rate (in hertz) for this audio.</summary>
[Newtonsoft.Json.JsonPropertyAttribute("sampleRateHertz")]
public virtual System.Nullable<int> SampleRateHertz { get; set; }

/// <summary>The ETag of the item.</summary>
public virtual string ETag { get; set; }
}

/// <summary>The response message for Operations.ListOperations.</summary>
public class ListOperationsResponse : Google.Apis.Requests.IDirectResponseSchema
{
Expand Down Expand Up @@ -1309,17 +1182,6 @@ public class Voice : Google.Apis.Requests.IDirectResponseSchema
public virtual string ETag { get; set; }
}

/// <summary>The configuration of Voice Clone feature.</summary>
public class VoiceCloneParams : Google.Apis.Requests.IDirectResponseSchema
{
/// <summary>Required. Created by GenerateVoiceCloningKey.</summary>
[Newtonsoft.Json.JsonPropertyAttribute("voiceCloningKey")]
public virtual string VoiceCloningKey { get; set; }

/// <summary>The ETag of the item.</summary>
public virtual string ETag { get; set; }
}

/// <summary>Description of which voice to use for a synthesis request.</summary>
public class VoiceSelectionParams : Google.Apis.Requests.IDirectResponseSchema
{
Expand Down Expand Up @@ -1358,13 +1220,6 @@ public class VoiceSelectionParams : Google.Apis.Requests.IDirectResponseSchema
[Newtonsoft.Json.JsonPropertyAttribute("ssmlGender")]
public virtual string SsmlGender { get; set; }

/// <summary>
/// Optional. The configuration for a voice clone. If [VoiceCloneParams.voice_clone_key] is set, the service
/// will choose the voice clone matching the specified configuration.
/// </summary>
[Newtonsoft.Json.JsonPropertyAttribute("voiceClone")]
public virtual VoiceCloneParams VoiceClone { get; set; }

/// <summary>The ETag of the item.</summary>
public virtual string ETag { get; set; }
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<!-- nupkg information -->
<PropertyGroup>
<Title>Google.Apis.Texttospeech.v1beta1 Client Library</Title>
<Version>1.68.0.3561</Version>
<Version>1.68.0.3568</Version>
<Authors>Google LLC</Authors>
<Copyright>Copyright 2024 Google LLC</Copyright>
<PackageTags>Google</PackageTags>
Expand Down

0 comments on commit 5296bc7

Please sign in to comment.