Class: Kaltura::KalturaAppTokenService
- Inherits:
-
KalturaServiceBase
- Object
- KalturaServiceBase
- Kaltura::KalturaAppTokenService
- Defined in:
- lib/kaltura_client.rb
Overview
Manage application authentication tokens
Instance Attribute Summary
Attributes inherited from KalturaServiceBase
Instance Method Summary collapse
-
#add(app_token) ⇒ KalturaAppToken
Add new application authentication token.
-
#delete(id) ⇒ Object
Delete application authentication token by ID.
-
#get(id) ⇒ KalturaAppToken
Get application authentication token by ID.
-
#initialize(client) ⇒ KalturaAppTokenService
constructor
A new instance of KalturaAppTokenService.
-
#list(filter = KalturaNotImplemented, pager = KalturaNotImplemented) ⇒ KalturaAppTokenListResponse
List application authentication tokens by filter and pager.
-
#start_session(id, token_hash, user_id = KalturaNotImplemented, type = KalturaNotImplemented, expiry = KalturaNotImplemented, session_privileges = KalturaNotImplemented) ⇒ KalturaSessionInfo
Starts a new KS (kaltura Session) based on an application authentication token ID.
-
#update(id, app_token) ⇒ KalturaAppToken
Update application authentication token by ID.
Constructor Details
#initialize(client) ⇒ KalturaAppTokenService
Returns a new instance of KalturaAppTokenService.
257 258 259 |
# File 'lib/kaltura_client.rb', line 257 def initialize(client) super(client) end |
Instance Method Details
#add(app_token) ⇒ KalturaAppToken
Add new application authentication token
263 264 265 266 267 268 269 270 271 |
# File 'lib/kaltura_client.rb', line 263 def add(app_token) kparams = {} client.add_param(kparams, 'appToken', app_token) client.queue_service_action_call('apptoken', 'add', 'KalturaAppToken', kparams) if (client.is_multirequest) return nil end return client.do_queue() end |
#delete(id) ⇒ Object
Delete application authentication token by ID
275 276 277 278 279 280 281 282 283 |
# File 'lib/kaltura_client.rb', line 275 def delete(id) kparams = {} client.add_param(kparams, 'id', id) client.queue_service_action_call('apptoken', 'delete', '', kparams) if (client.is_multirequest) return nil end return client.do_queue() end |
#get(id) ⇒ KalturaAppToken
Get application authentication token by ID
287 288 289 290 291 292 293 294 295 |
# File 'lib/kaltura_client.rb', line 287 def get(id) kparams = {} client.add_param(kparams, 'id', id) client.queue_service_action_call('apptoken', 'get', 'KalturaAppToken', kparams) if (client.is_multirequest) return nil end return client.do_queue() end |
#list(filter = KalturaNotImplemented, pager = KalturaNotImplemented) ⇒ KalturaAppTokenListResponse
List application authentication tokens by filter and pager
299 300 301 302 303 304 305 306 307 308 |
# File 'lib/kaltura_client.rb', line 299 def list(filter=KalturaNotImplemented, pager=KalturaNotImplemented) kparams = {} client.add_param(kparams, 'filter', filter) client.add_param(kparams, 'pager', pager) client.queue_service_action_call('apptoken', 'list', 'KalturaAppTokenListResponse', kparams) if (client.is_multirequest) return nil end return client.do_queue() end |
#start_session(id, token_hash, user_id = KalturaNotImplemented, type = KalturaNotImplemented, expiry = KalturaNotImplemented, session_privileges = KalturaNotImplemented) ⇒ KalturaSessionInfo
Starts a new KS (kaltura Session) based on an application authentication token ID
312 313 314 315 316 317 318 319 320 321 322 323 324 325 |
# File 'lib/kaltura_client.rb', line 312 def start_session(id, token_hash, user_id=KalturaNotImplemented, type=KalturaNotImplemented, expiry=KalturaNotImplemented, session_privileges=KalturaNotImplemented) kparams = {} client.add_param(kparams, 'id', id) client.add_param(kparams, 'tokenHash', token_hash) client.add_param(kparams, 'userId', user_id) client.add_param(kparams, 'type', type) client.add_param(kparams, 'expiry', expiry) client.add_param(kparams, 'sessionPrivileges', session_privileges) client.queue_service_action_call('apptoken', 'startSession', 'KalturaSessionInfo', kparams) if (client.is_multirequest) return nil end return client.do_queue() end |
#update(id, app_token) ⇒ KalturaAppToken
Update application authentication token by ID
329 330 331 332 333 334 335 336 337 338 |
# File 'lib/kaltura_client.rb', line 329 def update(id, app_token) kparams = {} client.add_param(kparams, 'id', id) client.add_param(kparams, 'appToken', app_token) client.queue_service_action_call('apptoken', 'update', 'KalturaAppToken', kparams) if (client.is_multirequest) return nil end return client.do_queue() end |