@dynamic-labs/sdk-api-core 0.0.507 → 0.0.508

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynamic-labs/sdk-api-core",
3
- "version": "0.0.507",
3
+ "version": "0.0.508",
4
4
  "author": "Dynamic Labs",
5
5
  "license": "Apache-2.0",
6
6
  "publishConfig": {
@@ -24,6 +24,7 @@ require('../models/EmbeddedWalletChainEnum.cjs');
24
24
  require('../models/EmbeddedWalletProviderEnum.cjs');
25
25
  var CreateEmbeddedWalletsRequest = require('../models/CreateEmbeddedWalletsRequest.cjs');
26
26
  require('../models/UserIdentifierTypeEnum.cjs');
27
+ var CreateWalletAccountRequest = require('../models/CreateWalletAccountRequest.cjs');
27
28
  require('../models/CurrencyType.cjs');
28
29
  require('../models/TimeUnitEnum.cjs');
29
30
  require('../models/EcdsaValidatorOptions.cjs');
@@ -89,6 +90,7 @@ var SmsVerificationVerifyRequest = require('../models/SmsVerificationVerifyReque
89
90
  var SupportedOnrampsResponse = require('../models/SupportedOnrampsResponse.cjs');
90
91
  var TelegramPostRequest = require('../models/TelegramPostRequest.cjs');
91
92
  var TokenBalance = require('../models/TokenBalance.cjs');
93
+ var TurnkeyCreateWalletAccountsRequestBody = require('../models/TurnkeyCreateWalletAccountsRequestBody.cjs');
92
94
  require('../models/UnprocessableEntityErrorCode.cjs');
93
95
  var UpdateRecoveryEmailRequest = require('../models/UpdateRecoveryEmailRequest.cjs');
94
96
  var UpdateSelfResponse = require('../models/UpdateSelfResponse.cjs');
@@ -606,6 +608,48 @@ class SDKApi extends runtime.BaseAPI {
606
608
  yield this.createVisitRaw(requestParameters, initOverrides);
607
609
  });
608
610
  }
611
+ /**
612
+ * Add a wallet account to a user\'s existing Turnkey HD wallet
613
+ * Add a wallet account to a user\'s existing Turnkey HD wallet
614
+ */
615
+ createWalletAccountRaw(requestParameters, initOverrides) {
616
+ return _tslib.__awaiter(this, void 0, void 0, function* () {
617
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
618
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling createWalletAccount.');
619
+ }
620
+ if (requestParameters.createWalletAccountRequest === null || requestParameters.createWalletAccountRequest === undefined) {
621
+ throw new runtime.RequiredError('createWalletAccountRequest', 'Required parameter requestParameters.createWalletAccountRequest was null or undefined when calling createWalletAccount.');
622
+ }
623
+ const queryParameters = {};
624
+ const headerParameters = {};
625
+ headerParameters['Content-Type'] = 'application/json';
626
+ if (this.configuration && this.configuration.accessToken) {
627
+ const token = this.configuration.accessToken;
628
+ const tokenString = yield token("bearerAuth", []);
629
+ if (tokenString) {
630
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
631
+ }
632
+ }
633
+ const response = yield this.request({
634
+ path: `/sdk/{environmentId}/users/embeddedWallets/walletAccounts`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
635
+ method: 'POST',
636
+ headers: headerParameters,
637
+ query: queryParameters,
638
+ body: CreateWalletAccountRequest.CreateWalletAccountRequestToJSON(requestParameters.createWalletAccountRequest),
639
+ }, initOverrides);
640
+ return new runtime.JSONApiResponse(response, (jsonValue) => VerifyResponse.VerifyResponseFromJSON(jsonValue));
641
+ });
642
+ }
643
+ /**
644
+ * Add a wallet account to a user\'s existing Turnkey HD wallet
645
+ * Add a wallet account to a user\'s existing Turnkey HD wallet
646
+ */
647
+ createWalletAccount(requestParameters, initOverrides) {
648
+ return _tslib.__awaiter(this, void 0, void 0, function* () {
649
+ const response = yield this.createWalletAccountRaw(requestParameters, initOverrides);
650
+ return yield response.value();
651
+ });
652
+ }
609
653
  /**
610
654
  * Delete a device (if not default device)
611
655
  */
@@ -1245,6 +1289,49 @@ class SDKApi extends runtime.BaseAPI {
1245
1289
  return yield response.value();
1246
1290
  });
1247
1291
  }
1292
+ /**
1293
+ * Generates the turnkey request body for a user\'s create wallet account request
1294
+ * Generates the turnkey request body for a user\'s create wallet account request
1295
+ */
1296
+ getCreateWalletAccountRequestRaw(requestParameters, initOverrides) {
1297
+ return _tslib.__awaiter(this, void 0, void 0, function* () {
1298
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
1299
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling getCreateWalletAccountRequest.');
1300
+ }
1301
+ if (requestParameters.chain === null || requestParameters.chain === undefined) {
1302
+ throw new runtime.RequiredError('chain', 'Required parameter requestParameters.chain was null or undefined when calling getCreateWalletAccountRequest.');
1303
+ }
1304
+ const queryParameters = {};
1305
+ if (requestParameters.chain !== undefined) {
1306
+ queryParameters['chain'] = requestParameters.chain;
1307
+ }
1308
+ const headerParameters = {};
1309
+ if (this.configuration && this.configuration.accessToken) {
1310
+ const token = this.configuration.accessToken;
1311
+ const tokenString = yield token("bearerAuth", []);
1312
+ if (tokenString) {
1313
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
1314
+ }
1315
+ }
1316
+ const response = yield this.request({
1317
+ path: `/sdk/{environmentId}/users/embeddedWallets/walletAccounts/createRequest`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
1318
+ method: 'GET',
1319
+ headers: headerParameters,
1320
+ query: queryParameters,
1321
+ }, initOverrides);
1322
+ return new runtime.JSONApiResponse(response, (jsonValue) => TurnkeyCreateWalletAccountsRequestBody.TurnkeyCreateWalletAccountsRequestBodyFromJSON(jsonValue));
1323
+ });
1324
+ }
1325
+ /**
1326
+ * Generates the turnkey request body for a user\'s create wallet account request
1327
+ * Generates the turnkey request body for a user\'s create wallet account request
1328
+ */
1329
+ getCreateWalletAccountRequest(requestParameters, initOverrides) {
1330
+ return _tslib.__awaiter(this, void 0, void 0, function* () {
1331
+ const response = yield this.getCreateWalletAccountRequestRaw(requestParameters, initOverrides);
1332
+ return yield response.value();
1333
+ });
1334
+ }
1248
1335
  /**
1249
1336
  * Return the email provider to be used for signing in with a given email. If an external provider such as magicLink is disabled, this endpoint would return emailOnly. If an external provider such as magicLink is enabled, it will return emailOnly when the email already exists in Dynamic and it is associated with a wallet, otherwise it will return magicLink.
1250
1337
  * Get signin email provider
@@ -4519,6 +4606,60 @@ class SDKApi extends runtime.BaseAPI {
4519
4606
  yield this.verifyUnlinkOptionsRaw(requestParameters, initOverrides);
4520
4607
  });
4521
4608
  }
4609
+ /**
4610
+ * Options call for this endpoint
4611
+ */
4612
+ walletAccountOptionsRaw(requestParameters, initOverrides) {
4613
+ return _tslib.__awaiter(this, void 0, void 0, function* () {
4614
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
4615
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling walletAccountOptions.');
4616
+ }
4617
+ const queryParameters = {};
4618
+ const headerParameters = {};
4619
+ const response = yield this.request({
4620
+ path: `/sdk/{environmentId}/users/embeddedWallets/walletAccounts`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
4621
+ method: 'OPTIONS',
4622
+ headers: headerParameters,
4623
+ query: queryParameters,
4624
+ }, initOverrides);
4625
+ return new runtime.VoidApiResponse(response);
4626
+ });
4627
+ }
4628
+ /**
4629
+ * Options call for this endpoint
4630
+ */
4631
+ walletAccountOptions(requestParameters, initOverrides) {
4632
+ return _tslib.__awaiter(this, void 0, void 0, function* () {
4633
+ yield this.walletAccountOptionsRaw(requestParameters, initOverrides);
4634
+ });
4635
+ }
4636
+ /**
4637
+ * Options call for this endpoint
4638
+ */
4639
+ walletAccountRequestOptionsRaw(requestParameters, initOverrides) {
4640
+ return _tslib.__awaiter(this, void 0, void 0, function* () {
4641
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
4642
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling walletAccountRequestOptions.');
4643
+ }
4644
+ const queryParameters = {};
4645
+ const headerParameters = {};
4646
+ const response = yield this.request({
4647
+ path: `/sdk/{environmentId}/users/embeddedWallets/walletAccounts/createRequest`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
4648
+ method: 'OPTIONS',
4649
+ headers: headerParameters,
4650
+ query: queryParameters,
4651
+ }, initOverrides);
4652
+ return new runtime.VoidApiResponse(response);
4653
+ });
4654
+ }
4655
+ /**
4656
+ * Options call for this endpoint
4657
+ */
4658
+ walletAccountRequestOptions(requestParameters, initOverrides) {
4659
+ return _tslib.__awaiter(this, void 0, void 0, function* () {
4660
+ yield this.walletAccountRequestOptionsRaw(requestParameters, initOverrides);
4661
+ });
4662
+ }
4522
4663
  }
4523
4664
  /**
4524
4665
  * @export
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import { CompletePasskeyRecoveryRequest, ConnectRequest, CreateEmbeddedWalletsRequest, EmailProviderResponse, EmailVerificationCreateRequest, EmailVerificationCreateResponse, EmailVerificationRetryRequest, EmailVerificationVerifyRequest, EmbeddedWalletAuthToken, EmbeddedWalletAuthType, EmbeddedWalletPasscodeClaimRequest, EmbeddedWalletSecret, ExportEmbeddedWalletResponse, ExternalAuthSigninRequest, FarcasterSignInRequest, GetUserPasskeysResponse, HealthcheckResponse, InitEmailAuthRequest, InitEmailAuthResponse, InitPasskeyRecoveryRequest, InitPasskeyRecoveryResponse, JwksResponse, MFAAuthRecoveryDevicePostRequest, MFAAuthTotpDevicePostRequest, MFADevice, MFAGetRecoveryCodesResponse, MFAListDevicesResponse, MFARegenRecoveryCodesResponse, MFARegisterTotpDeviceGetResponse, MFARegisterTotpDevicePostRequest, MFAUpdateDeviceRequest, MergeUserConflictResolutions, NetworkConfigurationResponse, NonceResponse, OauthInitAuthRequest, OauthProviderLoginUrl, OauthRequest, OauthResultRequest, OauthResultResponse, PrefetchRequest, ProjectSettings, ProviderEnum, PublishEvents, RegisterSessionKeyRequest, SdkSettingsRequest, SdkUser, SmsVerificationCreateRequest, SmsVerificationCreateResponse, SmsVerificationRetryRequest, SmsVerificationVerifyRequest, SupportedOnrampsResponse, TelegramPostRequest, TokenBalance, UpdateRecoveryEmailRequest, UpdateSelfResponse, UpdateUserPasskeyRequest, UserFields, UserPasskey, UserWalletSelectionRequest, VerifyRequest, VerifyResponse, VerifyUnlinkRequest } from '../models';
13
+ import { ChainEnum, CompletePasskeyRecoveryRequest, ConnectRequest, CreateEmbeddedWalletsRequest, CreateWalletAccountRequest, EmailProviderResponse, EmailVerificationCreateRequest, EmailVerificationCreateResponse, EmailVerificationRetryRequest, EmailVerificationVerifyRequest, EmbeddedWalletAuthToken, EmbeddedWalletAuthType, EmbeddedWalletPasscodeClaimRequest, EmbeddedWalletSecret, ExportEmbeddedWalletResponse, ExternalAuthSigninRequest, FarcasterSignInRequest, GetUserPasskeysResponse, HealthcheckResponse, InitEmailAuthRequest, InitEmailAuthResponse, InitPasskeyRecoveryRequest, InitPasskeyRecoveryResponse, JwksResponse, MFAAuthRecoveryDevicePostRequest, MFAAuthTotpDevicePostRequest, MFADevice, MFAGetRecoveryCodesResponse, MFAListDevicesResponse, MFARegenRecoveryCodesResponse, MFARegisterTotpDeviceGetResponse, MFARegisterTotpDevicePostRequest, MFAUpdateDeviceRequest, MergeUserConflictResolutions, NetworkConfigurationResponse, NonceResponse, OauthInitAuthRequest, OauthProviderLoginUrl, OauthRequest, OauthResultRequest, OauthResultResponse, PrefetchRequest, ProjectSettings, ProviderEnum, PublishEvents, RegisterSessionKeyRequest, SdkSettingsRequest, SdkUser, SmsVerificationCreateRequest, SmsVerificationCreateResponse, SmsVerificationRetryRequest, SmsVerificationVerifyRequest, SupportedOnrampsResponse, TelegramPostRequest, TokenBalance, TurnkeyCreateWalletAccountsRequestBody, UpdateRecoveryEmailRequest, UpdateSelfResponse, UpdateUserPasskeyRequest, UserFields, UserPasskey, UserWalletSelectionRequest, VerifyRequest, VerifyResponse, VerifyUnlinkRequest } from '../models';
14
14
  export interface AuthMfaRecoveryRequest {
15
15
  environmentId: string;
16
16
  mFAAuthRecoveryDevicePostRequest: MFAAuthRecoveryDevicePostRequest;
@@ -64,6 +64,10 @@ export interface CreateVisitRequest {
64
64
  environmentId: string;
65
65
  connectRequest: ConnectRequest;
66
66
  }
67
+ export interface CreateWalletAccountOperationRequest {
68
+ environmentId: string;
69
+ createWalletAccountRequest: CreateWalletAccountRequest;
70
+ }
67
71
  export interface DeleteMfaDeviceRequest {
68
72
  environmentId: string;
69
73
  mfaDeviceId: string;
@@ -139,6 +143,10 @@ export interface GetAuthTokenOptsRequest {
139
143
  export interface GetAuthenticatedUserRequest {
140
144
  environmentId: string;
141
145
  }
146
+ export interface GetCreateWalletAccountRequestRequest {
147
+ environmentId: string;
148
+ chain: ChainEnum;
149
+ }
142
150
  export interface GetEmailProviderRequest {
143
151
  environmentId: string;
144
152
  email: string;
@@ -512,6 +520,12 @@ export interface VerifyUnlinkOperationRequest {
512
520
  export interface VerifyUnlinkOptionsRequest {
513
521
  environmentId: string;
514
522
  }
523
+ export interface WalletAccountOptionsRequest {
524
+ environmentId: string;
525
+ }
526
+ export interface WalletAccountRequestOptionsRequest {
527
+ environmentId: string;
528
+ }
515
529
  /**
516
530
  *
517
531
  */
@@ -642,6 +656,16 @@ export declare class SDKApi extends runtime.BaseAPI {
642
656
  * Create a visit
643
657
  */
644
658
  createVisit(requestParameters: CreateVisitRequest, initOverrides?: RequestInit): Promise<void>;
659
+ /**
660
+ * Add a wallet account to a user\'s existing Turnkey HD wallet
661
+ * Add a wallet account to a user\'s existing Turnkey HD wallet
662
+ */
663
+ createWalletAccountRaw(requestParameters: CreateWalletAccountOperationRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<VerifyResponse>>;
664
+ /**
665
+ * Add a wallet account to a user\'s existing Turnkey HD wallet
666
+ * Add a wallet account to a user\'s existing Turnkey HD wallet
667
+ */
668
+ createWalletAccount(requestParameters: CreateWalletAccountOperationRequest, initOverrides?: RequestInit): Promise<VerifyResponse>;
645
669
  /**
646
670
  * Delete a device (if not default device)
647
671
  */
@@ -798,6 +822,16 @@ export declare class SDKApi extends runtime.BaseAPI {
798
822
  * Fetch user profile for the current authenticated user
799
823
  */
800
824
  getAuthenticatedUser(requestParameters: GetAuthenticatedUserRequest, initOverrides?: RequestInit): Promise<SdkUser>;
825
+ /**
826
+ * Generates the turnkey request body for a user\'s create wallet account request
827
+ * Generates the turnkey request body for a user\'s create wallet account request
828
+ */
829
+ getCreateWalletAccountRequestRaw(requestParameters: GetCreateWalletAccountRequestRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<TurnkeyCreateWalletAccountsRequestBody>>;
830
+ /**
831
+ * Generates the turnkey request body for a user\'s create wallet account request
832
+ * Generates the turnkey request body for a user\'s create wallet account request
833
+ */
834
+ getCreateWalletAccountRequest(requestParameters: GetCreateWalletAccountRequestRequest, initOverrides?: RequestInit): Promise<TurnkeyCreateWalletAccountsRequestBody>;
801
835
  /**
802
836
  * Return the email provider to be used for signing in with a given email. If an external provider such as magicLink is disabled, this endpoint would return emailOnly. If an external provider such as magicLink is enabled, it will return emailOnly when the email already exists in Dynamic and it is associated with a wallet, otherwise it will return magicLink.
803
837
  * Get signin email provider
@@ -1638,6 +1672,22 @@ export declare class SDKApi extends runtime.BaseAPI {
1638
1672
  * Options call for this endpoint
1639
1673
  */
1640
1674
  verifyUnlinkOptions(requestParameters: VerifyUnlinkOptionsRequest, initOverrides?: RequestInit): Promise<void>;
1675
+ /**
1676
+ * Options call for this endpoint
1677
+ */
1678
+ walletAccountOptionsRaw(requestParameters: WalletAccountOptionsRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<void>>;
1679
+ /**
1680
+ * Options call for this endpoint
1681
+ */
1682
+ walletAccountOptions(requestParameters: WalletAccountOptionsRequest, initOverrides?: RequestInit): Promise<void>;
1683
+ /**
1684
+ * Options call for this endpoint
1685
+ */
1686
+ walletAccountRequestOptionsRaw(requestParameters: WalletAccountRequestOptionsRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<void>>;
1687
+ /**
1688
+ * Options call for this endpoint
1689
+ */
1690
+ walletAccountRequestOptions(requestParameters: WalletAccountRequestOptionsRequest, initOverrides?: RequestInit): Promise<void>;
1641
1691
  }
1642
1692
  /**
1643
1693
  * @export
@@ -20,6 +20,7 @@ import '../models/EmbeddedWalletChainEnum.js';
20
20
  import '../models/EmbeddedWalletProviderEnum.js';
21
21
  import { CreateEmbeddedWalletsRequestToJSON } from '../models/CreateEmbeddedWalletsRequest.js';
22
22
  import '../models/UserIdentifierTypeEnum.js';
23
+ import { CreateWalletAccountRequestToJSON } from '../models/CreateWalletAccountRequest.js';
23
24
  import '../models/CurrencyType.js';
24
25
  import '../models/TimeUnitEnum.js';
25
26
  import '../models/EcdsaValidatorOptions.js';
@@ -85,6 +86,7 @@ import { SmsVerificationVerifyRequestToJSON } from '../models/SmsVerificationVer
85
86
  import { SupportedOnrampsResponseFromJSON } from '../models/SupportedOnrampsResponse.js';
86
87
  import { TelegramPostRequestToJSON } from '../models/TelegramPostRequest.js';
87
88
  import { TokenBalanceFromJSON } from '../models/TokenBalance.js';
89
+ import { TurnkeyCreateWalletAccountsRequestBodyFromJSON } from '../models/TurnkeyCreateWalletAccountsRequestBody.js';
88
90
  import '../models/UnprocessableEntityErrorCode.js';
89
91
  import { UpdateRecoveryEmailRequestToJSON } from '../models/UpdateRecoveryEmailRequest.js';
90
92
  import { UpdateSelfResponseFromJSON } from '../models/UpdateSelfResponse.js';
@@ -602,6 +604,48 @@ class SDKApi extends BaseAPI {
602
604
  yield this.createVisitRaw(requestParameters, initOverrides);
603
605
  });
604
606
  }
607
+ /**
608
+ * Add a wallet account to a user\'s existing Turnkey HD wallet
609
+ * Add a wallet account to a user\'s existing Turnkey HD wallet
610
+ */
611
+ createWalletAccountRaw(requestParameters, initOverrides) {
612
+ return __awaiter(this, void 0, void 0, function* () {
613
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
614
+ throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling createWalletAccount.');
615
+ }
616
+ if (requestParameters.createWalletAccountRequest === null || requestParameters.createWalletAccountRequest === undefined) {
617
+ throw new RequiredError('createWalletAccountRequest', 'Required parameter requestParameters.createWalletAccountRequest was null or undefined when calling createWalletAccount.');
618
+ }
619
+ const queryParameters = {};
620
+ const headerParameters = {};
621
+ headerParameters['Content-Type'] = 'application/json';
622
+ if (this.configuration && this.configuration.accessToken) {
623
+ const token = this.configuration.accessToken;
624
+ const tokenString = yield token("bearerAuth", []);
625
+ if (tokenString) {
626
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
627
+ }
628
+ }
629
+ const response = yield this.request({
630
+ path: `/sdk/{environmentId}/users/embeddedWallets/walletAccounts`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
631
+ method: 'POST',
632
+ headers: headerParameters,
633
+ query: queryParameters,
634
+ body: CreateWalletAccountRequestToJSON(requestParameters.createWalletAccountRequest),
635
+ }, initOverrides);
636
+ return new JSONApiResponse(response, (jsonValue) => VerifyResponseFromJSON(jsonValue));
637
+ });
638
+ }
639
+ /**
640
+ * Add a wallet account to a user\'s existing Turnkey HD wallet
641
+ * Add a wallet account to a user\'s existing Turnkey HD wallet
642
+ */
643
+ createWalletAccount(requestParameters, initOverrides) {
644
+ return __awaiter(this, void 0, void 0, function* () {
645
+ const response = yield this.createWalletAccountRaw(requestParameters, initOverrides);
646
+ return yield response.value();
647
+ });
648
+ }
605
649
  /**
606
650
  * Delete a device (if not default device)
607
651
  */
@@ -1241,6 +1285,49 @@ class SDKApi extends BaseAPI {
1241
1285
  return yield response.value();
1242
1286
  });
1243
1287
  }
1288
+ /**
1289
+ * Generates the turnkey request body for a user\'s create wallet account request
1290
+ * Generates the turnkey request body for a user\'s create wallet account request
1291
+ */
1292
+ getCreateWalletAccountRequestRaw(requestParameters, initOverrides) {
1293
+ return __awaiter(this, void 0, void 0, function* () {
1294
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
1295
+ throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling getCreateWalletAccountRequest.');
1296
+ }
1297
+ if (requestParameters.chain === null || requestParameters.chain === undefined) {
1298
+ throw new RequiredError('chain', 'Required parameter requestParameters.chain was null or undefined when calling getCreateWalletAccountRequest.');
1299
+ }
1300
+ const queryParameters = {};
1301
+ if (requestParameters.chain !== undefined) {
1302
+ queryParameters['chain'] = requestParameters.chain;
1303
+ }
1304
+ const headerParameters = {};
1305
+ if (this.configuration && this.configuration.accessToken) {
1306
+ const token = this.configuration.accessToken;
1307
+ const tokenString = yield token("bearerAuth", []);
1308
+ if (tokenString) {
1309
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
1310
+ }
1311
+ }
1312
+ const response = yield this.request({
1313
+ path: `/sdk/{environmentId}/users/embeddedWallets/walletAccounts/createRequest`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
1314
+ method: 'GET',
1315
+ headers: headerParameters,
1316
+ query: queryParameters,
1317
+ }, initOverrides);
1318
+ return new JSONApiResponse(response, (jsonValue) => TurnkeyCreateWalletAccountsRequestBodyFromJSON(jsonValue));
1319
+ });
1320
+ }
1321
+ /**
1322
+ * Generates the turnkey request body for a user\'s create wallet account request
1323
+ * Generates the turnkey request body for a user\'s create wallet account request
1324
+ */
1325
+ getCreateWalletAccountRequest(requestParameters, initOverrides) {
1326
+ return __awaiter(this, void 0, void 0, function* () {
1327
+ const response = yield this.getCreateWalletAccountRequestRaw(requestParameters, initOverrides);
1328
+ return yield response.value();
1329
+ });
1330
+ }
1244
1331
  /**
1245
1332
  * Return the email provider to be used for signing in with a given email. If an external provider such as magicLink is disabled, this endpoint would return emailOnly. If an external provider such as magicLink is enabled, it will return emailOnly when the email already exists in Dynamic and it is associated with a wallet, otherwise it will return magicLink.
1246
1333
  * Get signin email provider
@@ -4515,6 +4602,60 @@ class SDKApi extends BaseAPI {
4515
4602
  yield this.verifyUnlinkOptionsRaw(requestParameters, initOverrides);
4516
4603
  });
4517
4604
  }
4605
+ /**
4606
+ * Options call for this endpoint
4607
+ */
4608
+ walletAccountOptionsRaw(requestParameters, initOverrides) {
4609
+ return __awaiter(this, void 0, void 0, function* () {
4610
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
4611
+ throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling walletAccountOptions.');
4612
+ }
4613
+ const queryParameters = {};
4614
+ const headerParameters = {};
4615
+ const response = yield this.request({
4616
+ path: `/sdk/{environmentId}/users/embeddedWallets/walletAccounts`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
4617
+ method: 'OPTIONS',
4618
+ headers: headerParameters,
4619
+ query: queryParameters,
4620
+ }, initOverrides);
4621
+ return new VoidApiResponse(response);
4622
+ });
4623
+ }
4624
+ /**
4625
+ * Options call for this endpoint
4626
+ */
4627
+ walletAccountOptions(requestParameters, initOverrides) {
4628
+ return __awaiter(this, void 0, void 0, function* () {
4629
+ yield this.walletAccountOptionsRaw(requestParameters, initOverrides);
4630
+ });
4631
+ }
4632
+ /**
4633
+ * Options call for this endpoint
4634
+ */
4635
+ walletAccountRequestOptionsRaw(requestParameters, initOverrides) {
4636
+ return __awaiter(this, void 0, void 0, function* () {
4637
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
4638
+ throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling walletAccountRequestOptions.');
4639
+ }
4640
+ const queryParameters = {};
4641
+ const headerParameters = {};
4642
+ const response = yield this.request({
4643
+ path: `/sdk/{environmentId}/users/embeddedWallets/walletAccounts/createRequest`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
4644
+ method: 'OPTIONS',
4645
+ headers: headerParameters,
4646
+ query: queryParameters,
4647
+ }, initOverrides);
4648
+ return new VoidApiResponse(response);
4649
+ });
4650
+ }
4651
+ /**
4652
+ * Options call for this endpoint
4653
+ */
4654
+ walletAccountRequestOptions(requestParameters, initOverrides) {
4655
+ return __awaiter(this, void 0, void 0, function* () {
4656
+ yield this.walletAccountRequestOptionsRaw(requestParameters, initOverrides);
4657
+ });
4658
+ }
4518
4659
  }
4519
4660
  /**
4520
4661
  * @export
package/src/index.cjs CHANGED
@@ -22,6 +22,7 @@ var CreateMfaToken = require('./models/CreateMfaToken.cjs');
22
22
  var CreateTurnkeyEmbeddedWalletSpecificOpts = require('./models/CreateTurnkeyEmbeddedWalletSpecificOpts.cjs');
23
23
  var CreateUserEmbeddedWalletsFromFarcasterRequest = require('./models/CreateUserEmbeddedWalletsFromFarcasterRequest.cjs');
24
24
  var CreateUserEmbeddedWalletsRequest = require('./models/CreateUserEmbeddedWalletsRequest.cjs');
25
+ var CreateWalletAccountRequest = require('./models/CreateWalletAccountRequest.cjs');
25
26
  var Currency = require('./models/Currency.cjs');
26
27
  var CurrencyType = require('./models/CurrencyType.cjs');
27
28
  var CustomFieldType = require('./models/CustomFieldType.cjs');
@@ -165,8 +166,11 @@ var TelegramUser = require('./models/TelegramUser.cjs');
165
166
  var TimeUnitEnum = require('./models/TimeUnitEnum.cjs');
166
167
  var TokenBalance = require('./models/TokenBalance.cjs');
167
168
  var TooManyRequests = require('./models/TooManyRequests.cjs');
169
+ var TurnkeyCreateWalletAccountsRequestBody = require('./models/TurnkeyCreateWalletAccountsRequestBody.cjs');
170
+ var TurnkeyCreateWalletAccountsRequestBodyParameters = require('./models/TurnkeyCreateWalletAccountsRequestBodyParameters.cjs');
168
171
  var TurnkeySignedRequest = require('./models/TurnkeySignedRequest.cjs');
169
172
  var TurnkeyStamp = require('./models/TurnkeyStamp.cjs');
173
+ var TurnkeyWalletAccount = require('./models/TurnkeyWalletAccount.cjs');
170
174
  var TurnkeyWalletProperties = require('./models/TurnkeyWalletProperties.cjs');
171
175
  var Unauthorized = require('./models/Unauthorized.cjs');
172
176
  var UnprocessableEntity = require('./models/UnprocessableEntity.cjs');
@@ -287,6 +291,9 @@ exports.CreateUserEmbeddedWalletsFromFarcasterRequestToJSON = CreateUserEmbedded
287
291
  exports.CreateUserEmbeddedWalletsRequestFromJSON = CreateUserEmbeddedWalletsRequest.CreateUserEmbeddedWalletsRequestFromJSON;
288
292
  exports.CreateUserEmbeddedWalletsRequestFromJSONTyped = CreateUserEmbeddedWalletsRequest.CreateUserEmbeddedWalletsRequestFromJSONTyped;
289
293
  exports.CreateUserEmbeddedWalletsRequestToJSON = CreateUserEmbeddedWalletsRequest.CreateUserEmbeddedWalletsRequestToJSON;
294
+ exports.CreateWalletAccountRequestFromJSON = CreateWalletAccountRequest.CreateWalletAccountRequestFromJSON;
295
+ exports.CreateWalletAccountRequestFromJSONTyped = CreateWalletAccountRequest.CreateWalletAccountRequestFromJSONTyped;
296
+ exports.CreateWalletAccountRequestToJSON = CreateWalletAccountRequest.CreateWalletAccountRequestToJSON;
290
297
  exports.CurrencyFromJSON = Currency.CurrencyFromJSON;
291
298
  exports.CurrencyFromJSONTyped = Currency.CurrencyFromJSONTyped;
292
299
  exports.CurrencyToJSON = Currency.CurrencyToJSON;
@@ -828,12 +835,21 @@ exports.TokenBalanceToJSON = TokenBalance.TokenBalanceToJSON;
828
835
  exports.TooManyRequestsFromJSON = TooManyRequests.TooManyRequestsFromJSON;
829
836
  exports.TooManyRequestsFromJSONTyped = TooManyRequests.TooManyRequestsFromJSONTyped;
830
837
  exports.TooManyRequestsToJSON = TooManyRequests.TooManyRequestsToJSON;
838
+ exports.TurnkeyCreateWalletAccountsRequestBodyFromJSON = TurnkeyCreateWalletAccountsRequestBody.TurnkeyCreateWalletAccountsRequestBodyFromJSON;
839
+ exports.TurnkeyCreateWalletAccountsRequestBodyFromJSONTyped = TurnkeyCreateWalletAccountsRequestBody.TurnkeyCreateWalletAccountsRequestBodyFromJSONTyped;
840
+ exports.TurnkeyCreateWalletAccountsRequestBodyToJSON = TurnkeyCreateWalletAccountsRequestBody.TurnkeyCreateWalletAccountsRequestBodyToJSON;
841
+ exports.TurnkeyCreateWalletAccountsRequestBodyParametersFromJSON = TurnkeyCreateWalletAccountsRequestBodyParameters.TurnkeyCreateWalletAccountsRequestBodyParametersFromJSON;
842
+ exports.TurnkeyCreateWalletAccountsRequestBodyParametersFromJSONTyped = TurnkeyCreateWalletAccountsRequestBodyParameters.TurnkeyCreateWalletAccountsRequestBodyParametersFromJSONTyped;
843
+ exports.TurnkeyCreateWalletAccountsRequestBodyParametersToJSON = TurnkeyCreateWalletAccountsRequestBodyParameters.TurnkeyCreateWalletAccountsRequestBodyParametersToJSON;
831
844
  exports.TurnkeySignedRequestFromJSON = TurnkeySignedRequest.TurnkeySignedRequestFromJSON;
832
845
  exports.TurnkeySignedRequestFromJSONTyped = TurnkeySignedRequest.TurnkeySignedRequestFromJSONTyped;
833
846
  exports.TurnkeySignedRequestToJSON = TurnkeySignedRequest.TurnkeySignedRequestToJSON;
834
847
  exports.TurnkeyStampFromJSON = TurnkeyStamp.TurnkeyStampFromJSON;
835
848
  exports.TurnkeyStampFromJSONTyped = TurnkeyStamp.TurnkeyStampFromJSONTyped;
836
849
  exports.TurnkeyStampToJSON = TurnkeyStamp.TurnkeyStampToJSON;
850
+ exports.TurnkeyWalletAccountFromJSON = TurnkeyWalletAccount.TurnkeyWalletAccountFromJSON;
851
+ exports.TurnkeyWalletAccountFromJSONTyped = TurnkeyWalletAccount.TurnkeyWalletAccountFromJSONTyped;
852
+ exports.TurnkeyWalletAccountToJSON = TurnkeyWalletAccount.TurnkeyWalletAccountToJSON;
837
853
  exports.TurnkeyWalletPropertiesFromJSON = TurnkeyWalletProperties.TurnkeyWalletPropertiesFromJSON;
838
854
  exports.TurnkeyWalletPropertiesFromJSONTyped = TurnkeyWalletProperties.TurnkeyWalletPropertiesFromJSONTyped;
839
855
  exports.TurnkeyWalletPropertiesToJSON = TurnkeyWalletProperties.TurnkeyWalletPropertiesToJSON;
package/src/index.js CHANGED
@@ -18,6 +18,7 @@ export { CreateMfaTokenFromJSON, CreateMfaTokenFromJSONTyped, CreateMfaTokenToJS
18
18
  export { CreateTurnkeyEmbeddedWalletSpecificOptsFromJSON, CreateTurnkeyEmbeddedWalletSpecificOptsFromJSONTyped, CreateTurnkeyEmbeddedWalletSpecificOptsToJSON } from './models/CreateTurnkeyEmbeddedWalletSpecificOpts.js';
19
19
  export { CreateUserEmbeddedWalletsFromFarcasterRequestFromJSON, CreateUserEmbeddedWalletsFromFarcasterRequestFromJSONTyped, CreateUserEmbeddedWalletsFromFarcasterRequestToJSON } from './models/CreateUserEmbeddedWalletsFromFarcasterRequest.js';
20
20
  export { CreateUserEmbeddedWalletsRequestFromJSON, CreateUserEmbeddedWalletsRequestFromJSONTyped, CreateUserEmbeddedWalletsRequestToJSON } from './models/CreateUserEmbeddedWalletsRequest.js';
21
+ export { CreateWalletAccountRequestFromJSON, CreateWalletAccountRequestFromJSONTyped, CreateWalletAccountRequestToJSON } from './models/CreateWalletAccountRequest.js';
21
22
  export { CurrencyFromJSON, CurrencyFromJSONTyped, CurrencyToJSON } from './models/Currency.js';
22
23
  export { CurrencyType, CurrencyTypeFromJSON, CurrencyTypeFromJSONTyped, CurrencyTypeToJSON } from './models/CurrencyType.js';
23
24
  export { CustomFieldType, CustomFieldTypeFromJSON, CustomFieldTypeFromJSONTyped, CustomFieldTypeToJSON } from './models/CustomFieldType.js';
@@ -161,8 +162,11 @@ export { TelegramUserFromJSON, TelegramUserFromJSONTyped, TelegramUserToJSON } f
161
162
  export { TimeUnitEnum, TimeUnitEnumFromJSON, TimeUnitEnumFromJSONTyped, TimeUnitEnumToJSON } from './models/TimeUnitEnum.js';
162
163
  export { TokenBalanceFromJSON, TokenBalanceFromJSONTyped, TokenBalanceToJSON } from './models/TokenBalance.js';
163
164
  export { TooManyRequestsFromJSON, TooManyRequestsFromJSONTyped, TooManyRequestsToJSON } from './models/TooManyRequests.js';
165
+ export { TurnkeyCreateWalletAccountsRequestBodyFromJSON, TurnkeyCreateWalletAccountsRequestBodyFromJSONTyped, TurnkeyCreateWalletAccountsRequestBodyToJSON } from './models/TurnkeyCreateWalletAccountsRequestBody.js';
166
+ export { TurnkeyCreateWalletAccountsRequestBodyParametersFromJSON, TurnkeyCreateWalletAccountsRequestBodyParametersFromJSONTyped, TurnkeyCreateWalletAccountsRequestBodyParametersToJSON } from './models/TurnkeyCreateWalletAccountsRequestBodyParameters.js';
164
167
  export { TurnkeySignedRequestFromJSON, TurnkeySignedRequestFromJSONTyped, TurnkeySignedRequestToJSON } from './models/TurnkeySignedRequest.js';
165
168
  export { TurnkeyStampFromJSON, TurnkeyStampFromJSONTyped, TurnkeyStampToJSON } from './models/TurnkeyStamp.js';
169
+ export { TurnkeyWalletAccountFromJSON, TurnkeyWalletAccountFromJSONTyped, TurnkeyWalletAccountToJSON } from './models/TurnkeyWalletAccount.js';
166
170
  export { TurnkeyWalletPropertiesFromJSON, TurnkeyWalletPropertiesFromJSONTyped, TurnkeyWalletPropertiesToJSON } from './models/TurnkeyWalletProperties.js';
167
171
  export { UnauthorizedFromJSON, UnauthorizedFromJSONTyped, UnauthorizedToJSON } from './models/Unauthorized.js';
168
172
  export { UnprocessableEntityFromJSON, UnprocessableEntityFromJSONTyped, UnprocessableEntityToJSON } from './models/UnprocessableEntity.js';
@@ -0,0 +1,33 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var TurnkeySignedRequest = require('./TurnkeySignedRequest.cjs');
6
+
7
+ /* tslint:disable */
8
+ function CreateWalletAccountRequestFromJSON(json) {
9
+ return CreateWalletAccountRequestFromJSONTyped(json);
10
+ }
11
+ function CreateWalletAccountRequestFromJSONTyped(json, ignoreDiscriminator) {
12
+ if ((json === undefined) || (json === null)) {
13
+ return json;
14
+ }
15
+ return {
16
+ 'turnkeySignedRequest': TurnkeySignedRequest.TurnkeySignedRequestFromJSON(json['turnkeySignedRequest']),
17
+ };
18
+ }
19
+ function CreateWalletAccountRequestToJSON(value) {
20
+ if (value === undefined) {
21
+ return undefined;
22
+ }
23
+ if (value === null) {
24
+ return null;
25
+ }
26
+ return {
27
+ 'turnkeySignedRequest': TurnkeySignedRequest.TurnkeySignedRequestToJSON(value.turnkeySignedRequest),
28
+ };
29
+ }
30
+
31
+ exports.CreateWalletAccountRequestFromJSON = CreateWalletAccountRequestFromJSON;
32
+ exports.CreateWalletAccountRequestFromJSONTyped = CreateWalletAccountRequestFromJSONTyped;
33
+ exports.CreateWalletAccountRequestToJSON = CreateWalletAccountRequestToJSON;
@@ -0,0 +1,28 @@
1
+ /**
2
+ * Dashboard API
3
+ * Dashboard API documentation
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import { TurnkeySignedRequest } from './TurnkeySignedRequest';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface CreateWalletAccountRequest
17
+ */
18
+ export interface CreateWalletAccountRequest {
19
+ /**
20
+ *
21
+ * @type {TurnkeySignedRequest}
22
+ * @memberof CreateWalletAccountRequest
23
+ */
24
+ turnkeySignedRequest: TurnkeySignedRequest;
25
+ }
26
+ export declare function CreateWalletAccountRequestFromJSON(json: any): CreateWalletAccountRequest;
27
+ export declare function CreateWalletAccountRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateWalletAccountRequest;
28
+ export declare function CreateWalletAccountRequestToJSON(value?: CreateWalletAccountRequest | null): any;
@@ -0,0 +1,27 @@
1
+ import { TurnkeySignedRequestFromJSON, TurnkeySignedRequestToJSON } from './TurnkeySignedRequest.js';
2
+
3
+ /* tslint:disable */
4
+ function CreateWalletAccountRequestFromJSON(json) {
5
+ return CreateWalletAccountRequestFromJSONTyped(json);
6
+ }
7
+ function CreateWalletAccountRequestFromJSONTyped(json, ignoreDiscriminator) {
8
+ if ((json === undefined) || (json === null)) {
9
+ return json;
10
+ }
11
+ return {
12
+ 'turnkeySignedRequest': TurnkeySignedRequestFromJSON(json['turnkeySignedRequest']),
13
+ };
14
+ }
15
+ function CreateWalletAccountRequestToJSON(value) {
16
+ if (value === undefined) {
17
+ return undefined;
18
+ }
19
+ if (value === null) {
20
+ return null;
21
+ }
22
+ return {
23
+ 'turnkeySignedRequest': TurnkeySignedRequestToJSON(value.turnkeySignedRequest),
24
+ };
25
+ }
26
+
27
+ export { CreateWalletAccountRequestFromJSON, CreateWalletAccountRequestFromJSONTyped, CreateWalletAccountRequestToJSON };
@@ -0,0 +1,39 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var TurnkeyCreateWalletAccountsRequestBodyParameters = require('./TurnkeyCreateWalletAccountsRequestBodyParameters.cjs');
6
+
7
+ /* tslint:disable */
8
+ function TurnkeyCreateWalletAccountsRequestBodyFromJSON(json) {
9
+ return TurnkeyCreateWalletAccountsRequestBodyFromJSONTyped(json);
10
+ }
11
+ function TurnkeyCreateWalletAccountsRequestBodyFromJSONTyped(json, ignoreDiscriminator) {
12
+ if ((json === undefined) || (json === null)) {
13
+ return json;
14
+ }
15
+ return {
16
+ 'organizationId': json['organizationId'],
17
+ 'parameters': TurnkeyCreateWalletAccountsRequestBodyParameters.TurnkeyCreateWalletAccountsRequestBodyParametersFromJSON(json['parameters']),
18
+ 'timestampMs': json['timestampMs'],
19
+ 'type': json['type'],
20
+ };
21
+ }
22
+ function TurnkeyCreateWalletAccountsRequestBodyToJSON(value) {
23
+ if (value === undefined) {
24
+ return undefined;
25
+ }
26
+ if (value === null) {
27
+ return null;
28
+ }
29
+ return {
30
+ 'organizationId': value.organizationId,
31
+ 'parameters': TurnkeyCreateWalletAccountsRequestBodyParameters.TurnkeyCreateWalletAccountsRequestBodyParametersToJSON(value.parameters),
32
+ 'timestampMs': value.timestampMs,
33
+ 'type': value.type,
34
+ };
35
+ }
36
+
37
+ exports.TurnkeyCreateWalletAccountsRequestBodyFromJSON = TurnkeyCreateWalletAccountsRequestBodyFromJSON;
38
+ exports.TurnkeyCreateWalletAccountsRequestBodyFromJSONTyped = TurnkeyCreateWalletAccountsRequestBodyFromJSONTyped;
39
+ exports.TurnkeyCreateWalletAccountsRequestBodyToJSON = TurnkeyCreateWalletAccountsRequestBodyToJSON;
@@ -0,0 +1,46 @@
1
+ /**
2
+ * Dashboard API
3
+ * Dashboard API documentation
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import { TurnkeyCreateWalletAccountsRequestBodyParameters } from './TurnkeyCreateWalletAccountsRequestBodyParameters';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface TurnkeyCreateWalletAccountsRequestBody
17
+ */
18
+ export interface TurnkeyCreateWalletAccountsRequestBody {
19
+ /**
20
+ *
21
+ * @type {string}
22
+ * @memberof TurnkeyCreateWalletAccountsRequestBody
23
+ */
24
+ organizationId: string;
25
+ /**
26
+ *
27
+ * @type {TurnkeyCreateWalletAccountsRequestBodyParameters}
28
+ * @memberof TurnkeyCreateWalletAccountsRequestBody
29
+ */
30
+ parameters: TurnkeyCreateWalletAccountsRequestBodyParameters;
31
+ /**
32
+ *
33
+ * @type {string}
34
+ * @memberof TurnkeyCreateWalletAccountsRequestBody
35
+ */
36
+ timestampMs: string;
37
+ /**
38
+ *
39
+ * @type {string}
40
+ * @memberof TurnkeyCreateWalletAccountsRequestBody
41
+ */
42
+ type: string;
43
+ }
44
+ export declare function TurnkeyCreateWalletAccountsRequestBodyFromJSON(json: any): TurnkeyCreateWalletAccountsRequestBody;
45
+ export declare function TurnkeyCreateWalletAccountsRequestBodyFromJSONTyped(json: any, ignoreDiscriminator: boolean): TurnkeyCreateWalletAccountsRequestBody;
46
+ export declare function TurnkeyCreateWalletAccountsRequestBodyToJSON(value?: TurnkeyCreateWalletAccountsRequestBody | null): any;
@@ -0,0 +1,33 @@
1
+ import { TurnkeyCreateWalletAccountsRequestBodyParametersFromJSON, TurnkeyCreateWalletAccountsRequestBodyParametersToJSON } from './TurnkeyCreateWalletAccountsRequestBodyParameters.js';
2
+
3
+ /* tslint:disable */
4
+ function TurnkeyCreateWalletAccountsRequestBodyFromJSON(json) {
5
+ return TurnkeyCreateWalletAccountsRequestBodyFromJSONTyped(json);
6
+ }
7
+ function TurnkeyCreateWalletAccountsRequestBodyFromJSONTyped(json, ignoreDiscriminator) {
8
+ if ((json === undefined) || (json === null)) {
9
+ return json;
10
+ }
11
+ return {
12
+ 'organizationId': json['organizationId'],
13
+ 'parameters': TurnkeyCreateWalletAccountsRequestBodyParametersFromJSON(json['parameters']),
14
+ 'timestampMs': json['timestampMs'],
15
+ 'type': json['type'],
16
+ };
17
+ }
18
+ function TurnkeyCreateWalletAccountsRequestBodyToJSON(value) {
19
+ if (value === undefined) {
20
+ return undefined;
21
+ }
22
+ if (value === null) {
23
+ return null;
24
+ }
25
+ return {
26
+ 'organizationId': value.organizationId,
27
+ 'parameters': TurnkeyCreateWalletAccountsRequestBodyParametersToJSON(value.parameters),
28
+ 'timestampMs': value.timestampMs,
29
+ 'type': value.type,
30
+ };
31
+ }
32
+
33
+ export { TurnkeyCreateWalletAccountsRequestBodyFromJSON, TurnkeyCreateWalletAccountsRequestBodyFromJSONTyped, TurnkeyCreateWalletAccountsRequestBodyToJSON };
@@ -0,0 +1,35 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var TurnkeyWalletAccount = require('./TurnkeyWalletAccount.cjs');
6
+
7
+ /* tslint:disable */
8
+ function TurnkeyCreateWalletAccountsRequestBodyParametersFromJSON(json) {
9
+ return TurnkeyCreateWalletAccountsRequestBodyParametersFromJSONTyped(json);
10
+ }
11
+ function TurnkeyCreateWalletAccountsRequestBodyParametersFromJSONTyped(json, ignoreDiscriminator) {
12
+ if ((json === undefined) || (json === null)) {
13
+ return json;
14
+ }
15
+ return {
16
+ 'walletId': json['walletId'],
17
+ 'accounts': (json['accounts'].map(TurnkeyWalletAccount.TurnkeyWalletAccountFromJSON)),
18
+ };
19
+ }
20
+ function TurnkeyCreateWalletAccountsRequestBodyParametersToJSON(value) {
21
+ if (value === undefined) {
22
+ return undefined;
23
+ }
24
+ if (value === null) {
25
+ return null;
26
+ }
27
+ return {
28
+ 'walletId': value.walletId,
29
+ 'accounts': (value.accounts.map(TurnkeyWalletAccount.TurnkeyWalletAccountToJSON)),
30
+ };
31
+ }
32
+
33
+ exports.TurnkeyCreateWalletAccountsRequestBodyParametersFromJSON = TurnkeyCreateWalletAccountsRequestBodyParametersFromJSON;
34
+ exports.TurnkeyCreateWalletAccountsRequestBodyParametersFromJSONTyped = TurnkeyCreateWalletAccountsRequestBodyParametersFromJSONTyped;
35
+ exports.TurnkeyCreateWalletAccountsRequestBodyParametersToJSON = TurnkeyCreateWalletAccountsRequestBodyParametersToJSON;
@@ -0,0 +1,34 @@
1
+ /**
2
+ * Dashboard API
3
+ * Dashboard API documentation
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import { TurnkeyWalletAccount } from './TurnkeyWalletAccount';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface TurnkeyCreateWalletAccountsRequestBodyParameters
17
+ */
18
+ export interface TurnkeyCreateWalletAccountsRequestBodyParameters {
19
+ /**
20
+ *
21
+ * @type {string}
22
+ * @memberof TurnkeyCreateWalletAccountsRequestBodyParameters
23
+ */
24
+ walletId: string;
25
+ /**
26
+ *
27
+ * @type {Array<TurnkeyWalletAccount>}
28
+ * @memberof TurnkeyCreateWalletAccountsRequestBodyParameters
29
+ */
30
+ accounts: Array<TurnkeyWalletAccount>;
31
+ }
32
+ export declare function TurnkeyCreateWalletAccountsRequestBodyParametersFromJSON(json: any): TurnkeyCreateWalletAccountsRequestBodyParameters;
33
+ export declare function TurnkeyCreateWalletAccountsRequestBodyParametersFromJSONTyped(json: any, ignoreDiscriminator: boolean): TurnkeyCreateWalletAccountsRequestBodyParameters;
34
+ export declare function TurnkeyCreateWalletAccountsRequestBodyParametersToJSON(value?: TurnkeyCreateWalletAccountsRequestBodyParameters | null): any;
@@ -0,0 +1,29 @@
1
+ import { TurnkeyWalletAccountFromJSON, TurnkeyWalletAccountToJSON } from './TurnkeyWalletAccount.js';
2
+
3
+ /* tslint:disable */
4
+ function TurnkeyCreateWalletAccountsRequestBodyParametersFromJSON(json) {
5
+ return TurnkeyCreateWalletAccountsRequestBodyParametersFromJSONTyped(json);
6
+ }
7
+ function TurnkeyCreateWalletAccountsRequestBodyParametersFromJSONTyped(json, ignoreDiscriminator) {
8
+ if ((json === undefined) || (json === null)) {
9
+ return json;
10
+ }
11
+ return {
12
+ 'walletId': json['walletId'],
13
+ 'accounts': (json['accounts'].map(TurnkeyWalletAccountFromJSON)),
14
+ };
15
+ }
16
+ function TurnkeyCreateWalletAccountsRequestBodyParametersToJSON(value) {
17
+ if (value === undefined) {
18
+ return undefined;
19
+ }
20
+ if (value === null) {
21
+ return null;
22
+ }
23
+ return {
24
+ 'walletId': value.walletId,
25
+ 'accounts': (value.accounts.map(TurnkeyWalletAccountToJSON)),
26
+ };
27
+ }
28
+
29
+ export { TurnkeyCreateWalletAccountsRequestBodyParametersFromJSON, TurnkeyCreateWalletAccountsRequestBodyParametersFromJSONTyped, TurnkeyCreateWalletAccountsRequestBodyParametersToJSON };
@@ -0,0 +1,49 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ /* tslint:disable */
6
+ /* eslint-disable */
7
+ /**
8
+ * Dashboard API
9
+ * Dashboard API documentation
10
+ *
11
+ * The version of the OpenAPI document: 1.0.0
12
+ *
13
+ *
14
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
15
+ * https://openapi-generator.tech
16
+ * Do not edit the class manually.
17
+ */
18
+ function TurnkeyWalletAccountFromJSON(json) {
19
+ return TurnkeyWalletAccountFromJSONTyped(json);
20
+ }
21
+ function TurnkeyWalletAccountFromJSONTyped(json, ignoreDiscriminator) {
22
+ if ((json === undefined) || (json === null)) {
23
+ return json;
24
+ }
25
+ return {
26
+ 'curve': json['curve'],
27
+ 'pathFormat': json['pathFormat'],
28
+ 'path': json['path'],
29
+ 'addressFormat': json['addressFormat'],
30
+ };
31
+ }
32
+ function TurnkeyWalletAccountToJSON(value) {
33
+ if (value === undefined) {
34
+ return undefined;
35
+ }
36
+ if (value === null) {
37
+ return null;
38
+ }
39
+ return {
40
+ 'curve': value.curve,
41
+ 'pathFormat': value.pathFormat,
42
+ 'path': value.path,
43
+ 'addressFormat': value.addressFormat,
44
+ };
45
+ }
46
+
47
+ exports.TurnkeyWalletAccountFromJSON = TurnkeyWalletAccountFromJSON;
48
+ exports.TurnkeyWalletAccountFromJSONTyped = TurnkeyWalletAccountFromJSONTyped;
49
+ exports.TurnkeyWalletAccountToJSON = TurnkeyWalletAccountToJSON;
@@ -0,0 +1,45 @@
1
+ /**
2
+ * Dashboard API
3
+ * Dashboard API documentation
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface TurnkeyWalletAccount
16
+ */
17
+ export interface TurnkeyWalletAccount {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof TurnkeyWalletAccount
22
+ */
23
+ curve: string;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof TurnkeyWalletAccount
28
+ */
29
+ pathFormat: string;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof TurnkeyWalletAccount
34
+ */
35
+ path: string;
36
+ /**
37
+ *
38
+ * @type {string}
39
+ * @memberof TurnkeyWalletAccount
40
+ */
41
+ addressFormat: string;
42
+ }
43
+ export declare function TurnkeyWalletAccountFromJSON(json: any): TurnkeyWalletAccount;
44
+ export declare function TurnkeyWalletAccountFromJSONTyped(json: any, ignoreDiscriminator: boolean): TurnkeyWalletAccount;
45
+ export declare function TurnkeyWalletAccountToJSON(value?: TurnkeyWalletAccount | null): any;
@@ -0,0 +1,43 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Dashboard API
5
+ * Dashboard API documentation
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ function TurnkeyWalletAccountFromJSON(json) {
15
+ return TurnkeyWalletAccountFromJSONTyped(json);
16
+ }
17
+ function TurnkeyWalletAccountFromJSONTyped(json, ignoreDiscriminator) {
18
+ if ((json === undefined) || (json === null)) {
19
+ return json;
20
+ }
21
+ return {
22
+ 'curve': json['curve'],
23
+ 'pathFormat': json['pathFormat'],
24
+ 'path': json['path'],
25
+ 'addressFormat': json['addressFormat'],
26
+ };
27
+ }
28
+ function TurnkeyWalletAccountToJSON(value) {
29
+ if (value === undefined) {
30
+ return undefined;
31
+ }
32
+ if (value === null) {
33
+ return null;
34
+ }
35
+ return {
36
+ 'curve': value.curve,
37
+ 'pathFormat': value.pathFormat,
38
+ 'path': value.path,
39
+ 'addressFormat': value.addressFormat,
40
+ };
41
+ }
42
+
43
+ export { TurnkeyWalletAccountFromJSON, TurnkeyWalletAccountFromJSONTyped, TurnkeyWalletAccountToJSON };
@@ -109,6 +109,8 @@ exports.UnprocessableEntityErrorCode = void 0;
109
109
  UnprocessableEntityErrorCode["InvalidChainAddressMatch"] = "invalid_chain_address_match";
110
110
  UnprocessableEntityErrorCode["InvalidUpdate"] = "invalid_update";
111
111
  UnprocessableEntityErrorCode["CannotDeleteLastProject"] = "cannot_delete_last_project";
112
+ UnprocessableEntityErrorCode["NoHdWalletFound"] = "no_hd_wallet_found";
113
+ UnprocessableEntityErrorCode["WalletAccountExistsForChain"] = "wallet_account_exists_for_chain";
112
114
  })(exports.UnprocessableEntityErrorCode || (exports.UnprocessableEntityErrorCode = {}));
113
115
  function UnprocessableEntityErrorCodeFromJSON(json) {
114
116
  return UnprocessableEntityErrorCodeFromJSONTyped(json);
@@ -101,7 +101,9 @@ export declare enum UnprocessableEntityErrorCode {
101
101
  InvalidExternalAuth = "invalid_external_auth",
102
102
  InvalidChainAddressMatch = "invalid_chain_address_match",
103
103
  InvalidUpdate = "invalid_update",
104
- CannotDeleteLastProject = "cannot_delete_last_project"
104
+ CannotDeleteLastProject = "cannot_delete_last_project",
105
+ NoHdWalletFound = "no_hd_wallet_found",
106
+ WalletAccountExistsForChain = "wallet_account_exists_for_chain"
105
107
  }
106
108
  export declare function UnprocessableEntityErrorCodeFromJSON(json: any): UnprocessableEntityErrorCode;
107
109
  export declare function UnprocessableEntityErrorCodeFromJSONTyped(json: any, ignoreDiscriminator: boolean): UnprocessableEntityErrorCode;
@@ -105,6 +105,8 @@ var UnprocessableEntityErrorCode;
105
105
  UnprocessableEntityErrorCode["InvalidChainAddressMatch"] = "invalid_chain_address_match";
106
106
  UnprocessableEntityErrorCode["InvalidUpdate"] = "invalid_update";
107
107
  UnprocessableEntityErrorCode["CannotDeleteLastProject"] = "cannot_delete_last_project";
108
+ UnprocessableEntityErrorCode["NoHdWalletFound"] = "no_hd_wallet_found";
109
+ UnprocessableEntityErrorCode["WalletAccountExistsForChain"] = "wallet_account_exists_for_chain";
108
110
  })(UnprocessableEntityErrorCode || (UnprocessableEntityErrorCode = {}));
109
111
  function UnprocessableEntityErrorCodeFromJSON(json) {
110
112
  return UnprocessableEntityErrorCodeFromJSONTyped(json);
@@ -16,6 +16,7 @@ export * from './CreateMfaToken';
16
16
  export * from './CreateTurnkeyEmbeddedWalletSpecificOpts';
17
17
  export * from './CreateUserEmbeddedWalletsFromFarcasterRequest';
18
18
  export * from './CreateUserEmbeddedWalletsRequest';
19
+ export * from './CreateWalletAccountRequest';
19
20
  export * from './Currency';
20
21
  export * from './CurrencyType';
21
22
  export * from './CustomFieldType';
@@ -159,8 +160,11 @@ export * from './TelegramUser';
159
160
  export * from './TimeUnitEnum';
160
161
  export * from './TokenBalance';
161
162
  export * from './TooManyRequests';
163
+ export * from './TurnkeyCreateWalletAccountsRequestBody';
164
+ export * from './TurnkeyCreateWalletAccountsRequestBodyParameters';
162
165
  export * from './TurnkeySignedRequest';
163
166
  export * from './TurnkeyStamp';
167
+ export * from './TurnkeyWalletAccount';
164
168
  export * from './TurnkeyWalletProperties';
165
169
  export * from './Unauthorized';
166
170
  export * from './UnprocessableEntity';