@turnkey/sdk-browser 1.11.2 → 1.12.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.
- package/CHANGELOG.md +13 -0
- package/dist/__generated__/sdk-client-base.d.ts +4 -1
- package/dist/__generated__/sdk-client-base.d.ts.map +1 -1
- package/dist/__generated__/sdk-client-base.js +182 -154
- package/dist/__generated__/sdk-client-base.js.map +1 -1
- package/dist/__generated__/sdk-client-base.mjs +182 -154
- package/dist/__generated__/sdk-client-base.mjs.map +1 -1
- package/dist/__generated__/sdk_api_types.d.ts +5 -0
- package/dist/__generated__/sdk_api_types.d.ts.map +1 -1
- package/dist/__generated__/version.d.ts +1 -1
- package/dist/__generated__/version.js +1 -1
- package/dist/__generated__/version.mjs +1 -1
- package/dist/__inputs__/public_api.types.d.ts +50 -1
- package/dist/__inputs__/public_api.types.d.ts.map +1 -1
- package/dist/__types__/base.d.ts +4 -1
- package/dist/__types__/base.d.ts.map +1 -1
- package/dist/__types__/base.js.map +1 -1
- package/dist/__types__/base.mjs.map +1 -1
- package/dist/sdk-client.d.ts +2 -1
- package/dist/sdk-client.d.ts.map +1 -1
- package/dist/sdk-client.js +14 -19
- package/dist/sdk-client.js.map +1 -1
- package/dist/sdk-client.mjs +14 -19
- package/dist/sdk-client.mjs.map +1 -1
- package/package.json +2 -2
|
@@ -13,12 +13,12 @@ class TurnkeySDKClientBase {
|
|
|
13
13
|
});
|
|
14
14
|
};
|
|
15
15
|
this.stampGetActivity = async (input) => {
|
|
16
|
-
if (!this.
|
|
16
|
+
if (!this.stamper) {
|
|
17
17
|
return undefined;
|
|
18
18
|
}
|
|
19
19
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_activity";
|
|
20
20
|
const body = JSON.stringify(input);
|
|
21
|
-
const stamp = await this.
|
|
21
|
+
const stamp = await this.stamper.stamp(body);
|
|
22
22
|
return {
|
|
23
23
|
body: body,
|
|
24
24
|
stamp: stamp,
|
|
@@ -32,12 +32,12 @@ class TurnkeySDKClientBase {
|
|
|
32
32
|
});
|
|
33
33
|
};
|
|
34
34
|
this.stampGetApiKey = async (input) => {
|
|
35
|
-
if (!this.
|
|
35
|
+
if (!this.stamper) {
|
|
36
36
|
return undefined;
|
|
37
37
|
}
|
|
38
38
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_api_key";
|
|
39
39
|
const body = JSON.stringify(input);
|
|
40
|
-
const stamp = await this.
|
|
40
|
+
const stamp = await this.stamper.stamp(body);
|
|
41
41
|
return {
|
|
42
42
|
body: body,
|
|
43
43
|
stamp: stamp,
|
|
@@ -51,12 +51,12 @@ class TurnkeySDKClientBase {
|
|
|
51
51
|
});
|
|
52
52
|
};
|
|
53
53
|
this.stampGetApiKeys = async (input) => {
|
|
54
|
-
if (!this.
|
|
54
|
+
if (!this.stamper) {
|
|
55
55
|
return undefined;
|
|
56
56
|
}
|
|
57
57
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_api_keys";
|
|
58
58
|
const body = JSON.stringify(input);
|
|
59
|
-
const stamp = await this.
|
|
59
|
+
const stamp = await this.stamper.stamp(body);
|
|
60
60
|
return {
|
|
61
61
|
body: body,
|
|
62
62
|
stamp: stamp,
|
|
@@ -70,12 +70,12 @@ class TurnkeySDKClientBase {
|
|
|
70
70
|
});
|
|
71
71
|
};
|
|
72
72
|
this.stampGetAttestationDocument = async (input) => {
|
|
73
|
-
if (!this.
|
|
73
|
+
if (!this.stamper) {
|
|
74
74
|
return undefined;
|
|
75
75
|
}
|
|
76
76
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_attestation";
|
|
77
77
|
const body = JSON.stringify(input);
|
|
78
|
-
const stamp = await this.
|
|
78
|
+
const stamp = await this.stamper.stamp(body);
|
|
79
79
|
return {
|
|
80
80
|
body: body,
|
|
81
81
|
stamp: stamp,
|
|
@@ -89,12 +89,12 @@ class TurnkeySDKClientBase {
|
|
|
89
89
|
});
|
|
90
90
|
};
|
|
91
91
|
this.stampGetAuthenticator = async (input) => {
|
|
92
|
-
if (!this.
|
|
92
|
+
if (!this.stamper) {
|
|
93
93
|
return undefined;
|
|
94
94
|
}
|
|
95
95
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_authenticator";
|
|
96
96
|
const body = JSON.stringify(input);
|
|
97
|
-
const stamp = await this.
|
|
97
|
+
const stamp = await this.stamper.stamp(body);
|
|
98
98
|
return {
|
|
99
99
|
body: body,
|
|
100
100
|
stamp: stamp,
|
|
@@ -108,12 +108,12 @@ class TurnkeySDKClientBase {
|
|
|
108
108
|
});
|
|
109
109
|
};
|
|
110
110
|
this.stampGetAuthenticators = async (input) => {
|
|
111
|
-
if (!this.
|
|
111
|
+
if (!this.stamper) {
|
|
112
112
|
return undefined;
|
|
113
113
|
}
|
|
114
114
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_authenticators";
|
|
115
115
|
const body = JSON.stringify(input);
|
|
116
|
-
const stamp = await this.
|
|
116
|
+
const stamp = await this.stamper.stamp(body);
|
|
117
117
|
return {
|
|
118
118
|
body: body,
|
|
119
119
|
stamp: stamp,
|
|
@@ -127,12 +127,12 @@ class TurnkeySDKClientBase {
|
|
|
127
127
|
});
|
|
128
128
|
};
|
|
129
129
|
this.stampGetOauthProviders = async (input) => {
|
|
130
|
-
if (!this.
|
|
130
|
+
if (!this.stamper) {
|
|
131
131
|
return undefined;
|
|
132
132
|
}
|
|
133
133
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_oauth_providers";
|
|
134
134
|
const body = JSON.stringify(input);
|
|
135
|
-
const stamp = await this.
|
|
135
|
+
const stamp = await this.stamper.stamp(body);
|
|
136
136
|
return {
|
|
137
137
|
body: body,
|
|
138
138
|
stamp: stamp,
|
|
@@ -146,12 +146,12 @@ class TurnkeySDKClientBase {
|
|
|
146
146
|
});
|
|
147
147
|
};
|
|
148
148
|
this.stampGetOrganization = async (input) => {
|
|
149
|
-
if (!this.
|
|
149
|
+
if (!this.stamper) {
|
|
150
150
|
return undefined;
|
|
151
151
|
}
|
|
152
152
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_organization";
|
|
153
153
|
const body = JSON.stringify(input);
|
|
154
|
-
const stamp = await this.
|
|
154
|
+
const stamp = await this.stamper.stamp(body);
|
|
155
155
|
return {
|
|
156
156
|
body: body,
|
|
157
157
|
stamp: stamp,
|
|
@@ -165,12 +165,12 @@ class TurnkeySDKClientBase {
|
|
|
165
165
|
});
|
|
166
166
|
};
|
|
167
167
|
this.stampGetOrganizationConfigs = async (input) => {
|
|
168
|
-
if (!this.
|
|
168
|
+
if (!this.stamper) {
|
|
169
169
|
return undefined;
|
|
170
170
|
}
|
|
171
171
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_organization_configs";
|
|
172
172
|
const body = JSON.stringify(input);
|
|
173
|
-
const stamp = await this.
|
|
173
|
+
const stamp = await this.stamper.stamp(body);
|
|
174
174
|
return {
|
|
175
175
|
body: body,
|
|
176
176
|
stamp: stamp,
|
|
@@ -184,12 +184,12 @@ class TurnkeySDKClientBase {
|
|
|
184
184
|
});
|
|
185
185
|
};
|
|
186
186
|
this.stampGetPolicy = async (input) => {
|
|
187
|
-
if (!this.
|
|
187
|
+
if (!this.stamper) {
|
|
188
188
|
return undefined;
|
|
189
189
|
}
|
|
190
190
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_policy";
|
|
191
191
|
const body = JSON.stringify(input);
|
|
192
|
-
const stamp = await this.
|
|
192
|
+
const stamp = await this.stamper.stamp(body);
|
|
193
193
|
return {
|
|
194
194
|
body: body,
|
|
195
195
|
stamp: stamp,
|
|
@@ -203,12 +203,12 @@ class TurnkeySDKClientBase {
|
|
|
203
203
|
});
|
|
204
204
|
};
|
|
205
205
|
this.stampGetPrivateKey = async (input) => {
|
|
206
|
-
if (!this.
|
|
206
|
+
if (!this.stamper) {
|
|
207
207
|
return undefined;
|
|
208
208
|
}
|
|
209
209
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_private_key";
|
|
210
210
|
const body = JSON.stringify(input);
|
|
211
|
-
const stamp = await this.
|
|
211
|
+
const stamp = await this.stamper.stamp(body);
|
|
212
212
|
return {
|
|
213
213
|
body: body,
|
|
214
214
|
stamp: stamp,
|
|
@@ -222,12 +222,12 @@ class TurnkeySDKClientBase {
|
|
|
222
222
|
});
|
|
223
223
|
};
|
|
224
224
|
this.stampGetUser = async (input) => {
|
|
225
|
-
if (!this.
|
|
225
|
+
if (!this.stamper) {
|
|
226
226
|
return undefined;
|
|
227
227
|
}
|
|
228
228
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_user";
|
|
229
229
|
const body = JSON.stringify(input);
|
|
230
|
-
const stamp = await this.
|
|
230
|
+
const stamp = await this.stamper.stamp(body);
|
|
231
231
|
return {
|
|
232
232
|
body: body,
|
|
233
233
|
stamp: stamp,
|
|
@@ -241,12 +241,12 @@ class TurnkeySDKClientBase {
|
|
|
241
241
|
});
|
|
242
242
|
};
|
|
243
243
|
this.stampGetWallet = async (input) => {
|
|
244
|
-
if (!this.
|
|
244
|
+
if (!this.stamper) {
|
|
245
245
|
return undefined;
|
|
246
246
|
}
|
|
247
247
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/get_wallet";
|
|
248
248
|
const body = JSON.stringify(input);
|
|
249
|
-
const stamp = await this.
|
|
249
|
+
const stamp = await this.stamper.stamp(body);
|
|
250
250
|
return {
|
|
251
251
|
body: body,
|
|
252
252
|
stamp: stamp,
|
|
@@ -260,12 +260,12 @@ class TurnkeySDKClientBase {
|
|
|
260
260
|
});
|
|
261
261
|
};
|
|
262
262
|
this.stampGetActivities = async (input) => {
|
|
263
|
-
if (!this.
|
|
263
|
+
if (!this.stamper) {
|
|
264
264
|
return undefined;
|
|
265
265
|
}
|
|
266
266
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_activities";
|
|
267
267
|
const body = JSON.stringify(input);
|
|
268
|
-
const stamp = await this.
|
|
268
|
+
const stamp = await this.stamper.stamp(body);
|
|
269
269
|
return {
|
|
270
270
|
body: body,
|
|
271
271
|
stamp: stamp,
|
|
@@ -279,12 +279,12 @@ class TurnkeySDKClientBase {
|
|
|
279
279
|
});
|
|
280
280
|
};
|
|
281
281
|
this.stampGetPolicies = async (input) => {
|
|
282
|
-
if (!this.
|
|
282
|
+
if (!this.stamper) {
|
|
283
283
|
return undefined;
|
|
284
284
|
}
|
|
285
285
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_policies";
|
|
286
286
|
const body = JSON.stringify(input);
|
|
287
|
-
const stamp = await this.
|
|
287
|
+
const stamp = await this.stamper.stamp(body);
|
|
288
288
|
return {
|
|
289
289
|
body: body,
|
|
290
290
|
stamp: stamp,
|
|
@@ -298,12 +298,12 @@ class TurnkeySDKClientBase {
|
|
|
298
298
|
});
|
|
299
299
|
};
|
|
300
300
|
this.stampListPrivateKeyTags = async (input) => {
|
|
301
|
-
if (!this.
|
|
301
|
+
if (!this.stamper) {
|
|
302
302
|
return undefined;
|
|
303
303
|
}
|
|
304
304
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_private_key_tags";
|
|
305
305
|
const body = JSON.stringify(input);
|
|
306
|
-
const stamp = await this.
|
|
306
|
+
const stamp = await this.stamper.stamp(body);
|
|
307
307
|
return {
|
|
308
308
|
body: body,
|
|
309
309
|
stamp: stamp,
|
|
@@ -317,12 +317,12 @@ class TurnkeySDKClientBase {
|
|
|
317
317
|
});
|
|
318
318
|
};
|
|
319
319
|
this.stampGetPrivateKeys = async (input) => {
|
|
320
|
-
if (!this.
|
|
320
|
+
if (!this.stamper) {
|
|
321
321
|
return undefined;
|
|
322
322
|
}
|
|
323
323
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_private_keys";
|
|
324
324
|
const body = JSON.stringify(input);
|
|
325
|
-
const stamp = await this.
|
|
325
|
+
const stamp = await this.stamper.stamp(body);
|
|
326
326
|
return {
|
|
327
327
|
body: body,
|
|
328
328
|
stamp: stamp,
|
|
@@ -336,12 +336,12 @@ class TurnkeySDKClientBase {
|
|
|
336
336
|
});
|
|
337
337
|
};
|
|
338
338
|
this.stampGetSubOrgIds = async (input) => {
|
|
339
|
-
if (!this.
|
|
339
|
+
if (!this.stamper) {
|
|
340
340
|
return undefined;
|
|
341
341
|
}
|
|
342
342
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_suborgs";
|
|
343
343
|
const body = JSON.stringify(input);
|
|
344
|
-
const stamp = await this.
|
|
344
|
+
const stamp = await this.stamper.stamp(body);
|
|
345
345
|
return {
|
|
346
346
|
body: body,
|
|
347
347
|
stamp: stamp,
|
|
@@ -355,12 +355,12 @@ class TurnkeySDKClientBase {
|
|
|
355
355
|
});
|
|
356
356
|
};
|
|
357
357
|
this.stampListUserTags = async (input) => {
|
|
358
|
-
if (!this.
|
|
358
|
+
if (!this.stamper) {
|
|
359
359
|
return undefined;
|
|
360
360
|
}
|
|
361
361
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_user_tags";
|
|
362
362
|
const body = JSON.stringify(input);
|
|
363
|
-
const stamp = await this.
|
|
363
|
+
const stamp = await this.stamper.stamp(body);
|
|
364
364
|
return {
|
|
365
365
|
body: body,
|
|
366
366
|
stamp: stamp,
|
|
@@ -374,12 +374,12 @@ class TurnkeySDKClientBase {
|
|
|
374
374
|
});
|
|
375
375
|
};
|
|
376
376
|
this.stampGetUsers = async (input) => {
|
|
377
|
-
if (!this.
|
|
377
|
+
if (!this.stamper) {
|
|
378
378
|
return undefined;
|
|
379
379
|
}
|
|
380
380
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_users";
|
|
381
381
|
const body = JSON.stringify(input);
|
|
382
|
-
const stamp = await this.
|
|
382
|
+
const stamp = await this.stamper.stamp(body);
|
|
383
383
|
return {
|
|
384
384
|
body: body,
|
|
385
385
|
stamp: stamp,
|
|
@@ -393,12 +393,12 @@ class TurnkeySDKClientBase {
|
|
|
393
393
|
});
|
|
394
394
|
};
|
|
395
395
|
this.stampGetVerifiedSubOrgIds = async (input) => {
|
|
396
|
-
if (!this.
|
|
396
|
+
if (!this.stamper) {
|
|
397
397
|
return undefined;
|
|
398
398
|
}
|
|
399
399
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_verified_suborgs";
|
|
400
400
|
const body = JSON.stringify(input);
|
|
401
|
-
const stamp = await this.
|
|
401
|
+
const stamp = await this.stamper.stamp(body);
|
|
402
402
|
return {
|
|
403
403
|
body: body,
|
|
404
404
|
stamp: stamp,
|
|
@@ -412,12 +412,12 @@ class TurnkeySDKClientBase {
|
|
|
412
412
|
});
|
|
413
413
|
};
|
|
414
414
|
this.stampGetWalletAccounts = async (input) => {
|
|
415
|
-
if (!this.
|
|
415
|
+
if (!this.stamper) {
|
|
416
416
|
return undefined;
|
|
417
417
|
}
|
|
418
418
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_wallet_accounts";
|
|
419
419
|
const body = JSON.stringify(input);
|
|
420
|
-
const stamp = await this.
|
|
420
|
+
const stamp = await this.stamper.stamp(body);
|
|
421
421
|
return {
|
|
422
422
|
body: body,
|
|
423
423
|
stamp: stamp,
|
|
@@ -431,12 +431,12 @@ class TurnkeySDKClientBase {
|
|
|
431
431
|
});
|
|
432
432
|
};
|
|
433
433
|
this.stampGetWallets = async (input) => {
|
|
434
|
-
if (!this.
|
|
434
|
+
if (!this.stamper) {
|
|
435
435
|
return undefined;
|
|
436
436
|
}
|
|
437
437
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/list_wallets";
|
|
438
438
|
const body = JSON.stringify(input);
|
|
439
|
-
const stamp = await this.
|
|
439
|
+
const stamp = await this.stamper.stamp(body);
|
|
440
440
|
return {
|
|
441
441
|
body: body,
|
|
442
442
|
stamp: stamp,
|
|
@@ -450,12 +450,12 @@ class TurnkeySDKClientBase {
|
|
|
450
450
|
});
|
|
451
451
|
};
|
|
452
452
|
this.stampGetWhoami = async (input) => {
|
|
453
|
-
if (!this.
|
|
453
|
+
if (!this.stamper) {
|
|
454
454
|
return undefined;
|
|
455
455
|
}
|
|
456
456
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/query/whoami";
|
|
457
457
|
const body = JSON.stringify(input);
|
|
458
|
-
const stamp = await this.
|
|
458
|
+
const stamp = await this.stamper.stamp(body);
|
|
459
459
|
return {
|
|
460
460
|
body: body,
|
|
461
461
|
stamp: stamp,
|
|
@@ -475,12 +475,12 @@ class TurnkeySDKClientBase {
|
|
|
475
475
|
});
|
|
476
476
|
};
|
|
477
477
|
this.stampApproveActivity = async (input) => {
|
|
478
|
-
if (!this.
|
|
478
|
+
if (!this.stamper) {
|
|
479
479
|
return undefined;
|
|
480
480
|
}
|
|
481
481
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/approve_activity";
|
|
482
482
|
const body = JSON.stringify(input);
|
|
483
|
-
const stamp = await this.
|
|
483
|
+
const stamp = await this.stamper.stamp(body);
|
|
484
484
|
return {
|
|
485
485
|
body: body,
|
|
486
486
|
stamp: stamp,
|
|
@@ -500,12 +500,12 @@ class TurnkeySDKClientBase {
|
|
|
500
500
|
}, "createApiKeysResult");
|
|
501
501
|
};
|
|
502
502
|
this.stampCreateApiKeys = async (input) => {
|
|
503
|
-
if (!this.
|
|
503
|
+
if (!this.stamper) {
|
|
504
504
|
return undefined;
|
|
505
505
|
}
|
|
506
506
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_api_keys";
|
|
507
507
|
const body = JSON.stringify(input);
|
|
508
|
-
const stamp = await this.
|
|
508
|
+
const stamp = await this.stamper.stamp(body);
|
|
509
509
|
return {
|
|
510
510
|
body: body,
|
|
511
511
|
stamp: stamp,
|
|
@@ -525,12 +525,12 @@ class TurnkeySDKClientBase {
|
|
|
525
525
|
}, "createApiOnlyUsersResult");
|
|
526
526
|
};
|
|
527
527
|
this.stampCreateApiOnlyUsers = async (input) => {
|
|
528
|
-
if (!this.
|
|
528
|
+
if (!this.stamper) {
|
|
529
529
|
return undefined;
|
|
530
530
|
}
|
|
531
531
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_api_only_users";
|
|
532
532
|
const body = JSON.stringify(input);
|
|
533
|
-
const stamp = await this.
|
|
533
|
+
const stamp = await this.stamper.stamp(body);
|
|
534
534
|
return {
|
|
535
535
|
body: body,
|
|
536
536
|
stamp: stamp,
|
|
@@ -550,12 +550,12 @@ class TurnkeySDKClientBase {
|
|
|
550
550
|
}, "createAuthenticatorsResult");
|
|
551
551
|
};
|
|
552
552
|
this.stampCreateAuthenticators = async (input) => {
|
|
553
|
-
if (!this.
|
|
553
|
+
if (!this.stamper) {
|
|
554
554
|
return undefined;
|
|
555
555
|
}
|
|
556
556
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_authenticators";
|
|
557
557
|
const body = JSON.stringify(input);
|
|
558
|
-
const stamp = await this.
|
|
558
|
+
const stamp = await this.stamper.stamp(body);
|
|
559
559
|
return {
|
|
560
560
|
body: body,
|
|
561
561
|
stamp: stamp,
|
|
@@ -575,12 +575,12 @@ class TurnkeySDKClientBase {
|
|
|
575
575
|
}, "createInvitationsResult");
|
|
576
576
|
};
|
|
577
577
|
this.stampCreateInvitations = async (input) => {
|
|
578
|
-
if (!this.
|
|
578
|
+
if (!this.stamper) {
|
|
579
579
|
return undefined;
|
|
580
580
|
}
|
|
581
581
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_invitations";
|
|
582
582
|
const body = JSON.stringify(input);
|
|
583
|
-
const stamp = await this.
|
|
583
|
+
const stamp = await this.stamper.stamp(body);
|
|
584
584
|
return {
|
|
585
585
|
body: body,
|
|
586
586
|
stamp: stamp,
|
|
@@ -600,12 +600,12 @@ class TurnkeySDKClientBase {
|
|
|
600
600
|
}, "createOauthProvidersResult");
|
|
601
601
|
};
|
|
602
602
|
this.stampCreateOauthProviders = async (input) => {
|
|
603
|
-
if (!this.
|
|
603
|
+
if (!this.stamper) {
|
|
604
604
|
return undefined;
|
|
605
605
|
}
|
|
606
606
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_oauth_providers";
|
|
607
607
|
const body = JSON.stringify(input);
|
|
608
|
-
const stamp = await this.
|
|
608
|
+
const stamp = await this.stamper.stamp(body);
|
|
609
609
|
return {
|
|
610
610
|
body: body,
|
|
611
611
|
stamp: stamp,
|
|
@@ -625,12 +625,12 @@ class TurnkeySDKClientBase {
|
|
|
625
625
|
}, "createPoliciesResult");
|
|
626
626
|
};
|
|
627
627
|
this.stampCreatePolicies = async (input) => {
|
|
628
|
-
if (!this.
|
|
628
|
+
if (!this.stamper) {
|
|
629
629
|
return undefined;
|
|
630
630
|
}
|
|
631
631
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_policies";
|
|
632
632
|
const body = JSON.stringify(input);
|
|
633
|
-
const stamp = await this.
|
|
633
|
+
const stamp = await this.stamper.stamp(body);
|
|
634
634
|
return {
|
|
635
635
|
body: body,
|
|
636
636
|
stamp: stamp,
|
|
@@ -650,12 +650,12 @@ class TurnkeySDKClientBase {
|
|
|
650
650
|
}, "createPolicyResult");
|
|
651
651
|
};
|
|
652
652
|
this.stampCreatePolicy = async (input) => {
|
|
653
|
-
if (!this.
|
|
653
|
+
if (!this.stamper) {
|
|
654
654
|
return undefined;
|
|
655
655
|
}
|
|
656
656
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_policy";
|
|
657
657
|
const body = JSON.stringify(input);
|
|
658
|
-
const stamp = await this.
|
|
658
|
+
const stamp = await this.stamper.stamp(body);
|
|
659
659
|
return {
|
|
660
660
|
body: body,
|
|
661
661
|
stamp: stamp,
|
|
@@ -675,12 +675,12 @@ class TurnkeySDKClientBase {
|
|
|
675
675
|
}, "createPrivateKeyTagResult");
|
|
676
676
|
};
|
|
677
677
|
this.stampCreatePrivateKeyTag = async (input) => {
|
|
678
|
-
if (!this.
|
|
678
|
+
if (!this.stamper) {
|
|
679
679
|
return undefined;
|
|
680
680
|
}
|
|
681
681
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_private_key_tag";
|
|
682
682
|
const body = JSON.stringify(input);
|
|
683
|
-
const stamp = await this.
|
|
683
|
+
const stamp = await this.stamper.stamp(body);
|
|
684
684
|
return {
|
|
685
685
|
body: body,
|
|
686
686
|
stamp: stamp,
|
|
@@ -700,12 +700,12 @@ class TurnkeySDKClientBase {
|
|
|
700
700
|
}, "createPrivateKeysResultV2");
|
|
701
701
|
};
|
|
702
702
|
this.stampCreatePrivateKeys = async (input) => {
|
|
703
|
-
if (!this.
|
|
703
|
+
if (!this.stamper) {
|
|
704
704
|
return undefined;
|
|
705
705
|
}
|
|
706
706
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_private_keys";
|
|
707
707
|
const body = JSON.stringify(input);
|
|
708
|
-
const stamp = await this.
|
|
708
|
+
const stamp = await this.stamper.stamp(body);
|
|
709
709
|
return {
|
|
710
710
|
body: body,
|
|
711
711
|
stamp: stamp,
|
|
@@ -725,12 +725,12 @@ class TurnkeySDKClientBase {
|
|
|
725
725
|
}, "createReadOnlySessionResult");
|
|
726
726
|
};
|
|
727
727
|
this.stampCreateReadOnlySession = async (input) => {
|
|
728
|
-
if (!this.
|
|
728
|
+
if (!this.stamper) {
|
|
729
729
|
return undefined;
|
|
730
730
|
}
|
|
731
731
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_read_only_session";
|
|
732
732
|
const body = JSON.stringify(input);
|
|
733
|
-
const stamp = await this.
|
|
733
|
+
const stamp = await this.stamper.stamp(body);
|
|
734
734
|
return {
|
|
735
735
|
body: body,
|
|
736
736
|
stamp: stamp,
|
|
@@ -750,12 +750,12 @@ class TurnkeySDKClientBase {
|
|
|
750
750
|
}, "createReadWriteSessionResultV2");
|
|
751
751
|
};
|
|
752
752
|
this.stampCreateReadWriteSession = async (input) => {
|
|
753
|
-
if (!this.
|
|
753
|
+
if (!this.stamper) {
|
|
754
754
|
return undefined;
|
|
755
755
|
}
|
|
756
756
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_read_write_session";
|
|
757
757
|
const body = JSON.stringify(input);
|
|
758
|
-
const stamp = await this.
|
|
758
|
+
const stamp = await this.stamper.stamp(body);
|
|
759
759
|
return {
|
|
760
760
|
body: body,
|
|
761
761
|
stamp: stamp,
|
|
@@ -775,12 +775,12 @@ class TurnkeySDKClientBase {
|
|
|
775
775
|
}, "createSubOrganizationResultV7");
|
|
776
776
|
};
|
|
777
777
|
this.stampCreateSubOrganization = async (input) => {
|
|
778
|
-
if (!this.
|
|
778
|
+
if (!this.stamper) {
|
|
779
779
|
return undefined;
|
|
780
780
|
}
|
|
781
781
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_sub_organization";
|
|
782
782
|
const body = JSON.stringify(input);
|
|
783
|
-
const stamp = await this.
|
|
783
|
+
const stamp = await this.stamper.stamp(body);
|
|
784
784
|
return {
|
|
785
785
|
body: body,
|
|
786
786
|
stamp: stamp,
|
|
@@ -800,12 +800,12 @@ class TurnkeySDKClientBase {
|
|
|
800
800
|
}, "createUserTagResult");
|
|
801
801
|
};
|
|
802
802
|
this.stampCreateUserTag = async (input) => {
|
|
803
|
-
if (!this.
|
|
803
|
+
if (!this.stamper) {
|
|
804
804
|
return undefined;
|
|
805
805
|
}
|
|
806
806
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_user_tag";
|
|
807
807
|
const body = JSON.stringify(input);
|
|
808
|
-
const stamp = await this.
|
|
808
|
+
const stamp = await this.stamper.stamp(body);
|
|
809
809
|
return {
|
|
810
810
|
body: body,
|
|
811
811
|
stamp: stamp,
|
|
@@ -825,12 +825,12 @@ class TurnkeySDKClientBase {
|
|
|
825
825
|
}, "createUsersResult");
|
|
826
826
|
};
|
|
827
827
|
this.stampCreateUsers = async (input) => {
|
|
828
|
-
if (!this.
|
|
828
|
+
if (!this.stamper) {
|
|
829
829
|
return undefined;
|
|
830
830
|
}
|
|
831
831
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_users";
|
|
832
832
|
const body = JSON.stringify(input);
|
|
833
|
-
const stamp = await this.
|
|
833
|
+
const stamp = await this.stamper.stamp(body);
|
|
834
834
|
return {
|
|
835
835
|
body: body,
|
|
836
836
|
stamp: stamp,
|
|
@@ -850,12 +850,12 @@ class TurnkeySDKClientBase {
|
|
|
850
850
|
}, "createWalletResult");
|
|
851
851
|
};
|
|
852
852
|
this.stampCreateWallet = async (input) => {
|
|
853
|
-
if (!this.
|
|
853
|
+
if (!this.stamper) {
|
|
854
854
|
return undefined;
|
|
855
855
|
}
|
|
856
856
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_wallet";
|
|
857
857
|
const body = JSON.stringify(input);
|
|
858
|
-
const stamp = await this.
|
|
858
|
+
const stamp = await this.stamper.stamp(body);
|
|
859
859
|
return {
|
|
860
860
|
body: body,
|
|
861
861
|
stamp: stamp,
|
|
@@ -875,12 +875,12 @@ class TurnkeySDKClientBase {
|
|
|
875
875
|
}, "createWalletAccountsResult");
|
|
876
876
|
};
|
|
877
877
|
this.stampCreateWalletAccounts = async (input) => {
|
|
878
|
-
if (!this.
|
|
878
|
+
if (!this.stamper) {
|
|
879
879
|
return undefined;
|
|
880
880
|
}
|
|
881
881
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/create_wallet_accounts";
|
|
882
882
|
const body = JSON.stringify(input);
|
|
883
|
-
const stamp = await this.
|
|
883
|
+
const stamp = await this.stamper.stamp(body);
|
|
884
884
|
return {
|
|
885
885
|
body: body,
|
|
886
886
|
stamp: stamp,
|
|
@@ -900,12 +900,12 @@ class TurnkeySDKClientBase {
|
|
|
900
900
|
}, "deleteApiKeysResult");
|
|
901
901
|
};
|
|
902
902
|
this.stampDeleteApiKeys = async (input) => {
|
|
903
|
-
if (!this.
|
|
903
|
+
if (!this.stamper) {
|
|
904
904
|
return undefined;
|
|
905
905
|
}
|
|
906
906
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/delete_api_keys";
|
|
907
907
|
const body = JSON.stringify(input);
|
|
908
|
-
const stamp = await this.
|
|
908
|
+
const stamp = await this.stamper.stamp(body);
|
|
909
909
|
return {
|
|
910
910
|
body: body,
|
|
911
911
|
stamp: stamp,
|
|
@@ -925,12 +925,12 @@ class TurnkeySDKClientBase {
|
|
|
925
925
|
}, "deleteAuthenticatorsResult");
|
|
926
926
|
};
|
|
927
927
|
this.stampDeleteAuthenticators = async (input) => {
|
|
928
|
-
if (!this.
|
|
928
|
+
if (!this.stamper) {
|
|
929
929
|
return undefined;
|
|
930
930
|
}
|
|
931
931
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/delete_authenticators";
|
|
932
932
|
const body = JSON.stringify(input);
|
|
933
|
-
const stamp = await this.
|
|
933
|
+
const stamp = await this.stamper.stamp(body);
|
|
934
934
|
return {
|
|
935
935
|
body: body,
|
|
936
936
|
stamp: stamp,
|
|
@@ -950,12 +950,12 @@ class TurnkeySDKClientBase {
|
|
|
950
950
|
}, "deleteInvitationResult");
|
|
951
951
|
};
|
|
952
952
|
this.stampDeleteInvitation = async (input) => {
|
|
953
|
-
if (!this.
|
|
953
|
+
if (!this.stamper) {
|
|
954
954
|
return undefined;
|
|
955
955
|
}
|
|
956
956
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/delete_invitation";
|
|
957
957
|
const body = JSON.stringify(input);
|
|
958
|
-
const stamp = await this.
|
|
958
|
+
const stamp = await this.stamper.stamp(body);
|
|
959
959
|
return {
|
|
960
960
|
body: body,
|
|
961
961
|
stamp: stamp,
|
|
@@ -975,12 +975,12 @@ class TurnkeySDKClientBase {
|
|
|
975
975
|
}, "deleteOauthProvidersResult");
|
|
976
976
|
};
|
|
977
977
|
this.stampDeleteOauthProviders = async (input) => {
|
|
978
|
-
if (!this.
|
|
978
|
+
if (!this.stamper) {
|
|
979
979
|
return undefined;
|
|
980
980
|
}
|
|
981
981
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/delete_oauth_providers";
|
|
982
982
|
const body = JSON.stringify(input);
|
|
983
|
-
const stamp = await this.
|
|
983
|
+
const stamp = await this.stamper.stamp(body);
|
|
984
984
|
return {
|
|
985
985
|
body: body,
|
|
986
986
|
stamp: stamp,
|
|
@@ -1000,12 +1000,12 @@ class TurnkeySDKClientBase {
|
|
|
1000
1000
|
}, "deletePolicyResult");
|
|
1001
1001
|
};
|
|
1002
1002
|
this.stampDeletePolicy = async (input) => {
|
|
1003
|
-
if (!this.
|
|
1003
|
+
if (!this.stamper) {
|
|
1004
1004
|
return undefined;
|
|
1005
1005
|
}
|
|
1006
1006
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/delete_policy";
|
|
1007
1007
|
const body = JSON.stringify(input);
|
|
1008
|
-
const stamp = await this.
|
|
1008
|
+
const stamp = await this.stamper.stamp(body);
|
|
1009
1009
|
return {
|
|
1010
1010
|
body: body,
|
|
1011
1011
|
stamp: stamp,
|
|
@@ -1025,12 +1025,12 @@ class TurnkeySDKClientBase {
|
|
|
1025
1025
|
}, "deletePrivateKeyTagsResult");
|
|
1026
1026
|
};
|
|
1027
1027
|
this.stampDeletePrivateKeyTags = async (input) => {
|
|
1028
|
-
if (!this.
|
|
1028
|
+
if (!this.stamper) {
|
|
1029
1029
|
return undefined;
|
|
1030
1030
|
}
|
|
1031
1031
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/delete_private_key_tags";
|
|
1032
1032
|
const body = JSON.stringify(input);
|
|
1033
|
-
const stamp = await this.
|
|
1033
|
+
const stamp = await this.stamper.stamp(body);
|
|
1034
1034
|
return {
|
|
1035
1035
|
body: body,
|
|
1036
1036
|
stamp: stamp,
|
|
@@ -1050,12 +1050,12 @@ class TurnkeySDKClientBase {
|
|
|
1050
1050
|
}, "deletePrivateKeysResult");
|
|
1051
1051
|
};
|
|
1052
1052
|
this.stampDeletePrivateKeys = async (input) => {
|
|
1053
|
-
if (!this.
|
|
1053
|
+
if (!this.stamper) {
|
|
1054
1054
|
return undefined;
|
|
1055
1055
|
}
|
|
1056
1056
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/delete_private_keys";
|
|
1057
1057
|
const body = JSON.stringify(input);
|
|
1058
|
-
const stamp = await this.
|
|
1058
|
+
const stamp = await this.stamper.stamp(body);
|
|
1059
1059
|
return {
|
|
1060
1060
|
body: body,
|
|
1061
1061
|
stamp: stamp,
|
|
@@ -1075,12 +1075,12 @@ class TurnkeySDKClientBase {
|
|
|
1075
1075
|
}, "deleteSubOrganizationResult");
|
|
1076
1076
|
};
|
|
1077
1077
|
this.stampDeleteSubOrganization = async (input) => {
|
|
1078
|
-
if (!this.
|
|
1078
|
+
if (!this.stamper) {
|
|
1079
1079
|
return undefined;
|
|
1080
1080
|
}
|
|
1081
1081
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/delete_sub_organization";
|
|
1082
1082
|
const body = JSON.stringify(input);
|
|
1083
|
-
const stamp = await this.
|
|
1083
|
+
const stamp = await this.stamper.stamp(body);
|
|
1084
1084
|
return {
|
|
1085
1085
|
body: body,
|
|
1086
1086
|
stamp: stamp,
|
|
@@ -1100,12 +1100,12 @@ class TurnkeySDKClientBase {
|
|
|
1100
1100
|
}, "deleteUserTagsResult");
|
|
1101
1101
|
};
|
|
1102
1102
|
this.stampDeleteUserTags = async (input) => {
|
|
1103
|
-
if (!this.
|
|
1103
|
+
if (!this.stamper) {
|
|
1104
1104
|
return undefined;
|
|
1105
1105
|
}
|
|
1106
1106
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/delete_user_tags";
|
|
1107
1107
|
const body = JSON.stringify(input);
|
|
1108
|
-
const stamp = await this.
|
|
1108
|
+
const stamp = await this.stamper.stamp(body);
|
|
1109
1109
|
return {
|
|
1110
1110
|
body: body,
|
|
1111
1111
|
stamp: stamp,
|
|
@@ -1125,12 +1125,12 @@ class TurnkeySDKClientBase {
|
|
|
1125
1125
|
}, "deleteUsersResult");
|
|
1126
1126
|
};
|
|
1127
1127
|
this.stampDeleteUsers = async (input) => {
|
|
1128
|
-
if (!this.
|
|
1128
|
+
if (!this.stamper) {
|
|
1129
1129
|
return undefined;
|
|
1130
1130
|
}
|
|
1131
1131
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/delete_users";
|
|
1132
1132
|
const body = JSON.stringify(input);
|
|
1133
|
-
const stamp = await this.
|
|
1133
|
+
const stamp = await this.stamper.stamp(body);
|
|
1134
1134
|
return {
|
|
1135
1135
|
body: body,
|
|
1136
1136
|
stamp: stamp,
|
|
@@ -1150,12 +1150,12 @@ class TurnkeySDKClientBase {
|
|
|
1150
1150
|
}, "deleteWalletsResult");
|
|
1151
1151
|
};
|
|
1152
1152
|
this.stampDeleteWallets = async (input) => {
|
|
1153
|
-
if (!this.
|
|
1153
|
+
if (!this.stamper) {
|
|
1154
1154
|
return undefined;
|
|
1155
1155
|
}
|
|
1156
1156
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/delete_wallets";
|
|
1157
1157
|
const body = JSON.stringify(input);
|
|
1158
|
-
const stamp = await this.
|
|
1158
|
+
const stamp = await this.stamper.stamp(body);
|
|
1159
1159
|
return {
|
|
1160
1160
|
body: body,
|
|
1161
1161
|
stamp: stamp,
|
|
@@ -1175,12 +1175,12 @@ class TurnkeySDKClientBase {
|
|
|
1175
1175
|
}, "emailAuthResult");
|
|
1176
1176
|
};
|
|
1177
1177
|
this.stampEmailAuth = async (input) => {
|
|
1178
|
-
if (!this.
|
|
1178
|
+
if (!this.stamper) {
|
|
1179
1179
|
return undefined;
|
|
1180
1180
|
}
|
|
1181
1181
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/email_auth";
|
|
1182
1182
|
const body = JSON.stringify(input);
|
|
1183
|
-
const stamp = await this.
|
|
1183
|
+
const stamp = await this.stamper.stamp(body);
|
|
1184
1184
|
return {
|
|
1185
1185
|
body: body,
|
|
1186
1186
|
stamp: stamp,
|
|
@@ -1200,12 +1200,12 @@ class TurnkeySDKClientBase {
|
|
|
1200
1200
|
}, "exportPrivateKeyResult");
|
|
1201
1201
|
};
|
|
1202
1202
|
this.stampExportPrivateKey = async (input) => {
|
|
1203
|
-
if (!this.
|
|
1203
|
+
if (!this.stamper) {
|
|
1204
1204
|
return undefined;
|
|
1205
1205
|
}
|
|
1206
1206
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/export_private_key";
|
|
1207
1207
|
const body = JSON.stringify(input);
|
|
1208
|
-
const stamp = await this.
|
|
1208
|
+
const stamp = await this.stamper.stamp(body);
|
|
1209
1209
|
return {
|
|
1210
1210
|
body: body,
|
|
1211
1211
|
stamp: stamp,
|
|
@@ -1225,12 +1225,12 @@ class TurnkeySDKClientBase {
|
|
|
1225
1225
|
}, "exportWalletResult");
|
|
1226
1226
|
};
|
|
1227
1227
|
this.stampExportWallet = async (input) => {
|
|
1228
|
-
if (!this.
|
|
1228
|
+
if (!this.stamper) {
|
|
1229
1229
|
return undefined;
|
|
1230
1230
|
}
|
|
1231
1231
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/export_wallet";
|
|
1232
1232
|
const body = JSON.stringify(input);
|
|
1233
|
-
const stamp = await this.
|
|
1233
|
+
const stamp = await this.stamper.stamp(body);
|
|
1234
1234
|
return {
|
|
1235
1235
|
body: body,
|
|
1236
1236
|
stamp: stamp,
|
|
@@ -1250,12 +1250,12 @@ class TurnkeySDKClientBase {
|
|
|
1250
1250
|
}, "exportWalletAccountResult");
|
|
1251
1251
|
};
|
|
1252
1252
|
this.stampExportWalletAccount = async (input) => {
|
|
1253
|
-
if (!this.
|
|
1253
|
+
if (!this.stamper) {
|
|
1254
1254
|
return undefined;
|
|
1255
1255
|
}
|
|
1256
1256
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/export_wallet_account";
|
|
1257
1257
|
const body = JSON.stringify(input);
|
|
1258
|
-
const stamp = await this.
|
|
1258
|
+
const stamp = await this.stamper.stamp(body);
|
|
1259
1259
|
return {
|
|
1260
1260
|
body: body,
|
|
1261
1261
|
stamp: stamp,
|
|
@@ -1275,12 +1275,12 @@ class TurnkeySDKClientBase {
|
|
|
1275
1275
|
}, "importPrivateKeyResult");
|
|
1276
1276
|
};
|
|
1277
1277
|
this.stampImportPrivateKey = async (input) => {
|
|
1278
|
-
if (!this.
|
|
1278
|
+
if (!this.stamper) {
|
|
1279
1279
|
return undefined;
|
|
1280
1280
|
}
|
|
1281
1281
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/import_private_key";
|
|
1282
1282
|
const body = JSON.stringify(input);
|
|
1283
|
-
const stamp = await this.
|
|
1283
|
+
const stamp = await this.stamper.stamp(body);
|
|
1284
1284
|
return {
|
|
1285
1285
|
body: body,
|
|
1286
1286
|
stamp: stamp,
|
|
@@ -1300,12 +1300,12 @@ class TurnkeySDKClientBase {
|
|
|
1300
1300
|
}, "importWalletResult");
|
|
1301
1301
|
};
|
|
1302
1302
|
this.stampImportWallet = async (input) => {
|
|
1303
|
-
if (!this.
|
|
1303
|
+
if (!this.stamper) {
|
|
1304
1304
|
return undefined;
|
|
1305
1305
|
}
|
|
1306
1306
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/import_wallet";
|
|
1307
1307
|
const body = JSON.stringify(input);
|
|
1308
|
-
const stamp = await this.
|
|
1308
|
+
const stamp = await this.stamper.stamp(body);
|
|
1309
1309
|
return {
|
|
1310
1310
|
body: body,
|
|
1311
1311
|
stamp: stamp,
|
|
@@ -1325,12 +1325,12 @@ class TurnkeySDKClientBase {
|
|
|
1325
1325
|
}, "initImportPrivateKeyResult");
|
|
1326
1326
|
};
|
|
1327
1327
|
this.stampInitImportPrivateKey = async (input) => {
|
|
1328
|
-
if (!this.
|
|
1328
|
+
if (!this.stamper) {
|
|
1329
1329
|
return undefined;
|
|
1330
1330
|
}
|
|
1331
1331
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/init_import_private_key";
|
|
1332
1332
|
const body = JSON.stringify(input);
|
|
1333
|
-
const stamp = await this.
|
|
1333
|
+
const stamp = await this.stamper.stamp(body);
|
|
1334
1334
|
return {
|
|
1335
1335
|
body: body,
|
|
1336
1336
|
stamp: stamp,
|
|
@@ -1350,12 +1350,12 @@ class TurnkeySDKClientBase {
|
|
|
1350
1350
|
}, "initImportWalletResult");
|
|
1351
1351
|
};
|
|
1352
1352
|
this.stampInitImportWallet = async (input) => {
|
|
1353
|
-
if (!this.
|
|
1353
|
+
if (!this.stamper) {
|
|
1354
1354
|
return undefined;
|
|
1355
1355
|
}
|
|
1356
1356
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/init_import_wallet";
|
|
1357
1357
|
const body = JSON.stringify(input);
|
|
1358
|
-
const stamp = await this.
|
|
1358
|
+
const stamp = await this.stamper.stamp(body);
|
|
1359
1359
|
return {
|
|
1360
1360
|
body: body,
|
|
1361
1361
|
stamp: stamp,
|
|
@@ -1375,12 +1375,12 @@ class TurnkeySDKClientBase {
|
|
|
1375
1375
|
}, "initOtpAuthResult");
|
|
1376
1376
|
};
|
|
1377
1377
|
this.stampInitOtpAuth = async (input) => {
|
|
1378
|
-
if (!this.
|
|
1378
|
+
if (!this.stamper) {
|
|
1379
1379
|
return undefined;
|
|
1380
1380
|
}
|
|
1381
1381
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/init_otp_auth";
|
|
1382
1382
|
const body = JSON.stringify(input);
|
|
1383
|
-
const stamp = await this.
|
|
1383
|
+
const stamp = await this.stamper.stamp(body);
|
|
1384
1384
|
return {
|
|
1385
1385
|
body: body,
|
|
1386
1386
|
stamp: stamp,
|
|
@@ -1400,12 +1400,12 @@ class TurnkeySDKClientBase {
|
|
|
1400
1400
|
}, "initUserEmailRecoveryResult");
|
|
1401
1401
|
};
|
|
1402
1402
|
this.stampInitUserEmailRecovery = async (input) => {
|
|
1403
|
-
if (!this.
|
|
1403
|
+
if (!this.stamper) {
|
|
1404
1404
|
return undefined;
|
|
1405
1405
|
}
|
|
1406
1406
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/init_user_email_recovery";
|
|
1407
1407
|
const body = JSON.stringify(input);
|
|
1408
|
-
const stamp = await this.
|
|
1408
|
+
const stamp = await this.stamper.stamp(body);
|
|
1409
1409
|
return {
|
|
1410
1410
|
body: body,
|
|
1411
1411
|
stamp: stamp,
|
|
@@ -1425,12 +1425,12 @@ class TurnkeySDKClientBase {
|
|
|
1425
1425
|
}, "oauthResult");
|
|
1426
1426
|
};
|
|
1427
1427
|
this.stampOauth = async (input) => {
|
|
1428
|
-
if (!this.
|
|
1428
|
+
if (!this.stamper) {
|
|
1429
1429
|
return undefined;
|
|
1430
1430
|
}
|
|
1431
1431
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/oauth";
|
|
1432
1432
|
const body = JSON.stringify(input);
|
|
1433
|
-
const stamp = await this.
|
|
1433
|
+
const stamp = await this.stamper.stamp(body);
|
|
1434
1434
|
return {
|
|
1435
1435
|
body: body,
|
|
1436
1436
|
stamp: stamp,
|
|
@@ -1450,12 +1450,12 @@ class TurnkeySDKClientBase {
|
|
|
1450
1450
|
}, "otpAuthResult");
|
|
1451
1451
|
};
|
|
1452
1452
|
this.stampOtpAuth = async (input) => {
|
|
1453
|
-
if (!this.
|
|
1453
|
+
if (!this.stamper) {
|
|
1454
1454
|
return undefined;
|
|
1455
1455
|
}
|
|
1456
1456
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/otp_auth";
|
|
1457
1457
|
const body = JSON.stringify(input);
|
|
1458
|
-
const stamp = await this.
|
|
1458
|
+
const stamp = await this.stamper.stamp(body);
|
|
1459
1459
|
return {
|
|
1460
1460
|
body: body,
|
|
1461
1461
|
stamp: stamp,
|
|
@@ -1475,12 +1475,12 @@ class TurnkeySDKClientBase {
|
|
|
1475
1475
|
}, "recoverUserResult");
|
|
1476
1476
|
};
|
|
1477
1477
|
this.stampRecoverUser = async (input) => {
|
|
1478
|
-
if (!this.
|
|
1478
|
+
if (!this.stamper) {
|
|
1479
1479
|
return undefined;
|
|
1480
1480
|
}
|
|
1481
1481
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/recover_user";
|
|
1482
1482
|
const body = JSON.stringify(input);
|
|
1483
|
-
const stamp = await this.
|
|
1483
|
+
const stamp = await this.stamper.stamp(body);
|
|
1484
1484
|
return {
|
|
1485
1485
|
body: body,
|
|
1486
1486
|
stamp: stamp,
|
|
@@ -1500,12 +1500,12 @@ class TurnkeySDKClientBase {
|
|
|
1500
1500
|
});
|
|
1501
1501
|
};
|
|
1502
1502
|
this.stampRejectActivity = async (input) => {
|
|
1503
|
-
if (!this.
|
|
1503
|
+
if (!this.stamper) {
|
|
1504
1504
|
return undefined;
|
|
1505
1505
|
}
|
|
1506
1506
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/reject_activity";
|
|
1507
1507
|
const body = JSON.stringify(input);
|
|
1508
|
-
const stamp = await this.
|
|
1508
|
+
const stamp = await this.stamper.stamp(body);
|
|
1509
1509
|
return {
|
|
1510
1510
|
body: body,
|
|
1511
1511
|
stamp: stamp,
|
|
@@ -1525,12 +1525,12 @@ class TurnkeySDKClientBase {
|
|
|
1525
1525
|
}, "removeOrganizationFeatureResult");
|
|
1526
1526
|
};
|
|
1527
1527
|
this.stampRemoveOrganizationFeature = async (input) => {
|
|
1528
|
-
if (!this.
|
|
1528
|
+
if (!this.stamper) {
|
|
1529
1529
|
return undefined;
|
|
1530
1530
|
}
|
|
1531
1531
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/remove_organization_feature";
|
|
1532
1532
|
const body = JSON.stringify(input);
|
|
1533
|
-
const stamp = await this.
|
|
1533
|
+
const stamp = await this.stamper.stamp(body);
|
|
1534
1534
|
return {
|
|
1535
1535
|
body: body,
|
|
1536
1536
|
stamp: stamp,
|
|
@@ -1550,12 +1550,12 @@ class TurnkeySDKClientBase {
|
|
|
1550
1550
|
}, "setOrganizationFeatureResult");
|
|
1551
1551
|
};
|
|
1552
1552
|
this.stampSetOrganizationFeature = async (input) => {
|
|
1553
|
-
if (!this.
|
|
1553
|
+
if (!this.stamper) {
|
|
1554
1554
|
return undefined;
|
|
1555
1555
|
}
|
|
1556
1556
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/set_organization_feature";
|
|
1557
1557
|
const body = JSON.stringify(input);
|
|
1558
|
-
const stamp = await this.
|
|
1558
|
+
const stamp = await this.stamper.stamp(body);
|
|
1559
1559
|
return {
|
|
1560
1560
|
body: body,
|
|
1561
1561
|
stamp: stamp,
|
|
@@ -1575,12 +1575,12 @@ class TurnkeySDKClientBase {
|
|
|
1575
1575
|
}, "signRawPayloadResult");
|
|
1576
1576
|
};
|
|
1577
1577
|
this.stampSignRawPayload = async (input) => {
|
|
1578
|
-
if (!this.
|
|
1578
|
+
if (!this.stamper) {
|
|
1579
1579
|
return undefined;
|
|
1580
1580
|
}
|
|
1581
1581
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/sign_raw_payload";
|
|
1582
1582
|
const body = JSON.stringify(input);
|
|
1583
|
-
const stamp = await this.
|
|
1583
|
+
const stamp = await this.stamper.stamp(body);
|
|
1584
1584
|
return {
|
|
1585
1585
|
body: body,
|
|
1586
1586
|
stamp: stamp,
|
|
@@ -1600,12 +1600,12 @@ class TurnkeySDKClientBase {
|
|
|
1600
1600
|
}, "signRawPayloadsResult");
|
|
1601
1601
|
};
|
|
1602
1602
|
this.stampSignRawPayloads = async (input) => {
|
|
1603
|
-
if (!this.
|
|
1603
|
+
if (!this.stamper) {
|
|
1604
1604
|
return undefined;
|
|
1605
1605
|
}
|
|
1606
1606
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/sign_raw_payloads";
|
|
1607
1607
|
const body = JSON.stringify(input);
|
|
1608
|
-
const stamp = await this.
|
|
1608
|
+
const stamp = await this.stamper.stamp(body);
|
|
1609
1609
|
return {
|
|
1610
1610
|
body: body,
|
|
1611
1611
|
stamp: stamp,
|
|
@@ -1625,12 +1625,12 @@ class TurnkeySDKClientBase {
|
|
|
1625
1625
|
}, "signTransactionResult");
|
|
1626
1626
|
};
|
|
1627
1627
|
this.stampSignTransaction = async (input) => {
|
|
1628
|
-
if (!this.
|
|
1628
|
+
if (!this.stamper) {
|
|
1629
1629
|
return undefined;
|
|
1630
1630
|
}
|
|
1631
1631
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/sign_transaction";
|
|
1632
1632
|
const body = JSON.stringify(input);
|
|
1633
|
-
const stamp = await this.
|
|
1633
|
+
const stamp = await this.stamper.stamp(body);
|
|
1634
1634
|
return {
|
|
1635
1635
|
body: body,
|
|
1636
1636
|
stamp: stamp,
|
|
@@ -1650,12 +1650,12 @@ class TurnkeySDKClientBase {
|
|
|
1650
1650
|
}, "updatePolicyResult");
|
|
1651
1651
|
};
|
|
1652
1652
|
this.stampUpdatePolicy = async (input) => {
|
|
1653
|
-
if (!this.
|
|
1653
|
+
if (!this.stamper) {
|
|
1654
1654
|
return undefined;
|
|
1655
1655
|
}
|
|
1656
1656
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/update_policy";
|
|
1657
1657
|
const body = JSON.stringify(input);
|
|
1658
|
-
const stamp = await this.
|
|
1658
|
+
const stamp = await this.stamper.stamp(body);
|
|
1659
1659
|
return {
|
|
1660
1660
|
body: body,
|
|
1661
1661
|
stamp: stamp,
|
|
@@ -1675,12 +1675,12 @@ class TurnkeySDKClientBase {
|
|
|
1675
1675
|
}, "updatePrivateKeyTagResult");
|
|
1676
1676
|
};
|
|
1677
1677
|
this.stampUpdatePrivateKeyTag = async (input) => {
|
|
1678
|
-
if (!this.
|
|
1678
|
+
if (!this.stamper) {
|
|
1679
1679
|
return undefined;
|
|
1680
1680
|
}
|
|
1681
1681
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/update_private_key_tag";
|
|
1682
1682
|
const body = JSON.stringify(input);
|
|
1683
|
-
const stamp = await this.
|
|
1683
|
+
const stamp = await this.stamper.stamp(body);
|
|
1684
1684
|
return {
|
|
1685
1685
|
body: body,
|
|
1686
1686
|
stamp: stamp,
|
|
@@ -1700,12 +1700,12 @@ class TurnkeySDKClientBase {
|
|
|
1700
1700
|
}, "updateRootQuorumResult");
|
|
1701
1701
|
};
|
|
1702
1702
|
this.stampUpdateRootQuorum = async (input) => {
|
|
1703
|
-
if (!this.
|
|
1703
|
+
if (!this.stamper) {
|
|
1704
1704
|
return undefined;
|
|
1705
1705
|
}
|
|
1706
1706
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/update_root_quorum";
|
|
1707
1707
|
const body = JSON.stringify(input);
|
|
1708
|
-
const stamp = await this.
|
|
1708
|
+
const stamp = await this.stamper.stamp(body);
|
|
1709
1709
|
return {
|
|
1710
1710
|
body: body,
|
|
1711
1711
|
stamp: stamp,
|
|
@@ -1725,12 +1725,12 @@ class TurnkeySDKClientBase {
|
|
|
1725
1725
|
}, "updateUserResult");
|
|
1726
1726
|
};
|
|
1727
1727
|
this.stampUpdateUser = async (input) => {
|
|
1728
|
-
if (!this.
|
|
1728
|
+
if (!this.stamper) {
|
|
1729
1729
|
return undefined;
|
|
1730
1730
|
}
|
|
1731
1731
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/update_user";
|
|
1732
1732
|
const body = JSON.stringify(input);
|
|
1733
|
-
const stamp = await this.
|
|
1733
|
+
const stamp = await this.stamper.stamp(body);
|
|
1734
1734
|
return {
|
|
1735
1735
|
body: body,
|
|
1736
1736
|
stamp: stamp,
|
|
@@ -1750,12 +1750,37 @@ class TurnkeySDKClientBase {
|
|
|
1750
1750
|
}, "updateUserTagResult");
|
|
1751
1751
|
};
|
|
1752
1752
|
this.stampUpdateUserTag = async (input) => {
|
|
1753
|
-
if (!this.
|
|
1753
|
+
if (!this.stamper) {
|
|
1754
1754
|
return undefined;
|
|
1755
1755
|
}
|
|
1756
1756
|
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/update_user_tag";
|
|
1757
1757
|
const body = JSON.stringify(input);
|
|
1758
|
-
const stamp = await this.
|
|
1758
|
+
const stamp = await this.stamper.stamp(body);
|
|
1759
|
+
return {
|
|
1760
|
+
body: body,
|
|
1761
|
+
stamp: stamp,
|
|
1762
|
+
url: fullUrl,
|
|
1763
|
+
};
|
|
1764
|
+
};
|
|
1765
|
+
this.updateWallet = async (input) => {
|
|
1766
|
+
const { organizationId, timestampMs, ...rest } = input;
|
|
1767
|
+
const currentUser = await getStorageValue(StorageKeys.UserSession);
|
|
1768
|
+
return this.command("/public/v1/submit/update_wallet", {
|
|
1769
|
+
parameters: rest,
|
|
1770
|
+
organizationId: organizationId ??
|
|
1771
|
+
currentUser?.organization?.organizationId ??
|
|
1772
|
+
this.config.organizationId,
|
|
1773
|
+
timestampMs: timestampMs ?? String(Date.now()),
|
|
1774
|
+
type: "ACTIVITY_TYPE_UPDATE_WALLET",
|
|
1775
|
+
}, "updateWalletResult");
|
|
1776
|
+
};
|
|
1777
|
+
this.stampUpdateWallet = async (input) => {
|
|
1778
|
+
if (!this.stamper) {
|
|
1779
|
+
return undefined;
|
|
1780
|
+
}
|
|
1781
|
+
const fullUrl = this.config.apiBaseUrl + "/public/v1/submit/update_wallet";
|
|
1782
|
+
const body = JSON.stringify(input);
|
|
1783
|
+
const stamp = await this.stamper.stamp(body);
|
|
1759
1784
|
return {
|
|
1760
1785
|
body: body,
|
|
1761
1786
|
stamp: stamp,
|
|
@@ -1763,6 +1788,9 @@ class TurnkeySDKClientBase {
|
|
|
1763
1788
|
};
|
|
1764
1789
|
};
|
|
1765
1790
|
this.config = config;
|
|
1791
|
+
if (config.stamper) {
|
|
1792
|
+
this.stamper = config.stamper;
|
|
1793
|
+
}
|
|
1766
1794
|
}
|
|
1767
1795
|
async request(url, body) {
|
|
1768
1796
|
const fullUrl = this.config.apiBaseUrl + url;
|
|
@@ -1770,8 +1798,8 @@ class TurnkeySDKClientBase {
|
|
|
1770
1798
|
var headers = {
|
|
1771
1799
|
"X-Client-Version": VERSION,
|
|
1772
1800
|
};
|
|
1773
|
-
if (this.
|
|
1774
|
-
const stamp = await this.
|
|
1801
|
+
if (this.stamper) {
|
|
1802
|
+
const stamp = await this.stamper.stamp(stringifiedBody);
|
|
1775
1803
|
headers[stamp.stampHeaderName] = stamp.stampHeaderValue;
|
|
1776
1804
|
}
|
|
1777
1805
|
if (this.config.readOnlySession) {
|