google-apis-texttospeech_v1beta1 0.18.0 → 0.19.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a0830f1d96344493b7e3a0cc363235d9c66ce241dfbcc81f87a2a9ba8370ca6f
4
- data.tar.gz: 28abf5ae99fa880d9c77cbef8f06d5d74c871d927cd2364baecfba57d13d0b41
3
+ metadata.gz: f98f46c1a57884917c292d5b66abc39d87eb7afad105927d02827ddeebab698d
4
+ data.tar.gz: c37b6dd19a1a10070e98ba7fff5954271540e87b0baee6641dcc071ae9e537e2
5
5
  SHA512:
6
- metadata.gz: e7bcb7b088ecf84fbf19746ddc7f6748ff371209eef6e65ebaff1a4577960545d0eda571243241b09d0d0e5b8b7f2f202553c0dfd30cfa5a61294da368ff4322
7
- data.tar.gz: 4af9d3eb637ba42a92c74fd54d07dff6171b63321c5d2b47dd16cfc73a4d3c9116f5ceac249fba072552e061e6a06f22b97f29ddb2b961eddefd893740ba7d24
6
+ metadata.gz: 10e613457e166e8bb61c85349f6be63bb1a6da1c69e1f302bca3ba106ea876d50cec9eed6580fd58520bda21d84f22ea0955d976cd7fd5c7c57bd9f386c7cb8b
7
+ data.tar.gz: 2ebecb4f776fdd1b40a6c73dbfe104cc7f1f3b7e83e553972164268c7c19c9feda7ffb3de3f94fe46919e3b20a06656252f6003801d265db7d149ce5c6ef6602
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Release history for google-apis-texttospeech_v1beta1
2
2
 
3
+ ### v0.19.0 (2022-12-04)
4
+
5
+ * Regenerated from discovery document revision 20221201
6
+
3
7
  ### v0.18.0 (2022-10-28)
4
8
 
5
9
  * Regenerated using generator version 0.11.0
@@ -137,9 +137,110 @@ module Google
137
137
  end
138
138
  end
139
139
 
140
+ # This resource represents a long-running operation that is the result of a
141
+ # network API call.
142
+ class Operation
143
+ include Google::Apis::Core::Hashable
144
+
145
+ # If the value is `false`, it means the operation is still in progress. If `true`
146
+ # , the operation is completed, and either `error` or `response` is available.
147
+ # Corresponds to the JSON property `done`
148
+ # @return [Boolean]
149
+ attr_accessor :done
150
+ alias_method :done?, :done
151
+
152
+ # The `Status` type defines a logical error model that is suitable for different
153
+ # programming environments, including REST APIs and RPC APIs. It is used by [
154
+ # gRPC](https://github.com/grpc). Each `Status` message contains three pieces of
155
+ # data: error code, error message, and error details. You can find out more
156
+ # about this error model and how to work with it in the [API Design Guide](https:
157
+ # //cloud.google.com/apis/design/errors).
158
+ # Corresponds to the JSON property `error`
159
+ # @return [Google::Apis::TexttospeechV1beta1::Status]
160
+ attr_accessor :error
161
+
162
+ # Service-specific metadata associated with the operation. It typically contains
163
+ # progress information and common metadata such as create time. Some services
164
+ # might not provide such metadata. Any method that returns a long-running
165
+ # operation should document the metadata type, if any.
166
+ # Corresponds to the JSON property `metadata`
167
+ # @return [Hash<String,Object>]
168
+ attr_accessor :metadata
169
+
170
+ # The server-assigned name, which is only unique within the same service that
171
+ # originally returns it. If you use the default HTTP mapping, the `name` should
172
+ # be a resource name ending with `operations/`unique_id``.
173
+ # Corresponds to the JSON property `name`
174
+ # @return [String]
175
+ attr_accessor :name
176
+
177
+ # The normal response of the operation in case of success. If the original
178
+ # method returns no data on success, such as `Delete`, the response is `google.
179
+ # protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`,
180
+ # the response should be the resource. For other methods, the response should
181
+ # have the type `XxxResponse`, where `Xxx` is the original method name. For
182
+ # example, if the original method name is `TakeSnapshot()`, the inferred
183
+ # response type is `TakeSnapshotResponse`.
184
+ # Corresponds to the JSON property `response`
185
+ # @return [Hash<String,Object>]
186
+ attr_accessor :response
187
+
188
+ def initialize(**args)
189
+ update!(**args)
190
+ end
191
+
192
+ # Update properties of this object
193
+ def update!(**args)
194
+ @done = args[:done] if args.key?(:done)
195
+ @error = args[:error] if args.key?(:error)
196
+ @metadata = args[:metadata] if args.key?(:metadata)
197
+ @name = args[:name] if args.key?(:name)
198
+ @response = args[:response] if args.key?(:response)
199
+ end
200
+ end
201
+
202
+ # The `Status` type defines a logical error model that is suitable for different
203
+ # programming environments, including REST APIs and RPC APIs. It is used by [
204
+ # gRPC](https://github.com/grpc). Each `Status` message contains three pieces of
205
+ # data: error code, error message, and error details. You can find out more
206
+ # about this error model and how to work with it in the [API Design Guide](https:
207
+ # //cloud.google.com/apis/design/errors).
208
+ class Status
209
+ include Google::Apis::Core::Hashable
210
+
211
+ # The status code, which should be an enum value of google.rpc.Code.
212
+ # Corresponds to the JSON property `code`
213
+ # @return [Fixnum]
214
+ attr_accessor :code
215
+
216
+ # A list of messages that carry the error details. There is a common set of
217
+ # message types for APIs to use.
218
+ # Corresponds to the JSON property `details`
219
+ # @return [Array<Hash<String,Object>>]
220
+ attr_accessor :details
221
+
222
+ # A developer-facing error message, which should be in English. Any user-facing
223
+ # error message should be localized and sent in the google.rpc.Status.details
224
+ # field, or localized by the client.
225
+ # Corresponds to the JSON property `message`
226
+ # @return [String]
227
+ attr_accessor :message
228
+
229
+ def initialize(**args)
230
+ update!(**args)
231
+ end
232
+
233
+ # Update properties of this object
234
+ def update!(**args)
235
+ @code = args[:code] if args.key?(:code)
236
+ @details = args[:details] if args.key?(:details)
237
+ @message = args[:message] if args.key?(:message)
238
+ end
239
+ end
240
+
140
241
  # Contains text input to be synthesized. Either `text` or `ssml` must be
141
242
  # supplied. Supplying both or neither returns google.rpc.Code.INVALID_ARGUMENT.
142
- # The input size is limited to 5000 characters.
243
+ # The input size is limited to 5000 bytes.
143
244
  class SynthesisInput
144
245
  include Google::Apis::Core::Hashable
145
246
 
@@ -167,6 +268,46 @@ module Google
167
268
  end
168
269
  end
169
270
 
271
+ # The top-level message sent by the client for the `SynthesizeLongAudio` method.
272
+ class SynthesizeLongAudioRequest
273
+ include Google::Apis::Core::Hashable
274
+
275
+ # Description of audio data to be synthesized.
276
+ # Corresponds to the JSON property `audioConfig`
277
+ # @return [Google::Apis::TexttospeechV1beta1::AudioConfig]
278
+ attr_accessor :audio_config
279
+
280
+ # Contains text input to be synthesized. Either `text` or `ssml` must be
281
+ # supplied. Supplying both or neither returns google.rpc.Code.INVALID_ARGUMENT.
282
+ # The input size is limited to 5000 bytes.
283
+ # Corresponds to the JSON property `input`
284
+ # @return [Google::Apis::TexttospeechV1beta1::SynthesisInput]
285
+ attr_accessor :input
286
+
287
+ # Specifies a Cloud Storage URI for the synthesis results. Must be specified in
288
+ # the format: `gs://bucket_name/object_name`, and the bucket must already exist.
289
+ # Corresponds to the JSON property `outputGcsUri`
290
+ # @return [String]
291
+ attr_accessor :output_gcs_uri
292
+
293
+ # Description of which voice to use for a synthesis request.
294
+ # Corresponds to the JSON property `voice`
295
+ # @return [Google::Apis::TexttospeechV1beta1::VoiceSelectionParams]
296
+ attr_accessor :voice
297
+
298
+ def initialize(**args)
299
+ update!(**args)
300
+ end
301
+
302
+ # Update properties of this object
303
+ def update!(**args)
304
+ @audio_config = args[:audio_config] if args.key?(:audio_config)
305
+ @input = args[:input] if args.key?(:input)
306
+ @output_gcs_uri = args[:output_gcs_uri] if args.key?(:output_gcs_uri)
307
+ @voice = args[:voice] if args.key?(:voice)
308
+ end
309
+ end
310
+
170
311
  # The top-level message sent by the client for the `SynthesizeSpeech` method.
171
312
  class SynthesizeSpeechRequest
172
313
  include Google::Apis::Core::Hashable
@@ -183,7 +324,7 @@ module Google
183
324
 
184
325
  # Contains text input to be synthesized. Either `text` or `ssml` must be
185
326
  # supplied. Supplying both or neither returns google.rpc.Code.INVALID_ARGUMENT.
186
- # The input size is limited to 5000 characters.
327
+ # The input size is limited to 5000 bytes.
187
328
  # Corresponds to the JSON property `input`
188
329
  # @return [Google::Apis::TexttospeechV1beta1::SynthesisInput]
189
330
  attr_accessor :input
@@ -16,13 +16,13 @@ module Google
16
16
  module Apis
17
17
  module TexttospeechV1beta1
18
18
  # Version of the google-apis-texttospeech_v1beta1 gem
19
- GEM_VERSION = "0.18.0"
19
+ GEM_VERSION = "0.19.0"
20
20
 
21
21
  # Version of the code generator used to generate this client
22
22
  GENERATOR_VERSION = "0.11.0"
23
23
 
24
24
  # Revision of the discovery document this client was generated from
25
- REVISION = "20211130"
25
+ REVISION = "20221201"
26
26
  end
27
27
  end
28
28
  end
@@ -40,12 +40,30 @@ module Google
40
40
  include Google::Apis::Core::JsonObjectSupport
41
41
  end
42
42
 
43
+ class Operation
44
+ class Representation < Google::Apis::Core::JsonRepresentation; end
45
+
46
+ include Google::Apis::Core::JsonObjectSupport
47
+ end
48
+
49
+ class Status
50
+ class Representation < Google::Apis::Core::JsonRepresentation; end
51
+
52
+ include Google::Apis::Core::JsonObjectSupport
53
+ end
54
+
43
55
  class SynthesisInput
44
56
  class Representation < Google::Apis::Core::JsonRepresentation; end
45
57
 
46
58
  include Google::Apis::Core::JsonObjectSupport
47
59
  end
48
60
 
61
+ class SynthesizeLongAudioRequest
62
+ class Representation < Google::Apis::Core::JsonRepresentation; end
63
+
64
+ include Google::Apis::Core::JsonObjectSupport
65
+ end
66
+
49
67
  class SynthesizeSpeechRequest
50
68
  class Representation < Google::Apis::Core::JsonRepresentation; end
51
69
 
@@ -104,6 +122,27 @@ module Google
104
122
  end
105
123
  end
106
124
 
125
+ class Operation
126
+ # @private
127
+ class Representation < Google::Apis::Core::JsonRepresentation
128
+ property :done, as: 'done'
129
+ property :error, as: 'error', class: Google::Apis::TexttospeechV1beta1::Status, decorator: Google::Apis::TexttospeechV1beta1::Status::Representation
130
+
131
+ hash :metadata, as: 'metadata'
132
+ property :name, as: 'name'
133
+ hash :response, as: 'response'
134
+ end
135
+ end
136
+
137
+ class Status
138
+ # @private
139
+ class Representation < Google::Apis::Core::JsonRepresentation
140
+ property :code, as: 'code'
141
+ collection :details, as: 'details'
142
+ property :message, as: 'message'
143
+ end
144
+ end
145
+
107
146
  class SynthesisInput
108
147
  # @private
109
148
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -112,6 +151,19 @@ module Google
112
151
  end
113
152
  end
114
153
 
154
+ class SynthesizeLongAudioRequest
155
+ # @private
156
+ class Representation < Google::Apis::Core::JsonRepresentation
157
+ property :audio_config, as: 'audioConfig', class: Google::Apis::TexttospeechV1beta1::AudioConfig, decorator: Google::Apis::TexttospeechV1beta1::AudioConfig::Representation
158
+
159
+ property :input, as: 'input', class: Google::Apis::TexttospeechV1beta1::SynthesisInput, decorator: Google::Apis::TexttospeechV1beta1::SynthesisInput::Representation
160
+
161
+ property :output_gcs_uri, as: 'outputGcsUri'
162
+ property :voice, as: 'voice', class: Google::Apis::TexttospeechV1beta1::VoiceSelectionParams, decorator: Google::Apis::TexttospeechV1beta1::VoiceSelectionParams::Representation
163
+
164
+ end
165
+ end
166
+
115
167
  class SynthesizeSpeechRequest
116
168
  # @private
117
169
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -49,6 +49,40 @@ module Google
49
49
  @batch_path = 'batch'
50
50
  end
51
51
 
52
+ # Synthesizes long form text asynchronously.
53
+ # @param [String] parent
54
+ # The resource states of the request in the form of projects/*/locations/*/
55
+ # voices/*.
56
+ # @param [Google::Apis::TexttospeechV1beta1::SynthesizeLongAudioRequest] synthesize_long_audio_request_object
57
+ # @param [String] fields
58
+ # Selector specifying which fields to include in a partial response.
59
+ # @param [String] quota_user
60
+ # Available to use for quota purposes for server-side applications. Can be any
61
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
62
+ # @param [Google::Apis::RequestOptions] options
63
+ # Request-specific options
64
+ #
65
+ # @yield [result, err] Result & error if block supplied
66
+ # @yieldparam result [Google::Apis::TexttospeechV1beta1::Operation] parsed result object
67
+ # @yieldparam err [StandardError] error object if request failed
68
+ #
69
+ # @return [Google::Apis::TexttospeechV1beta1::Operation]
70
+ #
71
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
72
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
73
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
74
+ def synthesize_voice_long_audio(parent, synthesize_long_audio_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
75
+ command = make_simple_command(:post, 'v1beta1/{+parent}:SynthesizeLongAudio', options)
76
+ command.request_representation = Google::Apis::TexttospeechV1beta1::SynthesizeLongAudioRequest::Representation
77
+ command.request_object = synthesize_long_audio_request_object
78
+ command.response_representation = Google::Apis::TexttospeechV1beta1::Operation::Representation
79
+ command.response_class = Google::Apis::TexttospeechV1beta1::Operation
80
+ command.params['parent'] = parent unless parent.nil?
81
+ command.query['fields'] = fields unless fields.nil?
82
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
83
+ execute_or_queue_command(command, &block)
84
+ end
85
+
52
86
  # Synthesizes speech synchronously: receive results after all text input has
53
87
  # been processed.
54
88
  # @param [Google::Apis::TexttospeechV1beta1::SynthesizeSpeechRequest] synthesize_speech_request_object
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-apis-texttospeech_v1beta1
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.18.0
4
+ version: 0.19.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-10-31 00:00:00.000000000 Z
11
+ date: 2022-12-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google-apis-core
@@ -58,7 +58,7 @@ licenses:
58
58
  metadata:
59
59
  bug_tracker_uri: https://github.com/googleapis/google-api-ruby-client/issues
60
60
  changelog_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-texttospeech_v1beta1/CHANGELOG.md
61
- documentation_uri: https://googleapis.dev/ruby/google-apis-texttospeech_v1beta1/v0.18.0
61
+ documentation_uri: https://googleapis.dev/ruby/google-apis-texttospeech_v1beta1/v0.19.0
62
62
  source_code_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-texttospeech_v1beta1
63
63
  post_install_message:
64
64
  rdoc_options: []