Class: module:api/PromotionsApi

module:api/PromotionsApi(apiClient)

new module:api/PromotionsApi(apiClient)

Constructs a new PromotionsApi.

Parameters:
Name Type Description
apiClient module:ApiClient

Optional API client implementation to use, default to module:ApiClient#instance if unspecified.

Source:

Methods

getPromotion(code, opts) → {Promise}

getPromotion Returns details of a single promotion specified by a promotion code. Requests pertaining to promotions have been developed for the previous version of promotions and vouchers and therefore some of them are currently not compatible with the new promotion engine. Security: Permitted only for trusted client

Parameters:
Name Type Description
code String

Promotion identifier (code)

opts Object

Optional parameters

Properties
Name Type Description
fields String

Response configuration (list of fields, which should be returned in response)

Source:
Returns:

a Promise">www.promisejs.org/|Promise}, with data of type module:models/Promotion

Type
Promise

getPromotions(opts) → {Promise}

getPromotions Returns promotions defined for a current base site. Requests pertaining to promotions have been developed for the previous version of promotions and vouchers and therefore some of them are currently not compatible with the new promotion engine. Security: Permitted only for trusted client

Parameters:
Name Type Description
opts Object

Optional parameters

Properties
Name Type Description
promotionGroup String

Only promotions from this group are returned

type String

Defines what type of promotions should be returned. Values supported for that parameter are: <ul> <li>all: All available promotions are returned</li> <li>product: Only product promotions are returned</li> <li>order: Only order promotions are returned</li> </ul>

fields String

Response configuration (list of fields, which should be returned in response)

Source:
Returns:

a Promise">www.promisejs.org/|Promise}, with data of type module:models/PromotionList

Type
Promise

promotionsByCodeWithHttpInfo(code, opts) → {Promise}

getPromotion Returns details of a single promotion specified by a promotion code. Requests pertaining to promotions have been developed for the previous version of promotions and vouchers and therefore some of them are currently not compatible with the new promotion engine. Security: Permitted only for trusted client

Parameters:
Name Type Description
code String

Promotion identifier (code)

opts Object

Optional parameters

Properties
Name Type Description
fields String

Response configuration (list of fields, which should be returned in response)

Source:
Returns:

a Promise">www.promisejs.org/|Promise}, with an object containing data of type module:models/Promotion and HTTP response

Type
Promise

promotionsWithHttpInfo(opts) → {Promise}

getPromotions Returns promotions defined for a current base site. Requests pertaining to promotions have been developed for the previous version of promotions and vouchers and therefore some of them are currently not compatible with the new promotion engine. Security: Permitted only for trusted client

Parameters:
Name Type Description
opts Object

Optional parameters

Properties
Name Type Description
promotionGroup String

Only promotions from this group are returned

type String

Defines what type of promotions should be returned. Values supported for that parameter are: <ul> <li>all: All available promotions are returned</li> <li>product: Only product promotions are returned</li> <li>order: Only order promotions are returned</li> </ul>

fields String

Response configuration (list of fields, which should be returned in response)

Source:
Returns:

a Promise">www.promisejs.org/|Promise}, with an object containing data of type module:models/PromotionList and HTTP response

Type
Promise