@dynamic-labs/sdk-api 0.0.920 → 0.0.922

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 (120) hide show
  1. package/package.json +1 -1
  2. package/src/apis/AllowlistsApi.cjs +245 -286
  3. package/src/apis/AllowlistsApi.js +245 -286
  4. package/src/apis/AnalyticsApi.cjs +210 -235
  5. package/src/apis/AnalyticsApi.js +210 -235
  6. package/src/apis/ChainalysisApi.cjs +66 -79
  7. package/src/apis/ChainalysisApi.js +66 -79
  8. package/src/apis/ChainsApi.cjs +25 -30
  9. package/src/apis/ChainsApi.js +25 -30
  10. package/src/apis/CustomFieldsApi.cjs +119 -140
  11. package/src/apis/CustomFieldsApi.js +119 -140
  12. package/src/apis/CustomHostnamesApi.cjs +55 -68
  13. package/src/apis/CustomHostnamesApi.js +55 -68
  14. package/src/apis/CustomNetworksApi.cjs +128 -149
  15. package/src/apis/CustomNetworksApi.js +128 -149
  16. package/src/apis/DeeplinkUrlsApi.cjs +70 -83
  17. package/src/apis/DeeplinkUrlsApi.js +70 -83
  18. package/src/apis/DepositApi.cjs +83 -100
  19. package/src/apis/DepositApi.js +83 -100
  20. package/src/apis/EnvironmentsApi.cjs +168 -197
  21. package/src/apis/EnvironmentsApi.js +168 -197
  22. package/src/apis/EventsApi.cjs +60 -73
  23. package/src/apis/EventsApi.js +60 -73
  24. package/src/apis/ExportsApi.cjs +89 -106
  25. package/src/apis/ExportsApi.js +89 -106
  26. package/src/apis/ExternalJwtApi.cjs +27 -32
  27. package/src/apis/ExternalJwtApi.js +27 -32
  28. package/src/apis/GatesApi.cjs +154 -183
  29. package/src/apis/GatesApi.js +154 -183
  30. package/src/apis/GlobalWalletAccessControlApi.cjs +159 -188
  31. package/src/apis/GlobalWalletAccessControlApi.js +159 -188
  32. package/src/apis/GlobalWalletConnectionsApi.cjs +28 -33
  33. package/src/apis/GlobalWalletConnectionsApi.js +28 -33
  34. package/src/apis/GlobalWalletsApi.cjs +90 -111
  35. package/src/apis/GlobalWalletsApi.js +90 -111
  36. package/src/apis/InvitesApi.cjs +120 -141
  37. package/src/apis/InvitesApi.js +120 -141
  38. package/src/apis/MembersApi.cjs +115 -136
  39. package/src/apis/MembersApi.js +115 -136
  40. package/src/apis/MfaApi.cjs +42 -51
  41. package/src/apis/MfaApi.js +42 -51
  42. package/src/apis/MfaSettingsApi.cjs +72 -85
  43. package/src/apis/MfaSettingsApi.js +72 -85
  44. package/src/apis/NameServicesApi.cjs +123 -148
  45. package/src/apis/NameServicesApi.js +123 -148
  46. package/src/apis/OrganizationsApi.cjs +328 -381
  47. package/src/apis/OrganizationsApi.js +328 -381
  48. package/src/apis/OriginsApi.cjs +58 -71
  49. package/src/apis/OriginsApi.js +58 -71
  50. package/src/apis/ProjectsApi.cjs +119 -140
  51. package/src/apis/ProjectsApi.js +119 -140
  52. package/src/apis/SDKApi.cjs +6184 -7362
  53. package/src/apis/SDKApi.d.ts +3 -3
  54. package/src/apis/SDKApi.js +6184 -7362
  55. package/src/apis/SDKViewsApi.cjs +59 -72
  56. package/src/apis/SDKViewsApi.js +59 -72
  57. package/src/apis/SessionsApi.cjs +69 -82
  58. package/src/apis/SessionsApi.js +69 -82
  59. package/src/apis/SettingsApi.cjs +273 -330
  60. package/src/apis/SettingsApi.js +273 -330
  61. package/src/apis/TestAccountApi.cjs +47 -60
  62. package/src/apis/TestAccountApi.js +47 -60
  63. package/src/apis/TokensApi.cjs +92 -109
  64. package/src/apis/TokensApi.js +92 -109
  65. package/src/apis/UserApiTokensApi.cjs +64 -77
  66. package/src/apis/UserApiTokensApi.js +64 -77
  67. package/src/apis/UsersApi.cjs +357 -410
  68. package/src/apis/UsersApi.js +357 -410
  69. package/src/apis/VisitsApi.cjs +34 -39
  70. package/src/apis/VisitsApi.js +34 -39
  71. package/src/apis/WaasApi.cjs +470 -559
  72. package/src/apis/WaasApi.js +470 -559
  73. package/src/apis/WalletConnectApi.cjs +21 -26
  74. package/src/apis/WalletConnectApi.js +21 -26
  75. package/src/apis/WalletsApi.cjs +340 -393
  76. package/src/apis/WalletsApi.js +340 -393
  77. package/src/apis/WebhooksApi.cjs +167 -200
  78. package/src/apis/WebhooksApi.js +167 -200
  79. package/src/index.cjs +8 -16
  80. package/src/index.js +2 -4
  81. package/src/models/CheckoutTransaction.cjs +3 -10
  82. package/src/models/CheckoutTransaction.d.ts +3 -22
  83. package/src/models/CheckoutTransaction.js +3 -10
  84. package/src/models/CheckoutTransactionQuote.cjs +51 -0
  85. package/src/models/CheckoutTransactionQuote.d.ts +77 -0
  86. package/src/models/CheckoutTransactionQuote.js +45 -0
  87. package/src/models/CreateEmbeddedWalletSpecificOpts.cjs +2 -2
  88. package/src/models/CreateEmbeddedWalletSpecificOpts.js +2 -2
  89. package/src/models/Provider.cjs +2 -0
  90. package/src/models/Provider.d.ts +6 -0
  91. package/src/models/Provider.js +2 -0
  92. package/src/models/ProviderCreateRequest.cjs +2 -0
  93. package/src/models/ProviderCreateRequest.d.ts +6 -0
  94. package/src/models/ProviderCreateRequest.js +2 -0
  95. package/src/models/ProviderUpdateRequest.cjs +2 -0
  96. package/src/models/ProviderUpdateRequest.d.ts +6 -0
  97. package/src/models/ProviderUpdateRequest.js +2 -0
  98. package/src/models/SwapSigningPayload.cjs +4 -6
  99. package/src/models/SwapSigningPayload.d.ts +7 -9
  100. package/src/models/SwapSigningPayload.js +4 -6
  101. package/src/models/TransactionFeeEstimateRequest.cjs +37 -0
  102. package/src/models/TransactionFeeEstimateRequest.d.ts +39 -0
  103. package/src/models/TransactionFeeEstimateRequest.js +31 -0
  104. package/src/models/index.d.ts +2 -4
  105. package/src/runtime.cjs +45 -36
  106. package/src/runtime.js +45 -36
  107. package/_virtual/_tslib.cjs +0 -35
  108. package/_virtual/_tslib.js +0 -31
  109. package/src/models/CheckoutQuoteSnapshot.cjs +0 -50
  110. package/src/models/CheckoutQuoteSnapshot.d.ts +0 -76
  111. package/src/models/CheckoutQuoteSnapshot.js +0 -44
  112. package/src/models/InlineObject1.cjs +0 -43
  113. package/src/models/InlineObject1.d.ts +0 -27
  114. package/src/models/InlineObject1.js +0 -37
  115. package/src/models/SwapPsbtTransactionData.cjs +0 -43
  116. package/src/models/SwapPsbtTransactionData.d.ts +0 -27
  117. package/src/models/SwapPsbtTransactionData.js +0 -37
  118. package/src/models/SwapSerializedTransactionData.cjs +0 -43
  119. package/src/models/SwapSerializedTransactionData.d.ts +0 -27
  120. package/src/models/SwapSerializedTransactionData.js +0 -37
@@ -2,7 +2,6 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var _tslib = require('../../_virtual/_tslib.cjs');
6
5
  var runtime = require('../runtime.cjs');
7
6
  require('../models/AccessOutcomeEnum.cjs');
8
7
  require('../models/ExchangeKeyEnum.cjs');
@@ -125,396 +124,356 @@ class AllowlistsApi extends runtime.BaseAPI {
125
124
  * Creates a new allowlist for the specified environment.
126
125
  * Create an allowlist for the environment
127
126
  */
128
- createAllowlistByEnvironmentIdRaw(requestParameters, initOverrides) {
129
- return _tslib.__awaiter(this, void 0, void 0, function* () {
130
- if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
131
- throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling createAllowlistByEnvironmentId.');
127
+ async createAllowlistByEnvironmentIdRaw(requestParameters, initOverrides) {
128
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
129
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling createAllowlistByEnvironmentId.');
130
+ }
131
+ if (requestParameters.postAllowlistsRequest === null || requestParameters.postAllowlistsRequest === undefined) {
132
+ throw new runtime.RequiredError('postAllowlistsRequest', 'Required parameter requestParameters.postAllowlistsRequest was null or undefined when calling createAllowlistByEnvironmentId.');
133
+ }
134
+ const queryParameters = {};
135
+ const headerParameters = {};
136
+ headerParameters['Content-Type'] = 'application/json';
137
+ if (this.configuration && this.configuration.accessToken) {
138
+ const token = this.configuration.accessToken;
139
+ const tokenString = await token("bearerAuth", []);
140
+ if (tokenString) {
141
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
132
142
  }
133
- if (requestParameters.postAllowlistsRequest === null || requestParameters.postAllowlistsRequest === undefined) {
134
- throw new runtime.RequiredError('postAllowlistsRequest', 'Required parameter requestParameters.postAllowlistsRequest was null or undefined when calling createAllowlistByEnvironmentId.');
135
- }
136
- const queryParameters = {};
137
- const headerParameters = {};
138
- headerParameters['Content-Type'] = 'application/json';
139
- if (this.configuration && this.configuration.accessToken) {
140
- const token = this.configuration.accessToken;
141
- const tokenString = yield token("bearerAuth", []);
142
- if (tokenString) {
143
- headerParameters["Authorization"] = `Bearer ${tokenString}`;
144
- }
145
- }
146
- const response = yield this.request({
147
- path: `/environments/{environmentId}/allowlists`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
148
- method: 'POST',
149
- headers: headerParameters,
150
- query: queryParameters,
151
- body: PostAllowlistsRequest.PostAllowlistsRequestToJSON(requestParameters.postAllowlistsRequest),
152
- }, initOverrides);
153
- return new runtime.JSONApiResponse(response, (jsonValue) => Allowlist.AllowlistFromJSON(jsonValue));
154
- });
143
+ }
144
+ const response = await this.request({
145
+ path: `/environments/{environmentId}/allowlists`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
146
+ method: 'POST',
147
+ headers: headerParameters,
148
+ query: queryParameters,
149
+ body: PostAllowlistsRequest.PostAllowlistsRequestToJSON(requestParameters.postAllowlistsRequest),
150
+ }, initOverrides);
151
+ return new runtime.JSONApiResponse(response, (jsonValue) => Allowlist.AllowlistFromJSON(jsonValue));
155
152
  }
156
153
  /**
157
154
  * Creates a new allowlist for the specified environment.
158
155
  * Create an allowlist for the environment
159
156
  */
160
- createAllowlistByEnvironmentId(requestParameters, initOverrides) {
161
- return _tslib.__awaiter(this, void 0, void 0, function* () {
162
- const response = yield this.createAllowlistByEnvironmentIdRaw(requestParameters, initOverrides);
163
- return yield response.value();
164
- });
157
+ async createAllowlistByEnvironmentId(requestParameters, initOverrides) {
158
+ const response = await this.createAllowlistByEnvironmentIdRaw(requestParameters, initOverrides);
159
+ return await response.value();
165
160
  }
166
161
  /**
167
162
  * Permanently removes the specified allowlist.
168
163
  * Delete an allowlist
169
164
  */
170
- deleteAllowlistByIdRaw(requestParameters, initOverrides) {
171
- return _tslib.__awaiter(this, void 0, void 0, function* () {
172
- if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
173
- throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling deleteAllowlistById.');
174
- }
175
- const queryParameters = {};
176
- const headerParameters = {};
177
- if (this.configuration && this.configuration.accessToken) {
178
- const token = this.configuration.accessToken;
179
- const tokenString = yield token("bearerAuth", []);
180
- if (tokenString) {
181
- headerParameters["Authorization"] = `Bearer ${tokenString}`;
182
- }
165
+ async deleteAllowlistByIdRaw(requestParameters, initOverrides) {
166
+ if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
167
+ throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling deleteAllowlistById.');
168
+ }
169
+ const queryParameters = {};
170
+ const headerParameters = {};
171
+ if (this.configuration && this.configuration.accessToken) {
172
+ const token = this.configuration.accessToken;
173
+ const tokenString = await token("bearerAuth", []);
174
+ if (tokenString) {
175
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
183
176
  }
184
- const response = yield this.request({
185
- path: `/allowlists/{allowlistId}`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
186
- method: 'DELETE',
187
- headers: headerParameters,
188
- query: queryParameters,
189
- }, initOverrides);
190
- return new runtime.VoidApiResponse(response);
191
- });
177
+ }
178
+ const response = await this.request({
179
+ path: `/allowlists/{allowlistId}`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
180
+ method: 'DELETE',
181
+ headers: headerParameters,
182
+ query: queryParameters,
183
+ }, initOverrides);
184
+ return new runtime.VoidApiResponse(response);
192
185
  }
193
186
  /**
194
187
  * Permanently removes the specified allowlist.
195
188
  * Delete an allowlist
196
189
  */
197
- deleteAllowlistById(requestParameters, initOverrides) {
198
- return _tslib.__awaiter(this, void 0, void 0, function* () {
199
- yield this.deleteAllowlistByIdRaw(requestParameters, initOverrides);
200
- });
190
+ async deleteAllowlistById(requestParameters, initOverrides) {
191
+ await this.deleteAllowlistByIdRaw(requestParameters, initOverrides);
201
192
  }
202
193
  /**
203
194
  * Permanently removes the specified allowlist entry.
204
195
  * Delete an allowlist entry
205
196
  */
206
- deleteAllowlistEntryByIdRaw(requestParameters, initOverrides) {
207
- return _tslib.__awaiter(this, void 0, void 0, function* () {
208
- if (requestParameters.allowlistEntryId === null || requestParameters.allowlistEntryId === undefined) {
209
- throw new runtime.RequiredError('allowlistEntryId', 'Required parameter requestParameters.allowlistEntryId was null or undefined when calling deleteAllowlistEntryById.');
197
+ async deleteAllowlistEntryByIdRaw(requestParameters, initOverrides) {
198
+ if (requestParameters.allowlistEntryId === null || requestParameters.allowlistEntryId === undefined) {
199
+ throw new runtime.RequiredError('allowlistEntryId', 'Required parameter requestParameters.allowlistEntryId was null or undefined when calling deleteAllowlistEntryById.');
200
+ }
201
+ const queryParameters = {};
202
+ const headerParameters = {};
203
+ if (this.configuration && this.configuration.accessToken) {
204
+ const token = this.configuration.accessToken;
205
+ const tokenString = await token("bearerAuth", []);
206
+ if (tokenString) {
207
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
210
208
  }
211
- const queryParameters = {};
212
- const headerParameters = {};
213
- if (this.configuration && this.configuration.accessToken) {
214
- const token = this.configuration.accessToken;
215
- const tokenString = yield token("bearerAuth", []);
216
- if (tokenString) {
217
- headerParameters["Authorization"] = `Bearer ${tokenString}`;
218
- }
219
- }
220
- const response = yield this.request({
221
- path: `/allowlistEntries/{allowlistEntryId}`.replace(`{${"allowlistEntryId"}}`, encodeURIComponent(String(requestParameters.allowlistEntryId))),
222
- method: 'DELETE',
223
- headers: headerParameters,
224
- query: queryParameters,
225
- }, initOverrides);
226
- return new runtime.VoidApiResponse(response);
227
- });
209
+ }
210
+ const response = await this.request({
211
+ path: `/allowlistEntries/{allowlistEntryId}`.replace(`{${"allowlistEntryId"}}`, encodeURIComponent(String(requestParameters.allowlistEntryId))),
212
+ method: 'DELETE',
213
+ headers: headerParameters,
214
+ query: queryParameters,
215
+ }, initOverrides);
216
+ return new runtime.VoidApiResponse(response);
228
217
  }
229
218
  /**
230
219
  * Permanently removes the specified allowlist entry.
231
220
  * Delete an allowlist entry
232
221
  */
233
- deleteAllowlistEntryById(requestParameters, initOverrides) {
234
- return _tslib.__awaiter(this, void 0, void 0, function* () {
235
- yield this.deleteAllowlistEntryByIdRaw(requestParameters, initOverrides);
236
- });
222
+ async deleteAllowlistEntryById(requestParameters, initOverrides) {
223
+ await this.deleteAllowlistEntryByIdRaw(requestParameters, initOverrides);
237
224
  }
238
225
  /**
239
226
  * Disables the specified allowlist.
240
227
  * Disable the allow list
241
228
  */
242
- disableAllowlistByIdRaw(requestParameters, initOverrides) {
243
- return _tslib.__awaiter(this, void 0, void 0, function* () {
244
- if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
245
- throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling disableAllowlistById.');
246
- }
247
- const queryParameters = {};
248
- const headerParameters = {};
249
- if (this.configuration && this.configuration.accessToken) {
250
- const token = this.configuration.accessToken;
251
- const tokenString = yield token("bearerAuth", []);
252
- if (tokenString) {
253
- headerParameters["Authorization"] = `Bearer ${tokenString}`;
254
- }
229
+ async disableAllowlistByIdRaw(requestParameters, initOverrides) {
230
+ if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
231
+ throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling disableAllowlistById.');
232
+ }
233
+ const queryParameters = {};
234
+ const headerParameters = {};
235
+ if (this.configuration && this.configuration.accessToken) {
236
+ const token = this.configuration.accessToken;
237
+ const tokenString = await token("bearerAuth", []);
238
+ if (tokenString) {
239
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
255
240
  }
256
- const response = yield this.request({
257
- path: `/allowlists/{allowlistId}/disable`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
258
- method: 'PUT',
259
- headers: headerParameters,
260
- query: queryParameters,
261
- }, initOverrides);
262
- return new runtime.JSONApiResponse(response, (jsonValue) => Allowlist.AllowlistFromJSON(jsonValue));
263
- });
241
+ }
242
+ const response = await this.request({
243
+ path: `/allowlists/{allowlistId}/disable`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
244
+ method: 'PUT',
245
+ headers: headerParameters,
246
+ query: queryParameters,
247
+ }, initOverrides);
248
+ return new runtime.JSONApiResponse(response, (jsonValue) => Allowlist.AllowlistFromJSON(jsonValue));
264
249
  }
265
250
  /**
266
251
  * Disables the specified allowlist.
267
252
  * Disable the allow list
268
253
  */
269
- disableAllowlistById(requestParameters, initOverrides) {
270
- return _tslib.__awaiter(this, void 0, void 0, function* () {
271
- const response = yield this.disableAllowlistByIdRaw(requestParameters, initOverrides);
272
- return yield response.value();
273
- });
254
+ async disableAllowlistById(requestParameters, initOverrides) {
255
+ const response = await this.disableAllowlistByIdRaw(requestParameters, initOverrides);
256
+ return await response.value();
274
257
  }
275
258
  /**
276
259
  * Enables the specified allowlist.
277
260
  * Enable the allowlist
278
261
  */
279
- enableAllowlistByIdRaw(requestParameters, initOverrides) {
280
- return _tslib.__awaiter(this, void 0, void 0, function* () {
281
- if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
282
- throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling enableAllowlistById.');
262
+ async enableAllowlistByIdRaw(requestParameters, initOverrides) {
263
+ if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
264
+ throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling enableAllowlistById.');
265
+ }
266
+ const queryParameters = {};
267
+ const headerParameters = {};
268
+ if (this.configuration && this.configuration.accessToken) {
269
+ const token = this.configuration.accessToken;
270
+ const tokenString = await token("bearerAuth", []);
271
+ if (tokenString) {
272
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
283
273
  }
284
- const queryParameters = {};
285
- const headerParameters = {};
286
- if (this.configuration && this.configuration.accessToken) {
287
- const token = this.configuration.accessToken;
288
- const tokenString = yield token("bearerAuth", []);
289
- if (tokenString) {
290
- headerParameters["Authorization"] = `Bearer ${tokenString}`;
291
- }
292
- }
293
- const response = yield this.request({
294
- path: `/allowlists/{allowlistId}/enable`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
295
- method: 'PUT',
296
- headers: headerParameters,
297
- query: queryParameters,
298
- }, initOverrides);
299
- return new runtime.JSONApiResponse(response, (jsonValue) => Allowlist.AllowlistFromJSON(jsonValue));
300
- });
274
+ }
275
+ const response = await this.request({
276
+ path: `/allowlists/{allowlistId}/enable`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
277
+ method: 'PUT',
278
+ headers: headerParameters,
279
+ query: queryParameters,
280
+ }, initOverrides);
281
+ return new runtime.JSONApiResponse(response, (jsonValue) => Allowlist.AllowlistFromJSON(jsonValue));
301
282
  }
302
283
  /**
303
284
  * Enables the specified allowlist.
304
285
  * Enable the allowlist
305
286
  */
306
- enableAllowlistById(requestParameters, initOverrides) {
307
- return _tslib.__awaiter(this, void 0, void 0, function* () {
308
- const response = yield this.enableAllowlistByIdRaw(requestParameters, initOverrides);
309
- return yield response.value();
310
- });
287
+ async enableAllowlistById(requestParameters, initOverrides) {
288
+ const response = await this.enableAllowlistByIdRaw(requestParameters, initOverrides);
289
+ return await response.value();
311
290
  }
312
291
  /**
313
292
  * Returns the allowlists for the specified environment.
314
293
  * Get allowlists for the environment
315
294
  */
316
- getAllowlistsByEnvironmentIdRaw(requestParameters, initOverrides) {
317
- return _tslib.__awaiter(this, void 0, void 0, function* () {
318
- if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
319
- throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling getAllowlistsByEnvironmentId.');
320
- }
321
- const queryParameters = {};
322
- const headerParameters = {};
323
- if (this.configuration && this.configuration.accessToken) {
324
- const token = this.configuration.accessToken;
325
- const tokenString = yield token("bearerAuth", []);
326
- if (tokenString) {
327
- headerParameters["Authorization"] = `Bearer ${tokenString}`;
328
- }
295
+ async getAllowlistsByEnvironmentIdRaw(requestParameters, initOverrides) {
296
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
297
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling getAllowlistsByEnvironmentId.');
298
+ }
299
+ const queryParameters = {};
300
+ const headerParameters = {};
301
+ if (this.configuration && this.configuration.accessToken) {
302
+ const token = this.configuration.accessToken;
303
+ const tokenString = await token("bearerAuth", []);
304
+ if (tokenString) {
305
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
329
306
  }
330
- const response = yield this.request({
331
- path: `/environments/{environmentId}/allowlists`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
332
- method: 'GET',
333
- headers: headerParameters,
334
- query: queryParameters,
335
- }, initOverrides);
336
- return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(Allowlist.AllowlistFromJSON));
337
- });
307
+ }
308
+ const response = await this.request({
309
+ path: `/environments/{environmentId}/allowlists`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
310
+ method: 'GET',
311
+ headers: headerParameters,
312
+ query: queryParameters,
313
+ }, initOverrides);
314
+ return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(Allowlist.AllowlistFromJSON));
338
315
  }
339
316
  /**
340
317
  * Returns the allowlists for the specified environment.
341
318
  * Get allowlists for the environment
342
319
  */
343
- getAllowlistsByEnvironmentId(requestParameters, initOverrides) {
344
- return _tslib.__awaiter(this, void 0, void 0, function* () {
345
- const response = yield this.getAllowlistsByEnvironmentIdRaw(requestParameters, initOverrides);
346
- return yield response.value();
347
- });
320
+ async getAllowlistsByEnvironmentId(requestParameters, initOverrides) {
321
+ const response = await this.getAllowlistsByEnvironmentIdRaw(requestParameters, initOverrides);
322
+ return await response.value();
348
323
  }
349
324
  /**
350
325
  * Returns an allowlist by its unique identifier.
351
326
  * Get allowlist by id
352
327
  */
353
- getAllowlistsByIdRaw(requestParameters, initOverrides) {
354
- return _tslib.__awaiter(this, void 0, void 0, function* () {
355
- if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
356
- throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling getAllowlistsById.');
328
+ async getAllowlistsByIdRaw(requestParameters, initOverrides) {
329
+ if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
330
+ throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling getAllowlistsById.');
331
+ }
332
+ const queryParameters = {};
333
+ const headerParameters = {};
334
+ if (this.configuration && this.configuration.accessToken) {
335
+ const token = this.configuration.accessToken;
336
+ const tokenString = await token("bearerAuth", []);
337
+ if (tokenString) {
338
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
357
339
  }
358
- const queryParameters = {};
359
- const headerParameters = {};
360
- if (this.configuration && this.configuration.accessToken) {
361
- const token = this.configuration.accessToken;
362
- const tokenString = yield token("bearerAuth", []);
363
- if (tokenString) {
364
- headerParameters["Authorization"] = `Bearer ${tokenString}`;
365
- }
366
- }
367
- const response = yield this.request({
368
- path: `/allowlists/{allowlistId}`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
369
- method: 'GET',
370
- headers: headerParameters,
371
- query: queryParameters,
372
- }, initOverrides);
373
- return new runtime.JSONApiResponse(response, (jsonValue) => Allowlist.AllowlistFromJSON(jsonValue));
374
- });
340
+ }
341
+ const response = await this.request({
342
+ path: `/allowlists/{allowlistId}`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
343
+ method: 'GET',
344
+ headers: headerParameters,
345
+ query: queryParameters,
346
+ }, initOverrides);
347
+ return new runtime.JSONApiResponse(response, (jsonValue) => Allowlist.AllowlistFromJSON(jsonValue));
375
348
  }
376
349
  /**
377
350
  * Returns an allowlist by its unique identifier.
378
351
  * Get allowlist by id
379
352
  */
380
- getAllowlistsById(requestParameters, initOverrides) {
381
- return _tslib.__awaiter(this, void 0, void 0, function* () {
382
- const response = yield this.getAllowlistsByIdRaw(requestParameters, initOverrides);
383
- return yield response.value();
384
- });
353
+ async getAllowlistsById(requestParameters, initOverrides) {
354
+ const response = await this.getAllowlistsByIdRaw(requestParameters, initOverrides);
355
+ return await response.value();
385
356
  }
386
357
  /**
387
358
  * Returns all entries for the specified allowlist.
388
359
  * Get all entries for an allowlist
389
360
  */
390
- getEntriesByAllowlistIdRaw(requestParameters, initOverrides) {
391
- return _tslib.__awaiter(this, void 0, void 0, function* () {
392
- if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
393
- throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling getEntriesByAllowlistId.');
394
- }
395
- const queryParameters = {};
396
- if (requestParameters.orderBy !== undefined) {
397
- queryParameters['orderBy'] = requestParameters.orderBy;
361
+ async getEntriesByAllowlistIdRaw(requestParameters, initOverrides) {
362
+ if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
363
+ throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling getEntriesByAllowlistId.');
364
+ }
365
+ const queryParameters = {};
366
+ if (requestParameters.orderBy !== undefined) {
367
+ queryParameters['orderBy'] = requestParameters.orderBy;
368
+ }
369
+ if (requestParameters.offset !== undefined) {
370
+ queryParameters['offset'] = requestParameters.offset;
371
+ }
372
+ if (requestParameters.limit !== undefined) {
373
+ queryParameters['limit'] = requestParameters.limit;
374
+ }
375
+ if (requestParameters.query !== undefined) {
376
+ queryParameters['query'] = requestParameters.query;
377
+ }
378
+ const headerParameters = {};
379
+ if (this.configuration && this.configuration.accessToken) {
380
+ const token = this.configuration.accessToken;
381
+ const tokenString = await token("bearerAuth", []);
382
+ if (tokenString) {
383
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
398
384
  }
399
- if (requestParameters.offset !== undefined) {
400
- queryParameters['offset'] = requestParameters.offset;
401
- }
402
- if (requestParameters.limit !== undefined) {
403
- queryParameters['limit'] = requestParameters.limit;
404
- }
405
- if (requestParameters.query !== undefined) {
406
- queryParameters['query'] = requestParameters.query;
407
- }
408
- const headerParameters = {};
409
- if (this.configuration && this.configuration.accessToken) {
410
- const token = this.configuration.accessToken;
411
- const tokenString = yield token("bearerAuth", []);
412
- if (tokenString) {
413
- headerParameters["Authorization"] = `Bearer ${tokenString}`;
414
- }
415
- }
416
- const response = yield this.request({
417
- path: `/allowlists/{allowlistId}/entries`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
418
- method: 'GET',
419
- headers: headerParameters,
420
- query: queryParameters,
421
- }, initOverrides);
422
- return new runtime.JSONApiResponse(response, (jsonValue) => AllowlistEntriesResponse.AllowlistEntriesResponseFromJSON(jsonValue));
423
- });
385
+ }
386
+ const response = await this.request({
387
+ path: `/allowlists/{allowlistId}/entries`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
388
+ method: 'GET',
389
+ headers: headerParameters,
390
+ query: queryParameters,
391
+ }, initOverrides);
392
+ return new runtime.JSONApiResponse(response, (jsonValue) => AllowlistEntriesResponse.AllowlistEntriesResponseFromJSON(jsonValue));
424
393
  }
425
394
  /**
426
395
  * Returns all entries for the specified allowlist.
427
396
  * Get all entries for an allowlist
428
397
  */
429
- getEntriesByAllowlistId(requestParameters, initOverrides) {
430
- return _tslib.__awaiter(this, void 0, void 0, function* () {
431
- const response = yield this.getEntriesByAllowlistIdRaw(requestParameters, initOverrides);
432
- return yield response.value();
433
- });
398
+ async getEntriesByAllowlistId(requestParameters, initOverrides) {
399
+ const response = await this.getEntriesByAllowlistIdRaw(requestParameters, initOverrides);
400
+ return await response.value();
434
401
  }
435
402
  /**
436
403
  * Creates a new entry for the specified allowlist.
437
404
  * Create an allowlist entry
438
405
  */
439
- postEntryByAllowlistIdRaw(requestParameters, initOverrides) {
440
- return _tslib.__awaiter(this, void 0, void 0, function* () {
441
- if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
442
- throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling postEntryByAllowlistId.');
406
+ async postEntryByAllowlistIdRaw(requestParameters, initOverrides) {
407
+ if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
408
+ throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling postEntryByAllowlistId.');
409
+ }
410
+ if (requestParameters.postAllowlistEntriesRequest === null || requestParameters.postAllowlistEntriesRequest === undefined) {
411
+ throw new runtime.RequiredError('postAllowlistEntriesRequest', 'Required parameter requestParameters.postAllowlistEntriesRequest was null or undefined when calling postEntryByAllowlistId.');
412
+ }
413
+ const queryParameters = {};
414
+ const headerParameters = {};
415
+ headerParameters['Content-Type'] = 'application/json';
416
+ if (this.configuration && this.configuration.accessToken) {
417
+ const token = this.configuration.accessToken;
418
+ const tokenString = await token("bearerAuth", []);
419
+ if (tokenString) {
420
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
443
421
  }
444
- if (requestParameters.postAllowlistEntriesRequest === null || requestParameters.postAllowlistEntriesRequest === undefined) {
445
- throw new runtime.RequiredError('postAllowlistEntriesRequest', 'Required parameter requestParameters.postAllowlistEntriesRequest was null or undefined when calling postEntryByAllowlistId.');
446
- }
447
- const queryParameters = {};
448
- const headerParameters = {};
449
- headerParameters['Content-Type'] = 'application/json';
450
- if (this.configuration && this.configuration.accessToken) {
451
- const token = this.configuration.accessToken;
452
- const tokenString = yield token("bearerAuth", []);
453
- if (tokenString) {
454
- headerParameters["Authorization"] = `Bearer ${tokenString}`;
455
- }
456
- }
457
- const response = yield this.request({
458
- path: `/allowlists/{allowlistId}/entries`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
459
- method: 'POST',
460
- headers: headerParameters,
461
- query: queryParameters,
462
- body: PostAllowlistEntriesRequest.PostAllowlistEntriesRequestToJSON(requestParameters.postAllowlistEntriesRequest),
463
- }, initOverrides);
464
- return new runtime.JSONApiResponse(response, (jsonValue) => AllowlistEntry.AllowlistEntryFromJSON(jsonValue));
465
- });
422
+ }
423
+ const response = await this.request({
424
+ path: `/allowlists/{allowlistId}/entries`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
425
+ method: 'POST',
426
+ headers: headerParameters,
427
+ query: queryParameters,
428
+ body: PostAllowlistEntriesRequest.PostAllowlistEntriesRequestToJSON(requestParameters.postAllowlistEntriesRequest),
429
+ }, initOverrides);
430
+ return new runtime.JSONApiResponse(response, (jsonValue) => AllowlistEntry.AllowlistEntryFromJSON(jsonValue));
466
431
  }
467
432
  /**
468
433
  * Creates a new entry for the specified allowlist.
469
434
  * Create an allowlist entry
470
435
  */
471
- postEntryByAllowlistId(requestParameters, initOverrides) {
472
- return _tslib.__awaiter(this, void 0, void 0, function* () {
473
- const response = yield this.postEntryByAllowlistIdRaw(requestParameters, initOverrides);
474
- return yield response.value();
475
- });
436
+ async postEntryByAllowlistId(requestParameters, initOverrides) {
437
+ const response = await this.postEntryByAllowlistIdRaw(requestParameters, initOverrides);
438
+ return await response.value();
476
439
  }
477
440
  /**
478
441
  * Updates the specified allowlist.
479
442
  * Update the outcome, scope, or name of an allowlist entry by ID
480
443
  */
481
- updateAllowlistByIdRaw(requestParameters, initOverrides) {
482
- return _tslib.__awaiter(this, void 0, void 0, function* () {
483
- if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
484
- throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling updateAllowlistById.');
485
- }
486
- if (requestParameters.postAllowlistsRequest === null || requestParameters.postAllowlistsRequest === undefined) {
487
- throw new runtime.RequiredError('postAllowlistsRequest', 'Required parameter requestParameters.postAllowlistsRequest was null or undefined when calling updateAllowlistById.');
488
- }
489
- const queryParameters = {};
490
- const headerParameters = {};
491
- headerParameters['Content-Type'] = 'application/json';
492
- if (this.configuration && this.configuration.accessToken) {
493
- const token = this.configuration.accessToken;
494
- const tokenString = yield token("bearerAuth", []);
495
- if (tokenString) {
496
- headerParameters["Authorization"] = `Bearer ${tokenString}`;
497
- }
444
+ async updateAllowlistByIdRaw(requestParameters, initOverrides) {
445
+ if (requestParameters.allowlistId === null || requestParameters.allowlistId === undefined) {
446
+ throw new runtime.RequiredError('allowlistId', 'Required parameter requestParameters.allowlistId was null or undefined when calling updateAllowlistById.');
447
+ }
448
+ if (requestParameters.postAllowlistsRequest === null || requestParameters.postAllowlistsRequest === undefined) {
449
+ throw new runtime.RequiredError('postAllowlistsRequest', 'Required parameter requestParameters.postAllowlistsRequest was null or undefined when calling updateAllowlistById.');
450
+ }
451
+ const queryParameters = {};
452
+ const headerParameters = {};
453
+ headerParameters['Content-Type'] = 'application/json';
454
+ if (this.configuration && this.configuration.accessToken) {
455
+ const token = this.configuration.accessToken;
456
+ const tokenString = await token("bearerAuth", []);
457
+ if (tokenString) {
458
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
498
459
  }
499
- const response = yield this.request({
500
- path: `/allowlists/{allowlistId}`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
501
- method: 'PUT',
502
- headers: headerParameters,
503
- query: queryParameters,
504
- body: PostAllowlistsRequest.PostAllowlistsRequestToJSON(requestParameters.postAllowlistsRequest),
505
- }, initOverrides);
506
- return new runtime.JSONApiResponse(response, (jsonValue) => Allowlist.AllowlistFromJSON(jsonValue));
507
- });
460
+ }
461
+ const response = await this.request({
462
+ path: `/allowlists/{allowlistId}`.replace(`{${"allowlistId"}}`, encodeURIComponent(String(requestParameters.allowlistId))),
463
+ method: 'PUT',
464
+ headers: headerParameters,
465
+ query: queryParameters,
466
+ body: PostAllowlistsRequest.PostAllowlistsRequestToJSON(requestParameters.postAllowlistsRequest),
467
+ }, initOverrides);
468
+ return new runtime.JSONApiResponse(response, (jsonValue) => Allowlist.AllowlistFromJSON(jsonValue));
508
469
  }
509
470
  /**
510
471
  * Updates the specified allowlist.
511
472
  * Update the outcome, scope, or name of an allowlist entry by ID
512
473
  */
513
- updateAllowlistById(requestParameters, initOverrides) {
514
- return _tslib.__awaiter(this, void 0, void 0, function* () {
515
- const response = yield this.updateAllowlistByIdRaw(requestParameters, initOverrides);
516
- return yield response.value();
517
- });
474
+ async updateAllowlistById(requestParameters, initOverrides) {
475
+ const response = await this.updateAllowlistByIdRaw(requestParameters, initOverrides);
476
+ return await response.value();
518
477
  }
519
478
  }
520
479