Class: MuxRuby::LiveStreamsApi
- Inherits:
-
Object
- Object
- MuxRuby::LiveStreamsApi
- Defined in:
- lib/mux_ruby/api/live_streams_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#create_live_stream(create_live_stream_request, opts = {}) ⇒ LiveStreamResponse
Create a live stream.
-
#create_live_stream_playback_id(live_stream_id, create_playback_id_request, opts = {}) ⇒ CreatePlaybackIDResponse
Create a live stream playback ID.
-
#create_live_stream_playback_id_with_http_info(live_stream_id, create_playback_id_request, opts = {}) ⇒ Array<(CreatePlaybackIDResponse, Fixnum, Hash)>
Create a live stream playback ID.
-
#create_live_stream_simulcast_target(live_stream_id, create_simulcast_target_request, opts = {}) ⇒ SimulcastTargetResponse
Create a live stream simulcast target Create a simulcast target for the parent live stream.
-
#create_live_stream_simulcast_target_with_http_info(live_stream_id, create_simulcast_target_request, opts = {}) ⇒ Array<(SimulcastTargetResponse, Fixnum, Hash)>
Create a live stream simulcast target Create a simulcast target for the parent live stream.
-
#create_live_stream_with_http_info(create_live_stream_request, opts = {}) ⇒ Array<(LiveStreamResponse, Fixnum, Hash)>
Create a live stream.
-
#delete_live_stream(live_stream_id, opts = {}) ⇒ nil
Delete a live stream.
-
#delete_live_stream_playback_id(live_stream_id, playback_id, opts = {}) ⇒ nil
Delete a live stream playback ID.
-
#delete_live_stream_playback_id_with_http_info(live_stream_id, playback_id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>
Delete a live stream playback ID.
-
#delete_live_stream_simulcast_target(live_stream_id, simulcast_target_id, opts = {}) ⇒ nil
Delete a Live Stream Simulcast Target Delete the simulcast target using the simulcast target ID returned when creating the simulcast target.
-
#delete_live_stream_simulcast_target_with_http_info(live_stream_id, simulcast_target_id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>
Delete a Live Stream Simulcast Target Delete the simulcast target using the simulcast target ID returned when creating the simulcast target.
-
#delete_live_stream_with_http_info(live_stream_id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>
Delete a live stream.
-
#get_live_stream(live_stream_id, opts = {}) ⇒ LiveStreamResponse
Retrieve a live stream Retrieves the details of a live stream that has previously been created.
-
#get_live_stream_simulcast_target(live_stream_id, simulcast_target_id, opts = {}) ⇒ SimulcastTargetResponse
Retrieve a Live Stream Simulcast Target Retrieves the details of the simulcast target created for the parent live stream.
-
#get_live_stream_simulcast_target_with_http_info(live_stream_id, simulcast_target_id, opts = {}) ⇒ Array<(SimulcastTargetResponse, Fixnum, Hash)>
Retrieve a Live Stream Simulcast Target Retrieves the details of the simulcast target created for the parent live stream.
-
#get_live_stream_with_http_info(live_stream_id, opts = {}) ⇒ Array<(LiveStreamResponse, Fixnum, Hash)>
Retrieve a live stream Retrieves the details of a live stream that has previously been created.
-
#initialize(api_client = ApiClient.default) ⇒ LiveStreamsApi
constructor
A new instance of LiveStreamsApi.
-
#list_live_streams(opts = {}) ⇒ ListLiveStreamsResponse
List live streams.
-
#list_live_streams_with_http_info(opts = {}) ⇒ Array<(ListLiveStreamsResponse, Fixnum, Hash)>
List live streams.
-
#reset_stream_key(live_stream_id, opts = {}) ⇒ LiveStreamResponse
Reset a live stream’s stream key Reset a live stream key if you want to immediately stop the current stream key from working and create a new stream key that can be used for future broadcasts.
-
#reset_stream_key_with_http_info(live_stream_id, opts = {}) ⇒ Array<(LiveStreamResponse, Fixnum, Hash)>
Reset a live stream’s stream key Reset a live stream key if you want to immediately stop the current stream key from working and create a new stream key that can be used for future broadcasts.
-
#signal_live_stream_complete(live_stream_id, opts = {}) ⇒ SignalLiveStreamCompleteResponse
Signal a live stream is finished (Optional) Make the recorded asset available immediately instead of waiting for the reconnect_window.
-
#signal_live_stream_complete_with_http_info(live_stream_id, opts = {}) ⇒ Array<(SignalLiveStreamCompleteResponse, Fixnum, Hash)>
Signal a live stream is finished (Optional) Make the recorded asset available immediately instead of waiting for the reconnect_window.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ LiveStreamsApi
Returns a new instance of LiveStreamsApi.
12 13 14 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 12 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
10 11 12 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 10 def api_client @api_client end |
Instance Method Details
#create_live_stream(create_live_stream_request, opts = {}) ⇒ LiveStreamResponse
Create a live stream
19 20 21 22 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 19 def create_live_stream(create_live_stream_request, opts = {}) data, _status_code, _headers = create_live_stream_with_http_info(create_live_stream_request, opts) data end |
#create_live_stream_playback_id(live_stream_id, create_playback_id_request, opts = {}) ⇒ CreatePlaybackIDResponse
Create a live stream playback ID
73 74 75 76 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 73 def create_live_stream_playback_id(live_stream_id, create_playback_id_request, opts = {}) data, _status_code, _headers = create_live_stream_playback_id_with_http_info(live_stream_id, create_playback_id_request, opts) data end |
#create_live_stream_playback_id_with_http_info(live_stream_id, create_playback_id_request, opts = {}) ⇒ Array<(CreatePlaybackIDResponse, Fixnum, Hash)>
Create a live stream playback ID
83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 83 def create_live_stream_playback_id_with_http_info(live_stream_id, create_playback_id_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LiveStreamsApi.create_live_stream_playback_id ...' end # verify the required parameter 'live_stream_id' is set if @api_client.config.client_side_validation && live_stream_id.nil? fail ArgumentError, "Missing the required parameter 'live_stream_id' when calling LiveStreamsApi.create_live_stream_playback_id" end # verify the required parameter 'create_playback_id_request' is set if @api_client.config.client_side_validation && create_playback_id_request.nil? fail ArgumentError, "Missing the required parameter 'create_playback_id_request' when calling LiveStreamsApi.create_live_stream_playback_id" end # resource path local_var_path = '/video/v1/live-streams/{LIVE_STREAM_ID}/playback-ids'.sub('{' + 'LIVE_STREAM_ID' + '}', live_stream_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(create_playback_id_request) auth_names = ['accessToken'] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'CreatePlaybackIDResponse') if @api_client.config.debugging @api_client.config.logger.debug "API called: LiveStreamsApi#create_live_stream_playback_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_live_stream_simulcast_target(live_stream_id, create_simulcast_target_request, opts = {}) ⇒ SimulcastTargetResponse
Create a live stream simulcast target Create a simulcast target for the parent live stream. Simulcast target can only be created when the parent live stream is in idle state. Only one simulcast target can be created at a time with this API.
133 134 135 136 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 133 def create_live_stream_simulcast_target(live_stream_id, create_simulcast_target_request, opts = {}) data, _status_code, _headers = create_live_stream_simulcast_target_with_http_info(live_stream_id, create_simulcast_target_request, opts) data end |
#create_live_stream_simulcast_target_with_http_info(live_stream_id, create_simulcast_target_request, opts = {}) ⇒ Array<(SimulcastTargetResponse, Fixnum, Hash)>
Create a live stream simulcast target Create a simulcast target for the parent live stream. Simulcast target can only be created when the parent live stream is in idle state. Only one simulcast target can be created at a time with this API.
144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 144 def create_live_stream_simulcast_target_with_http_info(live_stream_id, create_simulcast_target_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LiveStreamsApi.create_live_stream_simulcast_target ...' end # verify the required parameter 'live_stream_id' is set if @api_client.config.client_side_validation && live_stream_id.nil? fail ArgumentError, "Missing the required parameter 'live_stream_id' when calling LiveStreamsApi.create_live_stream_simulcast_target" end # verify the required parameter 'create_simulcast_target_request' is set if @api_client.config.client_side_validation && create_simulcast_target_request.nil? fail ArgumentError, "Missing the required parameter 'create_simulcast_target_request' when calling LiveStreamsApi.create_live_stream_simulcast_target" end # resource path local_var_path = '/video/v1/live-streams/{LIVE_STREAM_ID}/simulcast-targets'.sub('{' + 'LIVE_STREAM_ID' + '}', live_stream_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(create_simulcast_target_request) auth_names = ['accessToken'] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'SimulcastTargetResponse') if @api_client.config.debugging @api_client.config.logger.debug "API called: LiveStreamsApi#create_live_stream_simulcast_target\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_live_stream_with_http_info(create_live_stream_request, opts = {}) ⇒ Array<(LiveStreamResponse, Fixnum, Hash)>
Create a live stream
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 28 def create_live_stream_with_http_info(create_live_stream_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LiveStreamsApi.create_live_stream ...' end # verify the required parameter 'create_live_stream_request' is set if @api_client.config.client_side_validation && create_live_stream_request.nil? fail ArgumentError, "Missing the required parameter 'create_live_stream_request' when calling LiveStreamsApi.create_live_stream" end # resource path local_var_path = '/video/v1/live-streams' # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(create_live_stream_request) auth_names = ['accessToken'] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'LiveStreamResponse') if @api_client.config.debugging @api_client.config.logger.debug "API called: LiveStreamsApi#create_live_stream\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_live_stream(live_stream_id, opts = {}) ⇒ nil
Delete a live stream
192 193 194 195 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 192 def delete_live_stream(live_stream_id, opts = {}) delete_live_stream_with_http_info(live_stream_id, opts) nil end |
#delete_live_stream_playback_id(live_stream_id, playback_id, opts = {}) ⇒ nil
Delete a live stream playback ID
241 242 243 244 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 241 def delete_live_stream_playback_id(live_stream_id, playback_id, opts = {}) delete_live_stream_playback_id_with_http_info(live_stream_id, playback_id, opts) nil end |
#delete_live_stream_playback_id_with_http_info(live_stream_id, playback_id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>
Delete a live stream playback ID
251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 251 def delete_live_stream_playback_id_with_http_info(live_stream_id, playback_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LiveStreamsApi.delete_live_stream_playback_id ...' end # verify the required parameter 'live_stream_id' is set if @api_client.config.client_side_validation && live_stream_id.nil? fail ArgumentError, "Missing the required parameter 'live_stream_id' when calling LiveStreamsApi.delete_live_stream_playback_id" end # verify the required parameter 'playback_id' is set if @api_client.config.client_side_validation && playback_id.nil? fail ArgumentError, "Missing the required parameter 'playback_id' when calling LiveStreamsApi.delete_live_stream_playback_id" end # resource path local_var_path = '/video/v1/live-streams/{LIVE_STREAM_ID}/playback-ids/{PLAYBACK_ID}'.sub('{' + 'LIVE_STREAM_ID' + '}', live_stream_id.to_s).sub('{' + 'PLAYBACK_ID' + '}', playback_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['accessToken'] data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names) if @api_client.config.debugging @api_client.config.logger.debug "API called: LiveStreamsApi#delete_live_stream_playback_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_live_stream_simulcast_target(live_stream_id, simulcast_target_id, opts = {}) ⇒ nil
Delete a Live Stream Simulcast Target Delete the simulcast target using the simulcast target ID returned when creating the simulcast target. Simulcast Target can only be deleted when the parent live stream is in idle state.
296 297 298 299 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 296 def delete_live_stream_simulcast_target(live_stream_id, simulcast_target_id, opts = {}) delete_live_stream_simulcast_target_with_http_info(live_stream_id, simulcast_target_id, opts) nil end |
#delete_live_stream_simulcast_target_with_http_info(live_stream_id, simulcast_target_id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>
Delete a Live Stream Simulcast Target Delete the simulcast target using the simulcast target ID returned when creating the simulcast target. Simulcast Target can only be deleted when the parent live stream is in idle state.
307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 307 def delete_live_stream_simulcast_target_with_http_info(live_stream_id, simulcast_target_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LiveStreamsApi.delete_live_stream_simulcast_target ...' end # verify the required parameter 'live_stream_id' is set if @api_client.config.client_side_validation && live_stream_id.nil? fail ArgumentError, "Missing the required parameter 'live_stream_id' when calling LiveStreamsApi.delete_live_stream_simulcast_target" end # verify the required parameter 'simulcast_target_id' is set if @api_client.config.client_side_validation && simulcast_target_id.nil? fail ArgumentError, "Missing the required parameter 'simulcast_target_id' when calling LiveStreamsApi.delete_live_stream_simulcast_target" end # resource path local_var_path = '/video/v1/live-streams/{LIVE_STREAM_ID}/simulcast-targets/{SIMULCAST_TARGET_ID}'.sub('{' + 'LIVE_STREAM_ID' + '}', live_stream_id.to_s).sub('{' + 'SIMULCAST_TARGET_ID' + '}', simulcast_target_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['accessToken'] data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names) if @api_client.config.debugging @api_client.config.logger.debug "API called: LiveStreamsApi#delete_live_stream_simulcast_target\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_live_stream_with_http_info(live_stream_id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>
Delete a live stream
201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 201 def delete_live_stream_with_http_info(live_stream_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LiveStreamsApi.delete_live_stream ...' end # verify the required parameter 'live_stream_id' is set if @api_client.config.client_side_validation && live_stream_id.nil? fail ArgumentError, "Missing the required parameter 'live_stream_id' when calling LiveStreamsApi.delete_live_stream" end # resource path local_var_path = '/video/v1/live-streams/{LIVE_STREAM_ID}'.sub('{' + 'LIVE_STREAM_ID' + '}', live_stream_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['accessToken'] data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names) if @api_client.config.debugging @api_client.config.logger.debug "API called: LiveStreamsApi#delete_live_stream\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_live_stream(live_stream_id, opts = {}) ⇒ LiveStreamResponse
Retrieve a live stream Retrieves the details of a live stream that has previously been created. Supply the unique live stream ID that was returned from your previous request, and Mux will return the corresponding live stream information. The same information is returned when creating a live stream.
351 352 353 354 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 351 def get_live_stream(live_stream_id, opts = {}) data, _status_code, _headers = get_live_stream_with_http_info(live_stream_id, opts) data end |
#get_live_stream_simulcast_target(live_stream_id, simulcast_target_id, opts = {}) ⇒ SimulcastTargetResponse
Retrieve a Live Stream Simulcast Target 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.
405 406 407 408 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 405 def get_live_stream_simulcast_target(live_stream_id, simulcast_target_id, opts = {}) data, _status_code, _headers = get_live_stream_simulcast_target_with_http_info(live_stream_id, simulcast_target_id, opts) data end |
#get_live_stream_simulcast_target_with_http_info(live_stream_id, simulcast_target_id, opts = {}) ⇒ Array<(SimulcastTargetResponse, Fixnum, Hash)>
Retrieve a Live Stream Simulcast Target 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.
416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 416 def get_live_stream_simulcast_target_with_http_info(live_stream_id, simulcast_target_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LiveStreamsApi.get_live_stream_simulcast_target ...' end # verify the required parameter 'live_stream_id' is set if @api_client.config.client_side_validation && live_stream_id.nil? fail ArgumentError, "Missing the required parameter 'live_stream_id' when calling LiveStreamsApi.get_live_stream_simulcast_target" end # verify the required parameter 'simulcast_target_id' is set if @api_client.config.client_side_validation && simulcast_target_id.nil? fail ArgumentError, "Missing the required parameter 'simulcast_target_id' when calling LiveStreamsApi.get_live_stream_simulcast_target" end # resource path local_var_path = '/video/v1/live-streams/{LIVE_STREAM_ID}/simulcast-targets/{SIMULCAST_TARGET_ID}'.sub('{' + 'LIVE_STREAM_ID' + '}', live_stream_id.to_s).sub('{' + 'SIMULCAST_TARGET_ID' + '}', simulcast_target_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['accessToken'] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'SimulcastTargetResponse') if @api_client.config.debugging @api_client.config.logger.debug "API called: LiveStreamsApi#get_live_stream_simulcast_target\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_live_stream_with_http_info(live_stream_id, opts = {}) ⇒ Array<(LiveStreamResponse, Fixnum, Hash)>
Retrieve a live stream Retrieves the details of a live stream that has previously been created. Supply the unique live stream ID that was returned from your previous request, and Mux will return the corresponding live stream information. The same information is returned when creating a live stream.
361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 361 def get_live_stream_with_http_info(live_stream_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LiveStreamsApi.get_live_stream ...' end # verify the required parameter 'live_stream_id' is set if @api_client.config.client_side_validation && live_stream_id.nil? fail ArgumentError, "Missing the required parameter 'live_stream_id' when calling LiveStreamsApi.get_live_stream" end # resource path local_var_path = '/video/v1/live-streams/{LIVE_STREAM_ID}'.sub('{' + 'LIVE_STREAM_ID' + '}', live_stream_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['accessToken'] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'LiveStreamResponse') if @api_client.config.debugging @api_client.config.logger.debug "API called: LiveStreamsApi#get_live_stream\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_live_streams(opts = {}) ⇒ ListLiveStreamsResponse
List live streams
463 464 465 466 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 463 def list_live_streams(opts = {}) data, _status_code, _headers = list_live_streams_with_http_info(opts) data end |
#list_live_streams_with_http_info(opts = {}) ⇒ Array<(ListLiveStreamsResponse, Fixnum, Hash)>
List live streams
473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 473 def list_live_streams_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LiveStreamsApi.list_live_streams ...' end # resource path local_var_path = '/video/v1/live-streams' # query parameters query_params = {} query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['accessToken'] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'ListLiveStreamsResponse') if @api_client.config.debugging @api_client.config.logger.debug "API called: LiveStreamsApi#list_live_streams\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#reset_stream_key(live_stream_id, opts = {}) ⇒ LiveStreamResponse
Reset a live stream’s stream key Reset a live stream key if you want to immediately stop the current stream key from working and create a new stream key that can be used for future broadcasts.
514 515 516 517 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 514 def reset_stream_key(live_stream_id, opts = {}) data, _status_code, _headers = reset_stream_key_with_http_info(live_stream_id, opts) data end |
#reset_stream_key_with_http_info(live_stream_id, opts = {}) ⇒ Array<(LiveStreamResponse, Fixnum, Hash)>
Reset a live stream’s stream key Reset a live stream key if you want to immediately stop the current stream key from working and create a new stream key that can be used for future broadcasts.
524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 524 def reset_stream_key_with_http_info(live_stream_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LiveStreamsApi.reset_stream_key ...' end # verify the required parameter 'live_stream_id' is set if @api_client.config.client_side_validation && live_stream_id.nil? fail ArgumentError, "Missing the required parameter 'live_stream_id' when calling LiveStreamsApi.reset_stream_key" end # resource path local_var_path = '/video/v1/live-streams/{LIVE_STREAM_ID}/reset-stream-key'.sub('{' + 'LIVE_STREAM_ID' + '}', live_stream_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['accessToken'] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'LiveStreamResponse') if @api_client.config.debugging @api_client.config.logger.debug "API called: LiveStreamsApi#reset_stream_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#signal_live_stream_complete(live_stream_id, opts = {}) ⇒ SignalLiveStreamCompleteResponse
Signal a live stream is finished (Optional) Make the recorded asset available immediately instead of waiting for the reconnect_window.
567 568 569 570 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 567 def signal_live_stream_complete(live_stream_id, opts = {}) data, _status_code, _headers = signal_live_stream_complete_with_http_info(live_stream_id, opts) data end |
#signal_live_stream_complete_with_http_info(live_stream_id, opts = {}) ⇒ Array<(SignalLiveStreamCompleteResponse, Fixnum, Hash)>
Signal a live stream is finished (Optional) Make the recorded asset available immediately instead of waiting for the reconnect_window.
577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 |
# File 'lib/mux_ruby/api/live_streams_api.rb', line 577 def signal_live_stream_complete_with_http_info(live_stream_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: LiveStreamsApi.signal_live_stream_complete ...' end # verify the required parameter 'live_stream_id' is set if @api_client.config.client_side_validation && live_stream_id.nil? fail ArgumentError, "Missing the required parameter 'live_stream_id' when calling LiveStreamsApi.signal_live_stream_complete" end # resource path local_var_path = '/video/v1/live-streams/{LIVE_STREAM_ID}/complete'.sub('{' + 'LIVE_STREAM_ID' + '}', live_stream_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['accessToken'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'SignalLiveStreamCompleteResponse') if @api_client.config.debugging @api_client.config.logger.debug "API called: LiveStreamsApi#signal_live_stream_complete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |