From e97487c759d9c77d454ea628f250921e6cb85f4d Mon Sep 17 00:00:00 2001 From: Amanda Tarafa Mas Date: Wed, 16 Oct 2024 01:08:34 -0700 Subject: [PATCH] feat: Generate Google.Apis.Texttospeech.v1 version 1.68.0.3568 --- DiscoveryJson/texttospeech.v1.json | 117 +------------- .../Google.Apis.Texttospeech.v1.cs | 145 ------------------ .../Google.Apis.Texttospeech.v1.csproj | 2 +- 3 files changed, 2 insertions(+), 262 deletions(-) diff --git a/DiscoveryJson/texttospeech.v1.json b/DiscoveryJson/texttospeech.v1.json index 80e1c407e23..782a11f4fdc 100644 --- a/DiscoveryJson/texttospeech.v1.json +++ b/DiscoveryJson/texttospeech.v1.json @@ -294,24 +294,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": "v1/voices:generateVoiceCloningKey", - "httpMethod": "POST", - "id": "texttospeech.voices.generateVoiceCloningKey", - "parameterOrder": [], - "parameters": {}, - "path": "v1/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": "v1/voices", @@ -336,7 +318,7 @@ } } }, - "revision": "20241001", + "revision": "20241008", "rootUrl": "https://texttospeech.googleapis.com/", "schemas": { "AdvancedVoiceOptions": { @@ -485,40 +467,6 @@ "properties": {}, "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" - }, "GoogleCloudTexttospeechV1SynthesizeLongAudioMetadata": { "description": "Metadata for response returned by the `SynthesizeLongAudio` method.", "id": "GoogleCloudTexttospeechV1SynthesizeLongAudioMetadata", @@ -542,54 +490,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", - "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.", - "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", @@ -823,17 +723,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", @@ -865,10 +754,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" diff --git a/Src/Generated/Google.Apis.Texttospeech.v1/Google.Apis.Texttospeech.v1.cs b/Src/Generated/Google.Apis.Texttospeech.v1/Google.Apis.Texttospeech.v1.cs index 149d82a388d..bfc0da9c861 100644 --- a/Src/Generated/Google.Apis.Texttospeech.v1/Google.Apis.Texttospeech.v1.cs +++ b/Src/Generated/Google.Apis.Texttospeech.v1/Google.Apis.Texttospeech.v1.cs @@ -725,51 +725,6 @@ public VoicesResource(Google.Apis.Services.IClientService service) this.service = service; } - /// - /// 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. - /// - /// The body of the request. - public virtual GenerateVoiceCloningKeyRequest GenerateVoiceCloningKey(Google.Apis.Texttospeech.v1.Data.GenerateVoiceCloningKeyRequest body) - { - return new GenerateVoiceCloningKeyRequest(this.service, body); - } - - /// - /// 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. - /// - public class GenerateVoiceCloningKeyRequest : TexttospeechBaseServiceRequest - { - /// Constructs a new GenerateVoiceCloningKey request. - public GenerateVoiceCloningKeyRequest(Google.Apis.Services.IClientService service, Google.Apis.Texttospeech.v1.Data.GenerateVoiceCloningKeyRequest body) : base(service) - { - Body = body; - InitParameters(); - } - - /// Gets or sets the body of this request. - Google.Apis.Texttospeech.v1.Data.GenerateVoiceCloningKeyRequest Body { get; set; } - - /// Returns the body of the request. - protected override object GetBody() => Body; - - /// Gets the method name. - public override string MethodName => "generateVoiceCloningKey"; - - /// Gets the HTTP method. - public override string HttpMethod => "POST"; - - /// Gets the REST path. - public override string RestPath => "v1/voices:generateVoiceCloningKey"; - - /// Initializes GenerateVoiceCloningKey parameter list. - protected override void InitParameters() - { - base.InitParameters(); - } - } - /// Returns a list of Voice supported for synthesis. public virtual ListRequest List() { @@ -957,54 +912,6 @@ public class Empty : Google.Apis.Requests.IDirectResponseSchema public virtual string ETag { get; set; } } - /// Request message for the `GenerateVoiceCloningKey` method. - public class GenerateVoiceCloningKeyRequest : Google.Apis.Requests.IDirectResponseSchema - { - /// - /// 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. - /// - [Newtonsoft.Json.JsonPropertyAttribute("consentScript")] - public virtual string ConsentScript { get; set; } - - /// - /// 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. - /// - [Newtonsoft.Json.JsonPropertyAttribute("languageCode")] - public virtual string LanguageCode { get; set; } - - /// - /// 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. - /// - [Newtonsoft.Json.JsonPropertyAttribute("referenceAudio")] - public virtual InputAudio ReferenceAudio { get; set; } - - /// Required. The voice talent audio used to verify consent to voice clone. - [Newtonsoft.Json.JsonPropertyAttribute("voiceTalentConsent")] - public virtual InputAudio VoiceTalentConsent { get; set; } - - /// The ETag of the item. - public virtual string ETag { get; set; } - } - - /// Response message for the `GenerateVoiceCloningKey` method. - public class GenerateVoiceCloningKeyResponse : Google.Apis.Requests.IDirectResponseSchema - { - /// - /// The voice clone key. Use it in the SynthesizeSpeechRequest by setting [voice.voice_clone.voice_cloning_key]. - /// - [Newtonsoft.Json.JsonPropertyAttribute("voiceCloningKey")] - public virtual string VoiceCloningKey { get; set; } - - /// The ETag of the item. - public virtual string ETag { get; set; } - } - /// Metadata for response returned by the `SynthesizeLongAudio` method. public class GoogleCloudTexttospeechV1SynthesizeLongAudioMetadata : Google.Apis.Requests.IDirectResponseSchema { @@ -1092,40 +999,6 @@ public virtual System.DateTimeOffset? StartTimeDateTimeOffset public virtual string ETag { get; set; } } - /// Holds audio content and config. - public class InputAudio : Google.Apis.Requests.IDirectResponseSchema - { - /// Required. Provides information that specifies how to process content. - [Newtonsoft.Json.JsonPropertyAttribute("audioConfig")] - public virtual InputAudioConfig AudioConfig { get; set; } - - /// - /// 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. - /// - [Newtonsoft.Json.JsonPropertyAttribute("content")] - public virtual string Content { get; set; } - - /// The ETag of the item. - public virtual string ETag { get; set; } - } - - /// Description of inputted audio data. - public class InputAudioConfig : Google.Apis.Requests.IDirectResponseSchema - { - /// Required. The format of the audio byte stream. - [Newtonsoft.Json.JsonPropertyAttribute("audioEncoding")] - public virtual string AudioEncoding { get; set; } - - /// Required. The sample rate (in hertz) for this audio. - [Newtonsoft.Json.JsonPropertyAttribute("sampleRateHertz")] - public virtual System.Nullable SampleRateHertz { get; set; } - - /// The ETag of the item. - public virtual string ETag { get; set; } - } - /// The response message for Operations.ListOperations. public class ListOperationsResponse : Google.Apis.Requests.IDirectResponseSchema { @@ -1434,17 +1307,6 @@ public class Voice : Google.Apis.Requests.IDirectResponseSchema public virtual string ETag { get; set; } } - /// The configuration of Voice Clone feature. - public class VoiceCloneParams : Google.Apis.Requests.IDirectResponseSchema - { - /// Required. Created by GenerateVoiceCloningKey. - [Newtonsoft.Json.JsonPropertyAttribute("voiceCloningKey")] - public virtual string VoiceCloningKey { get; set; } - - /// The ETag of the item. - public virtual string ETag { get; set; } - } - /// Description of which voice to use for a synthesis request. public class VoiceSelectionParams : Google.Apis.Requests.IDirectResponseSchema { @@ -1483,13 +1345,6 @@ public class VoiceSelectionParams : Google.Apis.Requests.IDirectResponseSchema [Newtonsoft.Json.JsonPropertyAttribute("ssmlGender")] public virtual string SsmlGender { get; set; } - /// - /// 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. - /// - [Newtonsoft.Json.JsonPropertyAttribute("voiceClone")] - public virtual VoiceCloneParams VoiceClone { get; set; } - /// The ETag of the item. public virtual string ETag { get; set; } } diff --git a/Src/Generated/Google.Apis.Texttospeech.v1/Google.Apis.Texttospeech.v1.csproj b/Src/Generated/Google.Apis.Texttospeech.v1/Google.Apis.Texttospeech.v1.csproj index 00853aa1235..4c4d5dc71a3 100644 --- a/Src/Generated/Google.Apis.Texttospeech.v1/Google.Apis.Texttospeech.v1.csproj +++ b/Src/Generated/Google.Apis.Texttospeech.v1/Google.Apis.Texttospeech.v1.csproj @@ -3,7 +3,7 @@ Google.Apis.Texttospeech.v1 Client Library - 1.68.0.3561 + 1.68.0.3568 Google LLC Copyright 2024 Google LLC Google