@emilgroup/account-sdk 1.39.1-beta.21 → 1.39.1-beta.23

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.
package/README.md CHANGED
@@ -17,11 +17,11 @@ Although this package can be used in both TypeScript and JavaScript, it is inten
17
17
  Navigate to the folder of your consuming project and run one of the following commands:
18
18
 
19
19
  ```
20
- npm install @emilgroup/account-sdk@1.39.1-beta.21 --save
20
+ npm install @emilgroup/account-sdk@1.39.1-beta.23 --save
21
21
  ```
22
22
  or
23
23
  ```
24
- yarn add @emilgroup/account-sdk@1.39.1-beta.21
24
+ yarn add @emilgroup/account-sdk@1.39.1-beta.23
25
25
  ```
26
26
 
27
27
  And then you can import `AccountsApi`.
@@ -171,6 +171,56 @@ export const AccountsApiAxiosParamCreator = function (configuration?: Configurat
171
171
 
172
172
 
173
173
 
174
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
175
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
176
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
177
+
178
+ return {
179
+ url: toPathString(localVarUrlObj),
180
+ options: localVarRequestOptions,
181
+ };
182
+ },
183
+ /**
184
+ * Retrieves the details of the account that was previously created. Supply the email that was returned when you created it and Emil Api will return the corresponding account information. Email matching is case-insensitive. **Required Permissions** \"partner-management.partners.view\"
185
+ * @summary Retrieve the account
186
+ * @param {string} email
187
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
188
+ * @param {'policies'} [expand]
189
+ * @param {*} [options] Override http request option.
190
+ * @throws {RequiredError}
191
+ */
192
+ getAccountByEmail: async (email: string, authorization?: string, expand?: 'policies', options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
193
+ // verify required parameter 'email' is not null or undefined
194
+ assertParamExists('getAccountByEmail', 'email', email)
195
+ const localVarPath = `/accountservice/v1/accounts/by-email/{email}`
196
+ .replace(`{${"email"}}`, encodeURIComponent(String(email)));
197
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
198
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
199
+ let baseOptions;
200
+ let baseAccessToken;
201
+ if (configuration) {
202
+ baseOptions = configuration.baseOptions;
203
+ baseAccessToken = configuration.accessToken;
204
+ }
205
+
206
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
207
+ const localVarHeaderParameter = {} as any;
208
+ const localVarQueryParameter = {} as any;
209
+
210
+ // authentication bearer required
211
+ // http bearer authentication required
212
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
213
+
214
+ if (expand !== undefined) {
215
+ localVarQueryParameter['expand'] = expand;
216
+ }
217
+
218
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
219
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
220
+ }
221
+
222
+
223
+
174
224
  setSearchParams(localVarUrlObj, localVarQueryParameter);
175
225
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
176
226
  localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
@@ -354,6 +404,19 @@ export const AccountsApiFp = function(configuration?: Configuration) {
354
404
  const localVarAxiosArgs = await localVarAxiosParamCreator.getAccount(code, authorization, expand, options);
355
405
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
356
406
  },
407
+ /**
408
+ * Retrieves the details of the account that was previously created. Supply the email that was returned when you created it and Emil Api will return the corresponding account information. Email matching is case-insensitive. **Required Permissions** \"partner-management.partners.view\"
409
+ * @summary Retrieve the account
410
+ * @param {string} email
411
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
412
+ * @param {'policies'} [expand]
413
+ * @param {*} [options] Override http request option.
414
+ * @throws {RequiredError}
415
+ */
416
+ async getAccountByEmail(email: string, authorization?: string, expand?: 'policies', options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetAccountResponseClass>> {
417
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getAccountByEmail(email, authorization, expand, options);
418
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
419
+ },
357
420
  /**
358
421
  * Returns a list of accounts you have previously created. The accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"partner-management.partners.view\"
359
422
  * @summary List accounts
@@ -429,6 +492,18 @@ export const AccountsApiFactory = function (configuration?: Configuration, baseP
429
492
  getAccount(code: string, authorization?: string, expand?: 'policies', options?: any): AxiosPromise<GetAccountResponseClass> {
430
493
  return localVarFp.getAccount(code, authorization, expand, options).then((request) => request(axios, basePath));
431
494
  },
495
+ /**
496
+ * Retrieves the details of the account that was previously created. Supply the email that was returned when you created it and Emil Api will return the corresponding account information. Email matching is case-insensitive. **Required Permissions** \"partner-management.partners.view\"
497
+ * @summary Retrieve the account
498
+ * @param {string} email
499
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
500
+ * @param {'policies'} [expand]
501
+ * @param {*} [options] Override http request option.
502
+ * @throws {RequiredError}
503
+ */
504
+ getAccountByEmail(email: string, authorization?: string, expand?: 'policies', options?: any): AxiosPromise<GetAccountResponseClass> {
505
+ return localVarFp.getAccountByEmail(email, authorization, expand, options).then((request) => request(axios, basePath));
506
+ },
432
507
  /**
433
508
  * Returns a list of accounts you have previously created. The accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"partner-management.partners.view\"
434
509
  * @summary List accounts
@@ -531,6 +606,34 @@ export interface AccountsApiGetAccountRequest {
531
606
  readonly expand?: 'policies'
532
607
  }
533
608
 
609
+ /**
610
+ * Request parameters for getAccountByEmail operation in AccountsApi.
611
+ * @export
612
+ * @interface AccountsApiGetAccountByEmailRequest
613
+ */
614
+ export interface AccountsApiGetAccountByEmailRequest {
615
+ /**
616
+ *
617
+ * @type {string}
618
+ * @memberof AccountsApiGetAccountByEmail
619
+ */
620
+ readonly email: string
621
+
622
+ /**
623
+ * Bearer Token: provided by the login endpoint under the name accessToken.
624
+ * @type {string}
625
+ * @memberof AccountsApiGetAccountByEmail
626
+ */
627
+ readonly authorization?: string
628
+
629
+ /**
630
+ *
631
+ * @type {'policies'}
632
+ * @memberof AccountsApiGetAccountByEmail
633
+ */
634
+ readonly expand?: 'policies'
635
+ }
636
+
534
637
  /**
535
638
  * Request parameters for listAccounts operation in AccountsApi.
536
639
  * @export
@@ -665,6 +768,18 @@ export class AccountsApi extends BaseAPI {
665
768
  return AccountsApiFp(this.configuration).getAccount(requestParameters.code, requestParameters.authorization, requestParameters.expand, options).then((request) => request(this.axios, this.basePath));
666
769
  }
667
770
 
771
+ /**
772
+ * Retrieves the details of the account that was previously created. Supply the email that was returned when you created it and Emil Api will return the corresponding account information. Email matching is case-insensitive. **Required Permissions** \"partner-management.partners.view\"
773
+ * @summary Retrieve the account
774
+ * @param {AccountsApiGetAccountByEmailRequest} requestParameters Request parameters.
775
+ * @param {*} [options] Override http request option.
776
+ * @throws {RequiredError}
777
+ * @memberof AccountsApi
778
+ */
779
+ public getAccountByEmail(requestParameters: AccountsApiGetAccountByEmailRequest, options?: AxiosRequestConfig) {
780
+ return AccountsApiFp(this.configuration).getAccountByEmail(requestParameters.email, requestParameters.authorization, requestParameters.expand, options).then((request) => request(this.axios, this.basePath));
781
+ }
782
+
668
783
  /**
669
784
  * Returns a list of accounts you have previously created. The accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"partner-management.partners.view\"
670
785
  * @summary List accounts
@@ -51,6 +51,16 @@ export declare const AccountsApiAxiosParamCreator: (configuration?: Configuratio
51
51
  * @throws {RequiredError}
52
52
  */
53
53
  getAccount: (code: string, authorization?: string, expand?: 'policies', options?: AxiosRequestConfig) => Promise<RequestArgs>;
54
+ /**
55
+ * Retrieves the details of the account that was previously created. Supply the email that was returned when you created it and Emil Api will return the corresponding account information. Email matching is case-insensitive. **Required Permissions** \"partner-management.partners.view\"
56
+ * @summary Retrieve the account
57
+ * @param {string} email
58
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
59
+ * @param {'policies'} [expand]
60
+ * @param {*} [options] Override http request option.
61
+ * @throws {RequiredError}
62
+ */
63
+ getAccountByEmail: (email: string, authorization?: string, expand?: 'policies', options?: AxiosRequestConfig) => Promise<RequestArgs>;
54
64
  /**
55
65
  * Returns a list of accounts you have previously created. The accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"partner-management.partners.view\"
56
66
  * @summary List accounts
@@ -110,6 +120,16 @@ export declare const AccountsApiFp: (configuration?: Configuration) => {
110
120
  * @throws {RequiredError}
111
121
  */
112
122
  getAccount(code: string, authorization?: string, expand?: 'policies', options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetAccountResponseClass>>;
123
+ /**
124
+ * Retrieves the details of the account that was previously created. Supply the email that was returned when you created it and Emil Api will return the corresponding account information. Email matching is case-insensitive. **Required Permissions** \"partner-management.partners.view\"
125
+ * @summary Retrieve the account
126
+ * @param {string} email
127
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
128
+ * @param {'policies'} [expand]
129
+ * @param {*} [options] Override http request option.
130
+ * @throws {RequiredError}
131
+ */
132
+ getAccountByEmail(email: string, authorization?: string, expand?: 'policies', options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetAccountResponseClass>>;
113
133
  /**
114
134
  * Returns a list of accounts you have previously created. The accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"partner-management.partners.view\"
115
135
  * @summary List accounts
@@ -169,6 +189,16 @@ export declare const AccountsApiFactory: (configuration?: Configuration, basePat
169
189
  * @throws {RequiredError}
170
190
  */
171
191
  getAccount(code: string, authorization?: string, expand?: 'policies', options?: any): AxiosPromise<GetAccountResponseClass>;
192
+ /**
193
+ * Retrieves the details of the account that was previously created. Supply the email that was returned when you created it and Emil Api will return the corresponding account information. Email matching is case-insensitive. **Required Permissions** \"partner-management.partners.view\"
194
+ * @summary Retrieve the account
195
+ * @param {string} email
196
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
197
+ * @param {'policies'} [expand]
198
+ * @param {*} [options] Override http request option.
199
+ * @throws {RequiredError}
200
+ */
201
+ getAccountByEmail(email: string, authorization?: string, expand?: 'policies', options?: any): AxiosPromise<GetAccountResponseClass>;
172
202
  /**
173
203
  * Returns a list of accounts you have previously created. The accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"partner-management.partners.view\"
174
204
  * @summary List accounts
@@ -258,6 +288,31 @@ export interface AccountsApiGetAccountRequest {
258
288
  */
259
289
  readonly expand?: 'policies';
260
290
  }
291
+ /**
292
+ * Request parameters for getAccountByEmail operation in AccountsApi.
293
+ * @export
294
+ * @interface AccountsApiGetAccountByEmailRequest
295
+ */
296
+ export interface AccountsApiGetAccountByEmailRequest {
297
+ /**
298
+ *
299
+ * @type {string}
300
+ * @memberof AccountsApiGetAccountByEmail
301
+ */
302
+ readonly email: string;
303
+ /**
304
+ * Bearer Token: provided by the login endpoint under the name accessToken.
305
+ * @type {string}
306
+ * @memberof AccountsApiGetAccountByEmail
307
+ */
308
+ readonly authorization?: string;
309
+ /**
310
+ *
311
+ * @type {'policies'}
312
+ * @memberof AccountsApiGetAccountByEmail
313
+ */
314
+ readonly expand?: 'policies';
315
+ }
261
316
  /**
262
317
  * Request parameters for listAccounts operation in AccountsApi.
263
318
  * @export
@@ -372,6 +427,15 @@ export declare class AccountsApi extends BaseAPI {
372
427
  * @memberof AccountsApi
373
428
  */
374
429
  getAccount(requestParameters: AccountsApiGetAccountRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetAccountResponseClass, any, {}>>;
430
+ /**
431
+ * Retrieves the details of the account that was previously created. Supply the email that was returned when you created it and Emil Api will return the corresponding account information. Email matching is case-insensitive. **Required Permissions** \"partner-management.partners.view\"
432
+ * @summary Retrieve the account
433
+ * @param {AccountsApiGetAccountByEmailRequest} requestParameters Request parameters.
434
+ * @param {*} [options] Override http request option.
435
+ * @throws {RequiredError}
436
+ * @memberof AccountsApi
437
+ */
438
+ getAccountByEmail(requestParameters: AccountsApiGetAccountByEmailRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetAccountResponseClass, any, {}>>;
375
439
  /**
376
440
  * Returns a list of accounts you have previously created. The accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"partner-management.partners.view\"
377
441
  * @summary List accounts
@@ -241,6 +241,58 @@ var AccountsApiAxiosParamCreator = function (configuration) {
241
241
  });
242
242
  });
243
243
  },
244
+ /**
245
+ * Retrieves the details of the account that was previously created. Supply the email that was returned when you created it and Emil Api will return the corresponding account information. Email matching is case-insensitive. **Required Permissions** \"partner-management.partners.view\"
246
+ * @summary Retrieve the account
247
+ * @param {string} email
248
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
249
+ * @param {'policies'} [expand]
250
+ * @param {*} [options] Override http request option.
251
+ * @throws {RequiredError}
252
+ */
253
+ getAccountByEmail: function (email, authorization, expand, options) {
254
+ if (options === void 0) { options = {}; }
255
+ return __awaiter(_this, void 0, void 0, function () {
256
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
257
+ return __generator(this, function (_a) {
258
+ switch (_a.label) {
259
+ case 0:
260
+ // verify required parameter 'email' is not null or undefined
261
+ (0, common_1.assertParamExists)('getAccountByEmail', 'email', email);
262
+ localVarPath = "/accountservice/v1/accounts/by-email/{email}"
263
+ .replace("{".concat("email", "}"), encodeURIComponent(String(email)));
264
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
265
+ if (configuration) {
266
+ baseOptions = configuration.baseOptions;
267
+ baseAccessToken = configuration.accessToken;
268
+ }
269
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
270
+ localVarHeaderParameter = {};
271
+ localVarQueryParameter = {};
272
+ // authentication bearer required
273
+ // http bearer authentication required
274
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
275
+ case 1:
276
+ // authentication bearer required
277
+ // http bearer authentication required
278
+ _a.sent();
279
+ if (expand !== undefined) {
280
+ localVarQueryParameter['expand'] = expand;
281
+ }
282
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
283
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
284
+ }
285
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
286
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
287
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
288
+ return [2 /*return*/, {
289
+ url: (0, common_1.toPathString)(localVarUrlObj),
290
+ options: localVarRequestOptions,
291
+ }];
292
+ }
293
+ });
294
+ });
295
+ },
244
296
  /**
245
297
  * Returns a list of accounts you have previously created. The accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"partner-management.partners.view\"
246
298
  * @summary List accounts
@@ -440,6 +492,28 @@ var AccountsApiFp = function (configuration) {
440
492
  });
441
493
  });
442
494
  },
495
+ /**
496
+ * Retrieves the details of the account that was previously created. Supply the email that was returned when you created it and Emil Api will return the corresponding account information. Email matching is case-insensitive. **Required Permissions** \"partner-management.partners.view\"
497
+ * @summary Retrieve the account
498
+ * @param {string} email
499
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
500
+ * @param {'policies'} [expand]
501
+ * @param {*} [options] Override http request option.
502
+ * @throws {RequiredError}
503
+ */
504
+ getAccountByEmail: function (email, authorization, expand, options) {
505
+ return __awaiter(this, void 0, void 0, function () {
506
+ var localVarAxiosArgs;
507
+ return __generator(this, function (_a) {
508
+ switch (_a.label) {
509
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.getAccountByEmail(email, authorization, expand, options)];
510
+ case 1:
511
+ localVarAxiosArgs = _a.sent();
512
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
513
+ }
514
+ });
515
+ });
516
+ },
443
517
  /**
444
518
  * Returns a list of accounts you have previously created. The accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"partner-management.partners.view\"
445
519
  * @summary List accounts
@@ -533,6 +607,18 @@ var AccountsApiFactory = function (configuration, basePath, axios) {
533
607
  getAccount: function (code, authorization, expand, options) {
534
608
  return localVarFp.getAccount(code, authorization, expand, options).then(function (request) { return request(axios, basePath); });
535
609
  },
610
+ /**
611
+ * Retrieves the details of the account that was previously created. Supply the email that was returned when you created it and Emil Api will return the corresponding account information. Email matching is case-insensitive. **Required Permissions** \"partner-management.partners.view\"
612
+ * @summary Retrieve the account
613
+ * @param {string} email
614
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
615
+ * @param {'policies'} [expand]
616
+ * @param {*} [options] Override http request option.
617
+ * @throws {RequiredError}
618
+ */
619
+ getAccountByEmail: function (email, authorization, expand, options) {
620
+ return localVarFp.getAccountByEmail(email, authorization, expand, options).then(function (request) { return request(axios, basePath); });
621
+ },
536
622
  /**
537
623
  * Returns a list of accounts you have previously created. The accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"partner-management.partners.view\"
538
624
  * @summary List accounts
@@ -612,6 +698,18 @@ var AccountsApi = /** @class */ (function (_super) {
612
698
  var _this = this;
613
699
  return (0, exports.AccountsApiFp)(this.configuration).getAccount(requestParameters.code, requestParameters.authorization, requestParameters.expand, options).then(function (request) { return request(_this.axios, _this.basePath); });
614
700
  };
701
+ /**
702
+ * Retrieves the details of the account that was previously created. Supply the email that was returned when you created it and Emil Api will return the corresponding account information. Email matching is case-insensitive. **Required Permissions** \"partner-management.partners.view\"
703
+ * @summary Retrieve the account
704
+ * @param {AccountsApiGetAccountByEmailRequest} requestParameters Request parameters.
705
+ * @param {*} [options] Override http request option.
706
+ * @throws {RequiredError}
707
+ * @memberof AccountsApi
708
+ */
709
+ AccountsApi.prototype.getAccountByEmail = function (requestParameters, options) {
710
+ var _this = this;
711
+ return (0, exports.AccountsApiFp)(this.configuration).getAccountByEmail(requestParameters.email, requestParameters.authorization, requestParameters.expand, options).then(function (request) { return request(_this.axios, _this.basePath); });
712
+ };
615
713
  /**
616
714
  * Returns a list of accounts you have previously created. The accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"partner-management.partners.view\"
617
715
  * @summary List accounts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@emilgroup/account-sdk",
3
- "version": "1.39.1-beta.21",
3
+ "version": "1.39.1-beta.23",
4
4
  "description": "OpenAPI client for @emilgroup/account-sdk",
5
5
  "author": "OpenAPI-Generator Contributors",
6
6
  "keywords": [