OOOoyalaAPIClient Class Reference

Ooyala API client implementation. More...

#import "OOOoyalaAPIClient.h"

+ Inheritance diagram for OOOoyalaAPIClient:

Instance Methods

(instancetype) - initWithPcode:domain:
 Initialize an OOOoyalaAPIClient with pcode and embed domain. More...
 
(instancetype) - initWithPcode:domain:embedTokenGenerator:
 Initialize an OOOoyalaAPIClient with pcode, embed domain and OOEmbedTokenGenerator. More...
 
(instancetype) - initWithPcode:domain:secureUrlGenerator:
 Initialize an OOOoyalaAPIClient with pcode, embed domain and OOSecureURLGenerator. More...
 
(instancetype) - initWithAPIKey:secret:pcode:domain:
 Initialize an OOOoyalaAPIClient with pcode, embed domain, API key and secret. More...
 
(instancetype) - initWithAPIKey:secret:pcode:domain:embedTokenGenerator:
 Initialize an OOOoyalaAPIClient with pcode, embed domain, API key and secret and OOEmbedTokenGenerator. More...
 
(instancetype) - initWithPcode:domain:embedTokenGenerator:secureUrlGenerator:
 Initialize an OOOoyalaAPIClient with pcode, embed domain, OOEmbedTokenGenerator and OOSecureURLGenerator. More...
 
(instancetype) - initWithPlayerAPIClient:secureUrlGenerator:
 
(instancetype) - initWithPlayerAPIClient:
 
(void) - contentTree:callback:
 Asynchronously fetch the content tree for a set of embed codes. More...
 
(void) - contentTree:adSetCode:callback:
 Asynchronously fetch the content tree for a set of embed codes, with the specified ad set. More...
 
(void) - contentTreeByExternalIds:callback:
 Asynchronously fetch the content tree for a set of external ids. More...
 
(void) - contentTreeNext:callback:
 Asynchronously fetch next part of the content tree if content tree is too large Use hasMoreChildren (OOPaginatedParentItem-p) to check if this is needed. More...
 
(void) - objectFromBacklotAPI:params:withCallback:
 Asynchronously fetch a raw NSDictionary/NSArray from any backlot API (GET requests only) More...
 
(NSString *) - pcode
 
(OOPlayerDomain *) - domain
 

Class Methods

(NSString *) + messageForAuthCode:
 

Detailed Description

Ooyala API client implementation.

OOOoyalaAPIClient.

Used internally by the OOOoyalaPlayer to load content information and metadata. Can be used by the customer app to query Backlot APIs

OOOoyalaAPIClient.h in OoyalaSDK

Method Documentation

- (void) contentTree: (NSArray *)  embedCodes
adSetCode: (NSString *)  adSetCode
callback: (OOContentTreeCallback)  callback 

Asynchronously fetch the content tree for a set of embed codes, with the specified ad set.

Parameters
[in]embedCodesan NSArray containing the embed codes to fetch the content tree for
[in]adSetCode(possibly nil) an NSString containing the ad set code for the ad set to dynamically assign
[in]callbackthe OOContentTreeCallback to execute when the asynchronous fetch completes
- (void) contentTree: (NSArray *)  embedCodes
callback: (OOContentTreeCallback)  callback 

Asynchronously fetch the content tree for a set of embed codes.

Parameters
[in]embedCodesan NSArray containing the embed codes to fetch the content tree for
[in]callbackthe OOContentTreeCallback to execute when the asynchronous fetch completes
- (void) contentTreeByExternalIds: (NSArray *)  externalIds
callback: (OOContentTreeCallback)  callback 

Asynchronously fetch the content tree for a set of external ids.

Note
: The external ids will not be in the resulting OOContentItem tree. All ContentItems are keyed based on embed code.
Parameters
[in]externalIdsan NSArray containing the external ids to fetch the content tree for
[in]callbackthe OOContentTreeCallback to execute when the asynchronous fetch completes
- (void) contentTreeNext: (id< OOPaginatedParentItem >)  parent
callback: (OOContentTreeNextCallback)  callback 

Asynchronously fetch next part of the content tree if content tree is too large Use hasMoreChildren (OOPaginatedParentItem-p) to check if this is needed.

Parameters
[in,out]parentthe OOPaginatedParentItem to fetch more children for
[in]callbacka block called on return
- (OOPlayerDomain *) domain
- (instancetype) initWithAPIKey: (NSString *)  apiKey
secret: (NSString *)  secret
pcode: (NSString *)  pcode
domain: (OOPlayerDomain *)  domain 

Initialize an OOOoyalaAPIClient with pcode, embed domain, API key and secret.

Allows accessing protected Backlot APIs. Use initWithPcode:domain:secureUrlGenerator: if you don't want to embed API keys in the app.

Parameters
[in]apiKeythe API Key to use (from Backlot)
[in]secretthe Secret to use (from Backlot)
[in]pcodethe Partner Code to use (from Backlot)
[in]domainthe embed domain
Returns
the initialized OOOoyalaAPIClient
- (instancetype) initWithAPIKey: (NSString *)  apiKey
secret: (NSString *)  secret
pcode: (NSString *)  pcode
domain: (OOPlayerDomain *)  domain
embedTokenGenerator: (id< OOEmbedTokenGenerator >)  generator 

Initialize an OOOoyalaAPIClient with pcode, embed domain, API key and secret and OOEmbedTokenGenerator.

Allows accessing content that is protected by Ooyala Player Tokens. Allows accessing protected Backlot APIs. Use initWithPcode:domain:embedTokenGenerator:secureUrlGenerator: if you don't want to embed API keys in the app.

Parameters
[in]apiKeythe API Key to use (from Backlot)
[in]secretthe Secret to use (from Backlot)
[in]pcodethe Partner Code to use (from Backlot)
[in]domainthe embed domain
[in]generatorthe initialized OOEmbedTokenGenerator to use
Returns
the initialized OOOoyalaAPIClient
- (instancetype) initWithPcode: (NSString *)  pcode
domain: (OOPlayerDomain *)  domain 

Initialize an OOOoyalaAPIClient with pcode and embed domain.

Parameters
[in]pcodethe Partner Code to use (from Backlot)
[in]domainthe embed domain
Returns
the initialized OOOoyalaAPIClient
- (instancetype) initWithPcode: (NSString *)  pcode
domain: (OOPlayerDomain *)  domain
embedTokenGenerator: (id< OOEmbedTokenGenerator >)  generator 

Initialize an OOOoyalaAPIClient with pcode, embed domain and OOEmbedTokenGenerator.

Allows accessing content that is protected by Ooyala Player Tokens.

Parameters
[in]pcodethe Partner Code to use (from Backlot)
[in]domainthe embed domain
[in]generatorOOEmbedTokenGenerator for creating Ooyala Player Tokens
Returns
the initialized OOOoyalaAPIClient
- (instancetype) initWithPcode: (NSString *)  pcode
domain: (OOPlayerDomain *)  domain
embedTokenGenerator: (id< OOEmbedTokenGenerator >)  generator
secureUrlGenerator: (id< OOSecureURLGenerator >)  secureURLGenerator 

Initialize an OOOoyalaAPIClient with pcode, embed domain, OOEmbedTokenGenerator and OOSecureURLGenerator.

Allows accessing content that is protected by Ooyala Player Tokens. Allows accessing protected Backlot APIs.

Parameters
[in]pcodethe Partner Code to use (from Backlot)
[in]domainthe embed domain
[in]generatorthe initialized OOEmbedTokenGenerator to use
[in]secureURLGeneratoran initialized instance of OOSecureURLGenerator used for signing Backlot requests
Returns
the initialized OOOoyalaAPIClient
- (instancetype) initWithPcode: (NSString *)  pcode
domain: (OOPlayerDomain *)  domain
secureUrlGenerator: (id< OOSecureURLGenerator >)  secureURLGenerator 

Initialize an OOOoyalaAPIClient with pcode, embed domain and OOSecureURLGenerator.

Allows accessing protected Backlot APIs

Parameters
[in]pcodethe Partner Code to use (from Backlot)
[in]domainthe embed domain
[in]secureURLGeneratoran initialized instance of OOSecureURLGenerator used for signing Backlot requests
Returns
the initialized OOOoyalaAPIClient
- (instancetype) initWithPlayerAPIClient: (OOPlayerAPIClient *)  thePlayerAPIClient
- (instancetype) initWithPlayerAPIClient: (OOPlayerAPIClient *)  playerAPI
secureUrlGenerator: (id< OOSecureURLGenerator >)  secureURLGenerator 
+ (NSString *) messageForAuthCode: (int)  code
- (void) objectFromBacklotAPI: (NSString *)  uri
params: (NSDictionary *)  params
withCallback: (OOObjectFromBacklotAPICallback)  callback 

Asynchronously fetch a raw NSDictionary/NSArray from any backlot API (GET requests only)

Parameters
[in]urithe URI to be fetched from backlot not including "/v2". For example, to request https://api.ooyala.com/v2/assets, uri should be "/assets"
[in]paramsAdditional params that the API may require in the form of dictionary.
[in]callbackthe OOObjectFromBacklotAPICallback to execute when the asynchronous fetch completes
- (NSString *) pcode

The documentation for this class was generated from the following file: