Home > @vsf-enterprise/sap-commerce-webservices-sdk > PromotionsApi > getPromotion

PromotionsApi.getPromotion() method

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. Get a promotion based on code

Signature:

getPromotion(baseSiteId: string, code: string, fields?: string, options?: any): Promise<import("axios").AxiosResponse<Promotion>>;

Parameters

Parameter Type Description
baseSiteId string Base site identifier
code string Promotion identifier (code)
fields string Response configuration. This is the list of fields that should be returned in the response body. Examples: BASIC, DEFAULT, FULL
options any Override http request option.

Returns:

Promise<import("axios").AxiosResponse<Promotion>>

Exceptions

{RequiredError} PromotionsApi