@tradecafe/offer-service-sdk 0.0.58 → 0.0.62

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (168) hide show
  1. package/.openapi-generator/FILES +77 -69
  2. package/api/apis.ts +3 -1
  3. package/api/matchedOffersApi.ts +260 -0
  4. package/api/promoTextsApi.ts +426 -0
  5. package/dist/api/apis.d.ts +22 -20
  6. package/dist/api/apis.js +58 -56
  7. package/dist/api/apis.js.map +1 -1
  8. package/dist/api/automatedOffersApi.d.ts +156 -156
  9. package/dist/api/automatedOffersApi.js +1218 -1218
  10. package/dist/api/futureBidsApi.d.ts +65 -65
  11. package/dist/api/futureBidsApi.js +456 -456
  12. package/dist/api/healthApi.d.ts +32 -32
  13. package/dist/api/healthApi.js +174 -174
  14. package/dist/api/matchedOffersApi.d.ts +301 -267
  15. package/dist/api/matchedOffersApi.js +2330 -2074
  16. package/dist/api/matchedOffersApi.js.map +1 -1
  17. package/dist/api/offersApi.d.ts +200 -200
  18. package/dist/api/offersApi.js +1605 -1605
  19. package/dist/api/promoTextsApi.d.ts +67 -0
  20. package/dist/api/promoTextsApi.js +436 -0
  21. package/dist/api/promoTextsApi.js.map +1 -0
  22. package/dist/api.d.ts +2 -2
  23. package/dist/api.js +18 -18
  24. package/dist/model/addFutureBidDto.d.ts +17 -17
  25. package/dist/model/addFutureBidDto.js +35 -35
  26. package/dist/model/addMatchedDeliveryDateDto.d.ts +14 -14
  27. package/dist/model/addMatchedDeliveryDateDto.js +20 -20
  28. package/dist/model/archivePromoTextDto.d.ts +14 -0
  29. package/dist/model/archivePromoTextDto.js +21 -0
  30. package/dist/model/archivePromoTextDto.js.map +1 -0
  31. package/dist/model/associatedCostDto.d.ts +16 -16
  32. package/dist/model/associatedCostDto.js +30 -30
  33. package/dist/model/bulkAddRelistingDto.d.ts +16 -16
  34. package/dist/model/bulkAddRelistingDto.js +25 -25
  35. package/dist/model/bulkAddTertiaryCostsDto.d.ts +16 -16
  36. package/dist/model/bulkAddTertiaryCostsDto.js +25 -25
  37. package/dist/model/bulkCancelPromotionDto.d.ts +16 -0
  38. package/dist/model/bulkCancelPromotionDto.js +31 -0
  39. package/dist/model/bulkCancelPromotionDto.js.map +1 -0
  40. package/dist/model/bulkChangeDestinationLocationDto.d.ts +16 -16
  41. package/dist/model/bulkChangeDestinationLocationDto.js +30 -30
  42. package/dist/model/bulkChangeFreightRatesDto.d.ts +19 -19
  43. package/dist/model/bulkChangeFreightRatesDto.js +40 -40
  44. package/dist/model/bulkChangeIncotermDto.d.ts +16 -16
  45. package/dist/model/bulkChangeIncotermDto.js +30 -30
  46. package/dist/model/bulkChangeSellPriceItemDto.d.ts +20 -20
  47. package/dist/model/bulkChangeSellPriceItemDto.js +45 -45
  48. package/dist/model/bulkChangeSellPricesDto.d.ts +23 -23
  49. package/dist/model/bulkChangeSellPricesDto.js +55 -55
  50. package/dist/model/bulkChangeSellingTraderDto.d.ts +16 -16
  51. package/dist/model/bulkChangeSellingTraderDto.js +30 -30
  52. package/dist/model/bulkDeleteBuyerSpecialInstructionsDto.d.ts +15 -15
  53. package/dist/model/bulkDeleteBuyerSpecialInstructionsDto.js +25 -25
  54. package/dist/model/bulkPromoteDto.d.ts +17 -0
  55. package/dist/model/bulkPromoteDto.js +36 -0
  56. package/dist/model/bulkPromoteDto.js.map +1 -0
  57. package/dist/model/bulkUpdateBuyerSpecialInstructionsDto.d.ts +19 -19
  58. package/dist/model/bulkUpdateBuyerSpecialInstructionsDto.js +45 -45
  59. package/dist/model/bulkUpdateDeliveryDatesDto.d.ts +16 -16
  60. package/dist/model/bulkUpdateDeliveryDatesDto.js +30 -30
  61. package/dist/model/bulkUpdateDocsCountryDto.d.ts +16 -16
  62. package/dist/model/bulkUpdateDocsCountryDto.js +30 -30
  63. package/dist/model/bulkUpdateMatchedDeliveryDatesDto.d.ts +15 -15
  64. package/dist/model/bulkUpdateMatchedDeliveryDatesDto.js +25 -25
  65. package/dist/model/costAmountDto.d.ts +17 -17
  66. package/dist/model/costAmountDto.js +35 -35
  67. package/dist/model/costAttributesDto.d.ts +32 -32
  68. package/dist/model/costAttributesDto.js +100 -100
  69. package/dist/model/costAttributesDtoAssociated.d.ts +16 -16
  70. package/dist/model/costAttributesDtoAssociated.js +30 -30
  71. package/dist/model/costAttributesDtoDefaultCost.d.ts +18 -18
  72. package/dist/model/costAttributesDtoDefaultCost.js +40 -40
  73. package/dist/model/costDto.d.ts +35 -35
  74. package/dist/model/costDto.js +110 -110
  75. package/dist/model/costDtoAmount.d.ts +17 -17
  76. package/dist/model/costDtoAmount.js +35 -35
  77. package/dist/model/costDtoAttributes.d.ts +32 -32
  78. package/dist/model/costDtoAttributes.js +100 -100
  79. package/dist/model/costDtoSource.d.ts +15 -15
  80. package/dist/model/costDtoSource.js +25 -25
  81. package/dist/model/costSourceDto.d.ts +15 -15
  82. package/dist/model/costSourceDto.js +25 -25
  83. package/dist/model/createAutomatedOfferDto.d.ts +124 -124
  84. package/dist/model/createAutomatedOfferDto.js +419 -419
  85. package/dist/model/createMatchedOfferDto.d.ts +85 -85
  86. package/dist/model/createMatchedOfferDto.js +315 -315
  87. package/dist/model/createMatchedOfferDtoAttributes.d.ts +34 -34
  88. package/dist/model/createMatchedOfferDtoAttributes.js +94 -94
  89. package/dist/model/createOfferDto.d.ts +111 -111
  90. package/dist/model/createOfferDto.js +397 -397
  91. package/dist/model/createOfferDtoAttributes.d.ts +52 -52
  92. package/dist/model/createOfferDtoAttributes.js +174 -174
  93. package/dist/model/createOfferDtoFormula.d.ts +19 -19
  94. package/dist/model/createOfferDtoFormula.js +40 -40
  95. package/dist/model/createOfferDtoPacking.d.ts +17 -17
  96. package/dist/model/createOfferDtoPacking.js +35 -35
  97. package/dist/model/createOfferDtoWeight.d.ts +15 -15
  98. package/dist/model/createOfferDtoWeight.js +25 -25
  99. package/dist/model/createPromoTextDto.d.ts +17 -0
  100. package/dist/model/createPromoTextDto.js +31 -0
  101. package/dist/model/createPromoTextDto.js.map +1 -0
  102. package/dist/model/defaultCostDto.d.ts +18 -18
  103. package/dist/model/defaultCostDto.js +40 -40
  104. package/dist/model/formulaDto.d.ts +19 -19
  105. package/dist/model/formulaDto.js +40 -40
  106. package/dist/model/formulaLineDto.d.ts +17 -17
  107. package/dist/model/formulaLineDto.js +35 -35
  108. package/dist/model/generalAddressDto.d.ts +43 -43
  109. package/dist/model/generalAddressDto.js +165 -165
  110. package/dist/model/healthControllerPing200Response.d.ts +24 -24
  111. package/dist/model/healthControllerPing200Response.js +35 -35
  112. package/dist/model/healthControllerPing200ResponseInfoValue.d.ts +10 -10
  113. package/dist/model/healthControllerPing200ResponseInfoValue.js +36 -36
  114. package/dist/model/healthControllerPing503Response.d.ts +24 -24
  115. package/dist/model/healthControllerPing503Response.js +35 -35
  116. package/dist/model/matchedOfferAttributesDto.d.ts +34 -34
  117. package/dist/model/matchedOfferAttributesDto.js +94 -94
  118. package/dist/model/models.d.ts +109 -102
  119. package/dist/model/models.js +424 -402
  120. package/dist/model/models.js.map +1 -1
  121. package/dist/model/offerAttributesDto.d.ts +52 -52
  122. package/dist/model/offerAttributesDto.js +174 -174
  123. package/dist/model/offerAttributesDtoEstablishment.d.ts +43 -43
  124. package/dist/model/offerAttributesDtoEstablishment.js +165 -165
  125. package/dist/model/overwriteItemDto.d.ts +22 -22
  126. package/dist/model/overwriteItemDto.js +55 -55
  127. package/dist/model/overwriteItemDtoWeight.d.ts +14 -14
  128. package/dist/model/overwriteItemDtoWeight.js +20 -20
  129. package/dist/model/packing.d.ts +17 -17
  130. package/dist/model/packing.js +35 -35
  131. package/dist/model/pinActionDto.d.ts +14 -14
  132. package/dist/model/pinActionDto.js +20 -20
  133. package/dist/model/promoTextPairDto.d.ts +24 -0
  134. package/dist/model/promoTextPairDto.js +41 -0
  135. package/dist/model/promoTextPairDto.js.map +1 -0
  136. package/dist/model/relistingConfigDto.d.ts +17 -17
  137. package/dist/model/relistingConfigDto.js +35 -35
  138. package/dist/model/relistingDetailDto.d.ts +31 -31
  139. package/dist/model/relistingDetailDto.js +62 -62
  140. package/dist/model/relistingDetailDtoRandomConfig.d.ts +19 -19
  141. package/dist/model/relistingDetailDtoRandomConfig.js +45 -45
  142. package/dist/model/relistingRandomConfigDto.d.ts +19 -19
  143. package/dist/model/relistingRandomConfigDto.js +45 -45
  144. package/dist/model/searchPromoTextDto.d.ts +15 -0
  145. package/dist/model/searchPromoTextDto.js +26 -0
  146. package/dist/model/searchPromoTextDto.js.map +1 -0
  147. package/dist/model/updateFutureBidDto.d.ts +17 -17
  148. package/dist/model/updateFutureBidDto.js +35 -35
  149. package/dist/model/updateMatchedDeliveryDateDto.d.ts +15 -15
  150. package/dist/model/updateMatchedDeliveryDateDto.js +25 -25
  151. package/dist/model/updatePromoTextDto.d.ts +17 -0
  152. package/dist/model/updatePromoTextDto.js +31 -0
  153. package/dist/model/updatePromoTextDto.js.map +1 -0
  154. package/dist/model/userPin.d.ts +15 -15
  155. package/dist/model/userPin.js +25 -25
  156. package/dist/model/weight.d.ts +15 -15
  157. package/dist/model/weight.js +25 -25
  158. package/dist/model/weightDto.d.ts +14 -14
  159. package/dist/model/weightDto.js +20 -20
  160. package/model/archivePromoTextDto.ts +34 -0
  161. package/model/bulkCancelPromotionDto.ts +49 -0
  162. package/model/bulkPromoteDto.ts +55 -0
  163. package/model/createPromoTextDto.ts +53 -0
  164. package/model/models.ts +22 -0
  165. package/model/promoTextPairDto.ts +60 -0
  166. package/model/searchPromoTextDto.ts +43 -0
  167. package/model/updatePromoTextDto.ts +47 -0
  168. package/package.json +1 -1
@@ -1,69 +1,77 @@
1
- .gitignore
2
- .openapi-generator-ignore
3
- api.ts
4
- api/apis.ts
5
- api/automatedOffersApi.ts
6
- api/futureBidsApi.ts
7
- api/healthApi.ts
8
- api/matchedOffersApi.ts
9
- api/offersApi.ts
10
- git_push.sh
11
- model/addFutureBidDto.ts
12
- model/addMatchedDeliveryDateDto.ts
13
- model/associatedCostDto.ts
14
- model/bulkAddRelistingDto.ts
15
- model/bulkAddTertiaryCostsDto.ts
16
- model/bulkChangeDestinationLocationDto.ts
17
- model/bulkChangeFreightRatesDto.ts
18
- model/bulkChangeIncotermDto.ts
19
- model/bulkChangeSellPriceItemDto.ts
20
- model/bulkChangeSellPricesDto.ts
21
- model/bulkChangeSellingTraderDto.ts
22
- model/bulkDeleteBuyerSpecialInstructionsDto.ts
23
- model/bulkUpdateBuyerSpecialInstructionsDto.ts
24
- model/bulkUpdateDeliveryDatesDto.ts
25
- model/bulkUpdateDocsCountryDto.ts
26
- model/bulkUpdateMatchedDeliveryDatesDto.ts
27
- model/costAmountDto.ts
28
- model/costAttributesDto.ts
29
- model/costAttributesDtoAssociated.ts
30
- model/costAttributesDtoDefaultCost.ts
31
- model/costDto.ts
32
- model/costDtoAmount.ts
33
- model/costDtoAttributes.ts
34
- model/costDtoSource.ts
35
- model/costSourceDto.ts
36
- model/createAutomatedOfferDto.ts
37
- model/createMatchedOfferDto.ts
38
- model/createMatchedOfferDtoAttributes.ts
39
- model/createOfferDto.ts
40
- model/createOfferDtoAttributes.ts
41
- model/createOfferDtoFormula.ts
42
- model/createOfferDtoPacking.ts
43
- model/createOfferDtoWeight.ts
44
- model/defaultCostDto.ts
45
- model/formulaDto.ts
46
- model/formulaLineDto.ts
47
- model/generalAddressDto.ts
48
- model/healthControllerPing200Response.ts
49
- model/healthControllerPing200ResponseInfoValue.ts
50
- model/healthControllerPing503Response.ts
51
- model/matchedOfferAttributesDto.ts
52
- model/models.ts
53
- model/offerAttributesDto.ts
54
- model/offerAttributesDtoEstablishment.ts
55
- model/overwriteItemDto.ts
56
- model/overwriteItemDtoWeight.ts
57
- model/packing.ts
58
- model/pinActionDto.ts
59
- model/relistingConfigDto.ts
60
- model/relistingDetailDto.ts
61
- model/relistingDetailDtoRandomConfig.ts
62
- model/relistingRandomConfigDto.ts
63
- model/updateFutureBidDto.ts
64
- model/updateMatchedDeliveryDateDto.ts
65
- model/userPin.ts
66
- model/weight.ts
67
- model/weightDto.ts
68
- package.json
69
- tsconfig.json
1
+ .gitignore
2
+ .openapi-generator-ignore
3
+ api.ts
4
+ api/apis.ts
5
+ api/automatedOffersApi.ts
6
+ api/futureBidsApi.ts
7
+ api/healthApi.ts
8
+ api/matchedOffersApi.ts
9
+ api/offersApi.ts
10
+ api/promoTextsApi.ts
11
+ git_push.sh
12
+ model/addFutureBidDto.ts
13
+ model/addMatchedDeliveryDateDto.ts
14
+ model/archivePromoTextDto.ts
15
+ model/associatedCostDto.ts
16
+ model/bulkAddRelistingDto.ts
17
+ model/bulkAddTertiaryCostsDto.ts
18
+ model/bulkCancelPromotionDto.ts
19
+ model/bulkChangeDestinationLocationDto.ts
20
+ model/bulkChangeFreightRatesDto.ts
21
+ model/bulkChangeIncotermDto.ts
22
+ model/bulkChangeSellPriceItemDto.ts
23
+ model/bulkChangeSellPricesDto.ts
24
+ model/bulkChangeSellingTraderDto.ts
25
+ model/bulkDeleteBuyerSpecialInstructionsDto.ts
26
+ model/bulkPromoteDto.ts
27
+ model/bulkUpdateBuyerSpecialInstructionsDto.ts
28
+ model/bulkUpdateDeliveryDatesDto.ts
29
+ model/bulkUpdateDocsCountryDto.ts
30
+ model/bulkUpdateMatchedDeliveryDatesDto.ts
31
+ model/costAmountDto.ts
32
+ model/costAttributesDto.ts
33
+ model/costAttributesDtoAssociated.ts
34
+ model/costAttributesDtoDefaultCost.ts
35
+ model/costDto.ts
36
+ model/costDtoAmount.ts
37
+ model/costDtoAttributes.ts
38
+ model/costDtoSource.ts
39
+ model/costSourceDto.ts
40
+ model/createAutomatedOfferDto.ts
41
+ model/createMatchedOfferDto.ts
42
+ model/createMatchedOfferDtoAttributes.ts
43
+ model/createOfferDto.ts
44
+ model/createOfferDtoAttributes.ts
45
+ model/createOfferDtoFormula.ts
46
+ model/createOfferDtoPacking.ts
47
+ model/createOfferDtoWeight.ts
48
+ model/createPromoTextDto.ts
49
+ model/defaultCostDto.ts
50
+ model/formulaDto.ts
51
+ model/formulaLineDto.ts
52
+ model/generalAddressDto.ts
53
+ model/healthControllerPing200Response.ts
54
+ model/healthControllerPing200ResponseInfoValue.ts
55
+ model/healthControllerPing503Response.ts
56
+ model/matchedOfferAttributesDto.ts
57
+ model/models.ts
58
+ model/offerAttributesDto.ts
59
+ model/offerAttributesDtoEstablishment.ts
60
+ model/overwriteItemDto.ts
61
+ model/overwriteItemDtoWeight.ts
62
+ model/packing.ts
63
+ model/pinActionDto.ts
64
+ model/promoTextPairDto.ts
65
+ model/relistingConfigDto.ts
66
+ model/relistingDetailDto.ts
67
+ model/relistingDetailDtoRandomConfig.ts
68
+ model/relistingRandomConfigDto.ts
69
+ model/searchPromoTextDto.ts
70
+ model/updateFutureBidDto.ts
71
+ model/updateMatchedDeliveryDateDto.ts
72
+ model/updatePromoTextDto.ts
73
+ model/userPin.ts
74
+ model/weight.ts
75
+ model/weightDto.ts
76
+ package.json
77
+ tsconfig.json
package/api/apis.ts CHANGED
@@ -8,6 +8,8 @@ export * from './matchedOffersApi';
8
8
  import { MatchedOffersApi } from './matchedOffersApi';
9
9
  export * from './offersApi';
10
10
  import { OffersApi } from './offersApi';
11
+ export * from './promoTextsApi';
12
+ import { PromoTextsApi } from './promoTextsApi';
11
13
  import * as http from 'http';
12
14
 
13
15
  export class HttpError extends Error {
@@ -19,4 +21,4 @@ export class HttpError extends Error {
19
21
 
20
22
  export { RequestFile } from '../model/models';
21
23
 
22
- export const APIS = [AutomatedOffersApi, FutureBidsApi, HealthApi, MatchedOffersApi, OffersApi];
24
+ export const APIS = [AutomatedOffersApi, FutureBidsApi, HealthApi, MatchedOffersApi, OffersApi, PromoTextsApi];
@@ -16,12 +16,14 @@ import http from 'http';
16
16
 
17
17
  /* tslint:disable:no-unused-locals */
18
18
  import { BulkAddTertiaryCostsDto } from '../model/bulkAddTertiaryCostsDto';
19
+ import { BulkCancelPromotionDto } from '../model/bulkCancelPromotionDto';
19
20
  import { BulkChangeDestinationLocationDto } from '../model/bulkChangeDestinationLocationDto';
20
21
  import { BulkChangeFreightRatesDto } from '../model/bulkChangeFreightRatesDto';
21
22
  import { BulkChangeIncotermDto } from '../model/bulkChangeIncotermDto';
22
23
  import { BulkChangeSellPricesDto } from '../model/bulkChangeSellPricesDto';
23
24
  import { BulkChangeSellingTraderDto } from '../model/bulkChangeSellingTraderDto';
24
25
  import { BulkDeleteBuyerSpecialInstructionsDto } from '../model/bulkDeleteBuyerSpecialInstructionsDto';
26
+ import { BulkPromoteDto } from '../model/bulkPromoteDto';
25
27
  import { BulkUpdateBuyerSpecialInstructionsDto } from '../model/bulkUpdateBuyerSpecialInstructionsDto';
26
28
  import { BulkUpdateDeliveryDatesDto } from '../model/bulkUpdateDeliveryDatesDto';
27
29
  import { BulkUpdateDocsCountryDto } from '../model/bulkUpdateDocsCountryDto';
@@ -97,6 +99,67 @@ export class MatchedOffersApi {
97
99
  this.interceptors.push(interceptor);
98
100
  }
99
101
 
102
+ /**
103
+ *
104
+ * @summary Lists live campaigns for the Promoted filter
105
+ * @param account
106
+ */
107
+ public async matchedOffersControllerActivepromotions (account: string, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ response: http.IncomingMessage; body?: any; }> {
108
+ const localVarPath = this.basePath + '/matched-offers/{account}/promotions/active'
109
+ .replace('{' + 'account' + '}', encodeURIComponent(String(account)));
110
+ let localVarQueryParameters: any = {};
111
+ let localVarHeaderParams: any = (<any>Object).assign({}, this._defaultHeaders);
112
+ let localVarFormParams: any = {};
113
+
114
+ // verify required parameter 'account' is not null or undefined
115
+ if (account === null || account === undefined) {
116
+ throw new Error('Required parameter account was null or undefined when calling matchedOffersControllerActivepromotions.');
117
+ }
118
+
119
+ (<any>Object).assign(localVarHeaderParams, options.headers);
120
+
121
+ let localVarUseFormData = false;
122
+
123
+ let localVarRequestOptions: localVarRequest.Options = {
124
+ method: 'GET',
125
+ qs: localVarQueryParameters,
126
+ headers: localVarHeaderParams,
127
+ uri: localVarPath,
128
+ useQuerystring: this._useQuerystring,
129
+ json: true,
130
+ };
131
+
132
+ let authenticationPromise = Promise.resolve();
133
+ authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
134
+
135
+ let interceptorPromise = authenticationPromise;
136
+ for (const interceptor of this.interceptors) {
137
+ interceptorPromise = interceptorPromise.then(() => interceptor(localVarRequestOptions));
138
+ }
139
+
140
+ return interceptorPromise.then(() => {
141
+ if (Object.keys(localVarFormParams).length) {
142
+ if (localVarUseFormData) {
143
+ (<any>localVarRequestOptions).formData = localVarFormParams;
144
+ } else {
145
+ localVarRequestOptions.form = localVarFormParams;
146
+ }
147
+ }
148
+ return new Promise<{ response: http.IncomingMessage; body?: any; }>((resolve, reject) => {
149
+ localVarRequest(localVarRequestOptions, (error, response, body) => {
150
+ if (error) {
151
+ reject(error);
152
+ } else {
153
+ if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
154
+ resolve({ response: response, body: body });
155
+ } else {
156
+ reject(new HttpError(response, body, response.statusCode));
157
+ }
158
+ }
159
+ });
160
+ });
161
+ });
162
+ }
100
163
  /**
101
164
  *
102
165
  * @summary Adds bid to the matched offer with the provided ID
@@ -329,6 +392,74 @@ export class MatchedOffersApi {
329
392
  });
330
393
  });
331
394
  }
395
+ /**
396
+ *
397
+ * @summary Cancels promotions by matched offer or by whole campaign
398
+ * @param account
399
+ * @param bulkCancelPromotionDto
400
+ */
401
+ public async matchedOffersControllerBulkcancelpromotion (account: string, bulkCancelPromotionDto: BulkCancelPromotionDto, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ response: http.IncomingMessage; body?: any; }> {
402
+ const localVarPath = this.basePath + '/matched-offers/{account}/bulk/cancel-promotion'
403
+ .replace('{' + 'account' + '}', encodeURIComponent(String(account)));
404
+ let localVarQueryParameters: any = {};
405
+ let localVarHeaderParams: any = (<any>Object).assign({}, this._defaultHeaders);
406
+ let localVarFormParams: any = {};
407
+
408
+ // verify required parameter 'account' is not null or undefined
409
+ if (account === null || account === undefined) {
410
+ throw new Error('Required parameter account was null or undefined when calling matchedOffersControllerBulkcancelpromotion.');
411
+ }
412
+
413
+ // verify required parameter 'bulkCancelPromotionDto' is not null or undefined
414
+ if (bulkCancelPromotionDto === null || bulkCancelPromotionDto === undefined) {
415
+ throw new Error('Required parameter bulkCancelPromotionDto was null or undefined when calling matchedOffersControllerBulkcancelpromotion.');
416
+ }
417
+
418
+ (<any>Object).assign(localVarHeaderParams, options.headers);
419
+
420
+ let localVarUseFormData = false;
421
+
422
+ let localVarRequestOptions: localVarRequest.Options = {
423
+ method: 'PUT',
424
+ qs: localVarQueryParameters,
425
+ headers: localVarHeaderParams,
426
+ uri: localVarPath,
427
+ useQuerystring: this._useQuerystring,
428
+ json: true,
429
+ body: ObjectSerializer.serialize(bulkCancelPromotionDto, "BulkCancelPromotionDto")
430
+ };
431
+
432
+ let authenticationPromise = Promise.resolve();
433
+ authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
434
+
435
+ let interceptorPromise = authenticationPromise;
436
+ for (const interceptor of this.interceptors) {
437
+ interceptorPromise = interceptorPromise.then(() => interceptor(localVarRequestOptions));
438
+ }
439
+
440
+ return interceptorPromise.then(() => {
441
+ if (Object.keys(localVarFormParams).length) {
442
+ if (localVarUseFormData) {
443
+ (<any>localVarRequestOptions).formData = localVarFormParams;
444
+ } else {
445
+ localVarRequestOptions.form = localVarFormParams;
446
+ }
447
+ }
448
+ return new Promise<{ response: http.IncomingMessage; body?: any; }>((resolve, reject) => {
449
+ localVarRequest(localVarRequestOptions, (error, response, body) => {
450
+ if (error) {
451
+ reject(error);
452
+ } else {
453
+ if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
454
+ resolve({ response: response, body: body });
455
+ } else {
456
+ reject(new HttpError(response, body, response.statusCode));
457
+ }
458
+ }
459
+ });
460
+ });
461
+ });
462
+ }
332
463
  /**
333
464
  *
334
465
  * @summary Changes the destination location on multiple matched offers in a single operation
@@ -737,6 +868,74 @@ export class MatchedOffersApi {
737
868
  });
738
869
  });
739
870
  }
871
+ /**
872
+ *
873
+ * @summary Promotes multiple matched offers under a single campaign
874
+ * @param account
875
+ * @param bulkPromoteDto
876
+ */
877
+ public async matchedOffersControllerBulkpromote (account: string, bulkPromoteDto: BulkPromoteDto, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ response: http.IncomingMessage; body?: any; }> {
878
+ const localVarPath = this.basePath + '/matched-offers/{account}/bulk/promote'
879
+ .replace('{' + 'account' + '}', encodeURIComponent(String(account)));
880
+ let localVarQueryParameters: any = {};
881
+ let localVarHeaderParams: any = (<any>Object).assign({}, this._defaultHeaders);
882
+ let localVarFormParams: any = {};
883
+
884
+ // verify required parameter 'account' is not null or undefined
885
+ if (account === null || account === undefined) {
886
+ throw new Error('Required parameter account was null or undefined when calling matchedOffersControllerBulkpromote.');
887
+ }
888
+
889
+ // verify required parameter 'bulkPromoteDto' is not null or undefined
890
+ if (bulkPromoteDto === null || bulkPromoteDto === undefined) {
891
+ throw new Error('Required parameter bulkPromoteDto was null or undefined when calling matchedOffersControllerBulkpromote.');
892
+ }
893
+
894
+ (<any>Object).assign(localVarHeaderParams, options.headers);
895
+
896
+ let localVarUseFormData = false;
897
+
898
+ let localVarRequestOptions: localVarRequest.Options = {
899
+ method: 'POST',
900
+ qs: localVarQueryParameters,
901
+ headers: localVarHeaderParams,
902
+ uri: localVarPath,
903
+ useQuerystring: this._useQuerystring,
904
+ json: true,
905
+ body: ObjectSerializer.serialize(bulkPromoteDto, "BulkPromoteDto")
906
+ };
907
+
908
+ let authenticationPromise = Promise.resolve();
909
+ authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
910
+
911
+ let interceptorPromise = authenticationPromise;
912
+ for (const interceptor of this.interceptors) {
913
+ interceptorPromise = interceptorPromise.then(() => interceptor(localVarRequestOptions));
914
+ }
915
+
916
+ return interceptorPromise.then(() => {
917
+ if (Object.keys(localVarFormParams).length) {
918
+ if (localVarUseFormData) {
919
+ (<any>localVarRequestOptions).formData = localVarFormParams;
920
+ } else {
921
+ localVarRequestOptions.form = localVarFormParams;
922
+ }
923
+ }
924
+ return new Promise<{ response: http.IncomingMessage; body?: any; }>((resolve, reject) => {
925
+ localVarRequest(localVarRequestOptions, (error, response, body) => {
926
+ if (error) {
927
+ reject(error);
928
+ } else {
929
+ if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
930
+ resolve({ response: response, body: body });
931
+ } else {
932
+ reject(new HttpError(response, body, response.statusCode));
933
+ }
934
+ }
935
+ });
936
+ });
937
+ });
938
+ }
740
939
  /**
741
940
  *
742
941
  * @summary Sets buyer special instructions on multiple matched offers in a single operation
@@ -1593,6 +1792,67 @@ export class MatchedOffersApi {
1593
1792
  });
1594
1793
  });
1595
1794
  }
1795
+ /**
1796
+ *
1797
+ * @summary Running promotions per buyer, for the Promote modal
1798
+ * @param account
1799
+ */
1800
+ public async matchedOffersControllerPromotionsbybuyer (account: string, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ response: http.IncomingMessage; body?: any; }> {
1801
+ const localVarPath = this.basePath + '/matched-offers/{account}/promotions/by-buyer'
1802
+ .replace('{' + 'account' + '}', encodeURIComponent(String(account)));
1803
+ let localVarQueryParameters: any = {};
1804
+ let localVarHeaderParams: any = (<any>Object).assign({}, this._defaultHeaders);
1805
+ let localVarFormParams: any = {};
1806
+
1807
+ // verify required parameter 'account' is not null or undefined
1808
+ if (account === null || account === undefined) {
1809
+ throw new Error('Required parameter account was null or undefined when calling matchedOffersControllerPromotionsbybuyer.');
1810
+ }
1811
+
1812
+ (<any>Object).assign(localVarHeaderParams, options.headers);
1813
+
1814
+ let localVarUseFormData = false;
1815
+
1816
+ let localVarRequestOptions: localVarRequest.Options = {
1817
+ method: 'GET',
1818
+ qs: localVarQueryParameters,
1819
+ headers: localVarHeaderParams,
1820
+ uri: localVarPath,
1821
+ useQuerystring: this._useQuerystring,
1822
+ json: true,
1823
+ };
1824
+
1825
+ let authenticationPromise = Promise.resolve();
1826
+ authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1827
+
1828
+ let interceptorPromise = authenticationPromise;
1829
+ for (const interceptor of this.interceptors) {
1830
+ interceptorPromise = interceptorPromise.then(() => interceptor(localVarRequestOptions));
1831
+ }
1832
+
1833
+ return interceptorPromise.then(() => {
1834
+ if (Object.keys(localVarFormParams).length) {
1835
+ if (localVarUseFormData) {
1836
+ (<any>localVarRequestOptions).formData = localVarFormParams;
1837
+ } else {
1838
+ localVarRequestOptions.form = localVarFormParams;
1839
+ }
1840
+ }
1841
+ return new Promise<{ response: http.IncomingMessage; body?: any; }>((resolve, reject) => {
1842
+ localVarRequest(localVarRequestOptions, (error, response, body) => {
1843
+ if (error) {
1844
+ reject(error);
1845
+ } else {
1846
+ if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1847
+ resolve({ response: response, body: body });
1848
+ } else {
1849
+ reject(new HttpError(response, body, response.statusCode));
1850
+ }
1851
+ }
1852
+ });
1853
+ });
1854
+ });
1855
+ }
1596
1856
  /**
1597
1857
  *
1598
1858
  * @summary Removes the matched offer with the provided ID