@emilgroup/account-sdk-node 1.35.1-beta.0 → 1.35.1-beta.2

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-node@1.35.1-beta.0 --save
20
+ npm install @emilgroup/account-sdk-node@1.35.1-beta.2 --save
21
21
  ```
22
22
  or
23
23
  ```
24
- yarn add @emilgroup/account-sdk-node@1.35.1-beta.0
24
+ yarn add @emilgroup/account-sdk-node@1.35.1-beta.2
25
25
  ```
26
26
 
27
27
  And then you can import `AccountsApi`.
@@ -43,7 +43,7 @@ const FormData = require('form-data');
43
43
  export const AccountsApiAxiosParamCreator = function (configuration?: Configuration) {
44
44
  return {
45
45
  /**
46
- * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information. **Required Permissions** \"partner-management.accounts.create\"
46
+ * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information.
47
47
  * @summary Create the account
48
48
  * @param {CreateAccountRequestDto} createAccountRequestDto
49
49
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -90,7 +90,7 @@ export const AccountsApiAxiosParamCreator = function (configuration?: Configurat
90
90
  };
91
91
  },
92
92
  /**
93
- * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it. **Required Permissions** \"partner-management.accounts.delete\"
93
+ * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it.
94
94
  * @summary Delete the account
95
95
  * @param {string} code Unique identifier for the object.
96
96
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -135,7 +135,7 @@ export const AccountsApiAxiosParamCreator = function (configuration?: Configurat
135
135
  };
136
136
  },
137
137
  /**
138
- * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information. **Required Permissions** \"partner-management.accounts.view\"
138
+ * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information.
139
139
  * @summary Retrieve the account
140
140
  * @param {string} code Unique identifier for the object.
141
141
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -185,7 +185,7 @@ export const AccountsApiAxiosParamCreator = function (configuration?: Configurat
185
185
  };
186
186
  },
187
187
  /**
188
- * 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.accounts.view\"
188
+ * 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.
189
189
  * @summary List accounts
190
190
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
191
191
  * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
@@ -261,7 +261,7 @@ export const AccountsApiAxiosParamCreator = function (configuration?: Configurat
261
261
  };
262
262
  },
263
263
  /**
264
- * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"partner-management.accounts.update\"
264
+ * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
265
265
  * @summary Update the account
266
266
  * @param {string} code Unique identifier for the object.
267
267
  * @param {UpdateAccountRequestDto} updateAccountRequestDto
@@ -322,7 +322,7 @@ export const AccountsApiFp = function(configuration?: Configuration) {
322
322
  const localVarAxiosParamCreator = AccountsApiAxiosParamCreator(configuration)
323
323
  return {
324
324
  /**
325
- * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information. **Required Permissions** \"partner-management.accounts.create\"
325
+ * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information.
326
326
  * @summary Create the account
327
327
  * @param {CreateAccountRequestDto} createAccountRequestDto
328
328
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -334,7 +334,7 @@ export const AccountsApiFp = function(configuration?: Configuration) {
334
334
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
335
335
  },
336
336
  /**
337
- * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it. **Required Permissions** \"partner-management.accounts.delete\"
337
+ * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it.
338
338
  * @summary Delete the account
339
339
  * @param {string} code Unique identifier for the object.
340
340
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -346,7 +346,7 @@ export const AccountsApiFp = function(configuration?: Configuration) {
346
346
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
347
347
  },
348
348
  /**
349
- * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information. **Required Permissions** \"partner-management.accounts.view\"
349
+ * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information.
350
350
  * @summary Retrieve the account
351
351
  * @param {string} code Unique identifier for the object.
352
352
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -359,7 +359,7 @@ export const AccountsApiFp = function(configuration?: Configuration) {
359
359
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
360
360
  },
361
361
  /**
362
- * 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.accounts.view\"
362
+ * 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.
363
363
  * @summary List accounts
364
364
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
365
365
  * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
@@ -377,7 +377,7 @@ export const AccountsApiFp = function(configuration?: Configuration) {
377
377
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
378
378
  },
379
379
  /**
380
- * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"partner-management.accounts.update\"
380
+ * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
381
381
  * @summary Update the account
382
382
  * @param {string} code Unique identifier for the object.
383
383
  * @param {UpdateAccountRequestDto} updateAccountRequestDto
@@ -400,7 +400,7 @@ export const AccountsApiFactory = function (configuration?: Configuration, baseP
400
400
  const localVarFp = AccountsApiFp(configuration)
401
401
  return {
402
402
  /**
403
- * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information. **Required Permissions** \"partner-management.accounts.create\"
403
+ * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information.
404
404
  * @summary Create the account
405
405
  * @param {CreateAccountRequestDto} createAccountRequestDto
406
406
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -411,7 +411,7 @@ export const AccountsApiFactory = function (configuration?: Configuration, baseP
411
411
  return localVarFp.createAccount(createAccountRequestDto, authorization, options).then((request) => request(axios, basePath));
412
412
  },
413
413
  /**
414
- * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it. **Required Permissions** \"partner-management.accounts.delete\"
414
+ * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it.
415
415
  * @summary Delete the account
416
416
  * @param {string} code Unique identifier for the object.
417
417
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -422,7 +422,7 @@ export const AccountsApiFactory = function (configuration?: Configuration, baseP
422
422
  return localVarFp.deleteAccount(code, authorization, options).then((request) => request(axios, basePath));
423
423
  },
424
424
  /**
425
- * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information. **Required Permissions** \"partner-management.accounts.view\"
425
+ * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information.
426
426
  * @summary Retrieve the account
427
427
  * @param {string} code Unique identifier for the object.
428
428
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -434,7 +434,7 @@ export const AccountsApiFactory = function (configuration?: Configuration, baseP
434
434
  return localVarFp.getAccount(code, authorization, expand, options).then((request) => request(axios, basePath));
435
435
  },
436
436
  /**
437
- * 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.accounts.view\"
437
+ * 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.
438
438
  * @summary List accounts
439
439
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
440
440
  * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
@@ -451,7 +451,7 @@ export const AccountsApiFactory = function (configuration?: Configuration, baseP
451
451
  return localVarFp.listAccounts(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then((request) => request(axios, basePath));
452
452
  },
453
453
  /**
454
- * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"partner-management.accounts.update\"
454
+ * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
455
455
  * @summary Update the account
456
456
  * @param {string} code Unique identifier for the object.
457
457
  * @param {UpdateAccountRequestDto} updateAccountRequestDto
@@ -634,7 +634,7 @@ export interface AccountsApiUpdateAccountRequest {
634
634
  */
635
635
  export class AccountsApi extends BaseAPI {
636
636
  /**
637
- * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information. **Required Permissions** \"partner-management.accounts.create\"
637
+ * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information.
638
638
  * @summary Create the account
639
639
  * @param {AccountsApiCreateAccountRequest} requestParameters Request parameters.
640
640
  * @param {*} [options] Override http request option.
@@ -646,7 +646,7 @@ export class AccountsApi extends BaseAPI {
646
646
  }
647
647
 
648
648
  /**
649
- * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it. **Required Permissions** \"partner-management.accounts.delete\"
649
+ * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it.
650
650
  * @summary Delete the account
651
651
  * @param {AccountsApiDeleteAccountRequest} requestParameters Request parameters.
652
652
  * @param {*} [options] Override http request option.
@@ -658,7 +658,7 @@ export class AccountsApi extends BaseAPI {
658
658
  }
659
659
 
660
660
  /**
661
- * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information. **Required Permissions** \"partner-management.accounts.view\"
661
+ * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information.
662
662
  * @summary Retrieve the account
663
663
  * @param {AccountsApiGetAccountRequest} requestParameters Request parameters.
664
664
  * @param {*} [options] Override http request option.
@@ -670,7 +670,7 @@ export class AccountsApi extends BaseAPI {
670
670
  }
671
671
 
672
672
  /**
673
- * 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.accounts.view\"
673
+ * 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.
674
674
  * @summary List accounts
675
675
  * @param {AccountsApiListAccountsRequest} requestParameters Request parameters.
676
676
  * @param {*} [options] Override http request option.
@@ -682,7 +682,7 @@ export class AccountsApi extends BaseAPI {
682
682
  }
683
683
 
684
684
  /**
685
- * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"partner-management.accounts.update\"
685
+ * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
686
686
  * @summary Update the account
687
687
  * @param {AccountsApiUpdateAccountRequest} requestParameters Request parameters.
688
688
  * @param {*} [options] Override http request option.
package/base.ts CHANGED
@@ -225,7 +225,7 @@ export class BaseAPI {
225
225
  const tokenString = await this.refreshTokenInternal();
226
226
  const accessToken = `Bearer ${tokenString}`;
227
227
 
228
- originalConfig.headers['Authorization'] = `Bearer ${accessToken}`
228
+ originalConfig.headers['Authorization'] = accessToken;
229
229
 
230
230
  this.configuration.accessToken = accessToken;
231
231
 
package/common.ts CHANGED
@@ -66,7 +66,7 @@ export const setBearerAuthToObject = async function (object: any, configuration?
66
66
  const accessToken = typeof configuration.accessToken === 'function'
67
67
  ? await configuration.accessToken()
68
68
  : await configuration.accessToken;
69
- object["Authorization"] = "Bearer " + accessToken;
69
+ object["Authorization"] = configuration.getBearerToken(accessToken);
70
70
  }
71
71
  }
72
72
 
@@ -79,7 +79,7 @@ export const setOAuthToObject = async function (object: any, name: string, scope
79
79
  const localVarAccessTokenValue = typeof configuration.accessToken === 'function'
80
80
  ? await configuration.accessToken(name, scopes)
81
81
  : await configuration.accessToken;
82
- object["Authorization"] = "Bearer " + localVarAccessTokenValue;
82
+ object["Authorization"] = configuration.getBearerToken(localVarAccessTokenValue);
83
83
  }
84
84
  }
85
85
 
package/configuration.ts CHANGED
@@ -106,4 +106,13 @@ export class Configuration {
106
106
  const jsonMime: RegExp = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i');
107
107
  return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json');
108
108
  }
109
+
110
+ /**
111
+ * Returns "Bearer" token.
112
+ * @param token - access token.
113
+ * @return Bearer token.
114
+ */
115
+ public getBearerToken(token?: string): string {
116
+ return ('' + token).startsWith("Bearer") ? token : "Bearer " + token;
117
+ }
109
118
  }
@@ -24,7 +24,7 @@ import { UpdateAccountResponseClass } from '../models';
24
24
  */
25
25
  export declare const AccountsApiAxiosParamCreator: (configuration?: Configuration) => {
26
26
  /**
27
- * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information. **Required Permissions** \"partner-management.accounts.create\"
27
+ * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information.
28
28
  * @summary Create the account
29
29
  * @param {CreateAccountRequestDto} createAccountRequestDto
30
30
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -33,7 +33,7 @@ export declare const AccountsApiAxiosParamCreator: (configuration?: Configuratio
33
33
  */
34
34
  createAccount: (createAccountRequestDto: CreateAccountRequestDto, authorization?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
35
35
  /**
36
- * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it. **Required Permissions** \"partner-management.accounts.delete\"
36
+ * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it.
37
37
  * @summary Delete the account
38
38
  * @param {string} code Unique identifier for the object.
39
39
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -42,7 +42,7 @@ export declare const AccountsApiAxiosParamCreator: (configuration?: Configuratio
42
42
  */
43
43
  deleteAccount: (code: string, authorization?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
44
44
  /**
45
- * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information. **Required Permissions** \"partner-management.accounts.view\"
45
+ * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information.
46
46
  * @summary Retrieve the account
47
47
  * @param {string} code Unique identifier for the object.
48
48
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -52,7 +52,7 @@ export declare const AccountsApiAxiosParamCreator: (configuration?: Configuratio
52
52
  */
53
53
  getAccount: (code: string, authorization?: string, expand?: 'policies', options?: AxiosRequestConfig) => Promise<RequestArgs>;
54
54
  /**
55
- * 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.accounts.view\"
55
+ * 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.
56
56
  * @summary List accounts
57
57
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
58
58
  * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
@@ -67,7 +67,7 @@ export declare const AccountsApiAxiosParamCreator: (configuration?: Configuratio
67
67
  */
68
68
  listAccounts: (authorization?: string, pageSize?: any, pageToken?: any, filter?: 'firstName' | 'code' | 'email' | 'createdAt' | 'birthDate' | 'accountNumber' | 'title' | 'lastName' | 'gender' | 'street' | 'houseNumber' | 'zipCode' | 'city' | 'phone' | 'type' | 'companyName' | 'name', search?: any, order?: 'id' | 'firstName' | 'lastName' | 'email' | 'createdAt' | 'accountNumber', expand?: 'policies', filters?: any, options?: AxiosRequestConfig) => Promise<RequestArgs>;
69
69
  /**
70
- * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"partner-management.accounts.update\"
70
+ * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
71
71
  * @summary Update the account
72
72
  * @param {string} code Unique identifier for the object.
73
73
  * @param {UpdateAccountRequestDto} updateAccountRequestDto
@@ -83,7 +83,7 @@ export declare const AccountsApiAxiosParamCreator: (configuration?: Configuratio
83
83
  */
84
84
  export declare const AccountsApiFp: (configuration?: Configuration) => {
85
85
  /**
86
- * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information. **Required Permissions** \"partner-management.accounts.create\"
86
+ * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information.
87
87
  * @summary Create the account
88
88
  * @param {CreateAccountRequestDto} createAccountRequestDto
89
89
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -92,7 +92,7 @@ export declare const AccountsApiFp: (configuration?: Configuration) => {
92
92
  */
93
93
  createAccount(createAccountRequestDto: CreateAccountRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateAccountResponseClass>>;
94
94
  /**
95
- * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it. **Required Permissions** \"partner-management.accounts.delete\"
95
+ * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it.
96
96
  * @summary Delete the account
97
97
  * @param {string} code Unique identifier for the object.
98
98
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -101,7 +101,7 @@ export declare const AccountsApiFp: (configuration?: Configuration) => {
101
101
  */
102
102
  deleteAccount(code: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
103
103
  /**
104
- * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information. **Required Permissions** \"partner-management.accounts.view\"
104
+ * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information.
105
105
  * @summary Retrieve the account
106
106
  * @param {string} code Unique identifier for the object.
107
107
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -111,7 +111,7 @@ export declare const AccountsApiFp: (configuration?: Configuration) => {
111
111
  */
112
112
  getAccount(code: string, authorization?: string, expand?: 'policies', options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetAccountResponseClass>>;
113
113
  /**
114
- * 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.accounts.view\"
114
+ * 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.
115
115
  * @summary List accounts
116
116
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
117
117
  * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
@@ -126,7 +126,7 @@ export declare const AccountsApiFp: (configuration?: Configuration) => {
126
126
  */
127
127
  listAccounts(authorization?: string, pageSize?: any, pageToken?: any, filter?: 'firstName' | 'code' | 'email' | 'createdAt' | 'birthDate' | 'accountNumber' | 'title' | 'lastName' | 'gender' | 'street' | 'houseNumber' | 'zipCode' | 'city' | 'phone' | 'type' | 'companyName' | 'name', search?: any, order?: 'id' | 'firstName' | 'lastName' | 'email' | 'createdAt' | 'accountNumber', expand?: 'policies', filters?: any, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ListAccountsResponseClass>>;
128
128
  /**
129
- * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"partner-management.accounts.update\"
129
+ * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
130
130
  * @summary Update the account
131
131
  * @param {string} code Unique identifier for the object.
132
132
  * @param {UpdateAccountRequestDto} updateAccountRequestDto
@@ -142,7 +142,7 @@ export declare const AccountsApiFp: (configuration?: Configuration) => {
142
142
  */
143
143
  export declare const AccountsApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
144
144
  /**
145
- * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information. **Required Permissions** \"partner-management.accounts.create\"
145
+ * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information.
146
146
  * @summary Create the account
147
147
  * @param {CreateAccountRequestDto} createAccountRequestDto
148
148
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -151,7 +151,7 @@ export declare const AccountsApiFactory: (configuration?: Configuration, basePat
151
151
  */
152
152
  createAccount(createAccountRequestDto: CreateAccountRequestDto, authorization?: string, options?: any): AxiosPromise<CreateAccountResponseClass>;
153
153
  /**
154
- * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it. **Required Permissions** \"partner-management.accounts.delete\"
154
+ * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it.
155
155
  * @summary Delete the account
156
156
  * @param {string} code Unique identifier for the object.
157
157
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -160,7 +160,7 @@ export declare const AccountsApiFactory: (configuration?: Configuration, basePat
160
160
  */
161
161
  deleteAccount(code: string, authorization?: string, options?: any): AxiosPromise<void>;
162
162
  /**
163
- * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information. **Required Permissions** \"partner-management.accounts.view\"
163
+ * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information.
164
164
  * @summary Retrieve the account
165
165
  * @param {string} code Unique identifier for the object.
166
166
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -170,7 +170,7 @@ export declare const AccountsApiFactory: (configuration?: Configuration, basePat
170
170
  */
171
171
  getAccount(code: string, authorization?: string, expand?: 'policies', options?: any): AxiosPromise<GetAccountResponseClass>;
172
172
  /**
173
- * 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.accounts.view\"
173
+ * 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.
174
174
  * @summary List accounts
175
175
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
176
176
  * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
@@ -185,7 +185,7 @@ export declare const AccountsApiFactory: (configuration?: Configuration, basePat
185
185
  */
186
186
  listAccounts(authorization?: string, pageSize?: any, pageToken?: any, filter?: 'firstName' | 'code' | 'email' | 'createdAt' | 'birthDate' | 'accountNumber' | 'title' | 'lastName' | 'gender' | 'street' | 'houseNumber' | 'zipCode' | 'city' | 'phone' | 'type' | 'companyName' | 'name', search?: any, order?: 'id' | 'firstName' | 'lastName' | 'email' | 'createdAt' | 'accountNumber', expand?: 'policies', filters?: any, options?: any): AxiosPromise<ListAccountsResponseClass>;
187
187
  /**
188
- * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"partner-management.accounts.update\"
188
+ * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
189
189
  * @summary Update the account
190
190
  * @param {string} code Unique identifier for the object.
191
191
  * @param {UpdateAccountRequestDto} updateAccountRequestDto
@@ -346,7 +346,7 @@ export interface AccountsApiUpdateAccountRequest {
346
346
  */
347
347
  export declare class AccountsApi extends BaseAPI {
348
348
  /**
349
- * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information. **Required Permissions** \"partner-management.accounts.create\"
349
+ * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information.
350
350
  * @summary Create the account
351
351
  * @param {AccountsApiCreateAccountRequest} requestParameters Request parameters.
352
352
  * @param {*} [options] Override http request option.
@@ -355,7 +355,7 @@ export declare class AccountsApi extends BaseAPI {
355
355
  */
356
356
  createAccount(requestParameters: AccountsApiCreateAccountRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateAccountResponseClass, any>>;
357
357
  /**
358
- * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it. **Required Permissions** \"partner-management.accounts.delete\"
358
+ * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it.
359
359
  * @summary Delete the account
360
360
  * @param {AccountsApiDeleteAccountRequest} requestParameters Request parameters.
361
361
  * @param {*} [options] Override http request option.
@@ -364,7 +364,7 @@ export declare class AccountsApi extends BaseAPI {
364
364
  */
365
365
  deleteAccount(requestParameters: AccountsApiDeleteAccountRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any>>;
366
366
  /**
367
- * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information. **Required Permissions** \"partner-management.accounts.view\"
367
+ * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information.
368
368
  * @summary Retrieve the account
369
369
  * @param {AccountsApiGetAccountRequest} requestParameters Request parameters.
370
370
  * @param {*} [options] Override http request option.
@@ -373,7 +373,7 @@ export declare class AccountsApi extends BaseAPI {
373
373
  */
374
374
  getAccount(requestParameters: AccountsApiGetAccountRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetAccountResponseClass, any>>;
375
375
  /**
376
- * 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.accounts.view\"
376
+ * 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.
377
377
  * @summary List accounts
378
378
  * @param {AccountsApiListAccountsRequest} requestParameters Request parameters.
379
379
  * @param {*} [options] Override http request option.
@@ -382,7 +382,7 @@ export declare class AccountsApi extends BaseAPI {
382
382
  */
383
383
  listAccounts(requestParameters?: AccountsApiListAccountsRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListAccountsResponseClass, any>>;
384
384
  /**
385
- * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"partner-management.accounts.update\"
385
+ * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
386
386
  * @summary Update the account
387
387
  * @param {AccountsApiUpdateAccountRequest} requestParameters Request parameters.
388
388
  * @param {*} [options] Override http request option.
@@ -97,7 +97,7 @@ var AccountsApiAxiosParamCreator = function (configuration) {
97
97
  var _this = this;
98
98
  return {
99
99
  /**
100
- * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information. **Required Permissions** \"partner-management.accounts.create\"
100
+ * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information.
101
101
  * @summary Create the account
102
102
  * @param {CreateAccountRequestDto} createAccountRequestDto
103
103
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -146,7 +146,7 @@ var AccountsApiAxiosParamCreator = function (configuration) {
146
146
  });
147
147
  },
148
148
  /**
149
- * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it. **Required Permissions** \"partner-management.accounts.delete\"
149
+ * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it.
150
150
  * @summary Delete the account
151
151
  * @param {string} code Unique identifier for the object.
152
152
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -194,7 +194,7 @@ var AccountsApiAxiosParamCreator = function (configuration) {
194
194
  });
195
195
  },
196
196
  /**
197
- * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information. **Required Permissions** \"partner-management.accounts.view\"
197
+ * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information.
198
198
  * @summary Retrieve the account
199
199
  * @param {string} code Unique identifier for the object.
200
200
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -246,7 +246,7 @@ var AccountsApiAxiosParamCreator = function (configuration) {
246
246
  });
247
247
  },
248
248
  /**
249
- * 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.accounts.view\"
249
+ * 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.
250
250
  * @summary List accounts
251
251
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
252
252
  * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
@@ -318,7 +318,7 @@ var AccountsApiAxiosParamCreator = function (configuration) {
318
318
  });
319
319
  },
320
320
  /**
321
- * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"partner-management.accounts.update\"
321
+ * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
322
322
  * @summary Update the account
323
323
  * @param {string} code Unique identifier for the object.
324
324
  * @param {UpdateAccountRequestDto} updateAccountRequestDto
@@ -381,7 +381,7 @@ var AccountsApiFp = function (configuration) {
381
381
  var localVarAxiosParamCreator = (0, exports.AccountsApiAxiosParamCreator)(configuration);
382
382
  return {
383
383
  /**
384
- * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information. **Required Permissions** \"partner-management.accounts.create\"
384
+ * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information.
385
385
  * @summary Create the account
386
386
  * @param {CreateAccountRequestDto} createAccountRequestDto
387
387
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -402,7 +402,7 @@ var AccountsApiFp = function (configuration) {
402
402
  });
403
403
  },
404
404
  /**
405
- * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it. **Required Permissions** \"partner-management.accounts.delete\"
405
+ * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it.
406
406
  * @summary Delete the account
407
407
  * @param {string} code Unique identifier for the object.
408
408
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -423,7 +423,7 @@ var AccountsApiFp = function (configuration) {
423
423
  });
424
424
  },
425
425
  /**
426
- * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information. **Required Permissions** \"partner-management.accounts.view\"
426
+ * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information.
427
427
  * @summary Retrieve the account
428
428
  * @param {string} code Unique identifier for the object.
429
429
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -445,7 +445,7 @@ var AccountsApiFp = function (configuration) {
445
445
  });
446
446
  },
447
447
  /**
448
- * 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.accounts.view\"
448
+ * 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.
449
449
  * @summary List accounts
450
450
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
451
451
  * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
@@ -472,7 +472,7 @@ var AccountsApiFp = function (configuration) {
472
472
  });
473
473
  },
474
474
  /**
475
- * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"partner-management.accounts.update\"
475
+ * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
476
476
  * @summary Update the account
477
477
  * @param {string} code Unique identifier for the object.
478
478
  * @param {UpdateAccountRequestDto} updateAccountRequestDto
@@ -504,7 +504,7 @@ var AccountsApiFactory = function (configuration, basePath, axios) {
504
504
  var localVarFp = (0, exports.AccountsApiFp)(configuration);
505
505
  return {
506
506
  /**
507
- * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information. **Required Permissions** \"partner-management.accounts.create\"
507
+ * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information.
508
508
  * @summary Create the account
509
509
  * @param {CreateAccountRequestDto} createAccountRequestDto
510
510
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -515,7 +515,7 @@ var AccountsApiFactory = function (configuration, basePath, axios) {
515
515
  return localVarFp.createAccount(createAccountRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
516
516
  },
517
517
  /**
518
- * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it. **Required Permissions** \"partner-management.accounts.delete\"
518
+ * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it.
519
519
  * @summary Delete the account
520
520
  * @param {string} code Unique identifier for the object.
521
521
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -526,7 +526,7 @@ var AccountsApiFactory = function (configuration, basePath, axios) {
526
526
  return localVarFp.deleteAccount(code, authorization, options).then(function (request) { return request(axios, basePath); });
527
527
  },
528
528
  /**
529
- * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information. **Required Permissions** \"partner-management.accounts.view\"
529
+ * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information.
530
530
  * @summary Retrieve the account
531
531
  * @param {string} code Unique identifier for the object.
532
532
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
@@ -538,7 +538,7 @@ var AccountsApiFactory = function (configuration, basePath, axios) {
538
538
  return localVarFp.getAccount(code, authorization, expand, options).then(function (request) { return request(axios, basePath); });
539
539
  },
540
540
  /**
541
- * 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.accounts.view\"
541
+ * 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.
542
542
  * @summary List accounts
543
543
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
544
544
  * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
@@ -555,7 +555,7 @@ var AccountsApiFactory = function (configuration, basePath, axios) {
555
555
  return localVarFp.listAccounts(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then(function (request) { return request(axios, basePath); });
556
556
  },
557
557
  /**
558
- * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"partner-management.accounts.update\"
558
+ * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
559
559
  * @summary Update the account
560
560
  * @param {string} code Unique identifier for the object.
561
561
  * @param {UpdateAccountRequestDto} updateAccountRequestDto
@@ -581,7 +581,7 @@ var AccountsApi = /** @class */ (function (_super) {
581
581
  return _super !== null && _super.apply(this, arguments) || this;
582
582
  }
583
583
  /**
584
- * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information. **Required Permissions** \"partner-management.accounts.create\"
584
+ * This will create an account in the database. Account creation is usually part of a complex workflow that starts with lead creation. Creating directly an account without prior knowledge might result in an unusable account. Look into lead creation for more information.
585
585
  * @summary Create the account
586
586
  * @param {AccountsApiCreateAccountRequest} requestParameters Request parameters.
587
587
  * @param {*} [options] Override http request option.
@@ -593,7 +593,7 @@ var AccountsApi = /** @class */ (function (_super) {
593
593
  return (0, exports.AccountsApiFp)(this.configuration).createAccount(requestParameters.createAccountRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
594
594
  };
595
595
  /**
596
- * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it. **Required Permissions** \"partner-management.accounts.delete\"
596
+ * Permanently deletes the account. Supply the unique code that was returned when you created the account and this will delete it.
597
597
  * @summary Delete the account
598
598
  * @param {AccountsApiDeleteAccountRequest} requestParameters Request parameters.
599
599
  * @param {*} [options] Override http request option.
@@ -605,7 +605,7 @@ var AccountsApi = /** @class */ (function (_super) {
605
605
  return (0, exports.AccountsApiFp)(this.configuration).deleteAccount(requestParameters.code, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
606
606
  };
607
607
  /**
608
- * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information. **Required Permissions** \"partner-management.accounts.view\"
608
+ * Retrieves the details of the account that was previously created. Supply the unique account code that was returned when you created it and Emil Api will return the corresponding account information.
609
609
  * @summary Retrieve the account
610
610
  * @param {AccountsApiGetAccountRequest} requestParameters Request parameters.
611
611
  * @param {*} [options] Override http request option.
@@ -617,7 +617,7 @@ var AccountsApi = /** @class */ (function (_super) {
617
617
  return (0, exports.AccountsApiFp)(this.configuration).getAccount(requestParameters.code, requestParameters.authorization, requestParameters.expand, options).then(function (request) { return request(_this.axios, _this.basePath); });
618
618
  };
619
619
  /**
620
- * 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.accounts.view\"
620
+ * 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.
621
621
  * @summary List accounts
622
622
  * @param {AccountsApiListAccountsRequest} requestParameters Request parameters.
623
623
  * @param {*} [options] Override http request option.
@@ -630,7 +630,7 @@ var AccountsApi = /** @class */ (function (_super) {
630
630
  return (0, exports.AccountsApiFp)(this.configuration).listAccounts(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); });
631
631
  };
632
632
  /**
633
- * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"partner-management.accounts.update\"
633
+ * Updates the specified account by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
634
634
  * @summary Update the account
635
635
  * @param {AccountsApiUpdateAccountRequest} requestParameters Request parameters.
636
636
  * @param {*} [options] Override http request option.
package/dist/base.js CHANGED
@@ -330,7 +330,7 @@ var BaseAPI = /** @class */ (function () {
330
330
  case 2:
331
331
  tokenString = _a.sent();
332
332
  accessToken = "Bearer ".concat(tokenString);
333
- originalConfig.headers['Authorization'] = "Bearer ".concat(accessToken);
333
+ originalConfig.headers['Authorization'] = accessToken;
334
334
  this.configuration.accessToken = accessToken;
335
335
  return [2 /*return*/, axios.request(originalConfig)];
336
336
  case 3:
package/dist/common.js CHANGED
@@ -141,7 +141,7 @@ var setBearerAuthToObject = function (object, configuration) {
141
141
  _b.label = 4;
142
142
  case 4:
143
143
  accessToken = _a;
144
- object["Authorization"] = "Bearer " + accessToken;
144
+ object["Authorization"] = configuration.getBearerToken(accessToken);
145
145
  _b.label = 5;
146
146
  case 5: return [2 /*return*/];
147
147
  }
@@ -171,7 +171,7 @@ var setOAuthToObject = function (object, name, scopes, configuration) {
171
171
  _b.label = 4;
172
172
  case 4:
173
173
  localVarAccessTokenValue = _a;
174
- object["Authorization"] = "Bearer " + localVarAccessTokenValue;
174
+ object["Authorization"] = configuration.getBearerToken(localVarAccessTokenValue);
175
175
  _b.label = 5;
176
176
  case 5: return [2 /*return*/];
177
177
  }
@@ -87,4 +87,10 @@ export declare class Configuration {
87
87
  * @return True if the given MIME is JSON, false otherwise.
88
88
  */
89
89
  isJsonMime(mime: string): boolean;
90
+ /**
91
+ * Returns "Bearer" token.
92
+ * @param token - access token.
93
+ * @return Bearer token.
94
+ */
95
+ getBearerToken(token?: string): string;
90
96
  }
@@ -39,6 +39,14 @@ var Configuration = /** @class */ (function () {
39
39
  var jsonMime = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i');
40
40
  return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json');
41
41
  };
42
+ /**
43
+ * Returns "Bearer" token.
44
+ * @param token - access token.
45
+ * @return Bearer token.
46
+ */
47
+ Configuration.prototype.getBearerToken = function (token) {
48
+ return ('' + token).startsWith("Bearer") ? token : "Bearer " + token;
49
+ };
42
50
  return Configuration;
43
51
  }());
44
52
  exports.Configuration = Configuration;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@emilgroup/account-sdk-node",
3
- "version": "1.35.1-beta.0",
3
+ "version": "1.35.1-beta.2",
4
4
  "description": "OpenAPI client for @emilgroup/account-sdk-node",
5
5
  "author": "OpenAPI-Generator Contributors",
6
6
  "keywords": [