@emilgroup/discount-sdk 1.5.1 → 1.7.0

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 (150) hide show
  1. package/.openapi-generator/FILES +54 -0
  2. package/.openapi-generator/VERSION +1 -0
  3. package/.openapi-generator-ignore +23 -0
  4. package/README.md +2 -2
  5. package/api/campaigns-api.ts +1433 -0
  6. package/api/default-api.ts +124 -0
  7. package/api/policy-vouchers-api.ts +999 -0
  8. package/api/vouchers-api.ts +691 -0
  9. package/api.ts +33 -0
  10. package/base.ts +331 -0
  11. package/common.ts +198 -0
  12. package/configuration.ts +110 -0
  13. package/dist/api/campaigns-api.d.ts +808 -0
  14. package/dist/api/campaigns-api.js +1251 -0
  15. package/dist/api/default-api.d.ts +70 -0
  16. package/dist/api/default-api.js +200 -0
  17. package/dist/api/policy-vouchers-api.d.ts +555 -0
  18. package/dist/api/policy-vouchers-api.js +915 -0
  19. package/dist/api/vouchers-api.d.ts +393 -0
  20. package/dist/api/vouchers-api.js +642 -0
  21. package/dist/api.d.ts +15 -0
  22. package/dist/api.js +33 -0
  23. package/dist/base.d.ts +86 -0
  24. package/dist/base.js +367 -0
  25. package/dist/common.d.ts +91 -0
  26. package/dist/common.js +276 -0
  27. package/dist/configuration.d.ts +89 -0
  28. package/dist/configuration.js +52 -0
  29. package/dist/index.d.ts +15 -0
  30. package/dist/index.js +36 -0
  31. package/dist/models/campaign-class.d.ts +105 -0
  32. package/dist/models/campaign-class.js +24 -0
  33. package/dist/models/charge-policy-voucher-request-dto.d.ts +48 -0
  34. package/dist/models/charge-policy-voucher-request-dto.js +15 -0
  35. package/dist/models/charge-policy-voucher-response-class.d.ts +96 -0
  36. package/dist/models/charge-policy-voucher-response-class.js +21 -0
  37. package/dist/models/check-account-eligibility-request-dto.d.ts +48 -0
  38. package/dist/models/check-account-eligibility-request-dto.js +15 -0
  39. package/dist/models/check-account-eligibility-response-class.d.ts +57 -0
  40. package/dist/models/check-account-eligibility-response-class.js +24 -0
  41. package/dist/models/create-campaign-request-dto.d.ts +42 -0
  42. package/dist/models/create-campaign-request-dto.js +15 -0
  43. package/dist/models/create-campaign-response-class.d.ts +25 -0
  44. package/dist/models/create-campaign-response-class.js +15 -0
  45. package/dist/models/create-eligible-account-request-dto.d.ts +30 -0
  46. package/dist/models/create-eligible-account-request-dto.js +15 -0
  47. package/dist/models/create-eligible-account-response-class.d.ts +25 -0
  48. package/dist/models/create-eligible-account-response-class.js +15 -0
  49. package/dist/models/create-policy-voucher-request-dto.d.ts +48 -0
  50. package/dist/models/create-policy-voucher-request-dto.js +15 -0
  51. package/dist/models/create-policy-voucher-response-class.d.ts +25 -0
  52. package/dist/models/create-policy-voucher-response-class.js +15 -0
  53. package/dist/models/create-product-discount-dto.d.ts +48 -0
  54. package/dist/models/create-product-discount-dto.js +15 -0
  55. package/dist/models/create-voucher-request-dto.d.ts +66 -0
  56. package/dist/models/create-voucher-request-dto.js +20 -0
  57. package/dist/models/create-voucher-response-class.d.ts +25 -0
  58. package/dist/models/create-voucher-response-class.js +15 -0
  59. package/dist/models/eligible-account-class.d.ts +78 -0
  60. package/dist/models/eligible-account-class.js +15 -0
  61. package/dist/models/get-campaign-response-class.d.ts +25 -0
  62. package/dist/models/get-campaign-response-class.js +15 -0
  63. package/dist/models/get-policy-voucher-response-class.d.ts +25 -0
  64. package/dist/models/get-policy-voucher-response-class.js +15 -0
  65. package/dist/models/get-voucher-response-class.d.ts +25 -0
  66. package/dist/models/get-voucher-response-class.js +15 -0
  67. package/dist/models/index.d.ts +37 -0
  68. package/dist/models/index.js +53 -0
  69. package/dist/models/inline-response200.d.ts +54 -0
  70. package/dist/models/inline-response200.js +15 -0
  71. package/dist/models/inline-response503.d.ts +54 -0
  72. package/dist/models/inline-response503.js +15 -0
  73. package/dist/models/list-campaigns-response-class.d.ts +43 -0
  74. package/dist/models/list-campaigns-response-class.js +15 -0
  75. package/dist/models/list-eligible-accounts-response-class.d.ts +43 -0
  76. package/dist/models/list-eligible-accounts-response-class.js +15 -0
  77. package/dist/models/list-policy-vouchers-response-class.d.ts +43 -0
  78. package/dist/models/list-policy-vouchers-response-class.js +15 -0
  79. package/dist/models/list-vouchers-response-class.d.ts +43 -0
  80. package/dist/models/list-vouchers-response-class.js +15 -0
  81. package/dist/models/policy-voucher-class.d.ts +165 -0
  82. package/dist/models/policy-voucher-class.js +21 -0
  83. package/dist/models/policy-voucher-transaction-class.d.ts +126 -0
  84. package/dist/models/policy-voucher-transaction-class.js +26 -0
  85. package/dist/models/product-discount-class.d.ts +90 -0
  86. package/dist/models/product-discount-class.js +15 -0
  87. package/dist/models/redeem-policy-voucher-request-dto.d.ts +48 -0
  88. package/dist/models/redeem-policy-voucher-request-dto.js +15 -0
  89. package/dist/models/redeem-policy-voucher-response-class.d.ts +84 -0
  90. package/dist/models/redeem-policy-voucher-response-class.js +21 -0
  91. package/dist/models/update-campaign-request-dto.d.ts +42 -0
  92. package/dist/models/update-campaign-request-dto.js +15 -0
  93. package/dist/models/update-campaign-response-class.d.ts +25 -0
  94. package/dist/models/update-campaign-response-class.js +15 -0
  95. package/dist/models/update-campaign-status-request-dto.d.ts +33 -0
  96. package/dist/models/update-campaign-status-request-dto.js +24 -0
  97. package/dist/models/update-voucher-request-dto.d.ts +60 -0
  98. package/dist/models/update-voucher-request-dto.js +20 -0
  99. package/dist/models/update-voucher-response-class.d.ts +25 -0
  100. package/dist/models/update-voucher-response-class.js +15 -0
  101. package/dist/models/voucher-class.d.ts +127 -0
  102. package/dist/models/voucher-class.js +20 -0
  103. package/dist/models/withdraw-policy-voucher-request-dto.d.ts +36 -0
  104. package/dist/models/withdraw-policy-voucher-request-dto.js +15 -0
  105. package/dist/models/withdraw-policy-voucher-response-class.d.ts +78 -0
  106. package/dist/models/withdraw-policy-voucher-response-class.js +21 -0
  107. package/git_push.sh +57 -0
  108. package/index.ts +19 -0
  109. package/models/campaign-class.ts +114 -0
  110. package/models/charge-policy-voucher-request-dto.ts +54 -0
  111. package/models/charge-policy-voucher-response-class.ts +105 -0
  112. package/models/check-account-eligibility-request-dto.ts +54 -0
  113. package/models/check-account-eligibility-response-class.ts +66 -0
  114. package/models/create-campaign-request-dto.ts +48 -0
  115. package/models/create-campaign-response-class.ts +31 -0
  116. package/models/create-eligible-account-request-dto.ts +36 -0
  117. package/models/create-eligible-account-response-class.ts +31 -0
  118. package/models/create-policy-voucher-request-dto.ts +54 -0
  119. package/models/create-policy-voucher-response-class.ts +31 -0
  120. package/models/create-product-discount-dto.ts +54 -0
  121. package/models/create-voucher-request-dto.ts +75 -0
  122. package/models/create-voucher-response-class.ts +31 -0
  123. package/models/eligible-account-class.ts +84 -0
  124. package/models/get-campaign-response-class.ts +31 -0
  125. package/models/get-policy-voucher-response-class.ts +31 -0
  126. package/models/get-voucher-response-class.ts +31 -0
  127. package/models/index.ts +37 -0
  128. package/models/inline-response200.ts +48 -0
  129. package/models/inline-response503.ts +48 -0
  130. package/models/list-campaigns-response-class.ts +49 -0
  131. package/models/list-eligible-accounts-response-class.ts +49 -0
  132. package/models/list-policy-vouchers-response-class.ts +49 -0
  133. package/models/list-vouchers-response-class.ts +49 -0
  134. package/models/policy-voucher-class.ts +174 -0
  135. package/models/policy-voucher-transaction-class.ts +136 -0
  136. package/models/product-discount-class.ts +96 -0
  137. package/models/redeem-policy-voucher-request-dto.ts +54 -0
  138. package/models/redeem-policy-voucher-response-class.ts +93 -0
  139. package/models/update-campaign-request-dto.ts +48 -0
  140. package/models/update-campaign-response-class.ts +31 -0
  141. package/models/update-campaign-status-request-dto.ts +42 -0
  142. package/models/update-voucher-request-dto.ts +69 -0
  143. package/models/update-voucher-response-class.ts +31 -0
  144. package/models/voucher-class.ts +136 -0
  145. package/models/withdraw-policy-voucher-request-dto.ts +42 -0
  146. package/models/withdraw-policy-voucher-response-class.ts +87 -0
  147. package/package.json +22 -8
  148. package/tsconfig.json +23 -0
  149. package/index.js +0 -99
  150. package/scripts/deploy.js +0 -225
@@ -0,0 +1,393 @@
1
+ /**
2
+ * EMIL DiscountService
3
+ * The EMIL DiscountService API description
4
+ *
5
+ * The version of the OpenAPI document: 1.0
6
+ * Contact: kontakt@emil.de
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
13
+ import { Configuration } from '../configuration';
14
+ import { RequestArgs, BaseAPI } from '../base';
15
+ import { CreateVoucherRequestDto } from '../models';
16
+ import { CreateVoucherResponseClass } from '../models';
17
+ import { GetVoucherResponseClass } from '../models';
18
+ import { ListVouchersResponseClass } from '../models';
19
+ import { UpdateVoucherRequestDto } from '../models';
20
+ import { UpdateVoucherResponseClass } from '../models';
21
+ /**
22
+ * VouchersApi - axios parameter creator
23
+ * @export
24
+ */
25
+ export declare const VouchersApiAxiosParamCreator: (configuration?: Configuration) => {
26
+ /**
27
+ * This will create a voucher.
28
+ * @summary Create the Voucher
29
+ * @param {CreateVoucherRequestDto} createVoucherRequestDto
30
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
31
+ * @param {*} [options] Override http request option.
32
+ * @throws {RequiredError}
33
+ */
34
+ createVoucher: (createVoucherRequestDto: CreateVoucherRequestDto, authorization?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
35
+ /**
36
+ * This will delete a voucher.
37
+ * @summary Delete the Voucher
38
+ * @param {string} code Unique identifier for the object.
39
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
40
+ * @param {*} [options] Override http request option.
41
+ * @throws {RequiredError}
42
+ */
43
+ deleteVoucher: (code: string, authorization?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
44
+ /**
45
+ * This will get a voucher.
46
+ * @summary Retrieve the Voucher
47
+ * @param {string} code Unique identifier for the object.
48
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
49
+ * @param {'campaign' | 'productDiscounts'} [expand] You can expand voucher in this endpoint.
50
+ * @param {*} [options] Override http request option.
51
+ * @throws {RequiredError}
52
+ */
53
+ getVoucher: (code: string, authorization?: string, expand?: 'campaign' | 'productDiscounts', options?: AxiosRequestConfig) => Promise<RequestArgs>;
54
+ /**
55
+ * Returns a list of Vouchers you have previously created. The Vouchers are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
56
+ * @summary List Vouchers
57
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
58
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
59
+ * @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
60
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, voucherCode, campaignId, discountType, createdAt, discountValue, discountPeriodMonths, productDiscounts.productSlug&lt;/i&gt;
61
+ * @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Searchable fields: code, voucherCode, productSlugsList&lt;/i&gt;
62
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: code, voucherCode, campaignId, discountPeriodMonths, discountType, discountValue, createdAt&lt;/i&gt;
63
+ * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: campaign, productDiscounts&lt;i&gt;
64
+ * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, voucherCode, campaignId, discountType, createdAt, discountValue, discountPeriodMonths, productDiscounts.productSlug&lt;/i&gt;
65
+ * @param {*} [options] Override http request option.
66
+ * @throws {RequiredError}
67
+ */
68
+ listVouchers: (authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
69
+ /**
70
+ * This will update a voucher.
71
+ * @summary Update the Voucher
72
+ * @param {string} code Unique identifier for the object.
73
+ * @param {UpdateVoucherRequestDto} updateVoucherRequestDto
74
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
75
+ * @param {*} [options] Override http request option.
76
+ * @throws {RequiredError}
77
+ */
78
+ updateVoucher: (code: string, updateVoucherRequestDto: UpdateVoucherRequestDto, authorization?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
79
+ };
80
+ /**
81
+ * VouchersApi - functional programming interface
82
+ * @export
83
+ */
84
+ export declare const VouchersApiFp: (configuration?: Configuration) => {
85
+ /**
86
+ * This will create a voucher.
87
+ * @summary Create the Voucher
88
+ * @param {CreateVoucherRequestDto} createVoucherRequestDto
89
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
90
+ * @param {*} [options] Override http request option.
91
+ * @throws {RequiredError}
92
+ */
93
+ createVoucher(createVoucherRequestDto: CreateVoucherRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateVoucherResponseClass>>;
94
+ /**
95
+ * This will delete a voucher.
96
+ * @summary Delete the Voucher
97
+ * @param {string} code Unique identifier for the object.
98
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
99
+ * @param {*} [options] Override http request option.
100
+ * @throws {RequiredError}
101
+ */
102
+ deleteVoucher(code: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
103
+ /**
104
+ * This will get a voucher.
105
+ * @summary Retrieve the Voucher
106
+ * @param {string} code Unique identifier for the object.
107
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
108
+ * @param {'campaign' | 'productDiscounts'} [expand] You can expand voucher in this endpoint.
109
+ * @param {*} [options] Override http request option.
110
+ * @throws {RequiredError}
111
+ */
112
+ getVoucher(code: string, authorization?: string, expand?: 'campaign' | 'productDiscounts', options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetVoucherResponseClass>>;
113
+ /**
114
+ * Returns a list of Vouchers you have previously created. The Vouchers are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
115
+ * @summary List Vouchers
116
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
117
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
118
+ * @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
119
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, voucherCode, campaignId, discountType, createdAt, discountValue, discountPeriodMonths, productDiscounts.productSlug&lt;/i&gt;
120
+ * @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Searchable fields: code, voucherCode, productSlugsList&lt;/i&gt;
121
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: code, voucherCode, campaignId, discountPeriodMonths, discountType, discountValue, createdAt&lt;/i&gt;
122
+ * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: campaign, productDiscounts&lt;i&gt;
123
+ * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, voucherCode, campaignId, discountType, createdAt, discountValue, discountPeriodMonths, productDiscounts.productSlug&lt;/i&gt;
124
+ * @param {*} [options] Override http request option.
125
+ * @throws {RequiredError}
126
+ */
127
+ listVouchers(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ListVouchersResponseClass>>;
128
+ /**
129
+ * This will update a voucher.
130
+ * @summary Update the Voucher
131
+ * @param {string} code Unique identifier for the object.
132
+ * @param {UpdateVoucherRequestDto} updateVoucherRequestDto
133
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
134
+ * @param {*} [options] Override http request option.
135
+ * @throws {RequiredError}
136
+ */
137
+ updateVoucher(code: string, updateVoucherRequestDto: UpdateVoucherRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UpdateVoucherResponseClass>>;
138
+ };
139
+ /**
140
+ * VouchersApi - factory interface
141
+ * @export
142
+ */
143
+ export declare const VouchersApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
144
+ /**
145
+ * This will create a voucher.
146
+ * @summary Create the Voucher
147
+ * @param {CreateVoucherRequestDto} createVoucherRequestDto
148
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
149
+ * @param {*} [options] Override http request option.
150
+ * @throws {RequiredError}
151
+ */
152
+ createVoucher(createVoucherRequestDto: CreateVoucherRequestDto, authorization?: string, options?: any): AxiosPromise<CreateVoucherResponseClass>;
153
+ /**
154
+ * This will delete a voucher.
155
+ * @summary Delete the Voucher
156
+ * @param {string} code Unique identifier for the object.
157
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
158
+ * @param {*} [options] Override http request option.
159
+ * @throws {RequiredError}
160
+ */
161
+ deleteVoucher(code: string, authorization?: string, options?: any): AxiosPromise<void>;
162
+ /**
163
+ * This will get a voucher.
164
+ * @summary Retrieve the Voucher
165
+ * @param {string} code Unique identifier for the object.
166
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
167
+ * @param {'campaign' | 'productDiscounts'} [expand] You can expand voucher in this endpoint.
168
+ * @param {*} [options] Override http request option.
169
+ * @throws {RequiredError}
170
+ */
171
+ getVoucher(code: string, authorization?: string, expand?: 'campaign' | 'productDiscounts', options?: any): AxiosPromise<GetVoucherResponseClass>;
172
+ /**
173
+ * Returns a list of Vouchers you have previously created. The Vouchers are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
174
+ * @summary List Vouchers
175
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
176
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
177
+ * @param {string} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
178
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, voucherCode, campaignId, discountType, createdAt, discountValue, discountPeriodMonths, productDiscounts.productSlug&lt;/i&gt;
179
+ * @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Searchable fields: code, voucherCode, productSlugsList&lt;/i&gt;
180
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: code, voucherCode, campaignId, discountPeriodMonths, discountType, discountValue, createdAt&lt;/i&gt;
181
+ * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: campaign, productDiscounts&lt;i&gt;
182
+ * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, voucherCode, campaignId, discountType, createdAt, discountValue, discountPeriodMonths, productDiscounts.productSlug&lt;/i&gt;
183
+ * @param {*} [options] Override http request option.
184
+ * @throws {RequiredError}
185
+ */
186
+ listVouchers(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: any): AxiosPromise<ListVouchersResponseClass>;
187
+ /**
188
+ * This will update a voucher.
189
+ * @summary Update the Voucher
190
+ * @param {string} code Unique identifier for the object.
191
+ * @param {UpdateVoucherRequestDto} updateVoucherRequestDto
192
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
193
+ * @param {*} [options] Override http request option.
194
+ * @throws {RequiredError}
195
+ */
196
+ updateVoucher(code: string, updateVoucherRequestDto: UpdateVoucherRequestDto, authorization?: string, options?: any): AxiosPromise<UpdateVoucherResponseClass>;
197
+ };
198
+ /**
199
+ * Request parameters for createVoucher operation in VouchersApi.
200
+ * @export
201
+ * @interface VouchersApiCreateVoucherRequest
202
+ */
203
+ export interface VouchersApiCreateVoucherRequest {
204
+ /**
205
+ *
206
+ * @type {CreateVoucherRequestDto}
207
+ * @memberof VouchersApiCreateVoucher
208
+ */
209
+ readonly createVoucherRequestDto: CreateVoucherRequestDto;
210
+ /**
211
+ * Bearer Token: provided by the login endpoint under the name accessToken.
212
+ * @type {string}
213
+ * @memberof VouchersApiCreateVoucher
214
+ */
215
+ readonly authorization?: string;
216
+ }
217
+ /**
218
+ * Request parameters for deleteVoucher operation in VouchersApi.
219
+ * @export
220
+ * @interface VouchersApiDeleteVoucherRequest
221
+ */
222
+ export interface VouchersApiDeleteVoucherRequest {
223
+ /**
224
+ * Unique identifier for the object.
225
+ * @type {string}
226
+ * @memberof VouchersApiDeleteVoucher
227
+ */
228
+ readonly code: string;
229
+ /**
230
+ * Bearer Token: provided by the login endpoint under the name accessToken.
231
+ * @type {string}
232
+ * @memberof VouchersApiDeleteVoucher
233
+ */
234
+ readonly authorization?: string;
235
+ }
236
+ /**
237
+ * Request parameters for getVoucher operation in VouchersApi.
238
+ * @export
239
+ * @interface VouchersApiGetVoucherRequest
240
+ */
241
+ export interface VouchersApiGetVoucherRequest {
242
+ /**
243
+ * Unique identifier for the object.
244
+ * @type {string}
245
+ * @memberof VouchersApiGetVoucher
246
+ */
247
+ readonly code: string;
248
+ /**
249
+ * Bearer Token: provided by the login endpoint under the name accessToken.
250
+ * @type {string}
251
+ * @memberof VouchersApiGetVoucher
252
+ */
253
+ readonly authorization?: string;
254
+ /**
255
+ * You can expand voucher in this endpoint.
256
+ * @type {'campaign' | 'productDiscounts'}
257
+ * @memberof VouchersApiGetVoucher
258
+ */
259
+ readonly expand?: 'campaign' | 'productDiscounts';
260
+ }
261
+ /**
262
+ * Request parameters for listVouchers operation in VouchersApi.
263
+ * @export
264
+ * @interface VouchersApiListVouchersRequest
265
+ */
266
+ export interface VouchersApiListVouchersRequest {
267
+ /**
268
+ * Bearer Token: provided by the login endpoint under the name accessToken.
269
+ * @type {string}
270
+ * @memberof VouchersApiListVouchers
271
+ */
272
+ readonly authorization?: string;
273
+ /**
274
+ * A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
275
+ * @type {number}
276
+ * @memberof VouchersApiListVouchers
277
+ */
278
+ readonly pageSize?: number;
279
+ /**
280
+ * A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
281
+ * @type {string}
282
+ * @memberof VouchersApiListVouchers
283
+ */
284
+ readonly pageToken?: string;
285
+ /**
286
+ * Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, voucherCode, campaignId, discountType, createdAt, discountValue, discountPeriodMonths, productDiscounts.productSlug&lt;/i&gt;
287
+ * @type {string}
288
+ * @memberof VouchersApiListVouchers
289
+ */
290
+ readonly filter?: string;
291
+ /**
292
+ * Search the response for matches in any searchable field. Use filter instead where possible for improved performance.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Searchable fields: code, voucherCode, productSlugsList&lt;/i&gt;
293
+ * @type {string}
294
+ * @memberof VouchersApiListVouchers
295
+ */
296
+ readonly search?: string;
297
+ /**
298
+ * Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: code, voucherCode, campaignId, discountPeriodMonths, discountType, discountValue, createdAt&lt;/i&gt;
299
+ * @type {string}
300
+ * @memberof VouchersApiListVouchers
301
+ */
302
+ readonly order?: string;
303
+ /**
304
+ * Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: campaign, productDiscounts&lt;i&gt;
305
+ * @type {string}
306
+ * @memberof VouchersApiListVouchers
307
+ */
308
+ readonly expand?: string;
309
+ /**
310
+ * Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, voucherCode, campaignId, discountType, createdAt, discountValue, discountPeriodMonths, productDiscounts.productSlug&lt;/i&gt;
311
+ * @type {string}
312
+ * @memberof VouchersApiListVouchers
313
+ */
314
+ readonly filters?: string;
315
+ }
316
+ /**
317
+ * Request parameters for updateVoucher operation in VouchersApi.
318
+ * @export
319
+ * @interface VouchersApiUpdateVoucherRequest
320
+ */
321
+ export interface VouchersApiUpdateVoucherRequest {
322
+ /**
323
+ * Unique identifier for the object.
324
+ * @type {string}
325
+ * @memberof VouchersApiUpdateVoucher
326
+ */
327
+ readonly code: string;
328
+ /**
329
+ *
330
+ * @type {UpdateVoucherRequestDto}
331
+ * @memberof VouchersApiUpdateVoucher
332
+ */
333
+ readonly updateVoucherRequestDto: UpdateVoucherRequestDto;
334
+ /**
335
+ * Bearer Token: provided by the login endpoint under the name accessToken.
336
+ * @type {string}
337
+ * @memberof VouchersApiUpdateVoucher
338
+ */
339
+ readonly authorization?: string;
340
+ }
341
+ /**
342
+ * VouchersApi - object-oriented interface
343
+ * @export
344
+ * @class VouchersApi
345
+ * @extends {BaseAPI}
346
+ */
347
+ export declare class VouchersApi extends BaseAPI {
348
+ /**
349
+ * This will create a voucher.
350
+ * @summary Create the Voucher
351
+ * @param {VouchersApiCreateVoucherRequest} requestParameters Request parameters.
352
+ * @param {*} [options] Override http request option.
353
+ * @throws {RequiredError}
354
+ * @memberof VouchersApi
355
+ */
356
+ createVoucher(requestParameters: VouchersApiCreateVoucherRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateVoucherResponseClass, any, {}>>;
357
+ /**
358
+ * This will delete a voucher.
359
+ * @summary Delete the Voucher
360
+ * @param {VouchersApiDeleteVoucherRequest} requestParameters Request parameters.
361
+ * @param {*} [options] Override http request option.
362
+ * @throws {RequiredError}
363
+ * @memberof VouchersApi
364
+ */
365
+ deleteVoucher(requestParameters: VouchersApiDeleteVoucherRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
366
+ /**
367
+ * This will get a voucher.
368
+ * @summary Retrieve the Voucher
369
+ * @param {VouchersApiGetVoucherRequest} requestParameters Request parameters.
370
+ * @param {*} [options] Override http request option.
371
+ * @throws {RequiredError}
372
+ * @memberof VouchersApi
373
+ */
374
+ getVoucher(requestParameters: VouchersApiGetVoucherRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetVoucherResponseClass, any, {}>>;
375
+ /**
376
+ * Returns a list of Vouchers you have previously created. The Vouchers are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
377
+ * @summary List Vouchers
378
+ * @param {VouchersApiListVouchersRequest} requestParameters Request parameters.
379
+ * @param {*} [options] Override http request option.
380
+ * @throws {RequiredError}
381
+ * @memberof VouchersApi
382
+ */
383
+ listVouchers(requestParameters?: VouchersApiListVouchersRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListVouchersResponseClass, any, {}>>;
384
+ /**
385
+ * This will update a voucher.
386
+ * @summary Update the Voucher
387
+ * @param {VouchersApiUpdateVoucherRequest} requestParameters Request parameters.
388
+ * @param {*} [options] Override http request option.
389
+ * @throws {RequiredError}
390
+ * @memberof VouchersApi
391
+ */
392
+ updateVoucher(requestParameters: VouchersApiUpdateVoucherRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<UpdateVoucherResponseClass, any, {}>>;
393
+ }