mux_ruby 2.0.0.pre.rc.2 → 2.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +3 -3
- data/README.md +4 -4
- data/docs/AssetsApi.md +2 -0
- data/docs/CreateLiveStreamRequest.md +2 -0
- data/docs/ExportDate.md +20 -0
- data/docs/ExportFile.md +22 -0
- data/docs/ExportsApi.md +69 -1
- data/docs/GetLiveStreamPlaybackIDResponse.md +18 -0
- data/docs/ListVideoViewExportsResponse.md +22 -0
- data/docs/LiveStream.md +2 -0
- data/docs/LiveStreamsApi.md +71 -0
- data/docs/MetricsApi.md +8 -8
- data/docs/RealTimeApi.md +2 -2
- data/docs/RealTimeBreakdownValue.md +2 -2
- data/docs/RealTimeTimeseriesDatapoint.md +2 -2
- data/gen/generator-config.json +2 -1
- data/gen/templates/gemspec.mustache +1 -0
- data/lib/mux_ruby/api/assets_api.rb +2 -0
- data/lib/mux_ruby/api/exports_api.rb +59 -2
- data/lib/mux_ruby/api/live_streams_api.rb +67 -0
- data/lib/mux_ruby/api/metrics_api.rb +16 -16
- data/lib/mux_ruby/api/real_time_api.rb +4 -4
- data/lib/mux_ruby/models/create_live_stream_request.rb +11 -1
- data/lib/mux_ruby/models/export_date.rb +229 -0
- data/lib/mux_ruby/models/export_file.rb +236 -0
- data/lib/mux_ruby/models/get_live_stream_playback_id_response.rb +218 -0
- data/lib/mux_ruby/models/list_video_view_exports_response.rb +240 -0
- data/lib/mux_ruby/models/live_stream.rb +11 -1
- data/lib/mux_ruby/models/real_time_breakdown_value.rb +7 -7
- data/lib/mux_ruby/models/real_time_timeseries_datapoint.rb +7 -7
- data/lib/mux_ruby/version.rb +1 -1
- data/lib/mux_ruby.rb +4 -0
- data/mux_ruby.gemspec +1 -0
- data/spec/models/export_date_spec.rb +40 -0
- data/spec/models/export_file_spec.rb +46 -0
- data/spec/models/get_live_stream_playback_id_response_spec.rb +34 -0
- data/spec/models/list_video_view_exports_response_spec.rb +46 -0
- metadata +107 -90
@@ -602,6 +602,73 @@ module MuxRuby
|
|
602
602
|
return data, status_code, headers
|
603
603
|
end
|
604
604
|
|
605
|
+
# Retrieve a live stream playback ID
|
606
|
+
# @param live_stream_id [String] The live stream ID
|
607
|
+
# @param playback_id [String] The live stream's playback ID.
|
608
|
+
# @param [Hash] opts the optional parameters
|
609
|
+
# @return [GetLiveStreamPlaybackIDResponse]
|
610
|
+
def get_live_stream_playback_id(live_stream_id, playback_id, opts = {})
|
611
|
+
data, _status_code, _headers = get_live_stream_playback_id_with_http_info(live_stream_id, playback_id, opts)
|
612
|
+
data
|
613
|
+
end
|
614
|
+
|
615
|
+
# Retrieve a live stream playback ID
|
616
|
+
# @param live_stream_id [String] The live stream ID
|
617
|
+
# @param playback_id [String] The live stream's playback ID.
|
618
|
+
# @param [Hash] opts the optional parameters
|
619
|
+
# @return [Array<(GetLiveStreamPlaybackIDResponse, Integer, Hash)>] GetLiveStreamPlaybackIDResponse data, response status code and response headers
|
620
|
+
def get_live_stream_playback_id_with_http_info(live_stream_id, playback_id, opts = {})
|
621
|
+
if @api_client.config.debugging
|
622
|
+
@api_client.config.logger.debug 'Calling API: LiveStreamsApi.get_live_stream_playback_id ...'
|
623
|
+
end
|
624
|
+
# verify the required parameter 'live_stream_id' is set
|
625
|
+
if @api_client.config.client_side_validation && live_stream_id.nil?
|
626
|
+
fail ArgumentError, "Missing the required parameter 'live_stream_id' when calling LiveStreamsApi.get_live_stream_playback_id"
|
627
|
+
end
|
628
|
+
# verify the required parameter 'playback_id' is set
|
629
|
+
if @api_client.config.client_side_validation && playback_id.nil?
|
630
|
+
fail ArgumentError, "Missing the required parameter 'playback_id' when calling LiveStreamsApi.get_live_stream_playback_id"
|
631
|
+
end
|
632
|
+
# resource path
|
633
|
+
local_var_path = '/video/v1/live-streams/{LIVE_STREAM_ID}/playback-ids/{PLAYBACK_ID}'.sub('{' + 'LIVE_STREAM_ID' + '}', CGI.escape(live_stream_id.to_s)).sub('{' + 'PLAYBACK_ID' + '}', CGI.escape(playback_id.to_s))
|
634
|
+
|
635
|
+
# query parameters
|
636
|
+
query_params = opts[:query_params] || {}
|
637
|
+
|
638
|
+
# header parameters
|
639
|
+
header_params = opts[:header_params] || {}
|
640
|
+
# HTTP header 'Accept' (if needed)
|
641
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
642
|
+
|
643
|
+
# form parameters
|
644
|
+
form_params = opts[:form_params] || {}
|
645
|
+
|
646
|
+
# http body (model)
|
647
|
+
post_body = opts[:debug_body]
|
648
|
+
|
649
|
+
# return_type
|
650
|
+
return_type = opts[:debug_return_type] || 'GetLiveStreamPlaybackIDResponse'
|
651
|
+
|
652
|
+
# auth_names
|
653
|
+
auth_names = opts[:debug_auth_names] || ['accessToken']
|
654
|
+
|
655
|
+
new_options = opts.merge(
|
656
|
+
:operation => :"LiveStreamsApi.get_live_stream_playback_id",
|
657
|
+
:header_params => header_params,
|
658
|
+
:query_params => query_params,
|
659
|
+
:form_params => form_params,
|
660
|
+
:body => post_body,
|
661
|
+
:auth_names => auth_names,
|
662
|
+
:return_type => return_type
|
663
|
+
)
|
664
|
+
|
665
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
666
|
+
if @api_client.config.debugging
|
667
|
+
@api_client.config.logger.debug "API called: LiveStreamsApi#get_live_stream_playback_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
668
|
+
end
|
669
|
+
return data, status_code, headers
|
670
|
+
end
|
671
|
+
|
605
672
|
# Retrieve a Live Stream Simulcast Target
|
606
673
|
# Retrieves the details of the simulcast target created for the parent live stream. Supply the unique live stream ID and simulcast target ID that was returned in the response of create simulcast target request, and Mux will return the corresponding information.
|
607
674
|
# @param live_stream_id [String] The live stream ID
|
@@ -25,7 +25,7 @@ module MuxRuby
|
|
25
25
|
# @param [Hash] opts the optional parameters
|
26
26
|
# @option opts [Array<String>] :timeframe Timeframe window to limit results by. Must be provided as an array query string parameter (e.g. timeframe[]=). Accepted formats are... * array of epoch timestamps e.g. timeframe[]=1498867200&timeframe[]=1498953600 * duration string e.g. timeframe[]=24:hours or timeframe[]=7:days.
|
27
27
|
# @option opts [Array<String>] :filters Filter key:value pairs. Must be provided as an array query string parameter (e.g. filters[]=operating_system:windows&filters[]=country:US). Possible filter names are the same as returned by the List Filters endpoint.
|
28
|
-
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the
|
28
|
+
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the default for the metric will be used.
|
29
29
|
# @option opts [String] :order_direction Sort order.
|
30
30
|
# @option opts [String] :group_by Time granularity to group results by. If this value is omitted, a default granularity is chosen based on the supplied timeframe.
|
31
31
|
# @return [GetMetricTimeseriesDataResponse]
|
@@ -40,7 +40,7 @@ module MuxRuby
|
|
40
40
|
# @param [Hash] opts the optional parameters
|
41
41
|
# @option opts [Array<String>] :timeframe Timeframe window to limit results by. Must be provided as an array query string parameter (e.g. timeframe[]=). Accepted formats are... * array of epoch timestamps e.g. timeframe[]=1498867200&timeframe[]=1498953600 * duration string e.g. timeframe[]=24:hours or timeframe[]=7:days.
|
42
42
|
# @option opts [Array<String>] :filters Filter key:value pairs. Must be provided as an array query string parameter (e.g. filters[]=operating_system:windows&filters[]=country:US). Possible filter names are the same as returned by the List Filters endpoint.
|
43
|
-
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the
|
43
|
+
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the default for the metric will be used.
|
44
44
|
# @option opts [String] :order_direction Sort order.
|
45
45
|
# @option opts [String] :group_by Time granularity to group results by. If this value is omitted, a default granularity is chosen based on the supplied timeframe.
|
46
46
|
# @return [Array<(GetMetricTimeseriesDataResponse, Integer, Hash)>] GetMetricTimeseriesDataResponse data, response status code and response headers
|
@@ -53,11 +53,11 @@ module MuxRuby
|
|
53
53
|
fail ArgumentError, "Missing the required parameter 'metric_id' when calling MetricsApi.get_metric_timeseries_data"
|
54
54
|
end
|
55
55
|
# verify enum value
|
56
|
-
allowable_values = ["aggregate_startup_time", "downscale_percentage", "exits_before_video_start", "max_downscale_percentage", "max_upscale_percentage", "page_load_time", "playback_failure_percentage", "playback_failure_score", "player_startup_time", "rebuffer_count", "rebuffer_duration", "rebuffer_frequency", "rebuffer_percentage", "rebuffer_score", "requests_for_first_preroll", "seek_latency", "startup_time_score", "upscale_percentage", "video_quality_score", "video_startup_preroll_load_time", "video_startup_preroll_request_time", "video_startup_time", "viewer_experience_score"]
|
56
|
+
allowable_values = ["aggregate_startup_time", "downscale_percentage", "exits_before_video_start", "max_downscale_percentage", "max_upscale_percentage", "page_load_time", "playback_failure_percentage", "playback_failure_score", "player_startup_time", "playing_time", "rebuffer_count", "rebuffer_duration", "rebuffer_frequency", "rebuffer_percentage", "rebuffer_score", "requests_for_first_preroll", "seek_latency", "startup_time_score", "unique_viewers", "upscale_percentage", "video_quality_score", "video_startup_preroll_load_time", "video_startup_preroll_request_time", "video_startup_time", "viewer_experience_score", "views", "weighted_average_bitrate"]
|
57
57
|
if @api_client.config.client_side_validation && !allowable_values.include?(metric_id)
|
58
58
|
fail ArgumentError, "invalid value for \"metric_id\", must be one of #{allowable_values}"
|
59
59
|
end
|
60
|
-
allowable_values = ["95th", "median", "avg"]
|
60
|
+
allowable_values = ["95th", "median", "avg", "count", "sum"]
|
61
61
|
if @api_client.config.client_side_validation && opts[:'measurement'] && !allowable_values.include?(opts[:'measurement'])
|
62
62
|
fail ArgumentError, "invalid value for \"measurement\", must be one of #{allowable_values}"
|
63
63
|
end
|
@@ -120,7 +120,7 @@ module MuxRuby
|
|
120
120
|
# @param [Hash] opts the optional parameters
|
121
121
|
# @option opts [Array<String>] :timeframe Timeframe window to limit results by. Must be provided as an array query string parameter (e.g. timeframe[]=). Accepted formats are... * array of epoch timestamps e.g. timeframe[]=1498867200&timeframe[]=1498953600 * duration string e.g. timeframe[]=24:hours or timeframe[]=7:days.
|
122
122
|
# @option opts [Array<String>] :filters Filter key:value pairs. Must be provided as an array query string parameter (e.g. filters[]=operating_system:windows&filters[]=country:US). Possible filter names are the same as returned by the List Filters endpoint.
|
123
|
-
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the
|
123
|
+
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the default for the metric will be used.
|
124
124
|
# @return [GetOverallValuesResponse]
|
125
125
|
def get_overall_values(metric_id, opts = {})
|
126
126
|
data, _status_code, _headers = get_overall_values_with_http_info(metric_id, opts)
|
@@ -133,7 +133,7 @@ module MuxRuby
|
|
133
133
|
# @param [Hash] opts the optional parameters
|
134
134
|
# @option opts [Array<String>] :timeframe Timeframe window to limit results by. Must be provided as an array query string parameter (e.g. timeframe[]=). Accepted formats are... * array of epoch timestamps e.g. timeframe[]=1498867200&timeframe[]=1498953600 * duration string e.g. timeframe[]=24:hours or timeframe[]=7:days.
|
135
135
|
# @option opts [Array<String>] :filters Filter key:value pairs. Must be provided as an array query string parameter (e.g. filters[]=operating_system:windows&filters[]=country:US). Possible filter names are the same as returned by the List Filters endpoint.
|
136
|
-
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the
|
136
|
+
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the default for the metric will be used.
|
137
137
|
# @return [Array<(GetOverallValuesResponse, Integer, Hash)>] GetOverallValuesResponse data, response status code and response headers
|
138
138
|
def get_overall_values_with_http_info(metric_id, opts = {})
|
139
139
|
if @api_client.config.debugging
|
@@ -144,11 +144,11 @@ module MuxRuby
|
|
144
144
|
fail ArgumentError, "Missing the required parameter 'metric_id' when calling MetricsApi.get_overall_values"
|
145
145
|
end
|
146
146
|
# verify enum value
|
147
|
-
allowable_values = ["aggregate_startup_time", "downscale_percentage", "exits_before_video_start", "max_downscale_percentage", "max_upscale_percentage", "page_load_time", "playback_failure_percentage", "playback_failure_score", "player_startup_time", "rebuffer_count", "rebuffer_duration", "rebuffer_frequency", "rebuffer_percentage", "rebuffer_score", "requests_for_first_preroll", "seek_latency", "startup_time_score", "upscale_percentage", "video_quality_score", "video_startup_preroll_load_time", "video_startup_preroll_request_time", "video_startup_time", "viewer_experience_score"]
|
147
|
+
allowable_values = ["aggregate_startup_time", "downscale_percentage", "exits_before_video_start", "max_downscale_percentage", "max_upscale_percentage", "page_load_time", "playback_failure_percentage", "playback_failure_score", "player_startup_time", "playing_time", "rebuffer_count", "rebuffer_duration", "rebuffer_frequency", "rebuffer_percentage", "rebuffer_score", "requests_for_first_preroll", "seek_latency", "startup_time_score", "unique_viewers", "upscale_percentage", "video_quality_score", "video_startup_preroll_load_time", "video_startup_preroll_request_time", "video_startup_time", "viewer_experience_score", "views", "weighted_average_bitrate"]
|
148
148
|
if @api_client.config.client_side_validation && !allowable_values.include?(metric_id)
|
149
149
|
fail ArgumentError, "invalid value for \"metric_id\", must be one of #{allowable_values}"
|
150
150
|
end
|
151
|
-
allowable_values = ["95th", "median", "avg"]
|
151
|
+
allowable_values = ["95th", "median", "avg", "count", "sum"]
|
152
152
|
if @api_client.config.client_side_validation && opts[:'measurement'] && !allowable_values.include?(opts[:'measurement'])
|
153
153
|
fail ArgumentError, "invalid value for \"measurement\", must be one of #{allowable_values}"
|
154
154
|
end
|
@@ -273,7 +273,7 @@ module MuxRuby
|
|
273
273
|
# @param metric_id [String] ID of the Metric
|
274
274
|
# @param [Hash] opts the optional parameters
|
275
275
|
# @option opts [String] :group_by Breakdown value to group the results by
|
276
|
-
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the
|
276
|
+
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the default for the metric will be used.
|
277
277
|
# @option opts [Array<String>] :filters Filter key:value pairs. Must be provided as an array query string parameter (e.g. filters[]=operating_system:windows&filters[]=country:US). Possible filter names are the same as returned by the List Filters endpoint.
|
278
278
|
# @option opts [Integer] :limit Number of items to include in the response (default to 25)
|
279
279
|
# @option opts [Integer] :page Offset by this many pages, of the size of `limit` (default to 1)
|
@@ -291,7 +291,7 @@ module MuxRuby
|
|
291
291
|
# @param metric_id [String] ID of the Metric
|
292
292
|
# @param [Hash] opts the optional parameters
|
293
293
|
# @option opts [String] :group_by Breakdown value to group the results by
|
294
|
-
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the
|
294
|
+
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the default for the metric will be used.
|
295
295
|
# @option opts [Array<String>] :filters Filter key:value pairs. Must be provided as an array query string parameter (e.g. filters[]=operating_system:windows&filters[]=country:US). Possible filter names are the same as returned by the List Filters endpoint.
|
296
296
|
# @option opts [Integer] :limit Number of items to include in the response
|
297
297
|
# @option opts [Integer] :page Offset by this many pages, of the size of `limit`
|
@@ -308,7 +308,7 @@ module MuxRuby
|
|
308
308
|
fail ArgumentError, "Missing the required parameter 'metric_id' when calling MetricsApi.list_breakdown_values"
|
309
309
|
end
|
310
310
|
# verify enum value
|
311
|
-
allowable_values = ["aggregate_startup_time", "downscale_percentage", "exits_before_video_start", "max_downscale_percentage", "max_upscale_percentage", "page_load_time", "playback_failure_percentage", "playback_failure_score", "player_startup_time", "rebuffer_count", "rebuffer_duration", "rebuffer_frequency", "rebuffer_percentage", "rebuffer_score", "requests_for_first_preroll", "seek_latency", "startup_time_score", "upscale_percentage", "video_quality_score", "video_startup_preroll_load_time", "video_startup_preroll_request_time", "video_startup_time", "viewer_experience_score"]
|
311
|
+
allowable_values = ["aggregate_startup_time", "downscale_percentage", "exits_before_video_start", "max_downscale_percentage", "max_upscale_percentage", "page_load_time", "playback_failure_percentage", "playback_failure_score", "player_startup_time", "playing_time", "rebuffer_count", "rebuffer_duration", "rebuffer_frequency", "rebuffer_percentage", "rebuffer_score", "requests_for_first_preroll", "seek_latency", "startup_time_score", "unique_viewers", "upscale_percentage", "video_quality_score", "video_startup_preroll_load_time", "video_startup_preroll_request_time", "video_startup_time", "viewer_experience_score", "views", "weighted_average_bitrate"]
|
312
312
|
if @api_client.config.client_side_validation && !allowable_values.include?(metric_id)
|
313
313
|
fail ArgumentError, "invalid value for \"metric_id\", must be one of #{allowable_values}"
|
314
314
|
end
|
@@ -316,7 +316,7 @@ module MuxRuby
|
|
316
316
|
if @api_client.config.client_side_validation && opts[:'group_by'] && !allowable_values.include?(opts[:'group_by'])
|
317
317
|
fail ArgumentError, "invalid value for \"group_by\", must be one of #{allowable_values}"
|
318
318
|
end
|
319
|
-
allowable_values = ["95th", "median", "avg"]
|
319
|
+
allowable_values = ["95th", "median", "avg", "count", "sum"]
|
320
320
|
if @api_client.config.client_side_validation && opts[:'measurement'] && !allowable_values.include?(opts[:'measurement'])
|
321
321
|
fail ArgumentError, "invalid value for \"measurement\", must be one of #{allowable_values}"
|
322
322
|
end
|
@@ -380,7 +380,7 @@ module MuxRuby
|
|
380
380
|
# Returns a list of insights for a metric. These are the worst performing values across all breakdowns sorted by how much they negatively impact a specific metric.
|
381
381
|
# @param metric_id [String] ID of the Metric
|
382
382
|
# @param [Hash] opts the optional parameters
|
383
|
-
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the
|
383
|
+
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the default for the metric will be used.
|
384
384
|
# @option opts [String] :order_direction Sort order.
|
385
385
|
# @option opts [Array<String>] :timeframe Timeframe window to limit results by. Must be provided as an array query string parameter (e.g. timeframe[]=). Accepted formats are... * array of epoch timestamps e.g. timeframe[]=1498867200&timeframe[]=1498953600 * duration string e.g. timeframe[]=24:hours or timeframe[]=7:days.
|
386
386
|
# @return [ListInsightsResponse]
|
@@ -393,7 +393,7 @@ module MuxRuby
|
|
393
393
|
# Returns a list of insights for a metric. These are the worst performing values across all breakdowns sorted by how much they negatively impact a specific metric.
|
394
394
|
# @param metric_id [String] ID of the Metric
|
395
395
|
# @param [Hash] opts the optional parameters
|
396
|
-
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the
|
396
|
+
# @option opts [String] :measurement Measurement for the provided metric. If omitted, the default for the metric will be used.
|
397
397
|
# @option opts [String] :order_direction Sort order.
|
398
398
|
# @option opts [Array<String>] :timeframe Timeframe window to limit results by. Must be provided as an array query string parameter (e.g. timeframe[]=). Accepted formats are... * array of epoch timestamps e.g. timeframe[]=1498867200&timeframe[]=1498953600 * duration string e.g. timeframe[]=24:hours or timeframe[]=7:days.
|
399
399
|
# @return [Array<(ListInsightsResponse, Integer, Hash)>] ListInsightsResponse data, response status code and response headers
|
@@ -406,11 +406,11 @@ module MuxRuby
|
|
406
406
|
fail ArgumentError, "Missing the required parameter 'metric_id' when calling MetricsApi.list_insights"
|
407
407
|
end
|
408
408
|
# verify enum value
|
409
|
-
allowable_values = ["aggregate_startup_time", "downscale_percentage", "exits_before_video_start", "max_downscale_percentage", "max_upscale_percentage", "page_load_time", "playback_failure_percentage", "playback_failure_score", "player_startup_time", "rebuffer_count", "rebuffer_duration", "rebuffer_frequency", "rebuffer_percentage", "rebuffer_score", "requests_for_first_preroll", "seek_latency", "startup_time_score", "upscale_percentage", "video_quality_score", "video_startup_preroll_load_time", "video_startup_preroll_request_time", "video_startup_time", "viewer_experience_score"]
|
409
|
+
allowable_values = ["aggregate_startup_time", "downscale_percentage", "exits_before_video_start", "max_downscale_percentage", "max_upscale_percentage", "page_load_time", "playback_failure_percentage", "playback_failure_score", "player_startup_time", "playing_time", "rebuffer_count", "rebuffer_duration", "rebuffer_frequency", "rebuffer_percentage", "rebuffer_score", "requests_for_first_preroll", "seek_latency", "startup_time_score", "unique_viewers", "upscale_percentage", "video_quality_score", "video_startup_preroll_load_time", "video_startup_preroll_request_time", "video_startup_time", "viewer_experience_score", "views", "weighted_average_bitrate"]
|
410
410
|
if @api_client.config.client_side_validation && !allowable_values.include?(metric_id)
|
411
411
|
fail ArgumentError, "invalid value for \"metric_id\", must be one of #{allowable_values}"
|
412
412
|
end
|
413
|
-
allowable_values = ["95th", "median", "avg"]
|
413
|
+
allowable_values = ["95th", "median", "avg", "count", "sum"]
|
414
414
|
if @api_client.config.client_side_validation && opts[:'measurement'] && !allowable_values.include?(opts[:'measurement'])
|
415
415
|
fail ArgumentError, "invalid value for \"measurement\", must be one of #{allowable_values}"
|
416
416
|
end
|
@@ -257,7 +257,7 @@ module MuxRuby
|
|
257
257
|
end
|
258
258
|
|
259
259
|
# List Real-Time Dimensions
|
260
|
-
# Lists
|
260
|
+
# Lists available real-time dimensions.
|
261
261
|
# @param [Hash] opts the optional parameters
|
262
262
|
# @return [ListRealTimeDimensionsResponse]
|
263
263
|
def list_realtime_dimensions(opts = {})
|
@@ -266,7 +266,7 @@ module MuxRuby
|
|
266
266
|
end
|
267
267
|
|
268
268
|
# List Real-Time Dimensions
|
269
|
-
# Lists
|
269
|
+
# Lists available real-time dimensions.
|
270
270
|
# @param [Hash] opts the optional parameters
|
271
271
|
# @return [Array<(ListRealTimeDimensionsResponse, Integer, Hash)>] ListRealTimeDimensionsResponse data, response status code and response headers
|
272
272
|
def list_realtime_dimensions_with_http_info(opts = {})
|
@@ -314,7 +314,7 @@ module MuxRuby
|
|
314
314
|
end
|
315
315
|
|
316
316
|
# List Real-Time Metrics
|
317
|
-
# Lists
|
317
|
+
# Lists available real-time metrics.
|
318
318
|
# @param [Hash] opts the optional parameters
|
319
319
|
# @return [ListRealTimeMetricsResponse]
|
320
320
|
def list_realtime_metrics(opts = {})
|
@@ -323,7 +323,7 @@ module MuxRuby
|
|
323
323
|
end
|
324
324
|
|
325
325
|
# List Real-Time Metrics
|
326
|
-
# Lists
|
326
|
+
# Lists available real-time metrics.
|
327
327
|
# @param [Hash] opts the optional parameters
|
328
328
|
# @return [Array<(ListRealTimeMetricsResponse, Integer, Hash)>] ListRealTimeMetricsResponse data, response status code and response headers
|
329
329
|
def list_realtime_metrics_with_http_info(opts = {})
|
@@ -30,6 +30,9 @@ module MuxRuby
|
|
30
30
|
# Latency is the time from when the streamer does something in real life to when you see it happen in the player. Set this if you want lower latency for your live stream. Note: Reconnect windows are incompatible with Reduced Latency and will always be set to zero (0) seconds. Read more here: https://mux.com/blog/reduced-latency-for-mux-live-streaming-now-available/
|
31
31
|
attr_accessor :reduced_latency
|
32
32
|
|
33
|
+
# Latency is the time from when the streamer does something in real life to when you see it happen in the player. Setting this option will enable compatibility with the LL-HLS specification for low-latency streaming. This typically has lower latency than Reduced Latency streams, and cannot be combined with Reduced Latency. Note: Reconnect windows are incompatible with Low Latency and will always be set to zero (0) seconds.
|
34
|
+
attr_accessor :low_latency
|
35
|
+
|
33
36
|
# Marks the live stream as a test live stream when the value is set to true. A test live stream can help evaluate the Mux Video APIs without incurring any cost. There is no limit on number of test live streams created. Test live streams are watermarked with the Mux logo and limited to 5 minutes. The test live stream is disabled after the stream is active for 5 mins and the recorded asset also deleted after 24 hours.
|
34
37
|
attr_accessor :test
|
35
38
|
|
@@ -44,6 +47,7 @@ module MuxRuby
|
|
44
47
|
:'passthrough' => :'passthrough',
|
45
48
|
:'audio_only' => :'audio_only',
|
46
49
|
:'reduced_latency' => :'reduced_latency',
|
50
|
+
:'low_latency' => :'low_latency',
|
47
51
|
:'test' => :'test',
|
48
52
|
:'simulcast_targets' => :'simulcast_targets'
|
49
53
|
}
|
@@ -63,6 +67,7 @@ module MuxRuby
|
|
63
67
|
:'passthrough' => :'String',
|
64
68
|
:'audio_only' => :'Boolean',
|
65
69
|
:'reduced_latency' => :'Boolean',
|
70
|
+
:'low_latency' => :'Boolean',
|
66
71
|
:'test' => :'Boolean',
|
67
72
|
:'simulcast_targets' => :'Array<CreateSimulcastTargetRequest>'
|
68
73
|
}
|
@@ -115,6 +120,10 @@ module MuxRuby
|
|
115
120
|
self.reduced_latency = attributes[:'reduced_latency']
|
116
121
|
end
|
117
122
|
|
123
|
+
if attributes.key?(:'low_latency')
|
124
|
+
self.low_latency = attributes[:'low_latency']
|
125
|
+
end
|
126
|
+
|
118
127
|
if attributes.key?(:'test')
|
119
128
|
self.test = attributes[:'test']
|
120
129
|
end
|
@@ -174,6 +183,7 @@ module MuxRuby
|
|
174
183
|
passthrough == o.passthrough &&
|
175
184
|
audio_only == o.audio_only &&
|
176
185
|
reduced_latency == o.reduced_latency &&
|
186
|
+
low_latency == o.low_latency &&
|
177
187
|
test == o.test &&
|
178
188
|
simulcast_targets == o.simulcast_targets
|
179
189
|
end
|
@@ -187,7 +197,7 @@ module MuxRuby
|
|
187
197
|
# Calculates hash code according to all attributes.
|
188
198
|
# @return [Integer] Hash code
|
189
199
|
def hash
|
190
|
-
[playback_policy, new_asset_settings, reconnect_window, passthrough, audio_only, reduced_latency, test, simulcast_targets].hash
|
200
|
+
[playback_policy, new_asset_settings, reconnect_window, passthrough, audio_only, reduced_latency, low_latency, test, simulcast_targets].hash
|
191
201
|
end
|
192
202
|
|
193
203
|
# Builds the object from hash
|
@@ -0,0 +1,229 @@
|
|
1
|
+
=begin
|
2
|
+
#Mux API
|
3
|
+
|
4
|
+
#Mux is how developers build online video. This API encompasses both Mux Video and Mux Data functionality to help you build your video-related projects better and faster than ever before.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v1
|
7
|
+
Contact: devex@mux.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 5.0.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module MuxRuby
|
17
|
+
class ExportDate
|
18
|
+
attr_accessor :export_date
|
19
|
+
|
20
|
+
attr_accessor :files
|
21
|
+
|
22
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
23
|
+
def self.attribute_map
|
24
|
+
{
|
25
|
+
:'export_date' => :'export_date',
|
26
|
+
:'files' => :'files'
|
27
|
+
}
|
28
|
+
end
|
29
|
+
|
30
|
+
# Returns all the JSON keys this model knows about
|
31
|
+
def self.acceptable_attributes
|
32
|
+
attribute_map.values
|
33
|
+
end
|
34
|
+
|
35
|
+
# Attribute type mapping.
|
36
|
+
def self.openapi_types
|
37
|
+
{
|
38
|
+
:'export_date' => :'Date',
|
39
|
+
:'files' => :'Array<ExportFile>'
|
40
|
+
}
|
41
|
+
end
|
42
|
+
|
43
|
+
# List of attributes with nullable: true
|
44
|
+
def self.openapi_nullable
|
45
|
+
Set.new([
|
46
|
+
])
|
47
|
+
end
|
48
|
+
|
49
|
+
# Initializes the object
|
50
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
51
|
+
def initialize(attributes = {})
|
52
|
+
if (!attributes.is_a?(Hash))
|
53
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `MuxRuby::ExportDate` initialize method"
|
54
|
+
end
|
55
|
+
|
56
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
57
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
58
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
59
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `MuxRuby::ExportDate`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
60
|
+
end
|
61
|
+
h[k.to_sym] = v
|
62
|
+
}
|
63
|
+
|
64
|
+
if attributes.key?(:'export_date')
|
65
|
+
self.export_date = attributes[:'export_date']
|
66
|
+
end
|
67
|
+
|
68
|
+
if attributes.key?(:'files')
|
69
|
+
if (value = attributes[:'files']).is_a?(Array)
|
70
|
+
self.files = value
|
71
|
+
end
|
72
|
+
end
|
73
|
+
end
|
74
|
+
|
75
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
76
|
+
# @return Array for valid properties with the reasons
|
77
|
+
def list_invalid_properties
|
78
|
+
invalid_properties = Array.new
|
79
|
+
invalid_properties
|
80
|
+
end
|
81
|
+
|
82
|
+
# Check to see if the all the properties in the model are valid
|
83
|
+
# @return true if the model is valid
|
84
|
+
def valid?
|
85
|
+
true
|
86
|
+
end
|
87
|
+
|
88
|
+
# Checks equality by comparing each attribute.
|
89
|
+
# @param [Object] Object to be compared
|
90
|
+
def ==(o)
|
91
|
+
return true if self.equal?(o)
|
92
|
+
self.class == o.class &&
|
93
|
+
export_date == o.export_date &&
|
94
|
+
files == o.files
|
95
|
+
end
|
96
|
+
|
97
|
+
# @see the `==` method
|
98
|
+
# @param [Object] Object to be compared
|
99
|
+
def eql?(o)
|
100
|
+
self == o
|
101
|
+
end
|
102
|
+
|
103
|
+
# Calculates hash code according to all attributes.
|
104
|
+
# @return [Integer] Hash code
|
105
|
+
def hash
|
106
|
+
[export_date, files].hash
|
107
|
+
end
|
108
|
+
|
109
|
+
# Builds the object from hash
|
110
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
111
|
+
# @return [Object] Returns the model itself
|
112
|
+
def self.build_from_hash(attributes)
|
113
|
+
new.build_from_hash(attributes)
|
114
|
+
end
|
115
|
+
|
116
|
+
# Builds the object from hash
|
117
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
118
|
+
# @return [Object] Returns the model itself
|
119
|
+
def build_from_hash(attributes)
|
120
|
+
return nil unless attributes.is_a?(Hash)
|
121
|
+
self.class.openapi_types.each_pair do |key, type|
|
122
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
123
|
+
self.send("#{key}=", nil)
|
124
|
+
elsif type =~ /\AArray<(.*)>/i
|
125
|
+
# check to ensure the input is an array given that the attribute
|
126
|
+
# is documented as an array but the input is not
|
127
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
128
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
129
|
+
end
|
130
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
131
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
132
|
+
end
|
133
|
+
end
|
134
|
+
|
135
|
+
self
|
136
|
+
end
|
137
|
+
|
138
|
+
# Deserializes the data based on type
|
139
|
+
# @param string type Data type
|
140
|
+
# @param string value Value to be deserialized
|
141
|
+
# @return [Object] Deserialized data
|
142
|
+
def _deserialize(type, value)
|
143
|
+
case type.to_sym
|
144
|
+
when :Time
|
145
|
+
Time.parse(value)
|
146
|
+
when :Date
|
147
|
+
Date.parse(value)
|
148
|
+
when :String
|
149
|
+
value.to_s
|
150
|
+
when :Integer
|
151
|
+
value.to_i
|
152
|
+
when :Float
|
153
|
+
value.to_f
|
154
|
+
when :Boolean
|
155
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
156
|
+
true
|
157
|
+
else
|
158
|
+
false
|
159
|
+
end
|
160
|
+
when :Object
|
161
|
+
# generic object (usually a Hash), return directly
|
162
|
+
value
|
163
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
164
|
+
inner_type = Regexp.last_match[:inner_type]
|
165
|
+
value.map { |v| _deserialize(inner_type, v) }
|
166
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
167
|
+
k_type = Regexp.last_match[:k_type]
|
168
|
+
v_type = Regexp.last_match[:v_type]
|
169
|
+
{}.tap do |hash|
|
170
|
+
value.each do |k, v|
|
171
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
172
|
+
end
|
173
|
+
end
|
174
|
+
else # model
|
175
|
+
# models (e.g. Pet) or oneOf
|
176
|
+
klass = MuxRuby.const_get(type)
|
177
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
178
|
+
end
|
179
|
+
end
|
180
|
+
|
181
|
+
# Returns the string representation of the object
|
182
|
+
# @return [String] String presentation of the object
|
183
|
+
def to_s
|
184
|
+
to_hash.to_s
|
185
|
+
end
|
186
|
+
|
187
|
+
# to_body is an alias to to_hash (backward compatibility)
|
188
|
+
# @return [Hash] Returns the object in the form of hash
|
189
|
+
def to_body
|
190
|
+
to_hash
|
191
|
+
end
|
192
|
+
|
193
|
+
# Returns the object in the form of hash
|
194
|
+
# @return [Hash] Returns the object in the form of hash
|
195
|
+
def to_hash
|
196
|
+
hash = {}
|
197
|
+
self.class.attribute_map.each_pair do |attr, param|
|
198
|
+
value = self.send(attr)
|
199
|
+
if value.nil?
|
200
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
201
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
202
|
+
end
|
203
|
+
|
204
|
+
hash[param] = _to_hash(value)
|
205
|
+
end
|
206
|
+
hash
|
207
|
+
end
|
208
|
+
|
209
|
+
# Outputs non-array value in the form of hash
|
210
|
+
# For object, use to_hash. Otherwise, just return the value
|
211
|
+
# @param [Object] value Any valid value
|
212
|
+
# @return [Hash] Returns the value in the form of hash
|
213
|
+
def _to_hash(value)
|
214
|
+
if value.is_a?(Array)
|
215
|
+
value.compact.map { |v| _to_hash(v) }
|
216
|
+
elsif value.is_a?(Hash)
|
217
|
+
{}.tap do |hash|
|
218
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
219
|
+
end
|
220
|
+
elsif value.respond_to? :to_hash
|
221
|
+
value.to_hash
|
222
|
+
else
|
223
|
+
value
|
224
|
+
end
|
225
|
+
end
|
226
|
+
|
227
|
+
end
|
228
|
+
|
229
|
+
end
|