class Kaltura::KalturaLiveChannelService
Live Channel service lets you manage live channels
Public Class Methods
# File lib/kaltura_client.rb, line 2216 def initialize(client) super(client) end
Public Instance Methods
Adds new live channel. @return [KalturaLiveChannel]
# File lib/kaltura_client.rb, line 2222 def add(live_channel) kparams = {} client.add_param(kparams, 'liveChannel', live_channel) client.queue_service_action_call('livechannel', 'add', 'KalturaLiveChannel', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
Append recorded video to live entry @return [KalturaLiveEntry]
# File lib/kaltura_client.rb, line 2234 def append_recording(entry_id, asset_id, media_server_index, resource, duration, is_last_chunk=false) kparams = {} client.add_param(kparams, 'entryId', entry_id) client.add_param(kparams, 'assetId', asset_id) client.add_param(kparams, 'mediaServerIndex', media_server_index) client.add_param(kparams, 'resource', resource) client.add_param(kparams, 'duration', duration) client.add_param(kparams, 'isLastChunk', is_last_chunk) client.queue_service_action_call('livechannel', 'appendRecording', 'KalturaLiveEntry', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
Create recorded entry id if it doesn't exist and make sure it happens on the DC that the live entry was created on. @return [KalturaLiveEntry]
# File lib/kaltura_client.rb, line 2251 def create_recorded_entry(entry_id, media_server_index, live_entry_status) kparams = {} client.add_param(kparams, 'entryId', entry_id) client.add_param(kparams, 'mediaServerIndex', media_server_index) client.add_param(kparams, 'liveEntryStatus', live_entry_status) client.queue_service_action_call('livechannel', 'createRecordedEntry', 'KalturaLiveEntry', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
Delete a live channel. @return []
# File lib/kaltura_client.rb, line 2265 def delete(id) kparams = {} client.add_param(kparams, 'id', id) client.queue_service_action_call('livechannel', 'delete', '', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
Get live channel by ID. @return [KalturaLiveChannel]
# File lib/kaltura_client.rb, line 2277 def get(id) kparams = {} client.add_param(kparams, 'id', id) client.queue_service_action_call('livechannel', 'get', 'KalturaLiveChannel', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
Delivering the status of a live channel (on-air/offline) @return [bool]
# File lib/kaltura_client.rb, line 2289 def is_live(id) kparams = {} client.add_param(kparams, 'id', id) client.queue_service_action_call('livechannel', 'isLive', 'bool', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
List live channels by filter with paging support. @return [KalturaLiveChannelListResponse]
# File lib/kaltura_client.rb, line 2301 def list(filter=KalturaNotImplemented, pager=KalturaNotImplemented) kparams = {} client.add_param(kparams, 'filter', filter) client.add_param(kparams, 'pager', pager) client.queue_service_action_call('livechannel', 'list', 'KalturaLiveChannelListResponse', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
Register media server to live entry @return [KalturaLiveEntry]
# File lib/kaltura_client.rb, line 2314 def register_media_server(entry_id, hostname, media_server_index, application_name=KalturaNotImplemented, live_entry_status=1, should_create_recorded_entry=true) kparams = {} client.add_param(kparams, 'entryId', entry_id) client.add_param(kparams, 'hostname', hostname) client.add_param(kparams, 'mediaServerIndex', media_server_index) client.add_param(kparams, 'applicationName', application_name) client.add_param(kparams, 'liveEntryStatus', live_entry_status) client.add_param(kparams, 'shouldCreateRecordedEntry', should_create_recorded_entry) client.queue_service_action_call('livechannel', 'registerMediaServer', 'KalturaLiveEntry', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
Set recorded video to live entry @return [KalturaLiveEntry]
# File lib/kaltura_client.rb, line 2331 def set_recorded_content(entry_id, media_server_index, resource, duration, recorded_entry_id=KalturaNotImplemented, flavor_params_id=KalturaNotImplemented) kparams = {} client.add_param(kparams, 'entryId', entry_id) client.add_param(kparams, 'mediaServerIndex', media_server_index) client.add_param(kparams, 'resource', resource) client.add_param(kparams, 'duration', duration) client.add_param(kparams, 'recordedEntryId', recorded_entry_id) client.add_param(kparams, 'flavorParamsId', flavor_params_id) client.queue_service_action_call('livechannel', 'setRecordedContent', 'KalturaLiveEntry', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
Unregister media server from live entry @return [KalturaLiveEntry]
# File lib/kaltura_client.rb, line 2348 def unregister_media_server(entry_id, hostname, media_server_index) kparams = {} client.add_param(kparams, 'entryId', entry_id) client.add_param(kparams, 'hostname', hostname) client.add_param(kparams, 'mediaServerIndex', media_server_index) client.queue_service_action_call('livechannel', 'unregisterMediaServer', 'KalturaLiveEntry', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
Update live channel. Only the properties that were set will be updated. @return [KalturaLiveChannel]
# File lib/kaltura_client.rb, line 2362 def update(id, live_channel) kparams = {} client.add_param(kparams, 'id', id) client.add_param(kparams, 'liveChannel', live_channel) client.queue_service_action_call('livechannel', 'update', 'KalturaLiveChannel', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
Validates all registered media servers @return []
# File lib/kaltura_client.rb, line 2375 def validate_registered_media_servers(entry_id) kparams = {} client.add_param(kparams, 'entryId', entry_id) client.queue_service_action_call('livechannel', 'validateRegisteredMediaServers', '', kparams) if (client.is_multirequest) return nil end return client.do_queue() end