@turnkey/core 2.3.0 → 2.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/dist/__clients__/core.d.ts +7 -0
  2. package/dist/__clients__/core.d.ts.map +1 -1
  3. package/dist/__clients__/core.js +35 -26
  4. package/dist/__clients__/core.js.map +1 -1
  5. package/dist/__clients__/core.mjs +35 -26
  6. package/dist/__clients__/core.mjs.map +1 -1
  7. package/dist/__generated__/sdk-client-base.d.ts +36 -7
  8. package/dist/__generated__/sdk-client-base.d.ts.map +1 -1
  9. package/dist/__generated__/sdk-client-base.js +514 -46
  10. package/dist/__generated__/sdk-client-base.js.map +1 -1
  11. package/dist/__generated__/sdk-client-base.mjs +514 -46
  12. package/dist/__generated__/sdk-client-base.mjs.map +1 -1
  13. package/dist/__generated__/version.d.ts +1 -1
  14. package/dist/__generated__/version.js +1 -1
  15. package/dist/__generated__/version.mjs +1 -1
  16. package/dist/__tests__/sol-send-transaction-helper-test.d.ts +2 -0
  17. package/dist/__tests__/sol-send-transaction-helper-test.d.ts.map +1 -0
  18. package/dist/__tests__/sol-send-transaction-test.d.ts +2 -0
  19. package/dist/__tests__/sol-send-transaction-test.d.ts.map +1 -0
  20. package/dist/__types__/method-types/shared.d.ts +10 -2
  21. package/dist/__types__/method-types/shared.d.ts.map +1 -1
  22. package/dist/index.d.ts +1 -1
  23. package/dist/index.d.ts.map +1 -1
  24. package/dist/index.js +1 -0
  25. package/dist/index.js.map +1 -1
  26. package/dist/index.mjs +1 -1
  27. package/dist/utils.d.ts +3 -1
  28. package/dist/utils.d.ts.map +1 -1
  29. package/dist/utils.js +26 -0
  30. package/dist/utils.js.map +1 -1
  31. package/dist/utils.mjs +26 -1
  32. package/dist/utils.mjs.map +1 -1
  33. package/package.json +8 -8
@@ -217,6 +217,96 @@ class TurnkeySDKClientBase {
217
217
  url: fullUrl,
218
218
  };
219
219
  };
220
+ this.getEarnDeployStatus = async (input, stampWith) => {
221
+ const session = await this.storageManager?.getActiveSession();
222
+ return this.request("/public/v1/query/get_earn_deploy_status", {
223
+ ...input,
224
+ organizationId: input.organizationId ??
225
+ session?.organizationId ??
226
+ this.config.organizationId,
227
+ }, stampWith);
228
+ };
229
+ this.stampGetEarnDeployStatus = async (input, stampWith) => {
230
+ const activeStamper = this.getStamper(stampWith);
231
+ if (!activeStamper) {
232
+ return undefined;
233
+ }
234
+ const session = await this.storageManager?.getActiveSession();
235
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_earn_deploy_status";
236
+ const body = {
237
+ ...input,
238
+ organizationId: input.organizationId ??
239
+ session?.organizationId ??
240
+ this.config.organizationId,
241
+ };
242
+ const stringifiedBody = JSON.stringify(body);
243
+ const stamp = await activeStamper.stamp(stringifiedBody);
244
+ return {
245
+ body: stringifiedBody,
246
+ stamp: stamp,
247
+ url: fullUrl,
248
+ };
249
+ };
250
+ this.getEarnDepositStatus = async (input, stampWith) => {
251
+ const session = await this.storageManager?.getActiveSession();
252
+ return this.request("/public/v1/query/get_earn_deposit_status", {
253
+ ...input,
254
+ organizationId: input.organizationId ??
255
+ session?.organizationId ??
256
+ this.config.organizationId,
257
+ }, stampWith);
258
+ };
259
+ this.stampGetEarnDepositStatus = async (input, stampWith) => {
260
+ const activeStamper = this.getStamper(stampWith);
261
+ if (!activeStamper) {
262
+ return undefined;
263
+ }
264
+ const session = await this.storageManager?.getActiveSession();
265
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_earn_deposit_status";
266
+ const body = {
267
+ ...input,
268
+ organizationId: input.organizationId ??
269
+ session?.organizationId ??
270
+ this.config.organizationId,
271
+ };
272
+ const stringifiedBody = JSON.stringify(body);
273
+ const stamp = await activeStamper.stamp(stringifiedBody);
274
+ return {
275
+ body: stringifiedBody,
276
+ stamp: stamp,
277
+ url: fullUrl,
278
+ };
279
+ };
280
+ this.getEarnWithdrawStatus = async (input, stampWith) => {
281
+ const session = await this.storageManager?.getActiveSession();
282
+ return this.request("/public/v1/query/get_earn_withdraw_status", {
283
+ ...input,
284
+ organizationId: input.organizationId ??
285
+ session?.organizationId ??
286
+ this.config.organizationId,
287
+ }, stampWith);
288
+ };
289
+ this.stampGetEarnWithdrawStatus = async (input, stampWith) => {
290
+ const activeStamper = this.getStamper(stampWith);
291
+ if (!activeStamper) {
292
+ return undefined;
293
+ }
294
+ const session = await this.storageManager?.getActiveSession();
295
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_earn_withdraw_status";
296
+ const body = {
297
+ ...input,
298
+ organizationId: input.organizationId ??
299
+ session?.organizationId ??
300
+ this.config.organizationId,
301
+ };
302
+ const stringifiedBody = JSON.stringify(body);
303
+ const stamp = await activeStamper.stamp(stringifiedBody);
304
+ return {
305
+ body: stringifiedBody,
306
+ stamp: stamp,
307
+ url: fullUrl,
308
+ };
309
+ };
220
310
  this.getGasUsage = async (input, stampWith) => {
221
311
  const session = await this.storageManager?.getActiveSession();
222
312
  return this.request("/public/v1/query/get_gas_usage", {
@@ -1027,6 +1117,96 @@ class TurnkeySDKClientBase {
1027
1117
  url: fullUrl,
1028
1118
  };
1029
1119
  };
1120
+ this.listEarnEnabledVaults = async (input, stampWith) => {
1121
+ const session = await this.storageManager?.getActiveSession();
1122
+ return this.request("/public/v1/query/list_earn_enabled_vaults", {
1123
+ ...input,
1124
+ organizationId: input.organizationId ??
1125
+ session?.organizationId ??
1126
+ this.config.organizationId,
1127
+ }, stampWith);
1128
+ };
1129
+ this.stampListEarnEnabledVaults = async (input, stampWith) => {
1130
+ const activeStamper = this.getStamper(stampWith);
1131
+ if (!activeStamper) {
1132
+ return undefined;
1133
+ }
1134
+ const session = await this.storageManager?.getActiveSession();
1135
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_earn_enabled_vaults";
1136
+ const body = {
1137
+ ...input,
1138
+ organizationId: input.organizationId ??
1139
+ session?.organizationId ??
1140
+ this.config.organizationId,
1141
+ };
1142
+ const stringifiedBody = JSON.stringify(body);
1143
+ const stamp = await activeStamper.stamp(stringifiedBody);
1144
+ return {
1145
+ body: stringifiedBody,
1146
+ stamp: stamp,
1147
+ url: fullUrl,
1148
+ };
1149
+ };
1150
+ this.listEarnPositions = async (input, stampWith) => {
1151
+ const session = await this.storageManager?.getActiveSession();
1152
+ return this.request("/public/v1/query/list_earn_positions", {
1153
+ ...input,
1154
+ organizationId: input.organizationId ??
1155
+ session?.organizationId ??
1156
+ this.config.organizationId,
1157
+ }, stampWith);
1158
+ };
1159
+ this.stampListEarnPositions = async (input, stampWith) => {
1160
+ const activeStamper = this.getStamper(stampWith);
1161
+ if (!activeStamper) {
1162
+ return undefined;
1163
+ }
1164
+ const session = await this.storageManager?.getActiveSession();
1165
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_earn_positions";
1166
+ const body = {
1167
+ ...input,
1168
+ organizationId: input.organizationId ??
1169
+ session?.organizationId ??
1170
+ this.config.organizationId,
1171
+ };
1172
+ const stringifiedBody = JSON.stringify(body);
1173
+ const stamp = await activeStamper.stamp(stringifiedBody);
1174
+ return {
1175
+ body: stringifiedBody,
1176
+ stamp: stamp,
1177
+ url: fullUrl,
1178
+ };
1179
+ };
1180
+ this.listEarnVaults = async (input, stampWith) => {
1181
+ const session = await this.storageManager?.getActiveSession();
1182
+ return this.request("/public/v1/query/list_earn_vaults", {
1183
+ ...input,
1184
+ organizationId: input.organizationId ??
1185
+ session?.organizationId ??
1186
+ this.config.organizationId,
1187
+ }, stampWith);
1188
+ };
1189
+ this.stampListEarnVaults = async (input, stampWith) => {
1190
+ const activeStamper = this.getStamper(stampWith);
1191
+ if (!activeStamper) {
1192
+ return undefined;
1193
+ }
1194
+ const session = await this.storageManager?.getActiveSession();
1195
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_earn_vaults";
1196
+ const body = {
1197
+ ...input,
1198
+ organizationId: input.organizationId ??
1199
+ session?.organizationId ??
1200
+ this.config.organizationId,
1201
+ };
1202
+ const stringifiedBody = JSON.stringify(body);
1203
+ const stamp = await activeStamper.stamp(stringifiedBody);
1204
+ return {
1205
+ body: stringifiedBody,
1206
+ stamp: stamp,
1207
+ url: fullUrl,
1208
+ };
1209
+ };
1030
1210
  this.listEmailEvents = async (input, stampWith) => {
1031
1211
  const session = await this.storageManager?.getActiveSession();
1032
1212
  return this.request("/public/v1/query/list_email_events", {
@@ -1057,6 +1237,36 @@ class TurnkeySDKClientBase {
1057
1237
  url: fullUrl,
1058
1238
  };
1059
1239
  };
1240
+ this.listEthTransactionHistory = async (input, stampWith) => {
1241
+ const session = await this.storageManager?.getActiveSession();
1242
+ return this.request("/public/v1/query/list_eth_transaction_history", {
1243
+ ...input,
1244
+ organizationId: input.organizationId ??
1245
+ session?.organizationId ??
1246
+ this.config.organizationId,
1247
+ }, stampWith);
1248
+ };
1249
+ this.stampListEthTransactionHistory = async (input, stampWith) => {
1250
+ const activeStamper = this.getStamper(stampWith);
1251
+ if (!activeStamper) {
1252
+ return undefined;
1253
+ }
1254
+ const session = await this.storageManager?.getActiveSession();
1255
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_eth_transaction_history";
1256
+ const body = {
1257
+ ...input,
1258
+ organizationId: input.organizationId ??
1259
+ session?.organizationId ??
1260
+ this.config.organizationId,
1261
+ };
1262
+ const stringifiedBody = JSON.stringify(body);
1263
+ const stamp = await activeStamper.stamp(stringifiedBody);
1264
+ return {
1265
+ body: stringifiedBody,
1266
+ stamp: stamp,
1267
+ url: fullUrl,
1268
+ };
1269
+ };
1060
1270
  this.listFiatOnRampCredentials = async (input, stampWith) => {
1061
1271
  const session = await this.storageManager?.getActiveSession();
1062
1272
  return this.request("/public/v1/query/list_fiat_on_ramp_credentials", {
@@ -1238,6 +1448,36 @@ class TurnkeySDKClientBase {
1238
1448
  url: fullUrl,
1239
1449
  };
1240
1450
  };
1451
+ this.listSolTransactionHistory = async (input, stampWith) => {
1452
+ const session = await this.storageManager?.getActiveSession();
1453
+ return this.request("/public/v1/query/list_sol_transaction_history", {
1454
+ ...input,
1455
+ organizationId: input.organizationId ??
1456
+ session?.organizationId ??
1457
+ this.config.organizationId,
1458
+ }, stampWith);
1459
+ };
1460
+ this.stampListSolTransactionHistory = async (input, stampWith) => {
1461
+ const activeStamper = this.getStamper(stampWith);
1462
+ if (!activeStamper) {
1463
+ return undefined;
1464
+ }
1465
+ const session = await this.storageManager?.getActiveSession();
1466
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_sol_transaction_history";
1467
+ const body = {
1468
+ ...input,
1469
+ organizationId: input.organizationId ??
1470
+ session?.organizationId ??
1471
+ this.config.organizationId,
1472
+ };
1473
+ const stringifiedBody = JSON.stringify(body);
1474
+ const stamp = await activeStamper.stamp(stringifiedBody);
1475
+ return {
1476
+ body: stringifiedBody,
1477
+ stamp: stamp,
1478
+ url: fullUrl,
1479
+ };
1480
+ };
1241
1481
  this.getSubOrgIds = async (input = {}, stampWith) => {
1242
1482
  const session = await this.storageManager?.getActiveSession();
1243
1483
  return this.request("/public/v1/query/list_suborgs", {
@@ -1634,6 +1874,43 @@ class TurnkeySDKClientBase {
1634
1874
  url: fullUrl,
1635
1875
  };
1636
1876
  };
1877
+ this.claimEarnFees = async (input, stampWith) => {
1878
+ const { organizationId, timestampMs, ...rest } = input;
1879
+ //@ts-ignore - generateAppProofs does not exist on all request types, so we ignore the type error here for those that are missing it
1880
+ const generateAppProofs = input?.generateAppProofs ?? false;
1881
+ const session = await this.storageManager?.getActiveSession();
1882
+ return this.activity("/public/v1/submit/claim_earn_fees", {
1883
+ parameters: rest,
1884
+ organizationId: organizationId ??
1885
+ session?.organizationId ??
1886
+ this.config.organizationId,
1887
+ timestampMs: timestampMs ?? String(Date.now()),
1888
+ generateAppProofs: generateAppProofs ?? false,
1889
+ type: "ACTIVITY_TYPE_CLAIM_EARN_FEES",
1890
+ }, "claimEarnFeesResult", stampWith);
1891
+ };
1892
+ this.stampClaimEarnFees = async (input, stampWith) => {
1893
+ const activeStamper = this.getStamper(stampWith);
1894
+ if (!activeStamper) {
1895
+ return undefined;
1896
+ }
1897
+ const { organizationId, timestampMs, ...parameters } = input;
1898
+ const session = await this.storageManager?.getActiveSession();
1899
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/claim_earn_fees";
1900
+ const bodyWithType = {
1901
+ parameters,
1902
+ organizationId: organizationId ?? session?.organizationId ?? this.config.organizationId,
1903
+ timestampMs: timestampMs ?? String(Date.now()),
1904
+ type: "ACTIVITY_TYPE_CLAIM_EARN_FEES",
1905
+ };
1906
+ const stringifiedBody = JSON.stringify(bodyWithType);
1907
+ const stamp = await activeStamper.stamp(stringifiedBody);
1908
+ return {
1909
+ body: stringifiedBody,
1910
+ stamp: stamp,
1911
+ url: fullUrl,
1912
+ };
1913
+ };
1637
1914
  this.createApiKeys = async (input, stampWith) => {
1638
1915
  const { organizationId, timestampMs, ...rest } = input;
1639
1916
  //@ts-ignore - generateAppProofs does not exist on all request types, so we ignore the type error here for those that are missing it
@@ -3268,6 +3545,154 @@ class TurnkeySDKClientBase {
3268
3545
  url: fullUrl,
3269
3546
  };
3270
3547
  };
3548
+ this.earnDeployWrapper = async (input, stampWith) => {
3549
+ const { organizationId, timestampMs, ...rest } = input;
3550
+ //@ts-ignore - generateAppProofs does not exist on all request types, so we ignore the type error here for those that are missing it
3551
+ const generateAppProofs = input?.generateAppProofs ?? false;
3552
+ const session = await this.storageManager?.getActiveSession();
3553
+ return this.activity("/public/v1/submit/earn_deploy_wrapper", {
3554
+ parameters: rest,
3555
+ organizationId: organizationId ??
3556
+ session?.organizationId ??
3557
+ this.config.organizationId,
3558
+ timestampMs: timestampMs ?? String(Date.now()),
3559
+ generateAppProofs: generateAppProofs ?? false,
3560
+ type: "ACTIVITY_TYPE_EARN_DEPLOY_WRAPPER",
3561
+ }, "earnDeployWrapperResult", stampWith);
3562
+ };
3563
+ this.stampEarnDeployWrapper = async (input, stampWith) => {
3564
+ const activeStamper = this.getStamper(stampWith);
3565
+ if (!activeStamper) {
3566
+ return undefined;
3567
+ }
3568
+ const { organizationId, timestampMs, ...parameters } = input;
3569
+ const session = await this.storageManager?.getActiveSession();
3570
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/earn_deploy_wrapper";
3571
+ const bodyWithType = {
3572
+ parameters,
3573
+ organizationId: organizationId ?? session?.organizationId ?? this.config.organizationId,
3574
+ timestampMs: timestampMs ?? String(Date.now()),
3575
+ type: "ACTIVITY_TYPE_EARN_DEPLOY_WRAPPER",
3576
+ };
3577
+ const stringifiedBody = JSON.stringify(bodyWithType);
3578
+ const stamp = await activeStamper.stamp(stringifiedBody);
3579
+ return {
3580
+ body: stringifiedBody,
3581
+ stamp: stamp,
3582
+ url: fullUrl,
3583
+ };
3584
+ };
3585
+ this.earnDeposit = async (input, stampWith) => {
3586
+ const { organizationId, timestampMs, ...rest } = input;
3587
+ //@ts-ignore - generateAppProofs does not exist on all request types, so we ignore the type error here for those that are missing it
3588
+ const generateAppProofs = input?.generateAppProofs ?? false;
3589
+ const session = await this.storageManager?.getActiveSession();
3590
+ return this.activity("/public/v1/submit/earn_deposit", {
3591
+ parameters: rest,
3592
+ organizationId: organizationId ??
3593
+ session?.organizationId ??
3594
+ this.config.organizationId,
3595
+ timestampMs: timestampMs ?? String(Date.now()),
3596
+ generateAppProofs: generateAppProofs ?? false,
3597
+ type: "ACTIVITY_TYPE_EARN_DEPOSIT",
3598
+ }, "earnDepositResult", stampWith);
3599
+ };
3600
+ this.stampEarnDeposit = async (input, stampWith) => {
3601
+ const activeStamper = this.getStamper(stampWith);
3602
+ if (!activeStamper) {
3603
+ return undefined;
3604
+ }
3605
+ const { organizationId, timestampMs, ...parameters } = input;
3606
+ const session = await this.storageManager?.getActiveSession();
3607
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/earn_deposit";
3608
+ const bodyWithType = {
3609
+ parameters,
3610
+ organizationId: organizationId ?? session?.organizationId ?? this.config.organizationId,
3611
+ timestampMs: timestampMs ?? String(Date.now()),
3612
+ type: "ACTIVITY_TYPE_EARN_DEPOSIT",
3613
+ };
3614
+ const stringifiedBody = JSON.stringify(bodyWithType);
3615
+ const stamp = await activeStamper.stamp(stringifiedBody);
3616
+ return {
3617
+ body: stringifiedBody,
3618
+ stamp: stamp,
3619
+ url: fullUrl,
3620
+ };
3621
+ };
3622
+ this.earnSetWrapperState = async (input, stampWith) => {
3623
+ const { organizationId, timestampMs, ...rest } = input;
3624
+ //@ts-ignore - generateAppProofs does not exist on all request types, so we ignore the type error here for those that are missing it
3625
+ const generateAppProofs = input?.generateAppProofs ?? false;
3626
+ const session = await this.storageManager?.getActiveSession();
3627
+ return this.activity("/public/v1/submit/earn_set_wrapper_state", {
3628
+ parameters: rest,
3629
+ organizationId: organizationId ??
3630
+ session?.organizationId ??
3631
+ this.config.organizationId,
3632
+ timestampMs: timestampMs ?? String(Date.now()),
3633
+ generateAppProofs: generateAppProofs ?? false,
3634
+ type: "ACTIVITY_TYPE_EARN_SET_WRAPPER_STATE",
3635
+ }, "earnSetWrapperStateResult", stampWith);
3636
+ };
3637
+ this.stampEarnSetWrapperState = async (input, stampWith) => {
3638
+ const activeStamper = this.getStamper(stampWith);
3639
+ if (!activeStamper) {
3640
+ return undefined;
3641
+ }
3642
+ const { organizationId, timestampMs, ...parameters } = input;
3643
+ const session = await this.storageManager?.getActiveSession();
3644
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/earn_set_wrapper_state";
3645
+ const bodyWithType = {
3646
+ parameters,
3647
+ organizationId: organizationId ?? session?.organizationId ?? this.config.organizationId,
3648
+ timestampMs: timestampMs ?? String(Date.now()),
3649
+ type: "ACTIVITY_TYPE_EARN_SET_WRAPPER_STATE",
3650
+ };
3651
+ const stringifiedBody = JSON.stringify(bodyWithType);
3652
+ const stamp = await activeStamper.stamp(stringifiedBody);
3653
+ return {
3654
+ body: stringifiedBody,
3655
+ stamp: stamp,
3656
+ url: fullUrl,
3657
+ };
3658
+ };
3659
+ this.earnWithdraw = async (input, stampWith) => {
3660
+ const { organizationId, timestampMs, ...rest } = input;
3661
+ //@ts-ignore - generateAppProofs does not exist on all request types, so we ignore the type error here for those that are missing it
3662
+ const generateAppProofs = input?.generateAppProofs ?? false;
3663
+ const session = await this.storageManager?.getActiveSession();
3664
+ return this.activity("/public/v1/submit/earn_withdraw", {
3665
+ parameters: rest,
3666
+ organizationId: organizationId ??
3667
+ session?.organizationId ??
3668
+ this.config.organizationId,
3669
+ timestampMs: timestampMs ?? String(Date.now()),
3670
+ generateAppProofs: generateAppProofs ?? false,
3671
+ type: "ACTIVITY_TYPE_EARN_WITHDRAW",
3672
+ }, "earnWithdrawResult", stampWith);
3673
+ };
3674
+ this.stampEarnWithdraw = async (input, stampWith) => {
3675
+ const activeStamper = this.getStamper(stampWith);
3676
+ if (!activeStamper) {
3677
+ return undefined;
3678
+ }
3679
+ const { organizationId, timestampMs, ...parameters } = input;
3680
+ const session = await this.storageManager?.getActiveSession();
3681
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/earn_withdraw";
3682
+ const bodyWithType = {
3683
+ parameters,
3684
+ organizationId: organizationId ?? session?.organizationId ?? this.config.organizationId,
3685
+ timestampMs: timestampMs ?? String(Date.now()),
3686
+ type: "ACTIVITY_TYPE_EARN_WITHDRAW",
3687
+ };
3688
+ const stringifiedBody = JSON.stringify(bodyWithType);
3689
+ const stamp = await activeStamper.stamp(stringifiedBody);
3690
+ return {
3691
+ body: stringifiedBody,
3692
+ stamp: stamp,
3693
+ url: fullUrl,
3694
+ };
3695
+ };
3271
3696
  this.emailAuth = async (input, stampWith) => {
3272
3697
  const { organizationId, timestampMs, ...rest } = input;
3273
3698
  //@ts-ignore - generateAppProofs does not exist on all request types, so we ignore the type error here for those that are missing it
@@ -4303,43 +4728,6 @@ class TurnkeySDKClientBase {
4303
4728
  url: fullUrl,
4304
4729
  };
4305
4730
  };
4306
- this.solSendTransaction = async (input, stampWith) => {
4307
- const { organizationId, timestampMs, ...rest } = input;
4308
- //@ts-ignore - generateAppProofs does not exist on all request types, so we ignore the type error here for those that are missing it
4309
- const generateAppProofs = input?.generateAppProofs ?? false;
4310
- const session = await this.storageManager?.getActiveSession();
4311
- return this.activity("/public/v1/submit/sol_send_transaction", {
4312
- parameters: rest,
4313
- organizationId: organizationId ??
4314
- session?.organizationId ??
4315
- this.config.organizationId,
4316
- timestampMs: timestampMs ?? String(Date.now()),
4317
- generateAppProofs: generateAppProofs ?? false,
4318
- type: "ACTIVITY_TYPE_SOL_SEND_TRANSACTION",
4319
- }, "solSendTransactionResult", stampWith);
4320
- };
4321
- this.stampSolSendTransaction = async (input, stampWith) => {
4322
- const activeStamper = this.getStamper(stampWith);
4323
- if (!activeStamper) {
4324
- return undefined;
4325
- }
4326
- const { organizationId, timestampMs, ...parameters } = input;
4327
- const session = await this.storageManager?.getActiveSession();
4328
- const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/sol_send_transaction";
4329
- const bodyWithType = {
4330
- parameters,
4331
- organizationId: organizationId ?? session?.organizationId ?? this.config.organizationId,
4332
- timestampMs: timestampMs ?? String(Date.now()),
4333
- type: "ACTIVITY_TYPE_SOL_SEND_TRANSACTION",
4334
- };
4335
- const stringifiedBody = JSON.stringify(bodyWithType);
4336
- const stamp = await activeStamper.stamp(stringifiedBody);
4337
- return {
4338
- body: stringifiedBody,
4339
- stamp: stamp,
4340
- url: fullUrl,
4341
- };
4342
- };
4343
4731
  this.sparkClaimTransfer = async (input, stampWith) => {
4344
4732
  const { organizationId, timestampMs, ...rest } = input;
4345
4733
  //@ts-ignore - generateAppProofs does not exist on all request types, so we ignore the type error here for those that are missing it
@@ -5156,6 +5544,80 @@ class TurnkeySDKClientBase {
5156
5544
  url: fullUrl,
5157
5545
  };
5158
5546
  };
5547
+ this.solSendTransaction = async (input, stampWith) => {
5548
+ const { organizationId, timestampMs, ...rest } = input;
5549
+ //@ts-ignore - generateAppProofs does not exist on all request types, so we ignore the type error here for those that are missing it
5550
+ const generateAppProofs = input?.generateAppProofs ?? false;
5551
+ const session = await this.storageManager?.getActiveSession();
5552
+ return this.activity("/public/v1/submit/sol_send_transaction", {
5553
+ parameters: rest,
5554
+ organizationId: organizationId ??
5555
+ session?.organizationId ??
5556
+ this.config.organizationId,
5557
+ timestampMs: timestampMs ?? String(Date.now()),
5558
+ generateAppProofs: generateAppProofs ?? false,
5559
+ type: "ACTIVITY_TYPE_SOL_SEND_TRANSACTION",
5560
+ }, "solSendTransactionResult", stampWith);
5561
+ };
5562
+ this.stampSolSendTransaction = async (input, stampWith) => {
5563
+ const activeStamper = this.getStamper(stampWith);
5564
+ if (!activeStamper) {
5565
+ return undefined;
5566
+ }
5567
+ const { organizationId, timestampMs, ...parameters } = input;
5568
+ const session = await this.storageManager?.getActiveSession();
5569
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/sol_send_transaction";
5570
+ const bodyWithType = {
5571
+ parameters,
5572
+ organizationId: organizationId ?? session?.organizationId ?? this.config.organizationId,
5573
+ timestampMs: timestampMs ?? String(Date.now()),
5574
+ type: "ACTIVITY_TYPE_SOL_SEND_TRANSACTION",
5575
+ };
5576
+ const stringifiedBody = JSON.stringify(bodyWithType);
5577
+ const stamp = await activeStamper.stamp(stringifiedBody);
5578
+ return {
5579
+ body: stringifiedBody,
5580
+ stamp: stamp,
5581
+ url: fullUrl,
5582
+ };
5583
+ };
5584
+ this.solSendTransactionV2 = async (input, stampWith) => {
5585
+ const { organizationId, timestampMs, ...rest } = input;
5586
+ //@ts-ignore - generateAppProofs does not exist on all request types, so we ignore the type error here for those that are missing it
5587
+ const generateAppProofs = input?.generateAppProofs ?? false;
5588
+ const session = await this.storageManager?.getActiveSession();
5589
+ return this.activity("/public/v1/submit/sol_send_transaction", {
5590
+ parameters: rest,
5591
+ organizationId: organizationId ??
5592
+ session?.organizationId ??
5593
+ this.config.organizationId,
5594
+ timestampMs: timestampMs ?? String(Date.now()),
5595
+ generateAppProofs: generateAppProofs ?? false,
5596
+ type: "ACTIVITY_TYPE_SOL_SEND_TRANSACTION_V2",
5597
+ }, "solSendTransactionResultV2", stampWith);
5598
+ };
5599
+ this.stampSolSendTransactionV2 = async (input, stampWith) => {
5600
+ const activeStamper = this.getStamper(stampWith);
5601
+ if (!activeStamper) {
5602
+ return undefined;
5603
+ }
5604
+ const { organizationId, timestampMs, ...parameters } = input;
5605
+ const session = await this.storageManager?.getActiveSession();
5606
+ const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/sol_send_transaction";
5607
+ const bodyWithType = {
5608
+ parameters,
5609
+ organizationId: organizationId ?? session?.organizationId ?? this.config.organizationId,
5610
+ timestampMs: timestampMs ?? String(Date.now()),
5611
+ type: "ACTIVITY_TYPE_SOL_SEND_TRANSACTION_V2",
5612
+ };
5613
+ const stringifiedBody = JSON.stringify(bodyWithType);
5614
+ const stamp = await activeStamper.stamp(stringifiedBody);
5615
+ return {
5616
+ body: stringifiedBody,
5617
+ stamp: stamp,
5618
+ url: fullUrl,
5619
+ };
5620
+ };
5159
5621
  this.proxyGetAccount = async (input) => {
5160
5622
  return this.authProxyRequest("/v1/account", input);
5161
5623
  };
@@ -5165,11 +5627,11 @@ class TurnkeySDKClientBase {
5165
5627
  this.proxyOAuthLogin = async (input) => {
5166
5628
  return this.authProxyRequest("/v1/oauth_login", input);
5167
5629
  };
5168
- this.proxyInitOtp = async (input) => {
5169
- return this.authProxyRequest("/v1/otp_init", input);
5630
+ this.proxyInitOtp = async (input, captchaToken) => {
5631
+ return this.authProxyRequest("/v1/otp_init", input, captchaToken);
5170
5632
  };
5171
- this.proxyInitOtpV2 = async (input) => {
5172
- return this.authProxyRequest("/v1/otp_init_v2", input);
5633
+ this.proxyInitOtpV2 = async (input, captchaToken) => {
5634
+ return this.authProxyRequest("/v1/otp_init_v2", input, captchaToken);
5173
5635
  };
5174
5636
  this.proxyOtpLogin = async (input) => {
5175
5637
  return this.authProxyRequest("/v1/otp_login", input);
@@ -5183,11 +5645,14 @@ class TurnkeySDKClientBase {
5183
5645
  this.proxyVerifyOtpV2 = async (input) => {
5184
5646
  return this.authProxyRequest("/v1/otp_verify_v2", input);
5185
5647
  };
5186
- this.proxySignup = async (input) => {
5187
- return this.authProxyRequest("/v1/signup", input);
5648
+ this.proxySignup = async (input, captchaToken) => {
5649
+ return this.authProxyRequest("/v1/signup", input, captchaToken);
5650
+ };
5651
+ this.proxySignupV2 = async (input, captchaToken) => {
5652
+ return this.authProxyRequest("/v1/signup_v2", input, captchaToken);
5188
5653
  };
5189
- this.proxySignupV2 = async (input) => {
5190
- return this.authProxyRequest("/v1/signup_v2", input);
5654
+ this.proxyGetWalletKitClientParams = async (input) => {
5655
+ return this.authProxyRequest("/v1/wallet_kit_client_params", input);
5191
5656
  };
5192
5657
  this.proxyGetWalletKitConfig = async (input) => {
5193
5658
  return this.authProxyRequest("/v1/wallet_kit_config", input);
@@ -5335,7 +5800,7 @@ class TurnkeySDKClientBase {
5335
5800
  ...activityData,
5336
5801
  };
5337
5802
  }
5338
- async authProxyRequest(url, body) {
5803
+ async authProxyRequest(url, body, captchaToken) {
5339
5804
  if (!this.config.authProxyUrl || !this.config.authProxyConfigId) {
5340
5805
  throw new sdkTypes.TurnkeyError("Auth Proxy URL or ID is not configured.", sdkTypes.TurnkeyErrorCodes.INVALID_CONFIGURATION);
5341
5806
  }
@@ -5345,6 +5810,9 @@ class TurnkeySDKClientBase {
5345
5810
  "Content-Type": "application/json",
5346
5811
  "X-Auth-Proxy-Config-ID": this.config.authProxyConfigId,
5347
5812
  };
5813
+ if (captchaToken) {
5814
+ headers["X-Captcha-Token"] = captchaToken;
5815
+ }
5348
5816
  const response = await fetch(fullUrl, {
5349
5817
  method: "POST",
5350
5818
  headers: headers,