@dynamic-labs/waas-sui 4.20.10 → 4.20.11
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/package.cjs +1 -1
- package/package.js +1 -1
- package/package.json +11 -11
- package/src/connector/DynamicWaasSuiConnector.cjs +22 -7
- package/src/connector/DynamicWaasSuiConnector.js +22 -7
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,17 @@
|
|
|
1
1
|
|
|
2
|
+
### [4.20.11](https://github.com/dynamic-labs/dynamic-auth/compare/v4.20.10...v4.20.11) (2025-07-01)
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
### Features
|
|
6
|
+
|
|
7
|
+
* add signed typed data to waas ([#9050](https://github.com/dynamic-labs/dynamic-auth/issues/9050)) ([19c8fea](https://github.com/dynamic-labs/dynamic-auth/commit/19c8fea2e5448e027cbec2f6158d32247dfcd321))
|
|
8
|
+
* pass jwt to waas operations ([#8981](https://github.com/dynamic-labs/dynamic-auth/issues/8981)) ([6b63394](https://github.com/dynamic-labs/dynamic-auth/commit/6b63394a1a724c2a1499a3d1ff13078d2314b10e))
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Bug Fixes
|
|
12
|
+
|
|
13
|
+
* 7702 signature for undeployed contracts ([#9052](https://github.com/dynamic-labs/dynamic-auth/issues/9052)) ([7052149](https://github.com/dynamic-labs/dynamic-auth/commit/7052149aae53524a0ac2bdad0b7ddf68e3c86189))
|
|
14
|
+
|
|
2
15
|
### [4.20.10](https://github.com/dynamic-labs/dynamic-auth/compare/v4.20.9...v4.20.10) (2025-06-30)
|
|
3
16
|
|
|
4
17
|
|
package/package.cjs
CHANGED
package/package.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/waas-sui",
|
|
3
|
-
"version": "4.20.
|
|
3
|
+
"version": "4.20.11",
|
|
4
4
|
"description": "A React SDK for implementing wallet web3 authentication and authorization to your website.",
|
|
5
5
|
"author": "Dynamic Labs, Inc.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -18,18 +18,18 @@
|
|
|
18
18
|
},
|
|
19
19
|
"homepage": "https://www.dynamic.xyz/",
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@dynamic-labs-wallet/browser-wallet-client": "0.0.
|
|
21
|
+
"@dynamic-labs-wallet/browser-wallet-client": "0.0.106",
|
|
22
22
|
"@mysten/sui": "1.24.0",
|
|
23
23
|
"@mysten/wallet-standard": "0.13.29",
|
|
24
|
-
"@dynamic-labs/assert-package-version": "4.20.
|
|
25
|
-
"@dynamic-labs/logger": "4.20.
|
|
26
|
-
"@dynamic-labs/rpc-providers": "4.20.
|
|
27
|
-
"@dynamic-labs/sui-core": "4.20.
|
|
28
|
-
"@dynamic-labs/types": "4.20.
|
|
29
|
-
"@dynamic-labs/utils": "4.20.
|
|
30
|
-
"@dynamic-labs/waas": "4.20.
|
|
31
|
-
"@dynamic-labs/wallet-book": "4.20.
|
|
32
|
-
"@dynamic-labs/wallet-connector-core": "4.20.
|
|
24
|
+
"@dynamic-labs/assert-package-version": "4.20.11",
|
|
25
|
+
"@dynamic-labs/logger": "4.20.11",
|
|
26
|
+
"@dynamic-labs/rpc-providers": "4.20.11",
|
|
27
|
+
"@dynamic-labs/sui-core": "4.20.11",
|
|
28
|
+
"@dynamic-labs/types": "4.20.11",
|
|
29
|
+
"@dynamic-labs/utils": "4.20.11",
|
|
30
|
+
"@dynamic-labs/waas": "4.20.11",
|
|
31
|
+
"@dynamic-labs/wallet-book": "4.20.11",
|
|
32
|
+
"@dynamic-labs/wallet-connector-core": "4.20.11"
|
|
33
33
|
},
|
|
34
34
|
"peerDependencies": {}
|
|
35
35
|
}
|
|
@@ -100,11 +100,12 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
100
100
|
}
|
|
101
101
|
validateActiveWallet(expectedAddress) {
|
|
102
102
|
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
103
|
-
var _a;
|
|
103
|
+
var _a, _b;
|
|
104
104
|
const walletClient = this.getWaasWalletClient();
|
|
105
105
|
const signedSessionId = yield ((_a = this.getSignedSessionId) === null || _a === void 0 ? void 0 : _a.call(this));
|
|
106
106
|
const targetWallet = yield walletClient.getWallet({
|
|
107
107
|
accountAddress: expectedAddress,
|
|
108
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
108
109
|
signedSessionId,
|
|
109
110
|
});
|
|
110
111
|
if (!targetWallet) {
|
|
@@ -118,10 +119,11 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
118
119
|
}
|
|
119
120
|
createWalletAccount() {
|
|
120
121
|
return _tslib.__awaiter(this, arguments, void 0, function* ({ thresholdSignatureScheme = 'TWO_OF_TWO', } = {}) {
|
|
121
|
-
var _a;
|
|
122
|
+
var _a, _b;
|
|
122
123
|
const walletClient = this.getWaasWalletClient();
|
|
123
124
|
const signedSessionId = yield ((_a = this.getSignedSessionId) === null || _a === void 0 ? void 0 : _a.call(this));
|
|
124
125
|
const createdWallet = yield walletClient.createWalletAccount({
|
|
126
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
125
127
|
signedSessionId,
|
|
126
128
|
thresholdSignatureScheme: thresholdSignatureScheme,
|
|
127
129
|
});
|
|
@@ -130,13 +132,14 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
130
132
|
}
|
|
131
133
|
importPrivateKey(_a) {
|
|
132
134
|
return _tslib.__awaiter(this, arguments, void 0, function* ({ privateKey, thresholdSignatureScheme = 'TWO_OF_TWO', }) {
|
|
133
|
-
var _b;
|
|
135
|
+
var _b, _c;
|
|
134
136
|
const walletClient = this.getWaasWalletClient();
|
|
135
137
|
const signedSessionId = yield ((_b = this.getSignedSessionId) === null || _b === void 0 ? void 0 : _b.call(this));
|
|
136
138
|
if (!signedSessionId) {
|
|
137
139
|
throw new Error('Signed session ID is required');
|
|
138
140
|
}
|
|
139
141
|
yield walletClient.importPrivateKey({
|
|
142
|
+
authToken: (_c = this.getAuthToken) === null || _c === void 0 ? void 0 : _c.call(this),
|
|
140
143
|
privateKey,
|
|
141
144
|
signedSessionId,
|
|
142
145
|
thresholdSignatureScheme: thresholdSignatureScheme,
|
|
@@ -145,7 +148,7 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
145
148
|
}
|
|
146
149
|
signMessage(message) {
|
|
147
150
|
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
148
|
-
var _a;
|
|
151
|
+
var _a, _b;
|
|
149
152
|
const waasSuiClient = this.getWaasWalletClient();
|
|
150
153
|
if (!this.activeAccountAddress) {
|
|
151
154
|
throw new Error('Active account address is required');
|
|
@@ -153,6 +156,7 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
153
156
|
const signedSessionId = yield ((_a = this.getSignedSessionId) === null || _a === void 0 ? void 0 : _a.call(this));
|
|
154
157
|
const signedMessage = yield waasSuiClient.signMessage({
|
|
155
158
|
accountAddress: this.activeAccountAddress,
|
|
159
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
156
160
|
message,
|
|
157
161
|
signedSessionId,
|
|
158
162
|
});
|
|
@@ -161,7 +165,7 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
161
165
|
}
|
|
162
166
|
createAndSignTransaction(transaction) {
|
|
163
167
|
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
164
|
-
var _a;
|
|
168
|
+
var _a, _b;
|
|
165
169
|
const networkName = yield this.getNetworkName();
|
|
166
170
|
const client$1 = new client.SuiClient({ url: client.getFullnodeUrl(networkName) });
|
|
167
171
|
const txBytes = yield transaction.build({ client: client$1 });
|
|
@@ -172,6 +176,7 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
172
176
|
}
|
|
173
177
|
const signedSessionId = yield ((_a = this.getSignedSessionId) === null || _a === void 0 ? void 0 : _a.call(this));
|
|
174
178
|
const signedTx = yield walletClient.signTransaction({
|
|
179
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
175
180
|
senderAddress: this.activeAccountAddress,
|
|
176
181
|
signedSessionId,
|
|
177
182
|
transaction: txString,
|
|
@@ -229,7 +234,7 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
229
234
|
}
|
|
230
235
|
exportPrivateKey() {
|
|
231
236
|
return _tslib.__awaiter(this, arguments, void 0, function* ({ accountAddress, displayContainer, password, } = {}) {
|
|
232
|
-
var _a;
|
|
237
|
+
var _a, _b;
|
|
233
238
|
const walletClient = this.getWaasWalletClient();
|
|
234
239
|
const targetAccountAddress = accountAddress || this.activeAccountAddress;
|
|
235
240
|
if (!targetAccountAddress) {
|
|
@@ -242,6 +247,7 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
242
247
|
const signedSessionId = yield ((_a = this.getSignedSessionId) === null || _a === void 0 ? void 0 : _a.call(this));
|
|
243
248
|
yield walletClient.exportPrivateKey({
|
|
244
249
|
accountAddress: targetAccountAddress,
|
|
250
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
245
251
|
displayContainer,
|
|
246
252
|
password,
|
|
247
253
|
signedSessionId,
|
|
@@ -253,7 +259,7 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
253
259
|
}
|
|
254
260
|
exportClientKeyshares(_a) {
|
|
255
261
|
return _tslib.__awaiter(this, arguments, void 0, function* ({ accountAddress, password, }) {
|
|
256
|
-
var _b;
|
|
262
|
+
var _b, _c;
|
|
257
263
|
const waasSuiClient = this.getWaasWalletClient();
|
|
258
264
|
const targetAccountAddress = accountAddress || this.activeAccountAddress;
|
|
259
265
|
if (!targetAccountAddress) {
|
|
@@ -262,6 +268,7 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
262
268
|
const signedSessionId = yield ((_b = this.getSignedSessionId) === null || _b === void 0 ? void 0 : _b.call(this));
|
|
263
269
|
yield waasSuiClient.exportClientKeyshares({
|
|
264
270
|
accountAddress: targetAccountAddress,
|
|
271
|
+
authToken: (_c = this.getAuthToken) === null || _c === void 0 ? void 0 : _c.call(this),
|
|
265
272
|
password,
|
|
266
273
|
signedSessionId,
|
|
267
274
|
});
|
|
@@ -269,36 +276,42 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
269
276
|
}
|
|
270
277
|
backupKeySharesToGoogleDrive(_a) {
|
|
271
278
|
return _tslib.__awaiter(this, arguments, void 0, function* ({ accountAddress, password, }) {
|
|
279
|
+
var _b;
|
|
272
280
|
if (!accountAddress) {
|
|
273
281
|
throw new Error('Account address is required');
|
|
274
282
|
}
|
|
275
283
|
const walletClient = this.getWaasWalletClient();
|
|
276
284
|
return walletClient.backupKeySharesToGoogleDrive({
|
|
277
285
|
accountAddress,
|
|
286
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
278
287
|
password,
|
|
279
288
|
});
|
|
280
289
|
});
|
|
281
290
|
}
|
|
282
291
|
refreshWalletAccountShares(_a) {
|
|
283
292
|
return _tslib.__awaiter(this, arguments, void 0, function* ({ accountAddress, password, }) {
|
|
293
|
+
var _b;
|
|
284
294
|
if (!accountAddress) {
|
|
285
295
|
throw new Error('Account address is required');
|
|
286
296
|
}
|
|
287
297
|
const walletClient = this.getWaasWalletClient();
|
|
288
298
|
return walletClient.refreshWalletAccountShares({
|
|
289
299
|
accountAddress,
|
|
300
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
290
301
|
password,
|
|
291
302
|
});
|
|
292
303
|
});
|
|
293
304
|
}
|
|
294
305
|
updatePassword(_a) {
|
|
295
306
|
return _tslib.__awaiter(this, arguments, void 0, function* ({ accountAddress, existingPassword, newPassword, }) {
|
|
307
|
+
var _b;
|
|
296
308
|
if (!accountAddress) {
|
|
297
309
|
throw new Error('Account address is required');
|
|
298
310
|
}
|
|
299
311
|
const walletClient = this.getWaasWalletClient();
|
|
300
312
|
return walletClient.updatePassword({
|
|
301
313
|
accountAddress,
|
|
314
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
302
315
|
existingPassword,
|
|
303
316
|
newPassword,
|
|
304
317
|
});
|
|
@@ -306,6 +319,7 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
306
319
|
}
|
|
307
320
|
signRawMessage(_a) {
|
|
308
321
|
return _tslib.__awaiter(this, arguments, void 0, function* ({ accountAddress, message, password, }) {
|
|
322
|
+
var _b;
|
|
309
323
|
if (!accountAddress) {
|
|
310
324
|
throw new Error('Account address is required');
|
|
311
325
|
}
|
|
@@ -315,6 +329,7 @@ class DynamicWaasSuiConnector extends waas.withDynamicWaas(suiCore.SuiWalletConn
|
|
|
315
329
|
const walletClient = this.getWaasWalletClient();
|
|
316
330
|
return walletClient.signRawMessage({
|
|
317
331
|
accountAddress,
|
|
332
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
318
333
|
message,
|
|
319
334
|
password,
|
|
320
335
|
});
|
|
@@ -96,11 +96,12 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
96
96
|
}
|
|
97
97
|
validateActiveWallet(expectedAddress) {
|
|
98
98
|
return __awaiter(this, void 0, void 0, function* () {
|
|
99
|
-
var _a;
|
|
99
|
+
var _a, _b;
|
|
100
100
|
const walletClient = this.getWaasWalletClient();
|
|
101
101
|
const signedSessionId = yield ((_a = this.getSignedSessionId) === null || _a === void 0 ? void 0 : _a.call(this));
|
|
102
102
|
const targetWallet = yield walletClient.getWallet({
|
|
103
103
|
accountAddress: expectedAddress,
|
|
104
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
104
105
|
signedSessionId,
|
|
105
106
|
});
|
|
106
107
|
if (!targetWallet) {
|
|
@@ -114,10 +115,11 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
114
115
|
}
|
|
115
116
|
createWalletAccount() {
|
|
116
117
|
return __awaiter(this, arguments, void 0, function* ({ thresholdSignatureScheme = 'TWO_OF_TWO', } = {}) {
|
|
117
|
-
var _a;
|
|
118
|
+
var _a, _b;
|
|
118
119
|
const walletClient = this.getWaasWalletClient();
|
|
119
120
|
const signedSessionId = yield ((_a = this.getSignedSessionId) === null || _a === void 0 ? void 0 : _a.call(this));
|
|
120
121
|
const createdWallet = yield walletClient.createWalletAccount({
|
|
122
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
121
123
|
signedSessionId,
|
|
122
124
|
thresholdSignatureScheme: thresholdSignatureScheme,
|
|
123
125
|
});
|
|
@@ -126,13 +128,14 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
126
128
|
}
|
|
127
129
|
importPrivateKey(_a) {
|
|
128
130
|
return __awaiter(this, arguments, void 0, function* ({ privateKey, thresholdSignatureScheme = 'TWO_OF_TWO', }) {
|
|
129
|
-
var _b;
|
|
131
|
+
var _b, _c;
|
|
130
132
|
const walletClient = this.getWaasWalletClient();
|
|
131
133
|
const signedSessionId = yield ((_b = this.getSignedSessionId) === null || _b === void 0 ? void 0 : _b.call(this));
|
|
132
134
|
if (!signedSessionId) {
|
|
133
135
|
throw new Error('Signed session ID is required');
|
|
134
136
|
}
|
|
135
137
|
yield walletClient.importPrivateKey({
|
|
138
|
+
authToken: (_c = this.getAuthToken) === null || _c === void 0 ? void 0 : _c.call(this),
|
|
136
139
|
privateKey,
|
|
137
140
|
signedSessionId,
|
|
138
141
|
thresholdSignatureScheme: thresholdSignatureScheme,
|
|
@@ -141,7 +144,7 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
141
144
|
}
|
|
142
145
|
signMessage(message) {
|
|
143
146
|
return __awaiter(this, void 0, void 0, function* () {
|
|
144
|
-
var _a;
|
|
147
|
+
var _a, _b;
|
|
145
148
|
const waasSuiClient = this.getWaasWalletClient();
|
|
146
149
|
if (!this.activeAccountAddress) {
|
|
147
150
|
throw new Error('Active account address is required');
|
|
@@ -149,6 +152,7 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
149
152
|
const signedSessionId = yield ((_a = this.getSignedSessionId) === null || _a === void 0 ? void 0 : _a.call(this));
|
|
150
153
|
const signedMessage = yield waasSuiClient.signMessage({
|
|
151
154
|
accountAddress: this.activeAccountAddress,
|
|
155
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
152
156
|
message,
|
|
153
157
|
signedSessionId,
|
|
154
158
|
});
|
|
@@ -157,7 +161,7 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
157
161
|
}
|
|
158
162
|
createAndSignTransaction(transaction) {
|
|
159
163
|
return __awaiter(this, void 0, void 0, function* () {
|
|
160
|
-
var _a;
|
|
164
|
+
var _a, _b;
|
|
161
165
|
const networkName = yield this.getNetworkName();
|
|
162
166
|
const client = new SuiClient({ url: getFullnodeUrl(networkName) });
|
|
163
167
|
const txBytes = yield transaction.build({ client });
|
|
@@ -168,6 +172,7 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
168
172
|
}
|
|
169
173
|
const signedSessionId = yield ((_a = this.getSignedSessionId) === null || _a === void 0 ? void 0 : _a.call(this));
|
|
170
174
|
const signedTx = yield walletClient.signTransaction({
|
|
175
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
171
176
|
senderAddress: this.activeAccountAddress,
|
|
172
177
|
signedSessionId,
|
|
173
178
|
transaction: txString,
|
|
@@ -225,7 +230,7 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
225
230
|
}
|
|
226
231
|
exportPrivateKey() {
|
|
227
232
|
return __awaiter(this, arguments, void 0, function* ({ accountAddress, displayContainer, password, } = {}) {
|
|
228
|
-
var _a;
|
|
233
|
+
var _a, _b;
|
|
229
234
|
const walletClient = this.getWaasWalletClient();
|
|
230
235
|
const targetAccountAddress = accountAddress || this.activeAccountAddress;
|
|
231
236
|
if (!targetAccountAddress) {
|
|
@@ -238,6 +243,7 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
238
243
|
const signedSessionId = yield ((_a = this.getSignedSessionId) === null || _a === void 0 ? void 0 : _a.call(this));
|
|
239
244
|
yield walletClient.exportPrivateKey({
|
|
240
245
|
accountAddress: targetAccountAddress,
|
|
246
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
241
247
|
displayContainer,
|
|
242
248
|
password,
|
|
243
249
|
signedSessionId,
|
|
@@ -249,7 +255,7 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
249
255
|
}
|
|
250
256
|
exportClientKeyshares(_a) {
|
|
251
257
|
return __awaiter(this, arguments, void 0, function* ({ accountAddress, password, }) {
|
|
252
|
-
var _b;
|
|
258
|
+
var _b, _c;
|
|
253
259
|
const waasSuiClient = this.getWaasWalletClient();
|
|
254
260
|
const targetAccountAddress = accountAddress || this.activeAccountAddress;
|
|
255
261
|
if (!targetAccountAddress) {
|
|
@@ -258,6 +264,7 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
258
264
|
const signedSessionId = yield ((_b = this.getSignedSessionId) === null || _b === void 0 ? void 0 : _b.call(this));
|
|
259
265
|
yield waasSuiClient.exportClientKeyshares({
|
|
260
266
|
accountAddress: targetAccountAddress,
|
|
267
|
+
authToken: (_c = this.getAuthToken) === null || _c === void 0 ? void 0 : _c.call(this),
|
|
261
268
|
password,
|
|
262
269
|
signedSessionId,
|
|
263
270
|
});
|
|
@@ -265,36 +272,42 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
265
272
|
}
|
|
266
273
|
backupKeySharesToGoogleDrive(_a) {
|
|
267
274
|
return __awaiter(this, arguments, void 0, function* ({ accountAddress, password, }) {
|
|
275
|
+
var _b;
|
|
268
276
|
if (!accountAddress) {
|
|
269
277
|
throw new Error('Account address is required');
|
|
270
278
|
}
|
|
271
279
|
const walletClient = this.getWaasWalletClient();
|
|
272
280
|
return walletClient.backupKeySharesToGoogleDrive({
|
|
273
281
|
accountAddress,
|
|
282
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
274
283
|
password,
|
|
275
284
|
});
|
|
276
285
|
});
|
|
277
286
|
}
|
|
278
287
|
refreshWalletAccountShares(_a) {
|
|
279
288
|
return __awaiter(this, arguments, void 0, function* ({ accountAddress, password, }) {
|
|
289
|
+
var _b;
|
|
280
290
|
if (!accountAddress) {
|
|
281
291
|
throw new Error('Account address is required');
|
|
282
292
|
}
|
|
283
293
|
const walletClient = this.getWaasWalletClient();
|
|
284
294
|
return walletClient.refreshWalletAccountShares({
|
|
285
295
|
accountAddress,
|
|
296
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
286
297
|
password,
|
|
287
298
|
});
|
|
288
299
|
});
|
|
289
300
|
}
|
|
290
301
|
updatePassword(_a) {
|
|
291
302
|
return __awaiter(this, arguments, void 0, function* ({ accountAddress, existingPassword, newPassword, }) {
|
|
303
|
+
var _b;
|
|
292
304
|
if (!accountAddress) {
|
|
293
305
|
throw new Error('Account address is required');
|
|
294
306
|
}
|
|
295
307
|
const walletClient = this.getWaasWalletClient();
|
|
296
308
|
return walletClient.updatePassword({
|
|
297
309
|
accountAddress,
|
|
310
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
298
311
|
existingPassword,
|
|
299
312
|
newPassword,
|
|
300
313
|
});
|
|
@@ -302,6 +315,7 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
302
315
|
}
|
|
303
316
|
signRawMessage(_a) {
|
|
304
317
|
return __awaiter(this, arguments, void 0, function* ({ accountAddress, message, password, }) {
|
|
318
|
+
var _b;
|
|
305
319
|
if (!accountAddress) {
|
|
306
320
|
throw new Error('Account address is required');
|
|
307
321
|
}
|
|
@@ -311,6 +325,7 @@ class DynamicWaasSuiConnector extends withDynamicWaas(SuiWalletConnector) {
|
|
|
311
325
|
const walletClient = this.getWaasWalletClient();
|
|
312
326
|
return walletClient.signRawMessage({
|
|
313
327
|
accountAddress,
|
|
328
|
+
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
314
329
|
message,
|
|
315
330
|
password,
|
|
316
331
|
});
|