@getpara/server-sdk 1.5.0 → 1.6.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/dist/cjs/index.js +225 -179
- package/dist/cjs/index.js.br +0 -0
- package/dist/cjs/index.js.gz +0 -0
- package/dist/cjs/package.json +3 -0
- package/dist/cjs/workers/worker.js +468 -412
- package/dist/cjs/workers/worker.js.br +0 -0
- package/dist/cjs/workers/worker.js.gz +0 -0
- package/dist/esm/package.json +4 -0
- package/dist/esm/workers/{chunk-MCKGQKYU.js → chunk-ILICZWQV.js} +22 -1
- package/dist/esm/workers/chunk-ILICZWQV.js.br +0 -0
- package/dist/esm/workers/chunk-ILICZWQV.js.gz +0 -0
- package/dist/esm/workers/{wasm_exec-UV7SYRZI.js → wasm_exec-CFNSOXDO.js} +67 -64
- package/dist/esm/workers/wasm_exec-CFNSOXDO.js.br +0 -0
- package/dist/esm/workers/wasm_exec-CFNSOXDO.js.gz +0 -0
- package/dist/esm/workers/worker.js +385 -350
- package/dist/esm/workers/worker.js.br +0 -0
- package/dist/esm/workers/worker.js.gz +0 -0
- package/dist/types/ServerUtils.d.ts +1 -0
- package/package.json +4 -4
- package/dist/esm/workers/chunk-MCKGQKYU.js.br +0 -0
- package/dist/esm/workers/chunk-MCKGQKYU.js.gz +0 -0
- package/dist/esm/workers/wasm_exec-UV7SYRZI.js.br +0 -0
- package/dist/esm/workers/wasm_exec-UV7SYRZI.js.gz +0 -0
package/dist/cjs/index.js
CHANGED
|
@@ -26,6 +26,26 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
26
26
|
mod
|
|
27
27
|
));
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var __async = (__this, __arguments, generator) => {
|
|
30
|
+
return new Promise((resolve, reject) => {
|
|
31
|
+
var fulfilled = (value) => {
|
|
32
|
+
try {
|
|
33
|
+
step(generator.next(value));
|
|
34
|
+
} catch (e) {
|
|
35
|
+
reject(e);
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
var rejected = (value) => {
|
|
39
|
+
try {
|
|
40
|
+
step(generator.throw(value));
|
|
41
|
+
} catch (e) {
|
|
42
|
+
reject(e);
|
|
43
|
+
}
|
|
44
|
+
};
|
|
45
|
+
var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
|
|
46
|
+
step((generator = generator.apply(__this, __arguments)).next());
|
|
47
|
+
});
|
|
48
|
+
};
|
|
29
49
|
|
|
30
50
|
// src/index.ts
|
|
31
51
|
var src_exports = {};
|
|
@@ -106,52 +126,60 @@ function removeWorkId(workId, skipClearTimeout) {
|
|
|
106
126
|
}
|
|
107
127
|
clearTimeout(timeoutId);
|
|
108
128
|
}
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
if (!worker || !worker.threadId) {
|
|
118
|
-
const workerRes = await fetch(`${(0, import_core_sdk.getPortalBaseURL)(ctx)}/static/js/mpcWorkerServer-bundle.js`);
|
|
119
|
-
worker = new import_worker_threads.Worker(await workerRes.text(), { eval: true });
|
|
120
|
-
const onmessage = async (message) => {
|
|
121
|
-
const { workId: messageWorkId } = message;
|
|
122
|
-
delete message.workId;
|
|
123
|
-
await resFunctionMap[messageWorkId].fn(message);
|
|
124
|
-
removeWorkId(messageWorkId);
|
|
129
|
+
function setupWorker(ctx, resFunction, workId) {
|
|
130
|
+
return __async(this, null, function* () {
|
|
131
|
+
const timeoutId = setTimeout(() => {
|
|
132
|
+
removeWorkId(workId, true);
|
|
133
|
+
}, CLEAR_WORKER_TIMEOUT_MS);
|
|
134
|
+
resFunctionMap[workId] = {
|
|
135
|
+
fn: resFunction,
|
|
136
|
+
timeoutId
|
|
125
137
|
};
|
|
126
|
-
worker.
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
138
|
+
if (!worker || !worker.threadId) {
|
|
139
|
+
const workerRes = yield fetch(`${(0, import_core_sdk.getPortalBaseURL)(ctx)}/static/js/mpcWorkerServer-bundle.js`);
|
|
140
|
+
worker = new import_worker_threads.Worker(yield workerRes.text(), { eval: true });
|
|
141
|
+
const onmessage = (message) => __async(this, null, function* () {
|
|
142
|
+
const { workId: messageWorkId } = message;
|
|
143
|
+
delete message.workId;
|
|
144
|
+
yield resFunctionMap[messageWorkId].fn(message);
|
|
145
|
+
removeWorkId(messageWorkId);
|
|
146
|
+
});
|
|
147
|
+
worker.on("message", onmessage);
|
|
148
|
+
worker.on("error", (err) => {
|
|
149
|
+
throw err;
|
|
150
|
+
});
|
|
151
|
+
worker.on("exit", (code) => {
|
|
152
|
+
console.error(`worker stopped with exit code ${code}`);
|
|
153
|
+
});
|
|
154
|
+
}
|
|
155
|
+
return worker;
|
|
156
|
+
});
|
|
135
157
|
}
|
|
136
158
|
|
|
137
159
|
// src/wallet/keygen.ts
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
160
|
+
function isKeygenComplete(ctx, userId, walletId) {
|
|
161
|
+
return __async(this, null, function* () {
|
|
162
|
+
const wallets = yield ctx.client.getWallets(userId);
|
|
163
|
+
const wallet = wallets.data.wallets.find((w) => w.id === walletId);
|
|
164
|
+
return !!wallet.address;
|
|
165
|
+
});
|
|
142
166
|
}
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
167
|
+
function isPreKeygenComplete(ctx, pregenIdentifier, pregenIdentifierType, walletId) {
|
|
168
|
+
return __async(this, null, function* () {
|
|
169
|
+
const wallets = yield ctx.client.getPregenWallets({ [pregenIdentifierType]: [pregenIdentifier] });
|
|
170
|
+
const wallet = wallets.wallets.find((w) => w.id === walletId);
|
|
171
|
+
return !!(wallet == null ? void 0 : wallet.address);
|
|
172
|
+
});
|
|
147
173
|
}
|
|
148
174
|
function keygen(ctx, userId, type, secretKey, skipDistribute = false, sessionCookie, _emailProps = {}) {
|
|
149
|
-
return new Promise(
|
|
175
|
+
return new Promise((resolve) => __async(this, null, function* () {
|
|
150
176
|
const workId = uuid.v4();
|
|
151
|
-
const worker2 =
|
|
177
|
+
const worker2 = yield setupWorker(
|
|
152
178
|
ctx,
|
|
153
|
-
|
|
154
|
-
|
|
179
|
+
(res) => __async(this, null, function* () {
|
|
180
|
+
yield (0, import_core_sdk2.waitUntilTrue)(() => __async(this, null, function* () {
|
|
181
|
+
return isKeygenComplete(ctx, userId, res.walletId);
|
|
182
|
+
}), 15e3, 1e3);
|
|
155
183
|
if (skipDistribute) {
|
|
156
184
|
resolve({
|
|
157
185
|
signer: res.signer,
|
|
@@ -159,7 +187,7 @@ function keygen(ctx, userId, type, secretKey, skipDistribute = false, sessionCoo
|
|
|
159
187
|
recoveryShare: null
|
|
160
188
|
});
|
|
161
189
|
}
|
|
162
|
-
},
|
|
190
|
+
}),
|
|
163
191
|
workId
|
|
164
192
|
);
|
|
165
193
|
worker2.postMessage({
|
|
@@ -176,16 +204,18 @@ function keygen(ctx, userId, type, secretKey, skipDistribute = false, sessionCoo
|
|
|
176
204
|
wasmOverride: ctx.wasmOverride,
|
|
177
205
|
workId
|
|
178
206
|
});
|
|
179
|
-
});
|
|
207
|
+
}));
|
|
180
208
|
}
|
|
181
209
|
function preKeygen(ctx, pregenIdentifier, pregenIdentifierType, type, secretKey, _skipDistribute = false, partnerId, sessionCookie) {
|
|
182
|
-
return new Promise(
|
|
210
|
+
return new Promise((resolve) => __async(this, null, function* () {
|
|
183
211
|
const workId = uuid.v4();
|
|
184
|
-
const worker2 =
|
|
212
|
+
const worker2 = yield setupWorker(
|
|
185
213
|
ctx,
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
214
|
+
(res) => __async(this, null, function* () {
|
|
215
|
+
yield (0, import_core_sdk2.waitUntilTrue)(
|
|
216
|
+
() => __async(this, null, function* () {
|
|
217
|
+
return isPreKeygenComplete(ctx, pregenIdentifier, pregenIdentifierType, res.walletId);
|
|
218
|
+
}),
|
|
189
219
|
15e3,
|
|
190
220
|
1e3
|
|
191
221
|
);
|
|
@@ -194,7 +224,7 @@ function preKeygen(ctx, pregenIdentifier, pregenIdentifierType, type, secretKey,
|
|
|
194
224
|
walletId: res.walletId,
|
|
195
225
|
recoveryShare: null
|
|
196
226
|
});
|
|
197
|
-
},
|
|
227
|
+
}),
|
|
198
228
|
workId
|
|
199
229
|
);
|
|
200
230
|
const email = void 0;
|
|
@@ -216,21 +246,23 @@ function preKeygen(ctx, pregenIdentifier, pregenIdentifierType, type, secretKey,
|
|
|
216
246
|
wasmOverride: ctx.wasmOverride,
|
|
217
247
|
workId
|
|
218
248
|
});
|
|
219
|
-
});
|
|
249
|
+
}));
|
|
220
250
|
}
|
|
221
251
|
function ed25519Keygen(ctx, userId, sessionCookie, _emailProps = {}) {
|
|
222
|
-
return new Promise(
|
|
252
|
+
return new Promise((resolve) => __async(this, null, function* () {
|
|
223
253
|
const workId = uuid.v4();
|
|
224
|
-
const worker2 =
|
|
254
|
+
const worker2 = yield setupWorker(
|
|
225
255
|
ctx,
|
|
226
|
-
|
|
227
|
-
|
|
256
|
+
(res) => __async(this, null, function* () {
|
|
257
|
+
yield (0, import_core_sdk2.waitUntilTrue)(() => __async(this, null, function* () {
|
|
258
|
+
return isKeygenComplete(ctx, userId, res.walletId);
|
|
259
|
+
}), 15e3, 1e3);
|
|
228
260
|
resolve({
|
|
229
261
|
signer: res.signer,
|
|
230
262
|
walletId: res.walletId,
|
|
231
263
|
recoveryShare: null
|
|
232
264
|
});
|
|
233
|
-
},
|
|
265
|
+
}),
|
|
234
266
|
workId
|
|
235
267
|
);
|
|
236
268
|
worker2.postMessage({
|
|
@@ -245,16 +277,18 @@ function ed25519Keygen(ctx, userId, sessionCookie, _emailProps = {}) {
|
|
|
245
277
|
wasmOverride: ctx.wasmOverride,
|
|
246
278
|
workId
|
|
247
279
|
});
|
|
248
|
-
});
|
|
280
|
+
}));
|
|
249
281
|
}
|
|
250
282
|
function ed25519PreKeygen(ctx, pregenIdentifier, pregenIdentifierType, sessionCookie) {
|
|
251
|
-
return new Promise(
|
|
283
|
+
return new Promise((resolve) => __async(this, null, function* () {
|
|
252
284
|
const workId = uuid.v4();
|
|
253
|
-
const worker2 =
|
|
285
|
+
const worker2 = yield setupWorker(
|
|
254
286
|
ctx,
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
287
|
+
(res) => __async(this, null, function* () {
|
|
288
|
+
yield (0, import_core_sdk2.waitUntilTrue)(
|
|
289
|
+
() => __async(this, null, function* () {
|
|
290
|
+
return isPreKeygenComplete(ctx, pregenIdentifier, pregenIdentifierType, res.walletId);
|
|
291
|
+
}),
|
|
258
292
|
15e3,
|
|
259
293
|
1e3
|
|
260
294
|
);
|
|
@@ -263,7 +297,7 @@ function ed25519PreKeygen(ctx, pregenIdentifier, pregenIdentifierType, sessionCo
|
|
|
263
297
|
walletId: res.walletId,
|
|
264
298
|
recoveryShare: null
|
|
265
299
|
});
|
|
266
|
-
},
|
|
300
|
+
}),
|
|
267
301
|
workId
|
|
268
302
|
);
|
|
269
303
|
const email = void 0;
|
|
@@ -283,138 +317,148 @@ function ed25519PreKeygen(ctx, pregenIdentifier, pregenIdentifierType, sessionCo
|
|
|
283
317
|
wasmOverride: ctx.wasmOverride,
|
|
284
318
|
workId
|
|
285
319
|
});
|
|
286
|
-
});
|
|
320
|
+
}));
|
|
287
321
|
}
|
|
288
322
|
|
|
289
323
|
// src/wallet/signing.ts
|
|
290
324
|
var uuid2 = __toESM(require("uuid"));
|
|
291
|
-
|
|
292
|
-
return
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
325
|
+
function signTransaction(ctx, userId, walletId, share, tx, chainId, sessionCookie, isDKLS) {
|
|
326
|
+
return __async(this, null, function* () {
|
|
327
|
+
return yield new Promise((resolve) => __async(this, null, function* () {
|
|
328
|
+
const workId = uuid2.v4();
|
|
329
|
+
const worker2 = yield setupWorker(
|
|
330
|
+
ctx,
|
|
331
|
+
(sendTransactionRes) => __async(this, null, function* () {
|
|
332
|
+
resolve(sendTransactionRes);
|
|
333
|
+
}),
|
|
334
|
+
workId
|
|
335
|
+
);
|
|
336
|
+
worker2.postMessage({
|
|
337
|
+
env: ctx.env,
|
|
338
|
+
apiKey: ctx.apiKey,
|
|
339
|
+
cosmosPrefix: ctx.cosmosPrefix,
|
|
340
|
+
params: { share, walletId, userId, tx, chainId },
|
|
341
|
+
functionType: "SIGN_TRANSACTION",
|
|
342
|
+
offloadMPCComputationURL: ctx.offloadMPCComputationURL,
|
|
343
|
+
disableWorkers: ctx.disableWorkers,
|
|
344
|
+
sessionCookie,
|
|
345
|
+
useDKLS: isDKLS,
|
|
346
|
+
disableWebSockets: ctx.disableWebSockets,
|
|
347
|
+
wasmOverride: ctx.wasmOverride,
|
|
348
|
+
workId
|
|
349
|
+
});
|
|
350
|
+
}));
|
|
315
351
|
});
|
|
316
352
|
}
|
|
317
|
-
|
|
318
|
-
return
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
353
|
+
function sendTransaction(ctx, userId, walletId, share, tx, chainId, sessionCookie, isDKLS) {
|
|
354
|
+
return __async(this, null, function* () {
|
|
355
|
+
return yield new Promise((resolve) => __async(this, null, function* () {
|
|
356
|
+
const workId = uuid2.v4();
|
|
357
|
+
const worker2 = yield setupWorker(
|
|
358
|
+
ctx,
|
|
359
|
+
(sendTransactionRes) => __async(this, null, function* () {
|
|
360
|
+
resolve(sendTransactionRes);
|
|
361
|
+
}),
|
|
362
|
+
workId
|
|
363
|
+
);
|
|
364
|
+
worker2.postMessage({
|
|
365
|
+
env: ctx.env,
|
|
366
|
+
apiKey: ctx.apiKey,
|
|
367
|
+
params: { share, walletId, userId, tx, chainId },
|
|
368
|
+
functionType: "SEND_TRANSACTION",
|
|
369
|
+
offloadMPCComputationURL: ctx.offloadMPCComputationURL,
|
|
370
|
+
disableWorkers: ctx.disableWorkers,
|
|
371
|
+
sessionCookie,
|
|
372
|
+
useDKLS: isDKLS,
|
|
373
|
+
disableWebSockets: ctx.disableWebSockets,
|
|
374
|
+
wasmOverride: ctx.wasmOverride,
|
|
375
|
+
workId
|
|
376
|
+
});
|
|
377
|
+
}));
|
|
340
378
|
});
|
|
341
379
|
}
|
|
342
|
-
|
|
343
|
-
return
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
380
|
+
function signMessage(ctx, userId, walletId, share, message, sessionCookie, isDKLS) {
|
|
381
|
+
return __async(this, null, function* () {
|
|
382
|
+
return yield new Promise((resolve) => __async(this, null, function* () {
|
|
383
|
+
const workId = uuid2.v4();
|
|
384
|
+
const worker2 = yield setupWorker(
|
|
385
|
+
ctx,
|
|
386
|
+
(signMessageRes) => __async(this, null, function* () {
|
|
387
|
+
resolve(signMessageRes);
|
|
388
|
+
}),
|
|
389
|
+
workId
|
|
390
|
+
);
|
|
391
|
+
worker2.postMessage({
|
|
392
|
+
env: ctx.env,
|
|
393
|
+
apiKey: ctx.apiKey,
|
|
394
|
+
params: { share, walletId, userId, message },
|
|
395
|
+
functionType: "SIGN_MESSAGE",
|
|
396
|
+
offloadMPCComputationURL: ctx.offloadMPCComputationURL,
|
|
397
|
+
disableWorkers: ctx.disableWorkers,
|
|
398
|
+
sessionCookie,
|
|
399
|
+
useDKLS: isDKLS,
|
|
400
|
+
disableWebSockets: ctx.disableWebSockets,
|
|
401
|
+
wasmOverride: ctx.wasmOverride,
|
|
402
|
+
workId
|
|
403
|
+
});
|
|
404
|
+
}));
|
|
365
405
|
});
|
|
366
406
|
}
|
|
367
|
-
|
|
368
|
-
return
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
407
|
+
function ed25519Sign(ctx, userId, walletId, share, base64Bytes, sessionCookie) {
|
|
408
|
+
return __async(this, null, function* () {
|
|
409
|
+
return yield new Promise((resolve) => __async(this, null, function* () {
|
|
410
|
+
const workId = uuid2.v4();
|
|
411
|
+
const worker2 = yield setupWorker(
|
|
412
|
+
ctx,
|
|
413
|
+
(signMessageRes) => __async(this, null, function* () {
|
|
414
|
+
resolve(signMessageRes);
|
|
415
|
+
}),
|
|
416
|
+
workId
|
|
417
|
+
);
|
|
418
|
+
worker2.postMessage({
|
|
419
|
+
env: ctx.env,
|
|
420
|
+
apiKey: ctx.apiKey,
|
|
421
|
+
params: { share, walletId, userId, base64Bytes },
|
|
422
|
+
functionType: "ED25519_SIGN",
|
|
423
|
+
offloadMPCComputationURL: ctx.offloadMPCComputationURL,
|
|
424
|
+
disableWorkers: ctx.disableWorkers,
|
|
425
|
+
sessionCookie,
|
|
426
|
+
disableWebSockets: ctx.disableWebSockets,
|
|
427
|
+
wasmOverride: ctx.wasmOverride,
|
|
428
|
+
workId
|
|
429
|
+
});
|
|
430
|
+
}));
|
|
389
431
|
});
|
|
390
432
|
}
|
|
391
433
|
|
|
392
434
|
// src/wallet/privateKey.ts
|
|
393
435
|
var uuid3 = __toESM(require("uuid"));
|
|
394
|
-
|
|
395
|
-
return
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
436
|
+
function getPrivateKey(ctx, userId, walletId, share, sessionCookie) {
|
|
437
|
+
return __async(this, null, function* () {
|
|
438
|
+
return yield new Promise((resolve) => __async(this, null, function* () {
|
|
439
|
+
const workId = uuid3.v4();
|
|
440
|
+
const worker2 = yield setupWorker(
|
|
441
|
+
ctx,
|
|
442
|
+
(res) => __async(this, null, function* () {
|
|
443
|
+
resolve(res);
|
|
444
|
+
}),
|
|
445
|
+
workId
|
|
446
|
+
);
|
|
447
|
+
worker2.postMessage({
|
|
448
|
+
env: ctx.env,
|
|
449
|
+
apiKey: ctx.apiKey,
|
|
450
|
+
cosmosPrefix: ctx.cosmosPrefix,
|
|
451
|
+
params: { share, walletId, userId },
|
|
452
|
+
functionType: "GET_PRIVATE_KEY",
|
|
453
|
+
offloadMPCComputationURL: ctx.offloadMPCComputationURL,
|
|
454
|
+
disableWorkers: ctx.disableWorkers,
|
|
455
|
+
sessionCookie,
|
|
456
|
+
useDKLS: ctx.useDKLS,
|
|
457
|
+
disableWebSockets: ctx.disableWebSockets,
|
|
458
|
+
wasmOverride: ctx.wasmOverride,
|
|
459
|
+
workId
|
|
460
|
+
});
|
|
461
|
+
}));
|
|
418
462
|
});
|
|
419
463
|
}
|
|
420
464
|
|
|
@@ -490,10 +534,12 @@ var Para = class extends import_core_sdk3.default {
|
|
|
490
534
|
* @param {TPregenIdentifierType} opts.pregenIdentifierType - the type of the identifier.
|
|
491
535
|
* @returns {Promise<string | undefined>} A promise that rejects with an error.
|
|
492
536
|
*/
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
537
|
+
claimPregenWallets() {
|
|
538
|
+
return __async(this, arguments, function* ({} = {}) {
|
|
539
|
+
throw new Error(
|
|
540
|
+
"claimPregenWallets is not available in the server SDK. This function is only supported on the client side. Please ensure you are using the client SDK to call this method."
|
|
541
|
+
);
|
|
542
|
+
});
|
|
497
543
|
}
|
|
498
544
|
};
|
|
499
545
|
|
package/dist/cjs/index.js.br
CHANGED
|
Binary file
|
package/dist/cjs/index.js.gz
CHANGED
|
Binary file
|