@emilgroup/partner-sdk 1.22.1-beta.22 → 1.22.1-beta.24

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 (163) hide show
  1. package/.openapi-generator/FILES +1 -42
  2. package/README.md +2 -2
  3. package/api/blacklist-api.ts +3 -3
  4. package/api/blacklist-reasons-api.ts +3 -3
  5. package/api/{health-api.ts → default-api.ts} +13 -13
  6. package/api/partners-api.ts +12 -119
  7. package/api.ts +2 -8
  8. package/base.ts +0 -1
  9. package/dist/api/blacklist-api.d.ts +4 -4
  10. package/dist/api/blacklist-reasons-api.d.ts +4 -4
  11. package/dist/api/{health-api.d.ts → default-api.d.ts} +10 -10
  12. package/dist/api/{health-api.js → default-api.js} +22 -22
  13. package/dist/api/partners-api.d.ts +12 -69
  14. package/dist/api/partners-api.js +9 -102
  15. package/dist/api.d.ts +1 -4
  16. package/dist/api.js +1 -4
  17. package/dist/base.d.ts +1 -2
  18. package/dist/base.js +0 -1
  19. package/dist/models/index.d.ts +0 -38
  20. package/dist/models/index.js +0 -38
  21. package/dist/models/list-blacklist-items-response-class.d.ts +0 -12
  22. package/dist/models/list-partner-relation-class.d.ts +6 -18
  23. package/dist/models/list-partner-relation-types-class.d.ts +6 -18
  24. package/dist/models/list-partner-types-response-class.d.ts +6 -18
  25. package/dist/models/list-partner-versions-response-class.d.ts +6 -18
  26. package/dist/models/list-partners-response-class.d.ts +6 -18
  27. package/dist/models/list-related-partners-response-class.d.ts +6 -18
  28. package/dist/models/list-tags-response-class.d.ts +6 -18
  29. package/dist/models/update-blacklist-reason-status-request-dto.d.ts +1 -1
  30. package/models/index.ts +0 -38
  31. package/models/list-blacklist-items-response-class.ts +0 -12
  32. package/models/list-partner-relation-class.ts +6 -18
  33. package/models/list-partner-relation-types-class.ts +6 -18
  34. package/models/list-partner-types-response-class.ts +6 -18
  35. package/models/list-partner-versions-response-class.ts +6 -18
  36. package/models/list-partners-response-class.ts +6 -18
  37. package/models/list-related-partners-response-class.ts +6 -18
  38. package/models/list-tags-response-class.ts +6 -18
  39. package/models/update-blacklist-reason-status-request-dto.ts +1 -1
  40. package/package.json +1 -1
  41. package/api/partner-hierarchies-api.ts +0 -1367
  42. package/api/partner-hierarchy-nodes-api.ts +0 -1197
  43. package/api/partner-hierarchy-types-api.ts +0 -679
  44. package/dist/api/partner-hierarchies-api.d.ts +0 -774
  45. package/dist/api/partner-hierarchies-api.js +0 -1171
  46. package/dist/api/partner-hierarchy-nodes-api.d.ts +0 -674
  47. package/dist/api/partner-hierarchy-nodes-api.js +0 -1049
  48. package/dist/api/partner-hierarchy-types-api.d.ts +0 -385
  49. package/dist/api/partner-hierarchy-types-api.js +0 -636
  50. package/dist/models/batch-create-partner-hierarchy-nodes-request-dto.d.ts +0 -30
  51. package/dist/models/batch-create-partner-hierarchy-nodes-request-dto.js +0 -15
  52. package/dist/models/create-partner-hierarchy-node-request-dto.d.ts +0 -42
  53. package/dist/models/create-partner-hierarchy-node-request-dto.js +0 -15
  54. package/dist/models/create-partner-hierarchy-node-response-class.d.ts +0 -25
  55. package/dist/models/create-partner-hierarchy-node-response-class.js +0 -15
  56. package/dist/models/create-partner-hierarchy-request-dto.d.ts +0 -30
  57. package/dist/models/create-partner-hierarchy-request-dto.js +0 -15
  58. package/dist/models/create-partner-hierarchy-response-class.d.ts +0 -25
  59. package/dist/models/create-partner-hierarchy-response-class.js +0 -15
  60. package/dist/models/create-partner-hierarchy-type-request-dto.d.ts +0 -30
  61. package/dist/models/create-partner-hierarchy-type-request-dto.js +0 -15
  62. package/dist/models/create-partner-hierarchy-type-response-class.d.ts +0 -25
  63. package/dist/models/create-partner-hierarchy-type-response-class.js +0 -15
  64. package/dist/models/delete-by-code-response-class.d.ts +0 -24
  65. package/dist/models/delete-by-code-response-class.js +0 -15
  66. package/dist/models/generate-upload-url-response-class.d.ts +0 -36
  67. package/dist/models/generate-upload-url-response-class.js +0 -15
  68. package/dist/models/get-partner-hierarchy-node-response-class.d.ts +0 -25
  69. package/dist/models/get-partner-hierarchy-node-response-class.js +0 -15
  70. package/dist/models/get-partner-hierarchy-response-class.d.ts +0 -25
  71. package/dist/models/get-partner-hierarchy-response-class.js +0 -15
  72. package/dist/models/get-partner-hierarchy-tree-file-response-class.d.ts +0 -42
  73. package/dist/models/get-partner-hierarchy-tree-file-response-class.js +0 -15
  74. package/dist/models/get-partner-hierarchy-tree-response-class.d.ts +0 -25
  75. package/dist/models/get-partner-hierarchy-tree-response-class.js +0 -15
  76. package/dist/models/get-partner-hierarchy-type-response-class.d.ts +0 -25
  77. package/dist/models/get-partner-hierarchy-type-response-class.js +0 -15
  78. package/dist/models/list-partner-hierarchies-response-class.d.ts +0 -43
  79. package/dist/models/list-partner-hierarchies-response-class.js +0 -15
  80. package/dist/models/list-partner-hierarchy-node-history-response-class.d.ts +0 -43
  81. package/dist/models/list-partner-hierarchy-node-history-response-class.js +0 -15
  82. package/dist/models/list-partner-hierarchy-nodes-response-class.d.ts +0 -43
  83. package/dist/models/list-partner-hierarchy-nodes-response-class.js +0 -15
  84. package/dist/models/list-partner-hierarchy-operations-response-class.d.ts +0 -43
  85. package/dist/models/list-partner-hierarchy-operations-response-class.js +0 -15
  86. package/dist/models/list-partner-hierarchy-types-response-class.d.ts +0 -43
  87. package/dist/models/list-partner-hierarchy-types-response-class.js +0 -15
  88. package/dist/models/move-partner-hierarchy-node-request-dto.d.ts +0 -30
  89. package/dist/models/move-partner-hierarchy-node-request-dto.js +0 -15
  90. package/dist/models/move-partner-hierarchy-node-response-class.d.ts +0 -25
  91. package/dist/models/move-partner-hierarchy-node-response-class.js +0 -15
  92. package/dist/models/partner-hierarchy-async-operation-response-class.d.ts +0 -30
  93. package/dist/models/partner-hierarchy-async-operation-response-class.js +0 -15
  94. package/dist/models/partner-hierarchy-class.d.ts +0 -78
  95. package/dist/models/partner-hierarchy-class.js +0 -15
  96. package/dist/models/partner-hierarchy-node-class.d.ts +0 -109
  97. package/dist/models/partner-hierarchy-node-class.js +0 -15
  98. package/dist/models/partner-hierarchy-node-history-class.d.ts +0 -97
  99. package/dist/models/partner-hierarchy-node-history-class.js +0 -15
  100. package/dist/models/partner-hierarchy-node-tree-class.d.ts +0 -96
  101. package/dist/models/partner-hierarchy-node-tree-class.js +0 -15
  102. package/dist/models/partner-hierarchy-operation-class.d.ts +0 -90
  103. package/dist/models/partner-hierarchy-operation-class.js +0 -15
  104. package/dist/models/partner-hierarchy-type-class.d.ts +0 -66
  105. package/dist/models/partner-hierarchy-type-class.js +0 -15
  106. package/dist/models/unassign-partner-hierarchy-node-response-class.d.ts +0 -25
  107. package/dist/models/unassign-partner-hierarchy-node-response-class.js +0 -15
  108. package/dist/models/update-partner-hierarchy-node-request-dto.d.ts +0 -30
  109. package/dist/models/update-partner-hierarchy-node-request-dto.js +0 -15
  110. package/dist/models/update-partner-hierarchy-node-response-class.d.ts +0 -25
  111. package/dist/models/update-partner-hierarchy-node-response-class.js +0 -15
  112. package/dist/models/update-partner-hierarchy-request-dto.d.ts +0 -24
  113. package/dist/models/update-partner-hierarchy-request-dto.js +0 -15
  114. package/dist/models/update-partner-hierarchy-response-class.d.ts +0 -25
  115. package/dist/models/update-partner-hierarchy-response-class.js +0 -15
  116. package/dist/models/update-partner-hierarchy-tree-request-body-dto.d.ts +0 -24
  117. package/dist/models/update-partner-hierarchy-tree-request-body-dto.js +0 -15
  118. package/dist/models/update-partner-hierarchy-type-request-dto.d.ts +0 -30
  119. package/dist/models/update-partner-hierarchy-type-request-dto.js +0 -15
  120. package/dist/models/update-partner-hierarchy-type-response-class.d.ts +0 -25
  121. package/dist/models/update-partner-hierarchy-type-response-class.js +0 -15
  122. package/dist/models/validate-partner-request-dto.d.ts +0 -30
  123. package/dist/models/validate-partner-request-dto.js +0 -15
  124. package/dist/models/validate-partner-response-class.d.ts +0 -30
  125. package/dist/models/validate-partner-response-class.js +0 -15
  126. package/models/batch-create-partner-hierarchy-nodes-request-dto.ts +0 -36
  127. package/models/create-partner-hierarchy-node-request-dto.ts +0 -48
  128. package/models/create-partner-hierarchy-node-response-class.ts +0 -31
  129. package/models/create-partner-hierarchy-request-dto.ts +0 -36
  130. package/models/create-partner-hierarchy-response-class.ts +0 -31
  131. package/models/create-partner-hierarchy-type-request-dto.ts +0 -36
  132. package/models/create-partner-hierarchy-type-response-class.ts +0 -31
  133. package/models/delete-by-code-response-class.ts +0 -30
  134. package/models/generate-upload-url-response-class.ts +0 -42
  135. package/models/get-partner-hierarchy-node-response-class.ts +0 -31
  136. package/models/get-partner-hierarchy-response-class.ts +0 -31
  137. package/models/get-partner-hierarchy-tree-file-response-class.ts +0 -48
  138. package/models/get-partner-hierarchy-tree-response-class.ts +0 -31
  139. package/models/get-partner-hierarchy-type-response-class.ts +0 -31
  140. package/models/list-partner-hierarchies-response-class.ts +0 -49
  141. package/models/list-partner-hierarchy-node-history-response-class.ts +0 -49
  142. package/models/list-partner-hierarchy-nodes-response-class.ts +0 -49
  143. package/models/list-partner-hierarchy-operations-response-class.ts +0 -49
  144. package/models/list-partner-hierarchy-types-response-class.ts +0 -49
  145. package/models/move-partner-hierarchy-node-request-dto.ts +0 -36
  146. package/models/move-partner-hierarchy-node-response-class.ts +0 -31
  147. package/models/partner-hierarchy-async-operation-response-class.ts +0 -36
  148. package/models/partner-hierarchy-class.ts +0 -84
  149. package/models/partner-hierarchy-node-class.ts +0 -115
  150. package/models/partner-hierarchy-node-history-class.ts +0 -103
  151. package/models/partner-hierarchy-node-tree-class.ts +0 -102
  152. package/models/partner-hierarchy-operation-class.ts +0 -96
  153. package/models/partner-hierarchy-type-class.ts +0 -72
  154. package/models/unassign-partner-hierarchy-node-response-class.ts +0 -31
  155. package/models/update-partner-hierarchy-node-request-dto.ts +0 -36
  156. package/models/update-partner-hierarchy-node-response-class.ts +0 -31
  157. package/models/update-partner-hierarchy-request-dto.ts +0 -30
  158. package/models/update-partner-hierarchy-response-class.ts +0 -31
  159. package/models/update-partner-hierarchy-tree-request-body-dto.ts +0 -30
  160. package/models/update-partner-hierarchy-type-request-dto.ts +0 -36
  161. package/models/update-partner-hierarchy-type-response-class.ts +0 -31
  162. package/models/validate-partner-request-dto.ts +0 -36
  163. package/models/validate-partner-response-class.ts +0 -36
@@ -1,1049 +0,0 @@
1
- "use strict";
2
- /* tslint:disable */
3
- /* eslint-disable */
4
- /**
5
- * EMIL PartnerService
6
- * The EMIL PartnerService API description
7
- *
8
- * The version of the OpenAPI document: 1.0
9
- * Contact: kontakt@emil.de
10
- *
11
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
- * https://openapi-generator.tech
13
- * Do not edit the class manually.
14
- */
15
- var __extends = (this && this.__extends) || (function () {
16
- var extendStatics = function (d, b) {
17
- extendStatics = Object.setPrototypeOf ||
18
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
19
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
20
- return extendStatics(d, b);
21
- };
22
- return function (d, b) {
23
- if (typeof b !== "function" && b !== null)
24
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
25
- extendStatics(d, b);
26
- function __() { this.constructor = d; }
27
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
28
- };
29
- })();
30
- var __assign = (this && this.__assign) || function () {
31
- __assign = Object.assign || function(t) {
32
- for (var s, i = 1, n = arguments.length; i < n; i++) {
33
- s = arguments[i];
34
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
35
- t[p] = s[p];
36
- }
37
- return t;
38
- };
39
- return __assign.apply(this, arguments);
40
- };
41
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
42
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
43
- return new (P || (P = Promise))(function (resolve, reject) {
44
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
45
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
46
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
47
- step((generator = generator.apply(thisArg, _arguments || [])).next());
48
- });
49
- };
50
- var __generator = (this && this.__generator) || function (thisArg, body) {
51
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
52
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
53
- function verb(n) { return function (v) { return step([n, v]); }; }
54
- function step(op) {
55
- if (f) throw new TypeError("Generator is already executing.");
56
- while (g && (g = 0, op[0] && (_ = 0)), _) try {
57
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
58
- if (y = 0, t) op = [op[0] & 2, t.value];
59
- switch (op[0]) {
60
- case 0: case 1: t = op; break;
61
- case 4: _.label++; return { value: op[1], done: false };
62
- case 5: _.label++; y = op[1]; op = [0]; continue;
63
- case 7: op = _.ops.pop(); _.trys.pop(); continue;
64
- default:
65
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
66
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
67
- if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
68
- if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
69
- if (t[2]) _.ops.pop();
70
- _.trys.pop(); continue;
71
- }
72
- op = body.call(thisArg, _);
73
- } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
74
- if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
75
- }
76
- };
77
- var __importDefault = (this && this.__importDefault) || function (mod) {
78
- return (mod && mod.__esModule) ? mod : { "default": mod };
79
- };
80
- Object.defineProperty(exports, "__esModule", { value: true });
81
- exports.PartnerHierarchyNodesApi = exports.PartnerHierarchyNodesApiFactory = exports.PartnerHierarchyNodesApiFp = exports.PartnerHierarchyNodesApiAxiosParamCreator = void 0;
82
- var axios_1 = __importDefault(require("axios"));
83
- // Some imports not used depending on template conditions
84
- // @ts-ignore
85
- var common_1 = require("../common");
86
- // @ts-ignore
87
- var base_1 = require("../base");
88
- /**
89
- * PartnerHierarchyNodesApi - axios parameter creator
90
- * @export
91
- */
92
- var PartnerHierarchyNodesApiAxiosParamCreator = function (configuration) {
93
- var _this = this;
94
- return {
95
- /**
96
- * Starts batch node creation from an uploaded file and returns the operation status. **Required Permissions** \"partner-management.partners.create\"
97
- * @summary Batch create partner hierarchy nodes
98
- * @param {BatchCreatePartnerHierarchyNodesRequestDto} batchCreatePartnerHierarchyNodesRequestDto
99
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
100
- * @param {*} [options] Override http request option.
101
- * @throws {RequiredError}
102
- */
103
- batchCreatePartnerHierarchyNodes: function (batchCreatePartnerHierarchyNodesRequestDto, authorization, options) {
104
- if (options === void 0) { options = {}; }
105
- return __awaiter(_this, void 0, void 0, function () {
106
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
107
- return __generator(this, function (_a) {
108
- switch (_a.label) {
109
- case 0:
110
- // verify required parameter 'batchCreatePartnerHierarchyNodesRequestDto' is not null or undefined
111
- (0, common_1.assertParamExists)('batchCreatePartnerHierarchyNodes', 'batchCreatePartnerHierarchyNodesRequestDto', batchCreatePartnerHierarchyNodesRequestDto);
112
- localVarPath = "/partnerservice/v1/partner-hierarchy-nodes/batch";
113
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
114
- if (configuration) {
115
- baseOptions = configuration.baseOptions;
116
- baseAccessToken = configuration.accessToken;
117
- }
118
- localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
119
- localVarHeaderParameter = {};
120
- localVarQueryParameter = {};
121
- // authentication bearer required
122
- // http bearer authentication required
123
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
124
- case 1:
125
- // authentication bearer required
126
- // http bearer authentication required
127
- _a.sent();
128
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
129
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
130
- }
131
- localVarHeaderParameter['Content-Type'] = 'application/json';
132
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
133
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
134
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
135
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(batchCreatePartnerHierarchyNodesRequestDto, localVarRequestOptions, configuration);
136
- return [2 /*return*/, {
137
- url: (0, common_1.toPathString)(localVarUrlObj),
138
- options: localVarRequestOptions,
139
- }];
140
- }
141
- });
142
- });
143
- },
144
- /**
145
- * Creates a node in a partner hierarchy. The node can be placed at the top of the hierarchy or under another node, and it can be created with or without an assigned partner. **Required Permissions** \"partner-management.partners.create\"
146
- * @summary Create a partner hierarchy node
147
- * @param {CreatePartnerHierarchyNodeRequestDto} createPartnerHierarchyNodeRequestDto
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
- createPartnerHierarchyNode: function (createPartnerHierarchyNodeRequestDto, authorization, options) {
153
- if (options === void 0) { options = {}; }
154
- return __awaiter(_this, void 0, void 0, function () {
155
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
156
- return __generator(this, function (_a) {
157
- switch (_a.label) {
158
- case 0:
159
- // verify required parameter 'createPartnerHierarchyNodeRequestDto' is not null or undefined
160
- (0, common_1.assertParamExists)('createPartnerHierarchyNode', 'createPartnerHierarchyNodeRequestDto', createPartnerHierarchyNodeRequestDto);
161
- localVarPath = "/partnerservice/v1/partner-hierarchy-nodes";
162
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
163
- if (configuration) {
164
- baseOptions = configuration.baseOptions;
165
- baseAccessToken = configuration.accessToken;
166
- }
167
- localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
168
- localVarHeaderParameter = {};
169
- localVarQueryParameter = {};
170
- // authentication bearer required
171
- // http bearer authentication required
172
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
173
- case 1:
174
- // authentication bearer required
175
- // http bearer authentication required
176
- _a.sent();
177
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
178
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
179
- }
180
- localVarHeaderParameter['Content-Type'] = 'application/json';
181
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
182
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
183
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
184
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(createPartnerHierarchyNodeRequestDto, localVarRequestOptions, configuration);
185
- return [2 /*return*/, {
186
- url: (0, common_1.toPathString)(localVarUrlObj),
187
- options: localVarRequestOptions,
188
- }];
189
- }
190
- });
191
- });
192
- },
193
- /**
194
- * Deletes a partner hierarchy node. The node must have no children before it can be deleted. **Required Permissions** \"partner-management.partners.delete\"
195
- * @summary Delete a partner hierarchy node
196
- * @param {string} code
197
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
198
- * @param {*} [options] Override http request option.
199
- * @throws {RequiredError}
200
- */
201
- deletePartnerHierarchyNode: function (code, authorization, options) {
202
- if (options === void 0) { options = {}; }
203
- return __awaiter(_this, void 0, void 0, function () {
204
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
205
- return __generator(this, function (_a) {
206
- switch (_a.label) {
207
- case 0:
208
- // verify required parameter 'code' is not null or undefined
209
- (0, common_1.assertParamExists)('deletePartnerHierarchyNode', 'code', code);
210
- localVarPath = "/partnerservice/v1/partner-hierarchy-nodes/{code}"
211
- .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
212
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
213
- if (configuration) {
214
- baseOptions = configuration.baseOptions;
215
- baseAccessToken = configuration.accessToken;
216
- }
217
- localVarRequestOptions = __assign(__assign({ method: 'DELETE' }, baseOptions), options);
218
- localVarHeaderParameter = {};
219
- localVarQueryParameter = {};
220
- // authentication bearer required
221
- // http bearer authentication required
222
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
223
- case 1:
224
- // authentication bearer required
225
- // http bearer authentication required
226
- _a.sent();
227
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
228
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
229
- }
230
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
231
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
232
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
233
- return [2 /*return*/, {
234
- url: (0, common_1.toPathString)(localVarUrlObj),
235
- options: localVarRequestOptions,
236
- }];
237
- }
238
- });
239
- });
240
- },
241
- /**
242
- * Returns the details of one partner hierarchy node. Partner and parent node details can be included when needed. **Required Permissions** \"partner-management.partners.view\"
243
- * @summary Get a partner hierarchy node
244
- * @param {string} code
245
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
246
- * @param {*} [options] Override http request option.
247
- * @throws {RequiredError}
248
- */
249
- getPartnerHierarchyNode: function (code, authorization, options) {
250
- if (options === void 0) { options = {}; }
251
- return __awaiter(_this, void 0, void 0, function () {
252
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
253
- return __generator(this, function (_a) {
254
- switch (_a.label) {
255
- case 0:
256
- // verify required parameter 'code' is not null or undefined
257
- (0, common_1.assertParamExists)('getPartnerHierarchyNode', 'code', code);
258
- localVarPath = "/partnerservice/v1/partner-hierarchy-nodes/{code}"
259
- .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
260
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
261
- if (configuration) {
262
- baseOptions = configuration.baseOptions;
263
- baseAccessToken = configuration.accessToken;
264
- }
265
- localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
266
- localVarHeaderParameter = {};
267
- localVarQueryParameter = {};
268
- // authentication bearer required
269
- // http bearer authentication required
270
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
271
- case 1:
272
- // authentication bearer required
273
- // http bearer authentication required
274
- _a.sent();
275
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
276
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
277
- }
278
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
279
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
280
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
281
- return [2 /*return*/, {
282
- url: (0, common_1.toPathString)(localVarUrlObj),
283
- options: localVarRequestOptions,
284
- }];
285
- }
286
- });
287
- });
288
- },
289
- /**
290
- * Returns a paginated list of previous versions of partner hierarchy nodes for history review. **Required Permissions** \"partner-management.partners.view\"
291
- * @summary List partner hierarchy node history
292
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
293
- * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
294
- * @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.
295
- * @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: code, partnerHierarchyCode, validFrom&lt;/i&gt;
296
- * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
297
- * @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: id, code, validFrom, validTo, createdAt&lt;/i&gt;
298
- * @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: partner&lt;i&gt;
299
- * @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: code, partnerHierarchyCode, validFrom&lt;/i&gt;
300
- * @param {*} [options] Override http request option.
301
- * @throws {RequiredError}
302
- */
303
- listPartnerHierarchyNodeHistory: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
304
- if (options === void 0) { options = {}; }
305
- return __awaiter(_this, void 0, void 0, function () {
306
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
307
- return __generator(this, function (_a) {
308
- switch (_a.label) {
309
- case 0:
310
- localVarPath = "/partnerservice/v1/partner-hierarchy-nodes/histories";
311
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
312
- if (configuration) {
313
- baseOptions = configuration.baseOptions;
314
- baseAccessToken = configuration.accessToken;
315
- }
316
- localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
317
- localVarHeaderParameter = {};
318
- localVarQueryParameter = {};
319
- // authentication bearer required
320
- // http bearer authentication required
321
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
322
- case 1:
323
- // authentication bearer required
324
- // http bearer authentication required
325
- _a.sent();
326
- if (pageSize !== undefined) {
327
- localVarQueryParameter['pageSize'] = pageSize;
328
- }
329
- if (pageToken !== undefined) {
330
- localVarQueryParameter['pageToken'] = pageToken;
331
- }
332
- if (filter !== undefined) {
333
- localVarQueryParameter['filter'] = filter;
334
- }
335
- if (search !== undefined) {
336
- localVarQueryParameter['search'] = search;
337
- }
338
- if (order !== undefined) {
339
- localVarQueryParameter['order'] = order;
340
- }
341
- if (expand !== undefined) {
342
- localVarQueryParameter['expand'] = expand;
343
- }
344
- if (filters !== undefined) {
345
- localVarQueryParameter['filters'] = filters;
346
- }
347
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
348
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
349
- }
350
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
351
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
352
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
353
- return [2 /*return*/, {
354
- url: (0, common_1.toPathString)(localVarUrlObj),
355
- options: localVarRequestOptions,
356
- }];
357
- }
358
- });
359
- });
360
- },
361
- /**
362
- * Returns a paginated list of partner hierarchy nodes. **Required Permissions** \"partner-management.partners.view\"
363
- * @summary List partner hierarchy nodes
364
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
365
- * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
366
- * @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.
367
- * @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: code, partnerHierarchyCode, partnerCode, parentNodeCode, roleCode, depth, createdAt, updatedAt&lt;/i&gt;
368
- * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
369
- * @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: id, code, depth, createdAt, updatedAt&lt;/i&gt;
370
- * @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: partner, parentNode&lt;i&gt;
371
- * @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: code, partnerHierarchyCode, partnerCode, parentNodeCode, roleCode, depth, createdAt, updatedAt&lt;/i&gt;
372
- * @param {*} [options] Override http request option.
373
- * @throws {RequiredError}
374
- */
375
- listPartnerHierarchyNodes: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
376
- if (options === void 0) { options = {}; }
377
- return __awaiter(_this, void 0, void 0, function () {
378
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
379
- return __generator(this, function (_a) {
380
- switch (_a.label) {
381
- case 0:
382
- localVarPath = "/partnerservice/v1/partner-hierarchy-nodes";
383
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
384
- if (configuration) {
385
- baseOptions = configuration.baseOptions;
386
- baseAccessToken = configuration.accessToken;
387
- }
388
- localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
389
- localVarHeaderParameter = {};
390
- localVarQueryParameter = {};
391
- // authentication bearer required
392
- // http bearer authentication required
393
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
394
- case 1:
395
- // authentication bearer required
396
- // http bearer authentication required
397
- _a.sent();
398
- if (pageSize !== undefined) {
399
- localVarQueryParameter['pageSize'] = pageSize;
400
- }
401
- if (pageToken !== undefined) {
402
- localVarQueryParameter['pageToken'] = pageToken;
403
- }
404
- if (filter !== undefined) {
405
- localVarQueryParameter['filter'] = filter;
406
- }
407
- if (search !== undefined) {
408
- localVarQueryParameter['search'] = search;
409
- }
410
- if (order !== undefined) {
411
- localVarQueryParameter['order'] = order;
412
- }
413
- if (expand !== undefined) {
414
- localVarQueryParameter['expand'] = expand;
415
- }
416
- if (filters !== undefined) {
417
- localVarQueryParameter['filters'] = filters;
418
- }
419
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
420
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
421
- }
422
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
423
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
424
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
425
- return [2 /*return*/, {
426
- url: (0, common_1.toPathString)(localVarUrlObj),
427
- options: localVarRequestOptions,
428
- }];
429
- }
430
- });
431
- });
432
- },
433
- /**
434
- * Moves a node under another parent at the same level in the same hierarchy. Any nodes below it move with it. **Required Permissions** \"partner-management.partners.update\"
435
- * @summary Move a partner hierarchy node to a new parent
436
- * @param {string} code
437
- * @param {MovePartnerHierarchyNodeRequestDto} movePartnerHierarchyNodeRequestDto
438
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
439
- * @param {*} [options] Override http request option.
440
- * @throws {RequiredError}
441
- */
442
- movePartnerHierarchyNode: function (code, movePartnerHierarchyNodeRequestDto, authorization, options) {
443
- if (options === void 0) { options = {}; }
444
- return __awaiter(_this, void 0, void 0, function () {
445
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
446
- return __generator(this, function (_a) {
447
- switch (_a.label) {
448
- case 0:
449
- // verify required parameter 'code' is not null or undefined
450
- (0, common_1.assertParamExists)('movePartnerHierarchyNode', 'code', code);
451
- // verify required parameter 'movePartnerHierarchyNodeRequestDto' is not null or undefined
452
- (0, common_1.assertParamExists)('movePartnerHierarchyNode', 'movePartnerHierarchyNodeRequestDto', movePartnerHierarchyNodeRequestDto);
453
- localVarPath = "/partnerservice/v1/partner-hierarchy-nodes/{code}/move"
454
- .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
455
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
456
- if (configuration) {
457
- baseOptions = configuration.baseOptions;
458
- baseAccessToken = configuration.accessToken;
459
- }
460
- localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
461
- localVarHeaderParameter = {};
462
- localVarQueryParameter = {};
463
- // authentication bearer required
464
- // http bearer authentication required
465
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
466
- case 1:
467
- // authentication bearer required
468
- // http bearer authentication required
469
- _a.sent();
470
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
471
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
472
- }
473
- localVarHeaderParameter['Content-Type'] = 'application/json';
474
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
475
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
476
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
477
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(movePartnerHierarchyNodeRequestDto, localVarRequestOptions, configuration);
478
- return [2 /*return*/, {
479
- url: (0, common_1.toPathString)(localVarUrlObj),
480
- options: localVarRequestOptions,
481
- }];
482
- }
483
- });
484
- });
485
- },
486
- /**
487
- * Removes the partner assigned to a partner hierarchy node while keeping the node in the tree. **Required Permissions** \"partner-management.partners.update\"
488
- * @summary Unassign a partner from a partner hierarchy node
489
- * @param {string} code
490
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
491
- * @param {*} [options] Override http request option.
492
- * @throws {RequiredError}
493
- */
494
- unassignPartnerHierarchyNode: function (code, authorization, options) {
495
- if (options === void 0) { options = {}; }
496
- return __awaiter(_this, void 0, void 0, function () {
497
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
498
- return __generator(this, function (_a) {
499
- switch (_a.label) {
500
- case 0:
501
- // verify required parameter 'code' is not null or undefined
502
- (0, common_1.assertParamExists)('unassignPartnerHierarchyNode', 'code', code);
503
- localVarPath = "/partnerservice/v1/partner-hierarchy-nodes/{code}/unassign"
504
- .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
505
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
506
- if (configuration) {
507
- baseOptions = configuration.baseOptions;
508
- baseAccessToken = configuration.accessToken;
509
- }
510
- localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
511
- localVarHeaderParameter = {};
512
- localVarQueryParameter = {};
513
- // authentication bearer required
514
- // http bearer authentication required
515
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
516
- case 1:
517
- // authentication bearer required
518
- // http bearer authentication required
519
- _a.sent();
520
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
521
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
522
- }
523
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
524
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
525
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
526
- return [2 /*return*/, {
527
- url: (0, common_1.toPathString)(localVarUrlObj),
528
- options: localVarRequestOptions,
529
- }];
530
- }
531
- });
532
- });
533
- },
534
- /**
535
- * Updates a node role or changes the partner assigned to the node. It does not move the node in the tree. **Required Permissions** \"partner-management.partners.update\"
536
- * @summary Update a partner hierarchy node
537
- * @param {string} code
538
- * @param {UpdatePartnerHierarchyNodeRequestDto} updatePartnerHierarchyNodeRequestDto
539
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
540
- * @param {*} [options] Override http request option.
541
- * @throws {RequiredError}
542
- */
543
- updatePartnerHierarchyNode: function (code, updatePartnerHierarchyNodeRequestDto, authorization, options) {
544
- if (options === void 0) { options = {}; }
545
- return __awaiter(_this, void 0, void 0, function () {
546
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
547
- return __generator(this, function (_a) {
548
- switch (_a.label) {
549
- case 0:
550
- // verify required parameter 'code' is not null or undefined
551
- (0, common_1.assertParamExists)('updatePartnerHierarchyNode', 'code', code);
552
- // verify required parameter 'updatePartnerHierarchyNodeRequestDto' is not null or undefined
553
- (0, common_1.assertParamExists)('updatePartnerHierarchyNode', 'updatePartnerHierarchyNodeRequestDto', updatePartnerHierarchyNodeRequestDto);
554
- localVarPath = "/partnerservice/v1/partner-hierarchy-nodes/{code}"
555
- .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
556
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
557
- if (configuration) {
558
- baseOptions = configuration.baseOptions;
559
- baseAccessToken = configuration.accessToken;
560
- }
561
- localVarRequestOptions = __assign(__assign({ method: 'PATCH' }, baseOptions), options);
562
- localVarHeaderParameter = {};
563
- localVarQueryParameter = {};
564
- // authentication bearer required
565
- // http bearer authentication required
566
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
567
- case 1:
568
- // authentication bearer required
569
- // http bearer authentication required
570
- _a.sent();
571
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
572
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
573
- }
574
- localVarHeaderParameter['Content-Type'] = 'application/json';
575
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
576
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
577
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
578
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(updatePartnerHierarchyNodeRequestDto, localVarRequestOptions, configuration);
579
- return [2 /*return*/, {
580
- url: (0, common_1.toPathString)(localVarUrlObj),
581
- options: localVarRequestOptions,
582
- }];
583
- }
584
- });
585
- });
586
- },
587
- };
588
- };
589
- exports.PartnerHierarchyNodesApiAxiosParamCreator = PartnerHierarchyNodesApiAxiosParamCreator;
590
- /**
591
- * PartnerHierarchyNodesApi - functional programming interface
592
- * @export
593
- */
594
- var PartnerHierarchyNodesApiFp = function (configuration) {
595
- var localVarAxiosParamCreator = (0, exports.PartnerHierarchyNodesApiAxiosParamCreator)(configuration);
596
- return {
597
- /**
598
- * Starts batch node creation from an uploaded file and returns the operation status. **Required Permissions** \"partner-management.partners.create\"
599
- * @summary Batch create partner hierarchy nodes
600
- * @param {BatchCreatePartnerHierarchyNodesRequestDto} batchCreatePartnerHierarchyNodesRequestDto
601
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
602
- * @param {*} [options] Override http request option.
603
- * @throws {RequiredError}
604
- */
605
- batchCreatePartnerHierarchyNodes: function (batchCreatePartnerHierarchyNodesRequestDto, authorization, options) {
606
- return __awaiter(this, void 0, void 0, function () {
607
- var localVarAxiosArgs;
608
- return __generator(this, function (_a) {
609
- switch (_a.label) {
610
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.batchCreatePartnerHierarchyNodes(batchCreatePartnerHierarchyNodesRequestDto, authorization, options)];
611
- case 1:
612
- localVarAxiosArgs = _a.sent();
613
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
614
- }
615
- });
616
- });
617
- },
618
- /**
619
- * Creates a node in a partner hierarchy. The node can be placed at the top of the hierarchy or under another node, and it can be created with or without an assigned partner. **Required Permissions** \"partner-management.partners.create\"
620
- * @summary Create a partner hierarchy node
621
- * @param {CreatePartnerHierarchyNodeRequestDto} createPartnerHierarchyNodeRequestDto
622
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
623
- * @param {*} [options] Override http request option.
624
- * @throws {RequiredError}
625
- */
626
- createPartnerHierarchyNode: function (createPartnerHierarchyNodeRequestDto, authorization, options) {
627
- return __awaiter(this, void 0, void 0, function () {
628
- var localVarAxiosArgs;
629
- return __generator(this, function (_a) {
630
- switch (_a.label) {
631
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.createPartnerHierarchyNode(createPartnerHierarchyNodeRequestDto, authorization, options)];
632
- case 1:
633
- localVarAxiosArgs = _a.sent();
634
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
635
- }
636
- });
637
- });
638
- },
639
- /**
640
- * Deletes a partner hierarchy node. The node must have no children before it can be deleted. **Required Permissions** \"partner-management.partners.delete\"
641
- * @summary Delete a partner hierarchy node
642
- * @param {string} code
643
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
644
- * @param {*} [options] Override http request option.
645
- * @throws {RequiredError}
646
- */
647
- deletePartnerHierarchyNode: function (code, authorization, options) {
648
- return __awaiter(this, void 0, void 0, function () {
649
- var localVarAxiosArgs;
650
- return __generator(this, function (_a) {
651
- switch (_a.label) {
652
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.deletePartnerHierarchyNode(code, authorization, options)];
653
- case 1:
654
- localVarAxiosArgs = _a.sent();
655
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
656
- }
657
- });
658
- });
659
- },
660
- /**
661
- * Returns the details of one partner hierarchy node. Partner and parent node details can be included when needed. **Required Permissions** \"partner-management.partners.view\"
662
- * @summary Get a partner hierarchy node
663
- * @param {string} code
664
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
665
- * @param {*} [options] Override http request option.
666
- * @throws {RequiredError}
667
- */
668
- getPartnerHierarchyNode: function (code, authorization, options) {
669
- return __awaiter(this, void 0, void 0, function () {
670
- var localVarAxiosArgs;
671
- return __generator(this, function (_a) {
672
- switch (_a.label) {
673
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.getPartnerHierarchyNode(code, authorization, options)];
674
- case 1:
675
- localVarAxiosArgs = _a.sent();
676
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
677
- }
678
- });
679
- });
680
- },
681
- /**
682
- * Returns a paginated list of previous versions of partner hierarchy nodes for history review. **Required Permissions** \"partner-management.partners.view\"
683
- * @summary List partner hierarchy node history
684
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
685
- * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
686
- * @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.
687
- * @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: code, partnerHierarchyCode, validFrom&lt;/i&gt;
688
- * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
689
- * @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: id, code, validFrom, validTo, createdAt&lt;/i&gt;
690
- * @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: partner&lt;i&gt;
691
- * @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: code, partnerHierarchyCode, validFrom&lt;/i&gt;
692
- * @param {*} [options] Override http request option.
693
- * @throws {RequiredError}
694
- */
695
- listPartnerHierarchyNodeHistory: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
696
- return __awaiter(this, void 0, void 0, function () {
697
- var localVarAxiosArgs;
698
- return __generator(this, function (_a) {
699
- switch (_a.label) {
700
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.listPartnerHierarchyNodeHistory(authorization, pageSize, pageToken, filter, search, order, expand, filters, options)];
701
- case 1:
702
- localVarAxiosArgs = _a.sent();
703
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
704
- }
705
- });
706
- });
707
- },
708
- /**
709
- * Returns a paginated list of partner hierarchy nodes. **Required Permissions** \"partner-management.partners.view\"
710
- * @summary List partner hierarchy nodes
711
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
712
- * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
713
- * @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.
714
- * @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: code, partnerHierarchyCode, partnerCode, parentNodeCode, roleCode, depth, createdAt, updatedAt&lt;/i&gt;
715
- * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
716
- * @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: id, code, depth, createdAt, updatedAt&lt;/i&gt;
717
- * @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: partner, parentNode&lt;i&gt;
718
- * @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: code, partnerHierarchyCode, partnerCode, parentNodeCode, roleCode, depth, createdAt, updatedAt&lt;/i&gt;
719
- * @param {*} [options] Override http request option.
720
- * @throws {RequiredError}
721
- */
722
- listPartnerHierarchyNodes: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
723
- return __awaiter(this, void 0, void 0, function () {
724
- var localVarAxiosArgs;
725
- return __generator(this, function (_a) {
726
- switch (_a.label) {
727
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.listPartnerHierarchyNodes(authorization, pageSize, pageToken, filter, search, order, expand, filters, options)];
728
- case 1:
729
- localVarAxiosArgs = _a.sent();
730
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
731
- }
732
- });
733
- });
734
- },
735
- /**
736
- * Moves a node under another parent at the same level in the same hierarchy. Any nodes below it move with it. **Required Permissions** \"partner-management.partners.update\"
737
- * @summary Move a partner hierarchy node to a new parent
738
- * @param {string} code
739
- * @param {MovePartnerHierarchyNodeRequestDto} movePartnerHierarchyNodeRequestDto
740
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
741
- * @param {*} [options] Override http request option.
742
- * @throws {RequiredError}
743
- */
744
- movePartnerHierarchyNode: function (code, movePartnerHierarchyNodeRequestDto, authorization, options) {
745
- return __awaiter(this, void 0, void 0, function () {
746
- var localVarAxiosArgs;
747
- return __generator(this, function (_a) {
748
- switch (_a.label) {
749
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.movePartnerHierarchyNode(code, movePartnerHierarchyNodeRequestDto, authorization, options)];
750
- case 1:
751
- localVarAxiosArgs = _a.sent();
752
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
753
- }
754
- });
755
- });
756
- },
757
- /**
758
- * Removes the partner assigned to a partner hierarchy node while keeping the node in the tree. **Required Permissions** \"partner-management.partners.update\"
759
- * @summary Unassign a partner from a partner hierarchy node
760
- * @param {string} code
761
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
762
- * @param {*} [options] Override http request option.
763
- * @throws {RequiredError}
764
- */
765
- unassignPartnerHierarchyNode: function (code, authorization, options) {
766
- return __awaiter(this, void 0, void 0, function () {
767
- var localVarAxiosArgs;
768
- return __generator(this, function (_a) {
769
- switch (_a.label) {
770
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.unassignPartnerHierarchyNode(code, authorization, options)];
771
- case 1:
772
- localVarAxiosArgs = _a.sent();
773
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
774
- }
775
- });
776
- });
777
- },
778
- /**
779
- * Updates a node role or changes the partner assigned to the node. It does not move the node in the tree. **Required Permissions** \"partner-management.partners.update\"
780
- * @summary Update a partner hierarchy node
781
- * @param {string} code
782
- * @param {UpdatePartnerHierarchyNodeRequestDto} updatePartnerHierarchyNodeRequestDto
783
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
784
- * @param {*} [options] Override http request option.
785
- * @throws {RequiredError}
786
- */
787
- updatePartnerHierarchyNode: function (code, updatePartnerHierarchyNodeRequestDto, authorization, options) {
788
- return __awaiter(this, void 0, void 0, function () {
789
- var localVarAxiosArgs;
790
- return __generator(this, function (_a) {
791
- switch (_a.label) {
792
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.updatePartnerHierarchyNode(code, updatePartnerHierarchyNodeRequestDto, authorization, options)];
793
- case 1:
794
- localVarAxiosArgs = _a.sent();
795
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
796
- }
797
- });
798
- });
799
- },
800
- };
801
- };
802
- exports.PartnerHierarchyNodesApiFp = PartnerHierarchyNodesApiFp;
803
- /**
804
- * PartnerHierarchyNodesApi - factory interface
805
- * @export
806
- */
807
- var PartnerHierarchyNodesApiFactory = function (configuration, basePath, axios) {
808
- var localVarFp = (0, exports.PartnerHierarchyNodesApiFp)(configuration);
809
- return {
810
- /**
811
- * Starts batch node creation from an uploaded file and returns the operation status. **Required Permissions** \"partner-management.partners.create\"
812
- * @summary Batch create partner hierarchy nodes
813
- * @param {BatchCreatePartnerHierarchyNodesRequestDto} batchCreatePartnerHierarchyNodesRequestDto
814
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
815
- * @param {*} [options] Override http request option.
816
- * @throws {RequiredError}
817
- */
818
- batchCreatePartnerHierarchyNodes: function (batchCreatePartnerHierarchyNodesRequestDto, authorization, options) {
819
- return localVarFp.batchCreatePartnerHierarchyNodes(batchCreatePartnerHierarchyNodesRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
820
- },
821
- /**
822
- * Creates a node in a partner hierarchy. The node can be placed at the top of the hierarchy or under another node, and it can be created with or without an assigned partner. **Required Permissions** \"partner-management.partners.create\"
823
- * @summary Create a partner hierarchy node
824
- * @param {CreatePartnerHierarchyNodeRequestDto} createPartnerHierarchyNodeRequestDto
825
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
826
- * @param {*} [options] Override http request option.
827
- * @throws {RequiredError}
828
- */
829
- createPartnerHierarchyNode: function (createPartnerHierarchyNodeRequestDto, authorization, options) {
830
- return localVarFp.createPartnerHierarchyNode(createPartnerHierarchyNodeRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
831
- },
832
- /**
833
- * Deletes a partner hierarchy node. The node must have no children before it can be deleted. **Required Permissions** \"partner-management.partners.delete\"
834
- * @summary Delete a partner hierarchy node
835
- * @param {string} code
836
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
837
- * @param {*} [options] Override http request option.
838
- * @throws {RequiredError}
839
- */
840
- deletePartnerHierarchyNode: function (code, authorization, options) {
841
- return localVarFp.deletePartnerHierarchyNode(code, authorization, options).then(function (request) { return request(axios, basePath); });
842
- },
843
- /**
844
- * Returns the details of one partner hierarchy node. Partner and parent node details can be included when needed. **Required Permissions** \"partner-management.partners.view\"
845
- * @summary Get a partner hierarchy node
846
- * @param {string} code
847
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
848
- * @param {*} [options] Override http request option.
849
- * @throws {RequiredError}
850
- */
851
- getPartnerHierarchyNode: function (code, authorization, options) {
852
- return localVarFp.getPartnerHierarchyNode(code, authorization, options).then(function (request) { return request(axios, basePath); });
853
- },
854
- /**
855
- * Returns a paginated list of previous versions of partner hierarchy nodes for history review. **Required Permissions** \"partner-management.partners.view\"
856
- * @summary List partner hierarchy node history
857
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
858
- * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
859
- * @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.
860
- * @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: code, partnerHierarchyCode, validFrom&lt;/i&gt;
861
- * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
862
- * @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: id, code, validFrom, validTo, createdAt&lt;/i&gt;
863
- * @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: partner&lt;i&gt;
864
- * @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: code, partnerHierarchyCode, validFrom&lt;/i&gt;
865
- * @param {*} [options] Override http request option.
866
- * @throws {RequiredError}
867
- */
868
- listPartnerHierarchyNodeHistory: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
869
- return localVarFp.listPartnerHierarchyNodeHistory(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then(function (request) { return request(axios, basePath); });
870
- },
871
- /**
872
- * Returns a paginated list of partner hierarchy nodes. **Required Permissions** \"partner-management.partners.view\"
873
- * @summary List partner hierarchy nodes
874
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
875
- * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
876
- * @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.
877
- * @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: code, partnerHierarchyCode, partnerCode, parentNodeCode, roleCode, depth, createdAt, updatedAt&lt;/i&gt;
878
- * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
879
- * @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: id, code, depth, createdAt, updatedAt&lt;/i&gt;
880
- * @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: partner, parentNode&lt;i&gt;
881
- * @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: code, partnerHierarchyCode, partnerCode, parentNodeCode, roleCode, depth, createdAt, updatedAt&lt;/i&gt;
882
- * @param {*} [options] Override http request option.
883
- * @throws {RequiredError}
884
- */
885
- listPartnerHierarchyNodes: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
886
- return localVarFp.listPartnerHierarchyNodes(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then(function (request) { return request(axios, basePath); });
887
- },
888
- /**
889
- * Moves a node under another parent at the same level in the same hierarchy. Any nodes below it move with it. **Required Permissions** \"partner-management.partners.update\"
890
- * @summary Move a partner hierarchy node to a new parent
891
- * @param {string} code
892
- * @param {MovePartnerHierarchyNodeRequestDto} movePartnerHierarchyNodeRequestDto
893
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
894
- * @param {*} [options] Override http request option.
895
- * @throws {RequiredError}
896
- */
897
- movePartnerHierarchyNode: function (code, movePartnerHierarchyNodeRequestDto, authorization, options) {
898
- return localVarFp.movePartnerHierarchyNode(code, movePartnerHierarchyNodeRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
899
- },
900
- /**
901
- * Removes the partner assigned to a partner hierarchy node while keeping the node in the tree. **Required Permissions** \"partner-management.partners.update\"
902
- * @summary Unassign a partner from a partner hierarchy node
903
- * @param {string} code
904
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
905
- * @param {*} [options] Override http request option.
906
- * @throws {RequiredError}
907
- */
908
- unassignPartnerHierarchyNode: function (code, authorization, options) {
909
- return localVarFp.unassignPartnerHierarchyNode(code, authorization, options).then(function (request) { return request(axios, basePath); });
910
- },
911
- /**
912
- * Updates a node role or changes the partner assigned to the node. It does not move the node in the tree. **Required Permissions** \"partner-management.partners.update\"
913
- * @summary Update a partner hierarchy node
914
- * @param {string} code
915
- * @param {UpdatePartnerHierarchyNodeRequestDto} updatePartnerHierarchyNodeRequestDto
916
- * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
917
- * @param {*} [options] Override http request option.
918
- * @throws {RequiredError}
919
- */
920
- updatePartnerHierarchyNode: function (code, updatePartnerHierarchyNodeRequestDto, authorization, options) {
921
- return localVarFp.updatePartnerHierarchyNode(code, updatePartnerHierarchyNodeRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
922
- },
923
- };
924
- };
925
- exports.PartnerHierarchyNodesApiFactory = PartnerHierarchyNodesApiFactory;
926
- /**
927
- * PartnerHierarchyNodesApi - object-oriented interface
928
- * @export
929
- * @class PartnerHierarchyNodesApi
930
- * @extends {BaseAPI}
931
- */
932
- var PartnerHierarchyNodesApi = /** @class */ (function (_super) {
933
- __extends(PartnerHierarchyNodesApi, _super);
934
- function PartnerHierarchyNodesApi() {
935
- return _super !== null && _super.apply(this, arguments) || this;
936
- }
937
- /**
938
- * Starts batch node creation from an uploaded file and returns the operation status. **Required Permissions** \"partner-management.partners.create\"
939
- * @summary Batch create partner hierarchy nodes
940
- * @param {PartnerHierarchyNodesApiBatchCreatePartnerHierarchyNodesRequest} requestParameters Request parameters.
941
- * @param {*} [options] Override http request option.
942
- * @throws {RequiredError}
943
- * @memberof PartnerHierarchyNodesApi
944
- */
945
- PartnerHierarchyNodesApi.prototype.batchCreatePartnerHierarchyNodes = function (requestParameters, options) {
946
- var _this = this;
947
- return (0, exports.PartnerHierarchyNodesApiFp)(this.configuration).batchCreatePartnerHierarchyNodes(requestParameters.batchCreatePartnerHierarchyNodesRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
948
- };
949
- /**
950
- * Creates a node in a partner hierarchy. The node can be placed at the top of the hierarchy or under another node, and it can be created with or without an assigned partner. **Required Permissions** \"partner-management.partners.create\"
951
- * @summary Create a partner hierarchy node
952
- * @param {PartnerHierarchyNodesApiCreatePartnerHierarchyNodeRequest} requestParameters Request parameters.
953
- * @param {*} [options] Override http request option.
954
- * @throws {RequiredError}
955
- * @memberof PartnerHierarchyNodesApi
956
- */
957
- PartnerHierarchyNodesApi.prototype.createPartnerHierarchyNode = function (requestParameters, options) {
958
- var _this = this;
959
- return (0, exports.PartnerHierarchyNodesApiFp)(this.configuration).createPartnerHierarchyNode(requestParameters.createPartnerHierarchyNodeRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
960
- };
961
- /**
962
- * Deletes a partner hierarchy node. The node must have no children before it can be deleted. **Required Permissions** \"partner-management.partners.delete\"
963
- * @summary Delete a partner hierarchy node
964
- * @param {PartnerHierarchyNodesApiDeletePartnerHierarchyNodeRequest} requestParameters Request parameters.
965
- * @param {*} [options] Override http request option.
966
- * @throws {RequiredError}
967
- * @memberof PartnerHierarchyNodesApi
968
- */
969
- PartnerHierarchyNodesApi.prototype.deletePartnerHierarchyNode = function (requestParameters, options) {
970
- var _this = this;
971
- return (0, exports.PartnerHierarchyNodesApiFp)(this.configuration).deletePartnerHierarchyNode(requestParameters.code, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
972
- };
973
- /**
974
- * Returns the details of one partner hierarchy node. Partner and parent node details can be included when needed. **Required Permissions** \"partner-management.partners.view\"
975
- * @summary Get a partner hierarchy node
976
- * @param {PartnerHierarchyNodesApiGetPartnerHierarchyNodeRequest} requestParameters Request parameters.
977
- * @param {*} [options] Override http request option.
978
- * @throws {RequiredError}
979
- * @memberof PartnerHierarchyNodesApi
980
- */
981
- PartnerHierarchyNodesApi.prototype.getPartnerHierarchyNode = function (requestParameters, options) {
982
- var _this = this;
983
- return (0, exports.PartnerHierarchyNodesApiFp)(this.configuration).getPartnerHierarchyNode(requestParameters.code, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
984
- };
985
- /**
986
- * Returns a paginated list of previous versions of partner hierarchy nodes for history review. **Required Permissions** \"partner-management.partners.view\"
987
- * @summary List partner hierarchy node history
988
- * @param {PartnerHierarchyNodesApiListPartnerHierarchyNodeHistoryRequest} requestParameters Request parameters.
989
- * @param {*} [options] Override http request option.
990
- * @throws {RequiredError}
991
- * @memberof PartnerHierarchyNodesApi
992
- */
993
- PartnerHierarchyNodesApi.prototype.listPartnerHierarchyNodeHistory = function (requestParameters, options) {
994
- var _this = this;
995
- if (requestParameters === void 0) { requestParameters = {}; }
996
- return (0, exports.PartnerHierarchyNodesApiFp)(this.configuration).listPartnerHierarchyNodeHistory(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then(function (request) { return request(_this.axios, _this.basePath); });
997
- };
998
- /**
999
- * Returns a paginated list of partner hierarchy nodes. **Required Permissions** \"partner-management.partners.view\"
1000
- * @summary List partner hierarchy nodes
1001
- * @param {PartnerHierarchyNodesApiListPartnerHierarchyNodesRequest} requestParameters Request parameters.
1002
- * @param {*} [options] Override http request option.
1003
- * @throws {RequiredError}
1004
- * @memberof PartnerHierarchyNodesApi
1005
- */
1006
- PartnerHierarchyNodesApi.prototype.listPartnerHierarchyNodes = function (requestParameters, options) {
1007
- var _this = this;
1008
- if (requestParameters === void 0) { requestParameters = {}; }
1009
- return (0, exports.PartnerHierarchyNodesApiFp)(this.configuration).listPartnerHierarchyNodes(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then(function (request) { return request(_this.axios, _this.basePath); });
1010
- };
1011
- /**
1012
- * Moves a node under another parent at the same level in the same hierarchy. Any nodes below it move with it. **Required Permissions** \"partner-management.partners.update\"
1013
- * @summary Move a partner hierarchy node to a new parent
1014
- * @param {PartnerHierarchyNodesApiMovePartnerHierarchyNodeRequest} requestParameters Request parameters.
1015
- * @param {*} [options] Override http request option.
1016
- * @throws {RequiredError}
1017
- * @memberof PartnerHierarchyNodesApi
1018
- */
1019
- PartnerHierarchyNodesApi.prototype.movePartnerHierarchyNode = function (requestParameters, options) {
1020
- var _this = this;
1021
- return (0, exports.PartnerHierarchyNodesApiFp)(this.configuration).movePartnerHierarchyNode(requestParameters.code, requestParameters.movePartnerHierarchyNodeRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
1022
- };
1023
- /**
1024
- * Removes the partner assigned to a partner hierarchy node while keeping the node in the tree. **Required Permissions** \"partner-management.partners.update\"
1025
- * @summary Unassign a partner from a partner hierarchy node
1026
- * @param {PartnerHierarchyNodesApiUnassignPartnerHierarchyNodeRequest} requestParameters Request parameters.
1027
- * @param {*} [options] Override http request option.
1028
- * @throws {RequiredError}
1029
- * @memberof PartnerHierarchyNodesApi
1030
- */
1031
- PartnerHierarchyNodesApi.prototype.unassignPartnerHierarchyNode = function (requestParameters, options) {
1032
- var _this = this;
1033
- return (0, exports.PartnerHierarchyNodesApiFp)(this.configuration).unassignPartnerHierarchyNode(requestParameters.code, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
1034
- };
1035
- /**
1036
- * Updates a node role or changes the partner assigned to the node. It does not move the node in the tree. **Required Permissions** \"partner-management.partners.update\"
1037
- * @summary Update a partner hierarchy node
1038
- * @param {PartnerHierarchyNodesApiUpdatePartnerHierarchyNodeRequest} requestParameters Request parameters.
1039
- * @param {*} [options] Override http request option.
1040
- * @throws {RequiredError}
1041
- * @memberof PartnerHierarchyNodesApi
1042
- */
1043
- PartnerHierarchyNodesApi.prototype.updatePartnerHierarchyNode = function (requestParameters, options) {
1044
- var _this = this;
1045
- return (0, exports.PartnerHierarchyNodesApiFp)(this.configuration).updatePartnerHierarchyNode(requestParameters.code, requestParameters.updatePartnerHierarchyNodeRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
1046
- };
1047
- return PartnerHierarchyNodesApi;
1048
- }(base_1.BaseAPI));
1049
- exports.PartnerHierarchyNodesApi = PartnerHierarchyNodesApi;