AbstractPayTvPurchaseService

AbstractPayTvPurchaseService ⇐ AbstractPurchaseService

Kind: global abstract class
Extends: AbstractPurchaseService
Service:
Properties

NameTypeDescription
isActivatedboolean

Activation state of PayTvPurchaseService Service

AbstractPayTvPurchaseService()

The PayTvPurchaseService exposes the purchase API for payTv.

init(options) ⇒ Promise

Init the service

Kind: instance method of AbstractPayTvPurchaseService

ParamTypeDescription
optionsObject

request options

setActivated(options) ⇒ Promise

Set flag isActivated to know if GDPR is active

Kind: instance method of AbstractPayTvPurchaseService

ParamTypeDescription
optionsObject

request options

getOffers([options]) ⇒ Promise.<Array>

Get a list of available offers : -> If we have a channelIds in parameter : the function return all the available offers, including this channelIds -> If we have a offerIds in parameter : the function return all the available offers, including this offerIds which are not already subscribed -> Otherwise : the function return all available offers structure

Kind: instance method of AbstractPayTvPurchaseService
Returns: Promise.<Array> - A list of models

ParamTypeDescription
[options]object
[options.channelIds]Array.<String>

the channelId list

[options.offerIds]Array.<String>

the offerId list

[options.filters]number

possible values : byType, isPurchased, orderByPrice

getOfferChannels(offerId) ⇒ Promise.<Array.<String>>

Get channels of the offer in parameter.

Kind: instance method of AbstractPayTvPurchaseService
Returns: Promise.<Array.<String>> - Array of channelId null if the offer does not exist

ParamTypeDescription
offerIdnumber

Id of the offer

_init(options) ⇒ Promise

Init the service

Kind: instance method of AbstractPayTvPurchaseService

ParamTypeDescription
optionsObject

request options

_setActivated(options) ⇒ Promise

Set flag isActivated to know if GDPR is active

Kind: instance method of AbstractPayTvPurchaseService

ParamTypeDescription
optionsObject

request options

_getOffers([options]) ⇒ *

Vendor implementation for getOffers function

Kind: instance method of AbstractPayTvPurchaseService

ParamTypeDescription
[options]object
[options.channelIds]Array.<String>

the channelId list

[options.offerIds]Array.<String>

the offerId list

[options.filters]number

possible values : byType, isPurchased, orderByPrice

_getOfferChannels(offerId) ⇒ *

Vendor implementation for getOfferChannels function

Kind: instance method of AbstractPayTvPurchaseService

ParamTypeDescription
offerIdnumber

Id of the offer