@dynamic-labs/sdk-api 0.0.248 → 0.0.250
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/package.json +1 -1
- package/src/apis/SDKApi.cjs +64 -0
- package/src/apis/SDKApi.d.ts +24 -0
- package/src/apis/SDKApi.js +64 -0
- package/src/models/UnprocessableEntityErrorCode.cjs +2 -0
- package/src/models/UnprocessableEntityErrorCode.d.ts +3 -1
- package/src/models/UnprocessableEntityErrorCode.js +2 -0
package/package.json
CHANGED
package/src/apis/SDKApi.cjs
CHANGED
|
@@ -455,6 +455,70 @@ class SDKApi extends runtime.BaseAPI {
|
|
|
455
455
|
yield this.logDynamicSdkSettingsRaw(requestParameters, initOverrides);
|
|
456
456
|
});
|
|
457
457
|
}
|
|
458
|
+
/**
|
|
459
|
+
* Used to merge two owned accounts connected by email address
|
|
460
|
+
* After successful verification allow to merge two owned accounts
|
|
461
|
+
*/
|
|
462
|
+
mergeUsersRaw(requestParameters, initOverrides) {
|
|
463
|
+
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
464
|
+
if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
|
|
465
|
+
throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling mergeUsers.');
|
|
466
|
+
}
|
|
467
|
+
const queryParameters = {};
|
|
468
|
+
const headerParameters = {};
|
|
469
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
470
|
+
const token = this.configuration.accessToken;
|
|
471
|
+
const tokenString = yield token("bearerAuth", []);
|
|
472
|
+
if (tokenString) {
|
|
473
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
474
|
+
}
|
|
475
|
+
}
|
|
476
|
+
const response = yield this.request({
|
|
477
|
+
path: `/sdk/{environmentId}/users/merge`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
|
|
478
|
+
method: 'POST',
|
|
479
|
+
headers: headerParameters,
|
|
480
|
+
query: queryParameters,
|
|
481
|
+
}, initOverrides);
|
|
482
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => VerifyResponse.VerifyResponseFromJSON(jsonValue));
|
|
483
|
+
});
|
|
484
|
+
}
|
|
485
|
+
/**
|
|
486
|
+
* Used to merge two owned accounts connected by email address
|
|
487
|
+
* After successful verification allow to merge two owned accounts
|
|
488
|
+
*/
|
|
489
|
+
mergeUsers(requestParameters, initOverrides) {
|
|
490
|
+
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
491
|
+
const response = yield this.mergeUsersRaw(requestParameters, initOverrides);
|
|
492
|
+
return yield response.value();
|
|
493
|
+
});
|
|
494
|
+
}
|
|
495
|
+
/**
|
|
496
|
+
* Options call for this endpoint
|
|
497
|
+
*/
|
|
498
|
+
mergeUsersOptionsRaw(requestParameters, initOverrides) {
|
|
499
|
+
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
500
|
+
if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
|
|
501
|
+
throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling mergeUsersOptions.');
|
|
502
|
+
}
|
|
503
|
+
const queryParameters = {};
|
|
504
|
+
const headerParameters = {};
|
|
505
|
+
const response = yield this.request({
|
|
506
|
+
path: `/sdk/{environmentId}/users/merge`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
|
|
507
|
+
method: 'OPTIONS',
|
|
508
|
+
headers: headerParameters,
|
|
509
|
+
query: queryParameters,
|
|
510
|
+
}, initOverrides);
|
|
511
|
+
return new runtime.VoidApiResponse(response);
|
|
512
|
+
});
|
|
513
|
+
}
|
|
514
|
+
/**
|
|
515
|
+
* Options call for this endpoint
|
|
516
|
+
*/
|
|
517
|
+
mergeUsersOptions(requestParameters, initOverrides) {
|
|
518
|
+
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
519
|
+
yield this.mergeUsersOptionsRaw(requestParameters, initOverrides);
|
|
520
|
+
});
|
|
521
|
+
}
|
|
458
522
|
/**
|
|
459
523
|
* Options call for this endpoint
|
|
460
524
|
*/
|
package/src/apis/SDKApi.d.ts
CHANGED
|
@@ -58,6 +58,12 @@ export interface LogDynamicSdkSettingsRequest {
|
|
|
58
58
|
environmentId: string;
|
|
59
59
|
sdkSettingsRequest: SdkSettingsRequest;
|
|
60
60
|
}
|
|
61
|
+
export interface MergeUsersRequest {
|
|
62
|
+
environmentId: string;
|
|
63
|
+
}
|
|
64
|
+
export interface MergeUsersOptionsRequest {
|
|
65
|
+
environmentId: string;
|
|
66
|
+
}
|
|
61
67
|
export interface NetworksOptionsRequest {
|
|
62
68
|
environmentId: string;
|
|
63
69
|
}
|
|
@@ -296,6 +302,24 @@ export declare class SDKApi extends runtime.BaseAPI {
|
|
|
296
302
|
* Update SDK settings for a specific environment
|
|
297
303
|
*/
|
|
298
304
|
logDynamicSdkSettings(requestParameters: LogDynamicSdkSettingsRequest, initOverrides?: RequestInit): Promise<void>;
|
|
305
|
+
/**
|
|
306
|
+
* Used to merge two owned accounts connected by email address
|
|
307
|
+
* After successful verification allow to merge two owned accounts
|
|
308
|
+
*/
|
|
309
|
+
mergeUsersRaw(requestParameters: MergeUsersRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<VerifyResponse>>;
|
|
310
|
+
/**
|
|
311
|
+
* Used to merge two owned accounts connected by email address
|
|
312
|
+
* After successful verification allow to merge two owned accounts
|
|
313
|
+
*/
|
|
314
|
+
mergeUsers(requestParameters: MergeUsersRequest, initOverrides?: RequestInit): Promise<VerifyResponse>;
|
|
315
|
+
/**
|
|
316
|
+
* Options call for this endpoint
|
|
317
|
+
*/
|
|
318
|
+
mergeUsersOptionsRaw(requestParameters: MergeUsersOptionsRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<void>>;
|
|
319
|
+
/**
|
|
320
|
+
* Options call for this endpoint
|
|
321
|
+
*/
|
|
322
|
+
mergeUsersOptions(requestParameters: MergeUsersOptionsRequest, initOverrides?: RequestInit): Promise<void>;
|
|
299
323
|
/**
|
|
300
324
|
* Options call for this endpoint
|
|
301
325
|
*/
|
package/src/apis/SDKApi.js
CHANGED
|
@@ -451,6 +451,70 @@ class SDKApi extends BaseAPI {
|
|
|
451
451
|
yield this.logDynamicSdkSettingsRaw(requestParameters, initOverrides);
|
|
452
452
|
});
|
|
453
453
|
}
|
|
454
|
+
/**
|
|
455
|
+
* Used to merge two owned accounts connected by email address
|
|
456
|
+
* After successful verification allow to merge two owned accounts
|
|
457
|
+
*/
|
|
458
|
+
mergeUsersRaw(requestParameters, initOverrides) {
|
|
459
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
460
|
+
if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
|
|
461
|
+
throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling mergeUsers.');
|
|
462
|
+
}
|
|
463
|
+
const queryParameters = {};
|
|
464
|
+
const headerParameters = {};
|
|
465
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
466
|
+
const token = this.configuration.accessToken;
|
|
467
|
+
const tokenString = yield token("bearerAuth", []);
|
|
468
|
+
if (tokenString) {
|
|
469
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
470
|
+
}
|
|
471
|
+
}
|
|
472
|
+
const response = yield this.request({
|
|
473
|
+
path: `/sdk/{environmentId}/users/merge`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
|
|
474
|
+
method: 'POST',
|
|
475
|
+
headers: headerParameters,
|
|
476
|
+
query: queryParameters,
|
|
477
|
+
}, initOverrides);
|
|
478
|
+
return new JSONApiResponse(response, (jsonValue) => VerifyResponseFromJSON(jsonValue));
|
|
479
|
+
});
|
|
480
|
+
}
|
|
481
|
+
/**
|
|
482
|
+
* Used to merge two owned accounts connected by email address
|
|
483
|
+
* After successful verification allow to merge two owned accounts
|
|
484
|
+
*/
|
|
485
|
+
mergeUsers(requestParameters, initOverrides) {
|
|
486
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
487
|
+
const response = yield this.mergeUsersRaw(requestParameters, initOverrides);
|
|
488
|
+
return yield response.value();
|
|
489
|
+
});
|
|
490
|
+
}
|
|
491
|
+
/**
|
|
492
|
+
* Options call for this endpoint
|
|
493
|
+
*/
|
|
494
|
+
mergeUsersOptionsRaw(requestParameters, initOverrides) {
|
|
495
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
496
|
+
if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
|
|
497
|
+
throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling mergeUsersOptions.');
|
|
498
|
+
}
|
|
499
|
+
const queryParameters = {};
|
|
500
|
+
const headerParameters = {};
|
|
501
|
+
const response = yield this.request({
|
|
502
|
+
path: `/sdk/{environmentId}/users/merge`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
|
|
503
|
+
method: 'OPTIONS',
|
|
504
|
+
headers: headerParameters,
|
|
505
|
+
query: queryParameters,
|
|
506
|
+
}, initOverrides);
|
|
507
|
+
return new VoidApiResponse(response);
|
|
508
|
+
});
|
|
509
|
+
}
|
|
510
|
+
/**
|
|
511
|
+
* Options call for this endpoint
|
|
512
|
+
*/
|
|
513
|
+
mergeUsersOptions(requestParameters, initOverrides) {
|
|
514
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
515
|
+
yield this.mergeUsersOptionsRaw(requestParameters, initOverrides);
|
|
516
|
+
});
|
|
517
|
+
}
|
|
454
518
|
/**
|
|
455
519
|
* Options call for this endpoint
|
|
456
520
|
*/
|
|
@@ -49,6 +49,8 @@ exports.UnprocessableEntityErrorCode = void 0;
|
|
|
49
49
|
UnprocessableEntityErrorCode["InvalidDynamicProps"] = "invalid_dynamic_props";
|
|
50
50
|
UnprocessableEntityErrorCode["TooManyOrganizationsForUser"] = "too_many_organizations_for_user";
|
|
51
51
|
UnprocessableEntityErrorCode["TooManyProjectsForOrganization"] = "too_many_projects_for_organization";
|
|
52
|
+
UnprocessableEntityErrorCode["EmailAssociatedWithDifferentProvider"] = "email_associated_with_different_provider";
|
|
53
|
+
UnprocessableEntityErrorCode["UserHasAlreadyAccountWithEmail"] = "user_has_already_account_with_email";
|
|
52
54
|
})(exports.UnprocessableEntityErrorCode || (exports.UnprocessableEntityErrorCode = {}));
|
|
53
55
|
function UnprocessableEntityErrorCodeFromJSON(json) {
|
|
54
56
|
return UnprocessableEntityErrorCodeFromJSONTyped(json);
|
|
@@ -41,7 +41,9 @@ export declare enum UnprocessableEntityErrorCode {
|
|
|
41
41
|
InvalidKeyExportUrl = "invalid_key_export_url",
|
|
42
42
|
InvalidDynamicProps = "invalid_dynamic_props",
|
|
43
43
|
TooManyOrganizationsForUser = "too_many_organizations_for_user",
|
|
44
|
-
TooManyProjectsForOrganization = "too_many_projects_for_organization"
|
|
44
|
+
TooManyProjectsForOrganization = "too_many_projects_for_organization",
|
|
45
|
+
EmailAssociatedWithDifferentProvider = "email_associated_with_different_provider",
|
|
46
|
+
UserHasAlreadyAccountWithEmail = "user_has_already_account_with_email"
|
|
45
47
|
}
|
|
46
48
|
export declare function UnprocessableEntityErrorCodeFromJSON(json: any): UnprocessableEntityErrorCode;
|
|
47
49
|
export declare function UnprocessableEntityErrorCodeFromJSONTyped(json: any, ignoreDiscriminator: boolean): UnprocessableEntityErrorCode;
|
|
@@ -45,6 +45,8 @@ var UnprocessableEntityErrorCode;
|
|
|
45
45
|
UnprocessableEntityErrorCode["InvalidDynamicProps"] = "invalid_dynamic_props";
|
|
46
46
|
UnprocessableEntityErrorCode["TooManyOrganizationsForUser"] = "too_many_organizations_for_user";
|
|
47
47
|
UnprocessableEntityErrorCode["TooManyProjectsForOrganization"] = "too_many_projects_for_organization";
|
|
48
|
+
UnprocessableEntityErrorCode["EmailAssociatedWithDifferentProvider"] = "email_associated_with_different_provider";
|
|
49
|
+
UnprocessableEntityErrorCode["UserHasAlreadyAccountWithEmail"] = "user_has_already_account_with_email";
|
|
48
50
|
})(UnprocessableEntityErrorCode || (UnprocessableEntityErrorCode = {}));
|
|
49
51
|
function UnprocessableEntityErrorCodeFromJSON(json) {
|
|
50
52
|
return UnprocessableEntityErrorCodeFromJSONTyped(json);
|