google-cloud-video-live_stream-v1 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (31) hide show
  1. checksums.yaml +7 -0
  2. data/.yardopts +12 -0
  3. data/AUTHENTICATION.md +149 -0
  4. data/LICENSE.md +201 -0
  5. data/README.md +139 -0
  6. data/lib/google/cloud/video/live_stream/v1/livestream_service/client.rb +2162 -0
  7. data/lib/google/cloud/video/live_stream/v1/livestream_service/credentials.rb +49 -0
  8. data/lib/google/cloud/video/live_stream/v1/livestream_service/operations.rb +769 -0
  9. data/lib/google/cloud/video/live_stream/v1/livestream_service/paths.rb +111 -0
  10. data/lib/google/cloud/video/live_stream/v1/livestream_service.rb +56 -0
  11. data/lib/google/cloud/video/live_stream/v1/version.rb +30 -0
  12. data/lib/google/cloud/video/live_stream/v1.rb +40 -0
  13. data/lib/google/cloud/video/livestream/v1/outputs_pb.rb +134 -0
  14. data/lib/google/cloud/video/livestream/v1/resources_pb.rb +168 -0
  15. data/lib/google/cloud/video/livestream/v1/service_pb.rb +154 -0
  16. data/lib/google/cloud/video/livestream/v1/service_services_pb.rb +84 -0
  17. data/lib/google-cloud-video-live_stream-v1.rb +21 -0
  18. data/proto_docs/README.md +4 -0
  19. data/proto_docs/google/api/field_behavior.rb +71 -0
  20. data/proto_docs/google/api/resource.rb +222 -0
  21. data/proto_docs/google/cloud/video/livestream/v1/outputs.rb +427 -0
  22. data/proto_docs/google/cloud/video/livestream/v1/resources.rb +450 -0
  23. data/proto_docs/google/cloud/video/livestream/v1/service.rb +523 -0
  24. data/proto_docs/google/longrunning/operations.rb +164 -0
  25. data/proto_docs/google/protobuf/any.rb +141 -0
  26. data/proto_docs/google/protobuf/duration.rb +98 -0
  27. data/proto_docs/google/protobuf/empty.rb +36 -0
  28. data/proto_docs/google/protobuf/field_mask.rb +229 -0
  29. data/proto_docs/google/protobuf/timestamp.rb +129 -0
  30. data/proto_docs/google/rpc/status.rb +46 -0
  31. metadata +222 -0
@@ -0,0 +1,450 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2022 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Cloud
22
+ module Video
23
+ module LiveStream
24
+ module V1
25
+ # Input resource represents the endpoint from which the channel ingests
26
+ # the input stream.
27
+ # @!attribute [rw] name
28
+ # @return [::String]
29
+ # The resource name of the input, in the form of:
30
+ # `projects/{project}/locations/{location}/inputs/{inputId}`.
31
+ # @!attribute [r] create_time
32
+ # @return [::Google::Protobuf::Timestamp]
33
+ # Output only. The creation time.
34
+ # @!attribute [r] update_time
35
+ # @return [::Google::Protobuf::Timestamp]
36
+ # Output only. The update time.
37
+ # @!attribute [rw] labels
38
+ # @return [::Google::Protobuf::Map{::String => ::String}]
39
+ # User-defined key/value metadata.
40
+ # @!attribute [rw] type
41
+ # @return [::Google::Cloud::Video::LiveStream::V1::Input::Type]
42
+ # Source type.
43
+ # @!attribute [rw] tier
44
+ # @return [::Google::Cloud::Video::LiveStream::V1::Input::Tier]
45
+ # Tier defines the maximum input specification that is accepted by the
46
+ # video pipeline. The billing is charged based on the tier specified here.
47
+ # See [Pricing](https://cloud.google.com/livestream/pricing) for more detail.
48
+ # The default is `HD`.
49
+ # @!attribute [r] uri
50
+ # @return [::String]
51
+ # Output only. URI to push the input stream to.
52
+ # Its format depends on the input {::Google::Cloud::Video::LiveStream::V1::Input#type type}, for example:
53
+ #
54
+ # * `RTMP_PUSH`: `rtmp://1.2.3.4/live/{STREAM-ID}`
55
+ # * `SRT_PUSH`: `srt://1.2.3.4:4201?streamid={STREAM-ID}`
56
+ # @!attribute [rw] preprocessing_config
57
+ # @return [::Google::Cloud::Video::LiveStream::V1::PreprocessingConfig]
58
+ # Preprocessing configurations.
59
+ # @!attribute [rw] security_rules
60
+ # @return [::Google::Cloud::Video::LiveStream::V1::Input::SecurityRule]
61
+ # Security rule for access control.
62
+ # @!attribute [r] input_stream_property
63
+ # @return [::Google::Cloud::Video::LiveStream::V1::InputStreamProperty]
64
+ # Output only. The information for the input stream. This field will be present only when
65
+ # this input receives the input stream.
66
+ class Input
67
+ include ::Google::Protobuf::MessageExts
68
+ extend ::Google::Protobuf::MessageExts::ClassMethods
69
+
70
+ # Security rules for access control. Each field represents one security rule.
71
+ # Only when the source of the input stream satisfies all the fields, this
72
+ # input stream can be accepted.
73
+ # @!attribute [rw] ip_ranges
74
+ # @return [::Array<::String>]
75
+ # At least one ip range must match unless none specified. The IP range is
76
+ # defined by CIDR block: for example, `192.0.1.0/24` for a range and
77
+ # `192.0.1.0/32` for a single IP address.
78
+ class SecurityRule
79
+ include ::Google::Protobuf::MessageExts
80
+ extend ::Google::Protobuf::MessageExts::ClassMethods
81
+ end
82
+
83
+ # @!attribute [rw] key
84
+ # @return [::String]
85
+ # @!attribute [rw] value
86
+ # @return [::String]
87
+ class LabelsEntry
88
+ include ::Google::Protobuf::MessageExts
89
+ extend ::Google::Protobuf::MessageExts::ClassMethods
90
+ end
91
+
92
+ # The type of the input.
93
+ module Type
94
+ # Input type is not specified.
95
+ TYPE_UNSPECIFIED = 0
96
+
97
+ # Input will take an rtmp input stream.
98
+ RTMP_PUSH = 1
99
+
100
+ # Input will take an srt (Secure Reliable Transport) input stream.
101
+ SRT_PUSH = 2
102
+ end
103
+
104
+ # Tier of the input specification.
105
+ module Tier
106
+ # Tier is not specified.
107
+ TIER_UNSPECIFIED = 0
108
+
109
+ # Resolution < 1280x720. Bitrate <= 6 Mbps. FPS <= 60.
110
+ SD = 1
111
+
112
+ # Resolution <= 1920x1080. Bitrate <= 25 Mbps. FPS <= 60.
113
+ HD = 2
114
+
115
+ # Resolution <= 4096x2160. Not supported yet.
116
+ UHD = 3
117
+ end
118
+ end
119
+
120
+ # Channel resource represents the processor that does a user-defined
121
+ # "streaming" operation, which includes getting an input stream through an
122
+ # input, transcoding it to multiple renditions, and publishing output live
123
+ # streams in certain formats (for example, HLS or DASH) to the specified
124
+ # location.
125
+ # @!attribute [rw] name
126
+ # @return [::String]
127
+ # The resource name of the channel, in the form of:
128
+ # `projects/{project}/locations/{location}/channels/{channelId}`.
129
+ # @!attribute [r] create_time
130
+ # @return [::Google::Protobuf::Timestamp]
131
+ # Output only. The creation time.
132
+ # @!attribute [r] update_time
133
+ # @return [::Google::Protobuf::Timestamp]
134
+ # Output only. The update time.
135
+ # @!attribute [rw] labels
136
+ # @return [::Google::Protobuf::Map{::String => ::String}]
137
+ # User-defined key/value metadata.
138
+ # @!attribute [rw] input_attachments
139
+ # @return [::Array<::Google::Cloud::Video::LiveStream::V1::InputAttachment>]
140
+ # A list of input attachments that this channel uses.
141
+ # One channel can have multiple inputs as the input sources. Only one
142
+ # input can be selected as the input source at one time.
143
+ # @!attribute [r] active_input
144
+ # @return [::String]
145
+ # Output only. The {::Google::Cloud::Video::LiveStream::V1::InputAttachment#key InputAttachment.key} that serves as the current input source. The
146
+ # first input in the {::Google::Cloud::Video::LiveStream::V1::Channel#input_attachments input_attachments} is the initial input source.
147
+ # @!attribute [rw] output
148
+ # @return [::Google::Cloud::Video::LiveStream::V1::Channel::Output]
149
+ # Required. Information about the output (that is, the Cloud Storage bucket to store
150
+ # the generated live stream).
151
+ # @!attribute [rw] elementary_streams
152
+ # @return [::Array<::Google::Cloud::Video::LiveStream::V1::ElementaryStream>]
153
+ # List of elementary streams.
154
+ # @!attribute [rw] mux_streams
155
+ # @return [::Array<::Google::Cloud::Video::LiveStream::V1::MuxStream>]
156
+ # List of multiplexing settings for output streams.
157
+ # @!attribute [rw] manifests
158
+ # @return [::Array<::Google::Cloud::Video::LiveStream::V1::Manifest>]
159
+ # List of output manifests.
160
+ # @!attribute [rw] sprite_sheets
161
+ # @return [::Array<::Google::Cloud::Video::LiveStream::V1::SpriteSheet>]
162
+ # List of output sprite sheets.
163
+ # @!attribute [r] streaming_state
164
+ # @return [::Google::Cloud::Video::LiveStream::V1::Channel::StreamingState]
165
+ # Output only. State of the streaming operation.
166
+ # @!attribute [r] streaming_error
167
+ # @return [::Google::Rpc::Status]
168
+ # Output only. A description of the reason for the streaming error. This property is
169
+ # always present when {::Google::Cloud::Video::LiveStream::V1::Channel#streaming_state streaming_state} is
170
+ # {::Google::Cloud::Video::LiveStream::V1::Channel::StreamingState::STREAMING_ERROR STREAMING_ERROR}.
171
+ # @!attribute [rw] log_config
172
+ # @return [::Google::Cloud::Video::LiveStream::V1::LogConfig]
173
+ # Configuration of platform logs for this channel.
174
+ class Channel
175
+ include ::Google::Protobuf::MessageExts
176
+ extend ::Google::Protobuf::MessageExts::ClassMethods
177
+
178
+ # Location of output file(s) in a Google Cloud Storage bucket.
179
+ # @!attribute [rw] uri
180
+ # @return [::String]
181
+ # URI for the output file(s). For example, `gs://my-bucket/outputs/`.
182
+ class Output
183
+ include ::Google::Protobuf::MessageExts
184
+ extend ::Google::Protobuf::MessageExts::ClassMethods
185
+ end
186
+
187
+ # @!attribute [rw] key
188
+ # @return [::String]
189
+ # @!attribute [rw] value
190
+ # @return [::String]
191
+ class LabelsEntry
192
+ include ::Google::Protobuf::MessageExts
193
+ extend ::Google::Protobuf::MessageExts::ClassMethods
194
+ end
195
+
196
+ # State of streaming operation that the channel is running.
197
+ module StreamingState
198
+ # Streaming state is not specified.
199
+ STREAMING_STATE_UNSPECIFIED = 0
200
+
201
+ # Channel is getting the input stream, generating the live streams to the
202
+ # specified output location.
203
+ STREAMING = 1
204
+
205
+ # Channel is waiting for the input stream through the input. Live streams
206
+ # do not start yet.
207
+ AWAITING_INPUT = 2
208
+
209
+ # Channel is running, but has trouble publishing the live streams onto the
210
+ # specified output location (for example, the specified Cloud Storage
211
+ # bucket is not writable).
212
+ STREAMING_ERROR = 4
213
+
214
+ # Channel is generating live streams with no input stream. Live streams are
215
+ # filled out with black screen, while input stream is missing.
216
+ STREAMING_NO_INPUT = 5
217
+
218
+ # Channel is stopped, finishing live streams.
219
+ STOPPED = 6
220
+
221
+ # Channel is starting.
222
+ STARTING = 7
223
+
224
+ # Channel is stopping.
225
+ STOPPING = 8
226
+ end
227
+ end
228
+
229
+ # Configuration of platform logs.
230
+ # See [Using and managing platform
231
+ # logs](https://cloud.google.com/logging/docs/api/platform-logs#managing-logs)
232
+ # for more information about how to view platform logs through Cloud Logging.
233
+ # @!attribute [rw] log_severity
234
+ # @return [::Google::Cloud::Video::LiveStream::V1::LogConfig::LogSeverity]
235
+ # The severity level of platform logging for this resource.
236
+ class LogConfig
237
+ include ::Google::Protobuf::MessageExts
238
+ extend ::Google::Protobuf::MessageExts::ClassMethods
239
+
240
+ # The severity level of platform logging for this channel. Logs with a
241
+ # severity level higher than or equal to the chosen severity level will be
242
+ # logged and can be viewed through Cloud Logging.
243
+ # The severity level of a log is ranked as followed from low to high: DEBUG <
244
+ # INFO < NOTICE < WARNING < ERROR < CRITICAL < ALERT < EMERGENCY.
245
+ # See
246
+ # [LogSeverity](https://cloud.google.com/logging/docs/reference/v2/rest/v2/LogEntry#logseverity)
247
+ # for more information.
248
+ module LogSeverity
249
+ # Log severity is not specified. This is the same as log severity is OFF.
250
+ LOG_SEVERITY_UNSPECIFIED = 0
251
+
252
+ # Log is turned off.
253
+ OFF = 1
254
+
255
+ # Log with severity higher than or equal to DEBUG are logged.
256
+ DEBUG = 100
257
+
258
+ # Logs with severity higher than or equal to INFO are logged.
259
+ INFO = 200
260
+
261
+ # Logs with severity higher than or equal to WARNING are logged.
262
+ WARNING = 400
263
+
264
+ # Logs with severity higher than or equal to ERROR are logged.
265
+ ERROR = 500
266
+ end
267
+ end
268
+
269
+ # Properties of the input stream.
270
+ # @!attribute [rw] last_establish_time
271
+ # @return [::Google::Protobuf::Timestamp]
272
+ # The time that the current input stream is accepted and the connection is
273
+ # established.
274
+ # @!attribute [rw] video_streams
275
+ # @return [::Array<::Google::Cloud::Video::LiveStream::V1::VideoStreamProperty>]
276
+ # Properties of the video streams.
277
+ # @!attribute [rw] audio_streams
278
+ # @return [::Array<::Google::Cloud::Video::LiveStream::V1::AudioStreamProperty>]
279
+ # Properties of the audio streams.
280
+ class InputStreamProperty
281
+ include ::Google::Protobuf::MessageExts
282
+ extend ::Google::Protobuf::MessageExts::ClassMethods
283
+ end
284
+
285
+ # Properties of the video stream.
286
+ # @!attribute [rw] index
287
+ # @return [::Integer]
288
+ # Index of this video stream.
289
+ # @!attribute [rw] video_format
290
+ # @return [::Google::Cloud::Video::LiveStream::V1::VideoFormat]
291
+ # Properties of the video format.
292
+ class VideoStreamProperty
293
+ include ::Google::Protobuf::MessageExts
294
+ extend ::Google::Protobuf::MessageExts::ClassMethods
295
+ end
296
+
297
+ # Properties of the video format.
298
+ # @!attribute [rw] codec
299
+ # @return [::String]
300
+ # Video codec used in this video stream.
301
+ # @!attribute [rw] width_pixels
302
+ # @return [::Integer]
303
+ # The width of the video stream in pixels.
304
+ # @!attribute [rw] height_pixels
305
+ # @return [::Integer]
306
+ # The height of the video stream in pixels.
307
+ # @!attribute [rw] frame_rate
308
+ # @return [::Float]
309
+ # The frame rate of the input video stream.
310
+ class VideoFormat
311
+ include ::Google::Protobuf::MessageExts
312
+ extend ::Google::Protobuf::MessageExts::ClassMethods
313
+ end
314
+
315
+ # Properties of the audio stream.
316
+ # @!attribute [rw] index
317
+ # @return [::Integer]
318
+ # Index of this audio stream.
319
+ # @!attribute [rw] audio_format
320
+ # @return [::Google::Cloud::Video::LiveStream::V1::AudioFormat]
321
+ # Properties of the audio format.
322
+ class AudioStreamProperty
323
+ include ::Google::Protobuf::MessageExts
324
+ extend ::Google::Protobuf::MessageExts::ClassMethods
325
+ end
326
+
327
+ # Properties of the audio format.
328
+ # @!attribute [rw] codec
329
+ # @return [::String]
330
+ # Audio codec used in this audio stream.
331
+ # @!attribute [rw] channel_count
332
+ # @return [::Integer]
333
+ # The number of audio channels.
334
+ # @!attribute [rw] channel_layout
335
+ # @return [::Array<::String>]
336
+ # A list of channel names specifying the layout of the audio channels.
337
+ class AudioFormat
338
+ include ::Google::Protobuf::MessageExts
339
+ extend ::Google::Protobuf::MessageExts::ClassMethods
340
+ end
341
+
342
+ # A group of information for attaching an input resource to this channel.
343
+ # @!attribute [rw] key
344
+ # @return [::String]
345
+ # A unique key for this input attachment.
346
+ # @!attribute [rw] input
347
+ # @return [::String]
348
+ # The resource name of an existing input, in the form of:
349
+ # `projects/{project}/locations/{location}/inputs/{inputId}`.
350
+ # @!attribute [rw] automatic_failover
351
+ # @return [::Google::Cloud::Video::LiveStream::V1::InputAttachment::AutomaticFailover]
352
+ # Automatic failover configurations.
353
+ class InputAttachment
354
+ include ::Google::Protobuf::MessageExts
355
+ extend ::Google::Protobuf::MessageExts::ClassMethods
356
+
357
+ # Configurations to follow when automatic failover happens.
358
+ # @!attribute [rw] input_keys
359
+ # @return [::Array<::String>]
360
+ # The {::Google::Cloud::Video::LiveStream::V1::InputAttachment#key InputAttachment.key}s of inputs to failover to when this input is
361
+ # disconnected. Currently, only up to one backup input is supported.
362
+ class AutomaticFailover
363
+ include ::Google::Protobuf::MessageExts
364
+ extend ::Google::Protobuf::MessageExts::ClassMethods
365
+ end
366
+ end
367
+
368
+ # Event is a sub-resource of a channel, which can be scheduled by the user to
369
+ # execute operations on a channel resource without having to stop the channel.
370
+ # @!attribute [rw] name
371
+ # @return [::String]
372
+ # The resource name of the event, in the form of:
373
+ # `projects/{project}/locations/{location}/channels/{channelId}/events/{eventId}`.
374
+ # @!attribute [r] create_time
375
+ # @return [::Google::Protobuf::Timestamp]
376
+ # Output only. The creation time.
377
+ # @!attribute [r] update_time
378
+ # @return [::Google::Protobuf::Timestamp]
379
+ # Output only. The update time.
380
+ # @!attribute [rw] labels
381
+ # @return [::Google::Protobuf::Map{::String => ::String}]
382
+ # User-defined key/value metadata.
383
+ # @!attribute [rw] ad_break
384
+ # @return [::Google::Cloud::Video::LiveStream::V1::Event::AdBreakTask]
385
+ # Required. Inserts a new ad opportunity.
386
+ # @!attribute [rw] execute_now
387
+ # @return [::Boolean]
388
+ # When this field is set to true, the event will be executed at the earliest
389
+ # time that the server can schedule the event and {::Google::Cloud::Video::LiveStream::V1::Event#execution_time execution_time} will be
390
+ # populated with the time that the server actually schedules the event.
391
+ # @!attribute [rw] execution_time
392
+ # @return [::Google::Protobuf::Timestamp]
393
+ # The time when the event should be executed. When {::Google::Cloud::Video::LiveStream::V1::Event#execute_now execute_now} is set to
394
+ # `true`, this field should not be set in `CreateEvent` request and will be
395
+ # populated with the time that the server schedules the event.
396
+ # @!attribute [r] state
397
+ # @return [::Google::Cloud::Video::LiveStream::V1::Event::State]
398
+ # Output only. The state of the event.
399
+ # @!attribute [r] error
400
+ # @return [::Google::Rpc::Status]
401
+ # Output only. An error object that describes the reason for the failure.
402
+ # This property is always present when `state` is `FAILED`.
403
+ class Event
404
+ include ::Google::Protobuf::MessageExts
405
+ extend ::Google::Protobuf::MessageExts::ClassMethods
406
+
407
+ # Inserts a new ad opportunity.
408
+ # @!attribute [rw] duration
409
+ # @return [::Google::Protobuf::Duration]
410
+ # Duration of an ad opportunity. Must be greater than 0.
411
+ class AdBreakTask
412
+ include ::Google::Protobuf::MessageExts
413
+ extend ::Google::Protobuf::MessageExts::ClassMethods
414
+ end
415
+
416
+ # @!attribute [rw] key
417
+ # @return [::String]
418
+ # @!attribute [rw] value
419
+ # @return [::String]
420
+ class LabelsEntry
421
+ include ::Google::Protobuf::MessageExts
422
+ extend ::Google::Protobuf::MessageExts::ClassMethods
423
+ end
424
+
425
+ # State of the event
426
+ module State
427
+ # Event state is not specified.
428
+ STATE_UNSPECIFIED = 0
429
+
430
+ # Event is scheduled but not executed yet.
431
+ SCHEDULED = 1
432
+
433
+ # Event is being executed.
434
+ RUNNING = 2
435
+
436
+ # Event has been successfully executed.
437
+ SUCCEEDED = 3
438
+
439
+ # Event fails to be executed.
440
+ FAILED = 4
441
+
442
+ # Event has been created but not scheduled yet.
443
+ PENDING = 5
444
+ end
445
+ end
446
+ end
447
+ end
448
+ end
449
+ end
450
+ end