From d71e3eafaf1eb6adb81069b55307d6a244f62303 Mon Sep 17 00:00:00 2001 From: Yimin Yu Date: Thu, 14 Mar 2024 18:56:54 +0800 Subject: [PATCH 01/36] fix instances array to allow input multiple instance --- dist/cjs/helper/util.js | 8 ++++++-- dist/cjs/interface/interface.d.ts | 2 +- dist/mjs/helper/util.js | 8 ++++++-- dist/mjs/interface/interface.d.ts | 2 +- src/helper/util.ts | 8 ++++++-- src/interface/interface.ts | 2 +- 6 files changed, 21 insertions(+), 9 deletions(-) diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index 4544bb34..42ec50cb 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -237,7 +237,11 @@ class ZkWasmUtil { let aggregate_proof = this.bytesToBigIntArray(params.aggregate_proof); let batchInstances = this.bytesToBigIntArray(params.batch_instances); let aux = this.bytesToBigIntArray(params.aux); - let instances = this.bytesToBigIntArray(params.instances); + let instances = []; + params.instances.forEach(instance => { + instances.push(this.bytesToBigIntArray(instance)); + }); + // let instances = this.bytesToBigIntArray(params.instances); // let args = ZkWasmUtil.parseArgs(params.instances).map((x) => // x.toString(10) // ); @@ -247,7 +251,7 @@ class ZkWasmUtil { // } // // convert to BigInt array // let bigIntArgs = args.map((x) => BigInt(x)); - let result = yield verify_contract.verify.send(aggregate_proof, batchInstances, aux, [instances]); + let result = yield verify_contract.verify.send(aggregate_proof, batchInstances, aux, instances); return result; }); } diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index 9661f825..6a81a03a 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -141,7 +141,7 @@ export interface VerifyProofParams { aggregate_proof: Uint8Array; batch_instances: Uint8Array; aux: Uint8Array; - instances: Uint8Array; + instances: Array; } export interface LogQuery { id: string; diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index 29d06d1b..2cdd500d 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -266,7 +266,11 @@ export class ZkWasmUtil { let aggregate_proof = this.bytesToBigIntArray(params.aggregate_proof); let batchInstances = this.bytesToBigIntArray(params.batch_instances); let aux = this.bytesToBigIntArray(params.aux); - let instances = this.bytesToBigIntArray(params.instances); + let instances = []; + params.instances.forEach(instance => { + instances.push(this.bytesToBigIntArray(instance)); + }); + // let instances = this.bytesToBigIntArray(params.instances); // let args = ZkWasmUtil.parseArgs(params.instances).map((x) => // x.toString(10) // ); @@ -276,7 +280,7 @@ export class ZkWasmUtil { // } // // convert to BigInt array // let bigIntArgs = args.map((x) => BigInt(x)); - let result = await verify_contract.verify.send(aggregate_proof, batchInstances, aux, [instances]); + let result = await verify_contract.verify.send(aggregate_proof, batchInstances, aux, instances); return result; } static async signMessage(message, priv_key) { diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index 9661f825..6a81a03a 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -141,7 +141,7 @@ export interface VerifyProofParams { aggregate_proof: Uint8Array; batch_instances: Uint8Array; aux: Uint8Array; - instances: Uint8Array; + instances: Array; } export interface LogQuery { id: string; diff --git a/src/helper/util.ts b/src/helper/util.ts index 50ac1183..eed975dc 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -333,7 +333,11 @@ export class ZkWasmUtil { let aggregate_proof = this.bytesToBigIntArray(params.aggregate_proof); let batchInstances = this.bytesToBigIntArray(params.batch_instances); let aux = this.bytesToBigIntArray(params.aux); - let instances = this.bytesToBigIntArray(params.instances); + let instances: Array = []; + params.instances.forEach(instance => { + instances.push(this.bytesToBigIntArray(instance)); + }); + // let instances = this.bytesToBigIntArray(params.instances); // let args = ZkWasmUtil.parseArgs(params.instances).map((x) => // x.toString(10) // ); @@ -348,7 +352,7 @@ export class ZkWasmUtil { aggregate_proof, batchInstances, aux, - [instances] + instances ); return result; } diff --git a/src/interface/interface.ts b/src/interface/interface.ts index d2f99508..bd38059f 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -177,7 +177,7 @@ export interface VerifyProofParams { aggregate_proof: Uint8Array; batch_instances: Uint8Array; aux: Uint8Array; - instances: Uint8Array; + instances: Array; } export interface LogQuery { From b8a1c5407a03ded00e4450a0714d6b35e239d2c7 Mon Sep 17 00:00:00 2001 From: rhaoio Date: Sat, 16 Mar 2024 18:04:27 +1100 Subject: [PATCH 02/36] shadow instances --- src/helper/util.ts | 8 ++++---- src/interface/interface.ts | 3 ++- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/helper/util.ts b/src/helper/util.ts index eed975dc..4f8f3f94 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -331,13 +331,13 @@ export class ZkWasmUtil { params: VerifyProofParams ) { let aggregate_proof = this.bytesToBigIntArray(params.aggregate_proof); - let batchInstances = this.bytesToBigIntArray(params.batch_instances); + let shadow_instances = this.bytesToBigIntArray(params.shadow_instances); let aux = this.bytesToBigIntArray(params.aux); let instances: Array = []; - params.instances.forEach(instance => { + params.instances.forEach((instance) => { instances.push(this.bytesToBigIntArray(instance)); }); - // let instances = this.bytesToBigIntArray(params.instances); + // let instances = this.bytesToBigIntArray(params.instances); // let args = ZkWasmUtil.parseArgs(params.instances).map((x) => // x.toString(10) // ); @@ -350,7 +350,7 @@ export class ZkWasmUtil { let result = await verify_contract.verify.send( aggregate_proof, - batchInstances, + shadow_instances, aux, instances ); diff --git a/src/interface/interface.ts b/src/interface/interface.ts index bd38059f..b98f5d28 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -175,7 +175,8 @@ export interface QueryParams { export interface VerifyProofParams { aggregate_proof: Uint8Array; - batch_instances: Uint8Array; + shadow_instances: Uint8Array; + aux: Uint8Array; instances: Array; } From 46d6d00844436fc02fd9c88602a6b1b048ffb17d Mon Sep 17 00:00:00 2001 From: rhaoio Date: Sat, 16 Mar 2024 18:14:52 +1100 Subject: [PATCH 03/36] build --- dist/cjs/helper/util.js | 6 +++--- dist/cjs/interface/interface.d.ts | 3 ++- dist/mjs/helper/util.js | 6 +++--- dist/mjs/interface/interface.d.ts | 3 ++- src/interface/interface.ts | 1 + 5 files changed, 11 insertions(+), 8 deletions(-) diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index 42ec50cb..c29e24f0 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -235,10 +235,10 @@ class ZkWasmUtil { static verifyProof(verify_contract, params) { return __awaiter(this, void 0, void 0, function* () { let aggregate_proof = this.bytesToBigIntArray(params.aggregate_proof); - let batchInstances = this.bytesToBigIntArray(params.batch_instances); + let shadow_instances = this.bytesToBigIntArray(params.shadow_instances); let aux = this.bytesToBigIntArray(params.aux); let instances = []; - params.instances.forEach(instance => { + params.instances.forEach((instance) => { instances.push(this.bytesToBigIntArray(instance)); }); // let instances = this.bytesToBigIntArray(params.instances); @@ -251,7 +251,7 @@ class ZkWasmUtil { // } // // convert to BigInt array // let bigIntArgs = args.map((x) => BigInt(x)); - let result = yield verify_contract.verify.send(aggregate_proof, batchInstances, aux, instances); + let result = yield verify_contract.verify.send(aggregate_proof, shadow_instances, aux, instances); return result; }); } diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index 6a81a03a..ed7c784f 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -20,6 +20,7 @@ export interface Task { proof: Uint8Array; aux: Uint8Array; external_host_table: Uint8Array; + shadow_instances: Uint8Array; batch_instances: Uint8Array; instances: Uint8Array; public_inputs: Array; @@ -139,7 +140,7 @@ export interface QueryParams { } export interface VerifyProofParams { aggregate_proof: Uint8Array; - batch_instances: Uint8Array; + shadow_instances: Uint8Array; aux: Uint8Array; instances: Array; } diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index 2cdd500d..dc1da021 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -264,10 +264,10 @@ export class ZkWasmUtil { } static async verifyProof(verify_contract, params) { let aggregate_proof = this.bytesToBigIntArray(params.aggregate_proof); - let batchInstances = this.bytesToBigIntArray(params.batch_instances); + let shadow_instances = this.bytesToBigIntArray(params.shadow_instances); let aux = this.bytesToBigIntArray(params.aux); let instances = []; - params.instances.forEach(instance => { + params.instances.forEach((instance) => { instances.push(this.bytesToBigIntArray(instance)); }); // let instances = this.bytesToBigIntArray(params.instances); @@ -280,7 +280,7 @@ export class ZkWasmUtil { // } // // convert to BigInt array // let bigIntArgs = args.map((x) => BigInt(x)); - let result = await verify_contract.verify.send(aggregate_proof, batchInstances, aux, instances); + let result = await verify_contract.verify.send(aggregate_proof, shadow_instances, aux, instances); return result; } static async signMessage(message, priv_key) { diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index 6a81a03a..ed7c784f 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -20,6 +20,7 @@ export interface Task { proof: Uint8Array; aux: Uint8Array; external_host_table: Uint8Array; + shadow_instances: Uint8Array; batch_instances: Uint8Array; instances: Uint8Array; public_inputs: Array; @@ -139,7 +140,7 @@ export interface QueryParams { } export interface VerifyProofParams { aggregate_proof: Uint8Array; - batch_instances: Uint8Array; + shadow_instances: Uint8Array; aux: Uint8Array; instances: Array; } diff --git a/src/interface/interface.ts b/src/interface/interface.ts index b98f5d28..b026dab8 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -23,6 +23,7 @@ export interface Task { proof: Uint8Array; aux: Uint8Array; external_host_table: Uint8Array; + shadow_instances: Uint8Array; batch_instances: Uint8Array; instances: Uint8Array; public_inputs: Array; From dfd3a00ade148976dbea05b0ea1a3ec6a5a62995 Mon Sep 17 00:00:00 2001 From: Yimin Yu Date: Mon, 25 Mar 2024 16:57:10 +0800 Subject: [PATCH 04/36] export image status string --- dist/cjs/interface/interface.d.ts | 1 + dist/mjs/interface/interface.d.ts | 1 + src/interface/interface.ts | 8 ++++++++ 3 files changed, 10 insertions(+) diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index ed7c784f..e150be8d 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -48,6 +48,7 @@ export interface VerifierContracts { circuit_size: number; } export type TaskType = "Setup" | "Prove" | "Reset"; +export type ImageStatus = "Received" | "Initialized" | "Verified"; export type TaskStatus = "Pending" | "Processing" | "DryRunFailed" | "Done" | "Fail" | "Stale"; export interface PaginationResult { data: T; diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index ed7c784f..e150be8d 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -48,6 +48,7 @@ export interface VerifierContracts { circuit_size: number; } export type TaskType = "Setup" | "Prove" | "Reset"; +export type ImageStatus = "Received" | "Initialized" | "Verified"; export type TaskStatus = "Pending" | "Processing" | "DryRunFailed" | "Done" | "Fail" | "Stale"; export interface PaginationResult { data: T; diff --git a/src/interface/interface.ts b/src/interface/interface.ts index b026dab8..9942ac24 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -55,6 +55,14 @@ export interface VerifierContracts { export type TaskType = "Setup" | "Prove" | "Reset"; +/** + * Image status: + * Received: Server received setup task of the image but haven’t been done successfully. + * Initialized: Server received setup task of the image and it is done successfully. No proof task had been done successfully for this image. + * Verified: At least one of the proof task had been done successfully for the image. + **/ +export type ImageStatus = "Received" | "Initialized" | "Verified"; + export type TaskStatus = | "Pending" | "Processing" From e0c4228e0ad439b34bdfd160d96b85c70cb50686 Mon Sep 17 00:00:00 2001 From: Oscar Downing Date: Fri, 5 Apr 2024 04:48:36 +0530 Subject: [PATCH 05/36] ZKWAS-228: add metadata param into interface for 'Creator Paid Proof' feature (#60) --- dist/cjs/helper/util.js | 4 ++++ dist/cjs/interface/interface.d.ts | 15 +++++++++++++++ dist/mjs/helper/util.js | 4 ++++ dist/mjs/interface/interface.d.ts | 15 +++++++++++++++ src/helper/util.ts | 4 ++++ src/interface/interface.ts | 7 +++++++ 6 files changed, 49 insertions(+) diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index c29e24f0..c9c5b129 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -126,6 +126,8 @@ class ZkWasmUtil { message += params.description_url; message += params.avator_url; message += params.circuit_size; + message += params.metadata_keys; + message += params.metadata_vals; // Additional params afterwards if (params.initial_context) { message += params.initial_context_md5; @@ -162,6 +164,8 @@ class ZkWasmUtil { message += params.md5; message += params.circuit_size; message += params.user_address; + message += params.metadata_keys; + message += params.metadata_vals; if (params.reset_context) { message += params.reset_context_md5; } diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index e150be8d..54f506f4 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -48,6 +48,12 @@ export interface VerifierContracts { circuit_size: number; } export type TaskType = "Setup" | "Prove" | "Reset"; +/** + * Image status: + * Received: Server received setup task of the image but haven’t been done successfully. + * Initialized: Server received setup task of the image and it is done successfully. No proof task had been done successfully for this image. + * Verified: At least one of the proof task had been done successfully for the image. + **/ export type ImageStatus = "Received" | "Initialized" | "Verified"; export type TaskStatus = "Pending" | "Processing" | "DryRunFailed" | "Done" | "Fail" | "Stale"; export interface PaginationResult { @@ -62,6 +68,8 @@ export interface BaseAddImageParams { description_url: string; avator_url: string; circuit_size: number; + metadata_keys: string[]; + metadata_vals: string[]; } export interface WithInitialContext { initial_context: unknown; @@ -103,6 +111,8 @@ export interface BaseResetImageParams { md5: string; circuit_size: number; user_address: string; + metadata_keys: string[]; + metadata_vals: string[]; } export interface WithResetContext { reset_context: unknown; @@ -210,6 +220,11 @@ export interface Image { initial_context?: Uint8Array; status: string; checksum: ImageChecksum | null; + metadata: { + values: { + [key: string]: string; + }; + }; } export interface ImageChecksum { x: Uint8Array; diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index dc1da021..a9c17c3a 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -156,6 +156,8 @@ export class ZkWasmUtil { message += params.description_url; message += params.avator_url; message += params.circuit_size; + message += params.metadata_keys; + message += params.metadata_vals; // Additional params afterwards if (params.initial_context) { message += params.initial_context_md5; @@ -192,6 +194,8 @@ export class ZkWasmUtil { message += params.md5; message += params.circuit_size; message += params.user_address; + message += params.metadata_keys; + message += params.metadata_vals; if (params.reset_context) { message += params.reset_context_md5; } diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index e150be8d..54f506f4 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -48,6 +48,12 @@ export interface VerifierContracts { circuit_size: number; } export type TaskType = "Setup" | "Prove" | "Reset"; +/** + * Image status: + * Received: Server received setup task of the image but haven’t been done successfully. + * Initialized: Server received setup task of the image and it is done successfully. No proof task had been done successfully for this image. + * Verified: At least one of the proof task had been done successfully for the image. + **/ export type ImageStatus = "Received" | "Initialized" | "Verified"; export type TaskStatus = "Pending" | "Processing" | "DryRunFailed" | "Done" | "Fail" | "Stale"; export interface PaginationResult { @@ -62,6 +68,8 @@ export interface BaseAddImageParams { description_url: string; avator_url: string; circuit_size: number; + metadata_keys: string[]; + metadata_vals: string[]; } export interface WithInitialContext { initial_context: unknown; @@ -103,6 +111,8 @@ export interface BaseResetImageParams { md5: string; circuit_size: number; user_address: string; + metadata_keys: string[]; + metadata_vals: string[]; } export interface WithResetContext { reset_context: unknown; @@ -210,6 +220,11 @@ export interface Image { initial_context?: Uint8Array; status: string; checksum: ImageChecksum | null; + metadata: { + values: { + [key: string]: string; + }; + }; } export interface ImageChecksum { x: Uint8Array; diff --git a/src/helper/util.ts b/src/helper/util.ts index 4f8f3f94..3c10a303 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -186,6 +186,8 @@ export class ZkWasmUtil { message += params.description_url; message += params.avator_url; message += params.circuit_size; + message += params.metadata_keys; + message += params.metadata_vals; // Additional params afterwards if (params.initial_context) { message += params.initial_context_md5; @@ -231,6 +233,8 @@ export class ZkWasmUtil { message += params.md5; message += params.circuit_size; message += params.user_address; + message += params.metadata_keys; + message += params.metadata_vals; if (params.reset_context) { message += params.reset_context_md5; } diff --git a/src/interface/interface.ts b/src/interface/interface.ts index 9942ac24..4b32f030 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -84,6 +84,8 @@ export interface BaseAddImageParams { description_url: string; avator_url: string; circuit_size: number; + metadata_keys: string[]; + metadata_vals: string[]; } export interface WithInitialContext { @@ -141,6 +143,8 @@ export interface BaseResetImageParams { md5: string; circuit_size: number; user_address: string; + metadata_keys: string[]; + metadata_vals: string[]; } export interface WithResetContext { @@ -262,6 +266,9 @@ export interface Image { initial_context?: Uint8Array; status: string; checksum: ImageChecksum | null; + metadata : { + values : { [key: string]: string } + }; } export interface ImageChecksum { From 258653d847b64d7e3b9366d5f51b7d361839f845 Mon Sep 17 00:00:00 2001 From: qozymandias Date: Tue, 9 Apr 2024 15:56:04 +1000 Subject: [PATCH 06/36] add types --- dist/cjs/interface/interface.d.ts | 14 ++++++++++++++ dist/cjs/interface/interface.js | 17 ++++++++++++++++- dist/mjs/interface/interface.d.ts | 14 ++++++++++++++ dist/mjs/interface/interface.js | 15 +++++++++++++++ src/interface/interface.ts | 17 +++++++++++++++++ 5 files changed, 76 insertions(+), 1 deletion(-) diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index 92678959..dc19ae04 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -56,6 +56,11 @@ export type TaskType = "Setup" | "Prove" | "Reset"; **/ export type ImageStatus = "Received" | "Initialized" | "Verified"; export type TaskStatus = "Pending" | "Processing" | "DryRunFailed" | "Done" | "Fail" | "Stale"; +export declare enum AutoSubmitStatus { + Queued = "Queued", + InProgress = "InProgress", + Done = "Done" +} export interface PaginationResult { data: T; total: number; @@ -87,11 +92,20 @@ export interface WithoutInitialContext { initial_context_md5?: never; } export type AddImageParams = BaseAddImageParams & (WithInitialContext | WithoutInitialContext); +export declare enum TaskMetadataKeys { + ProofSubmitMode = "ProofSubmitMode" +} +export declare enum TaskMetadataValsProofSubmitMode { + Manual = "Manual", + Auto = "Auto" +} export interface BaseProvingParams { user_address: string; md5: string; public_inputs: Array; private_inputs: Array; + metadata_keys: TaskMetadataKeys[]; + metadata_vals: string[]; } export interface WithCustomInputContextType { input_context_type: InputContextType.Custom; diff --git a/dist/cjs/interface/interface.js b/dist/cjs/interface/interface.js index d25516eb..34a031f2 100644 --- a/dist/cjs/interface/interface.js +++ b/dist/cjs/interface/interface.js @@ -1,12 +1,18 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.InputContextType = void 0; +exports.TaskMetadataValsProofSubmitMode = exports.TaskMetadataKeys = exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.AutoSubmitStatus = exports.InputContextType = void 0; var InputContextType; (function (InputContextType) { InputContextType["Custom"] = "Custom"; InputContextType["ImageInitial"] = "ImageInitial"; InputContextType["ImageCurrent"] = "ImageCurrent"; })(InputContextType = exports.InputContextType || (exports.InputContextType = {})); +var AutoSubmitStatus; +(function (AutoSubmitStatus) { + AutoSubmitStatus["Queued"] = "Queued"; + AutoSubmitStatus["InProgress"] = "InProgress"; + AutoSubmitStatus["Done"] = "Done"; +})(AutoSubmitStatus = exports.AutoSubmitStatus || (exports.AutoSubmitStatus = {})); var ImageMetadataKeys; (function (ImageMetadataKeys) { ImageMetadataKeys["ProvePaymentSrc"] = "ProvePaymentSrc"; @@ -16,3 +22,12 @@ var ImageMetadataValsProvePaymentSrc; ImageMetadataValsProvePaymentSrc["Default"] = "Default"; ImageMetadataValsProvePaymentSrc["CreatorPay"] = "CreatorPay"; })(ImageMetadataValsProvePaymentSrc = exports.ImageMetadataValsProvePaymentSrc || (exports.ImageMetadataValsProvePaymentSrc = {})); +var TaskMetadataKeys; +(function (TaskMetadataKeys) { + TaskMetadataKeys["ProofSubmitMode"] = "ProofSubmitMode"; +})(TaskMetadataKeys = exports.TaskMetadataKeys || (exports.TaskMetadataKeys = {})); +var TaskMetadataValsProofSubmitMode; +(function (TaskMetadataValsProofSubmitMode) { + TaskMetadataValsProofSubmitMode["Manual"] = "Manual"; + TaskMetadataValsProofSubmitMode["Auto"] = "Auto"; +})(TaskMetadataValsProofSubmitMode = exports.TaskMetadataValsProofSubmitMode || (exports.TaskMetadataValsProofSubmitMode = {})); diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index 92678959..dc19ae04 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -56,6 +56,11 @@ export type TaskType = "Setup" | "Prove" | "Reset"; **/ export type ImageStatus = "Received" | "Initialized" | "Verified"; export type TaskStatus = "Pending" | "Processing" | "DryRunFailed" | "Done" | "Fail" | "Stale"; +export declare enum AutoSubmitStatus { + Queued = "Queued", + InProgress = "InProgress", + Done = "Done" +} export interface PaginationResult { data: T; total: number; @@ -87,11 +92,20 @@ export interface WithoutInitialContext { initial_context_md5?: never; } export type AddImageParams = BaseAddImageParams & (WithInitialContext | WithoutInitialContext); +export declare enum TaskMetadataKeys { + ProofSubmitMode = "ProofSubmitMode" +} +export declare enum TaskMetadataValsProofSubmitMode { + Manual = "Manual", + Auto = "Auto" +} export interface BaseProvingParams { user_address: string; md5: string; public_inputs: Array; private_inputs: Array; + metadata_keys: TaskMetadataKeys[]; + metadata_vals: string[]; } export interface WithCustomInputContextType { input_context_type: InputContextType.Custom; diff --git a/dist/mjs/interface/interface.js b/dist/mjs/interface/interface.js index 7cc4ed0b..99350594 100644 --- a/dist/mjs/interface/interface.js +++ b/dist/mjs/interface/interface.js @@ -4,6 +4,12 @@ export var InputContextType; InputContextType["ImageInitial"] = "ImageInitial"; InputContextType["ImageCurrent"] = "ImageCurrent"; })(InputContextType || (InputContextType = {})); +export var AutoSubmitStatus; +(function (AutoSubmitStatus) { + AutoSubmitStatus["Queued"] = "Queued"; + AutoSubmitStatus["InProgress"] = "InProgress"; + AutoSubmitStatus["Done"] = "Done"; +})(AutoSubmitStatus || (AutoSubmitStatus = {})); export var ImageMetadataKeys; (function (ImageMetadataKeys) { ImageMetadataKeys["ProvePaymentSrc"] = "ProvePaymentSrc"; @@ -13,3 +19,12 @@ export var ImageMetadataValsProvePaymentSrc; ImageMetadataValsProvePaymentSrc["Default"] = "Default"; ImageMetadataValsProvePaymentSrc["CreatorPay"] = "CreatorPay"; })(ImageMetadataValsProvePaymentSrc || (ImageMetadataValsProvePaymentSrc = {})); +export var TaskMetadataKeys; +(function (TaskMetadataKeys) { + TaskMetadataKeys["ProofSubmitMode"] = "ProofSubmitMode"; +})(TaskMetadataKeys || (TaskMetadataKeys = {})); +export var TaskMetadataValsProofSubmitMode; +(function (TaskMetadataValsProofSubmitMode) { + TaskMetadataValsProofSubmitMode["Manual"] = "Manual"; + TaskMetadataValsProofSubmitMode["Auto"] = "Auto"; +})(TaskMetadataValsProofSubmitMode || (TaskMetadataValsProofSubmitMode = {})); diff --git a/src/interface/interface.ts b/src/interface/interface.ts index 997ca073..abdcf34d 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -71,6 +71,12 @@ export type TaskStatus = | "Fail" | "Stale"; +export enum AutoSubmitStatus { + Queued = "Queued", + InProgress = "InProgress", + Done = "Done", +} + export interface PaginationResult { data: T; total: number; @@ -110,11 +116,22 @@ export interface WithoutInitialContext { export type AddImageParams = BaseAddImageParams & (WithInitialContext | WithoutInitialContext); +export enum TaskMetadataKeys { + ProofSubmitMode = "ProofSubmitMode", +} + +export enum TaskMetadataValsProofSubmitMode { + Manual = "Manual", + Auto = "Auto", +} + export interface BaseProvingParams { user_address: string; md5: string; public_inputs: Array; private_inputs: Array; + metadata_keys: TaskMetadataKeys[]; + metadata_vals: string[]; } export interface WithCustomInputContextType { From 8c18e3e804a1e5e4405945a68e9cbf0937d6413a Mon Sep 17 00:00:00 2001 From: qozymandias Date: Tue, 9 Apr 2024 17:01:47 +1000 Subject: [PATCH 07/36] fix --- dist/cjs/index.d.ts | 4 ++-- dist/cjs/index.js | 4 +++- dist/mjs/index.d.ts | 4 ++-- dist/mjs/index.js | 4 ++-- src/index.ts | 4 ++++ 5 files changed, 13 insertions(+), 7 deletions(-) diff --git a/dist/cjs/index.d.ts b/dist/cjs/index.d.ts index 089f90c8..24a5650f 100644 --- a/dist/cjs/index.d.ts +++ b/dist/cjs/index.d.ts @@ -1,6 +1,6 @@ -import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc } from "./interface/interface.js"; +import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, }; export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, }; diff --git a/dist/cjs/index.js b/dist/cjs/index.js index a6267fac..a281e72a 100644 --- a/dist/cjs/index.js +++ b/dist/cjs/index.js @@ -1,10 +1,12 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.InputContextType = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; +exports.TaskMetadataValsProofSubmitMode = exports.TaskMetadataKeys = exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.InputContextType = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; const interface_js_1 = require("./interface/interface.js"); Object.defineProperty(exports, "InputContextType", { enumerable: true, get: function () { return interface_js_1.InputContextType; } }); Object.defineProperty(exports, "ImageMetadataKeys", { enumerable: true, get: function () { return interface_js_1.ImageMetadataKeys; } }); Object.defineProperty(exports, "ImageMetadataValsProvePaymentSrc", { enumerable: true, get: function () { return interface_js_1.ImageMetadataValsProvePaymentSrc; } }); +Object.defineProperty(exports, "TaskMetadataKeys", { enumerable: true, get: function () { return interface_js_1.TaskMetadataKeys; } }); +Object.defineProperty(exports, "TaskMetadataValsProofSubmitMode", { enumerable: true, get: function () { return interface_js_1.TaskMetadataValsProofSubmitMode; } }); const util_js_1 = require("./helper/util.js"); Object.defineProperty(exports, "ZkWasmUtil", { enumerable: true, get: function () { return util_js_1.ZkWasmUtil; } }); const endpoint_js_1 = require("./helper/endpoint.js"); diff --git a/dist/mjs/index.d.ts b/dist/mjs/index.d.ts index 089f90c8..24a5650f 100644 --- a/dist/mjs/index.d.ts +++ b/dist/mjs/index.d.ts @@ -1,6 +1,6 @@ -import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc } from "./interface/interface.js"; +import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, }; export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, }; diff --git a/dist/mjs/index.js b/dist/mjs/index.js index b17149ec..e12c756d 100644 --- a/dist/mjs/index.js +++ b/dist/mjs/index.js @@ -1,5 +1,5 @@ -import { InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, } from "./interface/interface.js"; +import { InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, }; diff --git a/src/index.ts b/src/index.ts index b80074b5..a607dc8f 100644 --- a/src/index.ts +++ b/src/index.ts @@ -40,6 +40,8 @@ import { WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, + TaskMetadataKeys, + TaskMetadataValsProofSubmitMode, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; @@ -53,6 +55,8 @@ export { InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, + TaskMetadataKeys, + TaskMetadataValsProofSubmitMode, }; export type { From 955b2f4850f814b42915e9367cc27cb0d5c113fb Mon Sep 17 00:00:00 2001 From: qozymandias Date: Thu, 11 Apr 2024 12:16:55 +1000 Subject: [PATCH 08/36] update message --- dist/cjs/helper/util.js | 2 ++ dist/mjs/helper/util.js | 2 ++ src/helper/util.ts | 3 +++ 3 files changed, 7 insertions(+) diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index c9c5b129..6e3f6831 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -146,6 +146,8 @@ class ZkWasmUtil { for (const input of params.private_inputs) { message += input; } + message += params.metadata_keys; + message += params.metadata_vals; // Only handle input_context if selected input_context_type.Custom if (params.input_context_type === interface_js_1.InputContextType.Custom && params.input_context) { diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index a9c17c3a..8eee8c1d 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -176,6 +176,8 @@ export class ZkWasmUtil { for (const input of params.private_inputs) { message += input; } + message += params.metadata_keys; + message += params.metadata_vals; // Only handle input_context if selected input_context_type.Custom if (params.input_context_type === InputContextType.Custom && params.input_context) { diff --git a/src/helper/util.ts b/src/helper/util.ts index 3c10a303..e7383833 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -210,6 +210,9 @@ export class ZkWasmUtil { message += input; } + message += params.metadata_keys; + message += params.metadata_vals; + // Only handle input_context if selected input_context_type.Custom if ( params.input_context_type === InputContextType.Custom && From 10e2f52e76aa14991a242d092343f2b8dd9e26c9 Mon Sep 17 00:00:00 2001 From: qozymandias Date: Thu, 11 Apr 2024 13:36:49 +1000 Subject: [PATCH 09/36] remove queued --- dist/cjs/interface/interface.d.ts | 1 - dist/cjs/interface/interface.js | 1 - dist/mjs/interface/interface.d.ts | 1 - dist/mjs/interface/interface.js | 1 - src/interface/interface.ts | 1 - 5 files changed, 5 deletions(-) diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index dc19ae04..d453f817 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -57,7 +57,6 @@ export type TaskType = "Setup" | "Prove" | "Reset"; export type ImageStatus = "Received" | "Initialized" | "Verified"; export type TaskStatus = "Pending" | "Processing" | "DryRunFailed" | "Done" | "Fail" | "Stale"; export declare enum AutoSubmitStatus { - Queued = "Queued", InProgress = "InProgress", Done = "Done" } diff --git a/dist/cjs/interface/interface.js b/dist/cjs/interface/interface.js index 34a031f2..6e6df633 100644 --- a/dist/cjs/interface/interface.js +++ b/dist/cjs/interface/interface.js @@ -9,7 +9,6 @@ var InputContextType; })(InputContextType = exports.InputContextType || (exports.InputContextType = {})); var AutoSubmitStatus; (function (AutoSubmitStatus) { - AutoSubmitStatus["Queued"] = "Queued"; AutoSubmitStatus["InProgress"] = "InProgress"; AutoSubmitStatus["Done"] = "Done"; })(AutoSubmitStatus = exports.AutoSubmitStatus || (exports.AutoSubmitStatus = {})); diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index dc19ae04..d453f817 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -57,7 +57,6 @@ export type TaskType = "Setup" | "Prove" | "Reset"; export type ImageStatus = "Received" | "Initialized" | "Verified"; export type TaskStatus = "Pending" | "Processing" | "DryRunFailed" | "Done" | "Fail" | "Stale"; export declare enum AutoSubmitStatus { - Queued = "Queued", InProgress = "InProgress", Done = "Done" } diff --git a/dist/mjs/interface/interface.js b/dist/mjs/interface/interface.js index 99350594..3d1357ba 100644 --- a/dist/mjs/interface/interface.js +++ b/dist/mjs/interface/interface.js @@ -6,7 +6,6 @@ export var InputContextType; })(InputContextType || (InputContextType = {})); export var AutoSubmitStatus; (function (AutoSubmitStatus) { - AutoSubmitStatus["Queued"] = "Queued"; AutoSubmitStatus["InProgress"] = "InProgress"; AutoSubmitStatus["Done"] = "Done"; })(AutoSubmitStatus || (AutoSubmitStatus = {})); diff --git a/src/interface/interface.ts b/src/interface/interface.ts index abdcf34d..f1f7eef9 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -72,7 +72,6 @@ export type TaskStatus = | "Stale"; export enum AutoSubmitStatus { - Queued = "Queued", InProgress = "InProgress", Done = "Done", } From 27e1154076241eaa5449fe2816efbd4a70de9a78 Mon Sep 17 00:00:00 2001 From: Richard Hao Date: Tue, 30 Apr 2024 13:41:46 +1000 Subject: [PATCH 10/36] ZKWAS-257 (#65) * add batch proof types * add initial types and query api * paginated result * update types for metadata + auto submit * refine type * export * fix enum export --- dist/cjs/helper/task.d.ts | 10 ++- dist/cjs/helper/task.js | 30 +++++++ dist/cjs/index.d.ts | 6 +- dist/cjs/index.js | 3 +- dist/cjs/interface/interface.d.ts | 94 +++++++++++++++++++- dist/cjs/interface/interface.js | 21 ++++- dist/mjs/helper/task.d.ts | 10 ++- dist/mjs/helper/task.js | 24 ++++++ dist/mjs/index.d.ts | 6 +- dist/mjs/index.js | 4 +- dist/mjs/interface/interface.d.ts | 94 +++++++++++++++++++- dist/mjs/interface/interface.js | 19 ++++- src/helper/task.ts | 66 +++++++++++++- src/index.ts | 24 ++++++ src/interface/interface.ts | 137 +++++++++++++++++++++++++++--- 15 files changed, 514 insertions(+), 34 deletions(-) diff --git a/dist/cjs/helper/task.d.ts b/dist/cjs/helper/task.d.ts index 7cd2388c..a1cee621 100644 --- a/dist/cjs/helper/task.d.ts +++ b/dist/cjs/helper/task.d.ts @@ -1,4 +1,4 @@ -import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription } from "../interface/interface.js"; +import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, Round1BatchProofQuery, Round2BatchProofQuery, Round2BatchProof, Round1BatchProof, FinalBatchProofQuery, FinalBatchProof } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; export declare class ZkWasmServiceHelper { endpoint: ZkWasmServiceEndpoint; @@ -12,6 +12,9 @@ export declare class ZkWasmServiceHelper { queryConfig(): Promise; loadStatistics(): Promise; loadTasks(query: QueryParams): Promise>; + queryRound1BatchProofs(query: PaginatedQuery): Promise>; + queryRound2BatchProofs(query: PaginatedQuery): Promise>; + queryFinalBatchProofs(query: PaginatedQuery): Promise>; queryLogs(query: WithSignature): Promise; addPayment(payRequest: PaymentParams): Promise; addSubscription(subscription: SubscriptionRequest): Promise; @@ -33,5 +36,8 @@ export declare enum TaskEndpoint { MODIFY = "/modify", PAY = "/pay", SUBSCRIBE = "/subscribe", - LOGS = "/logs" + LOGS = "/logs", + ROUND_1_BATCH = "/round1_batch_proofs", + ROUND_2_BATCH = "/round2_batch_proofs", + FINAL_BATCH = "/final_batch_proofs" } diff --git a/dist/cjs/helper/task.js b/dist/cjs/helper/task.js index 3e45e89d..59fd012a 100644 --- a/dist/cjs/helper/task.js +++ b/dist/cjs/helper/task.js @@ -169,6 +169,33 @@ class ZkWasmServiceHelper { return tasks; }); } + queryRound1BatchProofs(query) { + return __awaiter(this, void 0, void 0, function* () { + let proofData = yield this.endpoint.invokeRequest("GET", TaskEndpoint.ROUND_1_BATCH, JSON.parse(JSON.stringify(query))); + if (this.endpoint.enable_logs) { + console.log("loading proof data!"); + } + return proofData; + }); + } + queryRound2BatchProofs(query) { + return __awaiter(this, void 0, void 0, function* () { + let proofData = yield this.endpoint.invokeRequest("GET", TaskEndpoint.ROUND_2_BATCH, JSON.parse(JSON.stringify(query))); + if (this.endpoint.enable_logs) { + console.log("loading proof data!"); + } + return proofData; + }); + } + queryFinalBatchProofs(query) { + return __awaiter(this, void 0, void 0, function* () { + let proofData = yield this.endpoint.invokeRequest("GET", TaskEndpoint.FINAL_BATCH, JSON.parse(JSON.stringify(query))); + if (this.endpoint.enable_logs) { + console.log("loading proof data!"); + } + return proofData; + }); + } queryLogs(query) { return __awaiter(this, void 0, void 0, function* () { let logs = yield this.sendRequestWithSignature("GET", TaskEndpoint.LOGS, query); @@ -294,4 +321,7 @@ var TaskEndpoint; TaskEndpoint["PAY"] = "/pay"; TaskEndpoint["SUBSCRIBE"] = "/subscribe"; TaskEndpoint["LOGS"] = "/logs"; + TaskEndpoint["ROUND_1_BATCH"] = "/round1_batch_proofs"; + TaskEndpoint["ROUND_2_BATCH"] = "/round2_batch_proofs"; + TaskEndpoint["FINAL_BATCH"] = "/final_batch_proofs"; })(TaskEndpoint = exports.TaskEndpoint || (exports.TaskEndpoint = {})); diff --git a/dist/cjs/index.d.ts b/dist/cjs/index.d.ts index 24a5650f..3ca3808d 100644 --- a/dist/cjs/index.d.ts +++ b/dist/cjs/index.d.ts @@ -1,6 +1,6 @@ -import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode } from "./interface/interface.js"; +import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, TaskMetadata } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, }; -export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, }; +export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, }; diff --git a/dist/cjs/index.js b/dist/cjs/index.js index a281e72a..3eaf1033 100644 --- a/dist/cjs/index.js +++ b/dist/cjs/index.js @@ -1,12 +1,13 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.TaskMetadataValsProofSubmitMode = exports.TaskMetadataKeys = exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.InputContextType = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; +exports.AutoSubmitStatus = exports.TaskMetadataValsProofSubmitMode = exports.TaskMetadataKeys = exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.InputContextType = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; const interface_js_1 = require("./interface/interface.js"); Object.defineProperty(exports, "InputContextType", { enumerable: true, get: function () { return interface_js_1.InputContextType; } }); Object.defineProperty(exports, "ImageMetadataKeys", { enumerable: true, get: function () { return interface_js_1.ImageMetadataKeys; } }); Object.defineProperty(exports, "ImageMetadataValsProvePaymentSrc", { enumerable: true, get: function () { return interface_js_1.ImageMetadataValsProvePaymentSrc; } }); Object.defineProperty(exports, "TaskMetadataKeys", { enumerable: true, get: function () { return interface_js_1.TaskMetadataKeys; } }); Object.defineProperty(exports, "TaskMetadataValsProofSubmitMode", { enumerable: true, get: function () { return interface_js_1.TaskMetadataValsProofSubmitMode; } }); +Object.defineProperty(exports, "AutoSubmitStatus", { enumerable: true, get: function () { return interface_js_1.AutoSubmitStatus; } }); const util_js_1 = require("./helper/util.js"); Object.defineProperty(exports, "ZkWasmUtil", { enumerable: true, get: function () { return util_js_1.ZkWasmUtil; } }); const endpoint_js_1 = require("./helper/endpoint.js"); diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index d453f817..e86f5f52 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -37,6 +37,86 @@ export interface Task { internal_message?: string; task_verification_data: TaskVerificationData; debug_logs?: string; + metadata: TaskMetadata; + auto_submit_status?: AutoSubmitStatus; +} +export interface Round1BatchProof { + _id?: any; + task_id: string; + base_proof_circuit_size: number; + proof: number[]; + batch_instances: number[]; + shadow_instances?: number[]; + aux: number[]; + batch_started?: string; + batch_finished?: string; + internal_message?: string; + static_files_verification_data: StaticFileVerificationData; + status: Round1BatchProofStatus; +} +export interface StaticFileVerificationData { + static_file_checksum: Uint8Array; +} +export declare enum Round1BatchProofStatus { + Pending = "Pending", + Batched = "Batched", + Failed = "Failed" +} +export interface Round2BatchProof { + _id?: any; + round_1_ids: string[]; + task_ids: string[]; + target_instances: number[][]; + proof: number[]; + batch_instances: number[]; + shadow_instances?: number[]; + aux: number[]; + batch_started?: string; + batch_finished?: string; + internal_message?: string; + static_files_verification_data: StaticFileVerificationData; + status: Round2BatchProofStatus; +} +export declare enum Round2BatchProofStatus { + Pending = "Pending", + Batched = "Batched", + Failed = "Failed" +} +export interface FinalBatchProof { + _id?: any; + round_2_ids: string[]; + task_ids: string[]; + target_instances: number[][]; + proof: number[]; + batch_instances: number[]; + shadow_instances?: number[]; + aux: number[]; + batched_time?: string; + internal_message?: string; + static_files_verification_data: StaticFileVerificationData; + verifier_contracts: VerifierContracts[]; +} +export type PaginatedQuery = T & PaginationQuery; +export interface Round1BatchProofQuery { + id?: string; + task_id?: string; + status?: Round1BatchProofStatus; + circuit_size?: number; +} +export interface Round2BatchProofQuery { + id?: string; + task_id?: string; + status?: Round2BatchProofStatus; + circuit_size?: number; +} +export interface FinalBatchProofQuery { + id?: string; + round_2_id?: string; + task_id?: string; +} +export interface PaginationQuery { + total?: number; + start?: number; } export interface TaskVerificationData { static_file_checksum: Uint8Array; @@ -57,9 +137,14 @@ export type TaskType = "Setup" | "Prove" | "Reset"; export type ImageStatus = "Received" | "Initialized" | "Verified"; export type TaskStatus = "Pending" | "Processing" | "DryRunFailed" | "Done" | "Fail" | "Stale"; export declare enum AutoSubmitStatus { - InProgress = "InProgress", - Done = "Done" + Round1 = "Round1", + Round2 = "Round2", + Done = "Done", + Failed = "Failed" } +export type TaskMetadata = { + values: Record; +}; export interface PaginationResult { data: T; total: number; @@ -92,7 +177,10 @@ export interface WithoutInitialContext { } export type AddImageParams = BaseAddImageParams & (WithInitialContext | WithoutInitialContext); export declare enum TaskMetadataKeys { - ProofSubmitMode = "ProofSubmitMode" + ProofSubmitMode = "ProofSubmitMode", + Round1BatchProofId = "Round1BatchProofTaskId", + Round2BatchProofId = "Round2BatchProofTaskId", + FinalBatchProofId = "FinalBatchProofId" } export declare enum TaskMetadataValsProofSubmitMode { Manual = "Manual", diff --git a/dist/cjs/interface/interface.js b/dist/cjs/interface/interface.js index 6e6df633..95e35cc5 100644 --- a/dist/cjs/interface/interface.js +++ b/dist/cjs/interface/interface.js @@ -1,16 +1,30 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.TaskMetadataValsProofSubmitMode = exports.TaskMetadataKeys = exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.AutoSubmitStatus = exports.InputContextType = void 0; +exports.TaskMetadataValsProofSubmitMode = exports.TaskMetadataKeys = exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.AutoSubmitStatus = exports.Round2BatchProofStatus = exports.Round1BatchProofStatus = exports.InputContextType = void 0; var InputContextType; (function (InputContextType) { InputContextType["Custom"] = "Custom"; InputContextType["ImageInitial"] = "ImageInitial"; InputContextType["ImageCurrent"] = "ImageCurrent"; })(InputContextType = exports.InputContextType || (exports.InputContextType = {})); +var Round1BatchProofStatus; +(function (Round1BatchProofStatus) { + Round1BatchProofStatus["Pending"] = "Pending"; + Round1BatchProofStatus["Batched"] = "Batched"; + Round1BatchProofStatus["Failed"] = "Failed"; +})(Round1BatchProofStatus = exports.Round1BatchProofStatus || (exports.Round1BatchProofStatus = {})); +var Round2BatchProofStatus; +(function (Round2BatchProofStatus) { + Round2BatchProofStatus["Pending"] = "Pending"; + Round2BatchProofStatus["Batched"] = "Batched"; + Round2BatchProofStatus["Failed"] = "Failed"; +})(Round2BatchProofStatus = exports.Round2BatchProofStatus || (exports.Round2BatchProofStatus = {})); var AutoSubmitStatus; (function (AutoSubmitStatus) { - AutoSubmitStatus["InProgress"] = "InProgress"; + AutoSubmitStatus["Round1"] = "Round1"; + AutoSubmitStatus["Round2"] = "Round2"; AutoSubmitStatus["Done"] = "Done"; + AutoSubmitStatus["Failed"] = "Failed"; })(AutoSubmitStatus = exports.AutoSubmitStatus || (exports.AutoSubmitStatus = {})); var ImageMetadataKeys; (function (ImageMetadataKeys) { @@ -24,6 +38,9 @@ var ImageMetadataValsProvePaymentSrc; var TaskMetadataKeys; (function (TaskMetadataKeys) { TaskMetadataKeys["ProofSubmitMode"] = "ProofSubmitMode"; + TaskMetadataKeys["Round1BatchProofId"] = "Round1BatchProofTaskId"; + TaskMetadataKeys["Round2BatchProofId"] = "Round2BatchProofTaskId"; + TaskMetadataKeys["FinalBatchProofId"] = "FinalBatchProofId"; })(TaskMetadataKeys = exports.TaskMetadataKeys || (exports.TaskMetadataKeys = {})); var TaskMetadataValsProofSubmitMode; (function (TaskMetadataValsProofSubmitMode) { diff --git a/dist/mjs/helper/task.d.ts b/dist/mjs/helper/task.d.ts index 7cd2388c..a1cee621 100644 --- a/dist/mjs/helper/task.d.ts +++ b/dist/mjs/helper/task.d.ts @@ -1,4 +1,4 @@ -import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription } from "../interface/interface.js"; +import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, Round1BatchProofQuery, Round2BatchProofQuery, Round2BatchProof, Round1BatchProof, FinalBatchProofQuery, FinalBatchProof } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; export declare class ZkWasmServiceHelper { endpoint: ZkWasmServiceEndpoint; @@ -12,6 +12,9 @@ export declare class ZkWasmServiceHelper { queryConfig(): Promise; loadStatistics(): Promise; loadTasks(query: QueryParams): Promise>; + queryRound1BatchProofs(query: PaginatedQuery): Promise>; + queryRound2BatchProofs(query: PaginatedQuery): Promise>; + queryFinalBatchProofs(query: PaginatedQuery): Promise>; queryLogs(query: WithSignature): Promise; addPayment(payRequest: PaymentParams): Promise; addSubscription(subscription: SubscriptionRequest): Promise; @@ -33,5 +36,8 @@ export declare enum TaskEndpoint { MODIFY = "/modify", PAY = "/pay", SUBSCRIBE = "/subscribe", - LOGS = "/logs" + LOGS = "/logs", + ROUND_1_BATCH = "/round1_batch_proofs", + ROUND_2_BATCH = "/round2_batch_proofs", + FINAL_BATCH = "/final_batch_proofs" } diff --git a/dist/mjs/helper/task.js b/dist/mjs/helper/task.js index 9de78440..68046612 100644 --- a/dist/mjs/helper/task.js +++ b/dist/mjs/helper/task.js @@ -126,6 +126,27 @@ export class ZkWasmServiceHelper { } return tasks; } + async queryRound1BatchProofs(query) { + let proofData = await this.endpoint.invokeRequest("GET", TaskEndpoint.ROUND_1_BATCH, JSON.parse(JSON.stringify(query))); + if (this.endpoint.enable_logs) { + console.log("loading proof data!"); + } + return proofData; + } + async queryRound2BatchProofs(query) { + let proofData = await this.endpoint.invokeRequest("GET", TaskEndpoint.ROUND_2_BATCH, JSON.parse(JSON.stringify(query))); + if (this.endpoint.enable_logs) { + console.log("loading proof data!"); + } + return proofData; + } + async queryFinalBatchProofs(query) { + let proofData = await this.endpoint.invokeRequest("GET", TaskEndpoint.FINAL_BATCH, JSON.parse(JSON.stringify(query))); + if (this.endpoint.enable_logs) { + console.log("loading proof data!"); + } + return proofData; + } async queryLogs(query) { let logs = await this.sendRequestWithSignature("GET", TaskEndpoint.LOGS, query); if (this.endpoint.enable_logs) { @@ -232,4 +253,7 @@ export var TaskEndpoint; TaskEndpoint["PAY"] = "/pay"; TaskEndpoint["SUBSCRIBE"] = "/subscribe"; TaskEndpoint["LOGS"] = "/logs"; + TaskEndpoint["ROUND_1_BATCH"] = "/round1_batch_proofs"; + TaskEndpoint["ROUND_2_BATCH"] = "/round2_batch_proofs"; + TaskEndpoint["FINAL_BATCH"] = "/final_batch_proofs"; })(TaskEndpoint || (TaskEndpoint = {})); diff --git a/dist/mjs/index.d.ts b/dist/mjs/index.d.ts index 24a5650f..3ca3808d 100644 --- a/dist/mjs/index.d.ts +++ b/dist/mjs/index.d.ts @@ -1,6 +1,6 @@ -import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode } from "./interface/interface.js"; +import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, TaskMetadata } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, }; -export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, }; +export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, }; diff --git a/dist/mjs/index.js b/dist/mjs/index.js index e12c756d..d0cbeb9d 100644 --- a/dist/mjs/index.js +++ b/dist/mjs/index.js @@ -1,5 +1,5 @@ -import { InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, } from "./interface/interface.js"; +import { InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, }; diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index d453f817..e86f5f52 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -37,6 +37,86 @@ export interface Task { internal_message?: string; task_verification_data: TaskVerificationData; debug_logs?: string; + metadata: TaskMetadata; + auto_submit_status?: AutoSubmitStatus; +} +export interface Round1BatchProof { + _id?: any; + task_id: string; + base_proof_circuit_size: number; + proof: number[]; + batch_instances: number[]; + shadow_instances?: number[]; + aux: number[]; + batch_started?: string; + batch_finished?: string; + internal_message?: string; + static_files_verification_data: StaticFileVerificationData; + status: Round1BatchProofStatus; +} +export interface StaticFileVerificationData { + static_file_checksum: Uint8Array; +} +export declare enum Round1BatchProofStatus { + Pending = "Pending", + Batched = "Batched", + Failed = "Failed" +} +export interface Round2BatchProof { + _id?: any; + round_1_ids: string[]; + task_ids: string[]; + target_instances: number[][]; + proof: number[]; + batch_instances: number[]; + shadow_instances?: number[]; + aux: number[]; + batch_started?: string; + batch_finished?: string; + internal_message?: string; + static_files_verification_data: StaticFileVerificationData; + status: Round2BatchProofStatus; +} +export declare enum Round2BatchProofStatus { + Pending = "Pending", + Batched = "Batched", + Failed = "Failed" +} +export interface FinalBatchProof { + _id?: any; + round_2_ids: string[]; + task_ids: string[]; + target_instances: number[][]; + proof: number[]; + batch_instances: number[]; + shadow_instances?: number[]; + aux: number[]; + batched_time?: string; + internal_message?: string; + static_files_verification_data: StaticFileVerificationData; + verifier_contracts: VerifierContracts[]; +} +export type PaginatedQuery = T & PaginationQuery; +export interface Round1BatchProofQuery { + id?: string; + task_id?: string; + status?: Round1BatchProofStatus; + circuit_size?: number; +} +export interface Round2BatchProofQuery { + id?: string; + task_id?: string; + status?: Round2BatchProofStatus; + circuit_size?: number; +} +export interface FinalBatchProofQuery { + id?: string; + round_2_id?: string; + task_id?: string; +} +export interface PaginationQuery { + total?: number; + start?: number; } export interface TaskVerificationData { static_file_checksum: Uint8Array; @@ -57,9 +137,14 @@ export type TaskType = "Setup" | "Prove" | "Reset"; export type ImageStatus = "Received" | "Initialized" | "Verified"; export type TaskStatus = "Pending" | "Processing" | "DryRunFailed" | "Done" | "Fail" | "Stale"; export declare enum AutoSubmitStatus { - InProgress = "InProgress", - Done = "Done" + Round1 = "Round1", + Round2 = "Round2", + Done = "Done", + Failed = "Failed" } +export type TaskMetadata = { + values: Record; +}; export interface PaginationResult { data: T; total: number; @@ -92,7 +177,10 @@ export interface WithoutInitialContext { } export type AddImageParams = BaseAddImageParams & (WithInitialContext | WithoutInitialContext); export declare enum TaskMetadataKeys { - ProofSubmitMode = "ProofSubmitMode" + ProofSubmitMode = "ProofSubmitMode", + Round1BatchProofId = "Round1BatchProofTaskId", + Round2BatchProofId = "Round2BatchProofTaskId", + FinalBatchProofId = "FinalBatchProofId" } export declare enum TaskMetadataValsProofSubmitMode { Manual = "Manual", diff --git a/dist/mjs/interface/interface.js b/dist/mjs/interface/interface.js index 3d1357ba..d1d2dc3f 100644 --- a/dist/mjs/interface/interface.js +++ b/dist/mjs/interface/interface.js @@ -4,10 +4,24 @@ export var InputContextType; InputContextType["ImageInitial"] = "ImageInitial"; InputContextType["ImageCurrent"] = "ImageCurrent"; })(InputContextType || (InputContextType = {})); +export var Round1BatchProofStatus; +(function (Round1BatchProofStatus) { + Round1BatchProofStatus["Pending"] = "Pending"; + Round1BatchProofStatus["Batched"] = "Batched"; + Round1BatchProofStatus["Failed"] = "Failed"; +})(Round1BatchProofStatus || (Round1BatchProofStatus = {})); +export var Round2BatchProofStatus; +(function (Round2BatchProofStatus) { + Round2BatchProofStatus["Pending"] = "Pending"; + Round2BatchProofStatus["Batched"] = "Batched"; + Round2BatchProofStatus["Failed"] = "Failed"; +})(Round2BatchProofStatus || (Round2BatchProofStatus = {})); export var AutoSubmitStatus; (function (AutoSubmitStatus) { - AutoSubmitStatus["InProgress"] = "InProgress"; + AutoSubmitStatus["Round1"] = "Round1"; + AutoSubmitStatus["Round2"] = "Round2"; AutoSubmitStatus["Done"] = "Done"; + AutoSubmitStatus["Failed"] = "Failed"; })(AutoSubmitStatus || (AutoSubmitStatus = {})); export var ImageMetadataKeys; (function (ImageMetadataKeys) { @@ -21,6 +35,9 @@ export var ImageMetadataValsProvePaymentSrc; export var TaskMetadataKeys; (function (TaskMetadataKeys) { TaskMetadataKeys["ProofSubmitMode"] = "ProofSubmitMode"; + TaskMetadataKeys["Round1BatchProofId"] = "Round1BatchProofTaskId"; + TaskMetadataKeys["Round2BatchProofId"] = "Round2BatchProofTaskId"; + TaskMetadataKeys["FinalBatchProofId"] = "FinalBatchProofId"; })(TaskMetadataKeys || (TaskMetadataKeys = {})); export var TaskMetadataValsProofSubmitMode; (function (TaskMetadataValsProofSubmitMode) { diff --git a/src/helper/task.ts b/src/helper/task.ts index 1aab10e2..0c63f3a5 100644 --- a/src/helper/task.ts +++ b/src/helper/task.ts @@ -23,6 +23,13 @@ import { ERC20DepositInfo, User, Subscription, + PaginatedQuery, + Round1BatchProofQuery, + Round2BatchProofQuery, + Round2BatchProof, + Round1BatchProof, + FinalBatchProofQuery, + FinalBatchProof, } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; import { ethers } from "ethers"; @@ -30,8 +37,18 @@ import { ethers } from "ethers"; export class ZkWasmServiceHelper { endpoint: ZkWasmServiceEndpoint; - constructor(endpoint: string, username: string, useraddress: string, enable_logs : boolean = true) { - this.endpoint = new ZkWasmServiceEndpoint(endpoint, username, useraddress, enable_logs); + constructor( + endpoint: string, + username: string, + useraddress: string, + enable_logs: boolean = true + ) { + this.endpoint = new ZkWasmServiceEndpoint( + endpoint, + username, + useraddress, + enable_logs + ); } async queryImage(md5: string): Promise { @@ -190,6 +207,48 @@ export class ZkWasmServiceHelper { return tasks; } + async queryRound1BatchProofs( + query: PaginatedQuery + ): Promise> { + let proofData = await this.endpoint.invokeRequest( + "GET", + TaskEndpoint.ROUND_1_BATCH, + JSON.parse(JSON.stringify(query)) + ); + if (this.endpoint.enable_logs) { + console.log("loading proof data!"); + } + return proofData; + } + + async queryRound2BatchProofs( + query: PaginatedQuery + ): Promise> { + let proofData = await this.endpoint.invokeRequest( + "GET", + TaskEndpoint.ROUND_2_BATCH, + JSON.parse(JSON.stringify(query)) + ); + if (this.endpoint.enable_logs) { + console.log("loading proof data!"); + } + return proofData; + } + + async queryFinalBatchProofs( + query: PaginatedQuery + ): Promise> { + let proofData = await this.endpoint.invokeRequest( + "GET", + TaskEndpoint.FINAL_BATCH, + JSON.parse(JSON.stringify(query)) + ); + if (this.endpoint.enable_logs) { + console.log("loading proof data!"); + } + return proofData; + } + async queryLogs(query: WithSignature): Promise { let logs = await this.sendRequestWithSignature( "GET", @@ -356,4 +415,7 @@ export enum TaskEndpoint { PAY = "/pay", SUBSCRIBE = "/subscribe", LOGS = "/logs", + ROUND_1_BATCH = "/round1_batch_proofs", + ROUND_2_BATCH = "/round2_batch_proofs", + FINAL_BATCH = "/final_batch_proofs", } diff --git a/src/index.ts b/src/index.ts index a607dc8f..0cff0d02 100644 --- a/src/index.ts +++ b/src/index.ts @@ -42,6 +42,18 @@ import { ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, + Round1BatchProof, + Round2BatchProof, + FinalBatchProof, + Round1BatchProofStatus, + Round2BatchProofStatus, + Round1BatchProofQuery, + Round2BatchProofQuery, + FinalBatchProofQuery, + PaginatedQuery, + PaginationQuery, + AutoSubmitStatus, + TaskMetadata, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; @@ -57,6 +69,7 @@ export { ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, + AutoSubmitStatus, }; export type { @@ -97,4 +110,15 @@ export type { WithoutInitialContext, WithoutInputContextType, WithoutResetContext, + Round1BatchProof, + Round2BatchProof, + FinalBatchProof, + Round1BatchProofStatus, + Round2BatchProofStatus, + Round1BatchProofQuery, + Round2BatchProofQuery, + FinalBatchProofQuery, + PaginatedQuery, + PaginationQuery, + TaskMetadata, }; diff --git a/src/interface/interface.ts b/src/interface/interface.ts index f1f7eef9..1ac545d0 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -40,6 +40,114 @@ export interface Task { internal_message?: string; task_verification_data: TaskVerificationData; debug_logs?: string; + metadata: TaskMetadata; + auto_submit_status?: AutoSubmitStatus; +} + +export interface Round1BatchProof { + _id?: any; + // The task id of the original aggregate proof task + task_id: string; + base_proof_circuit_size: number; + // Proof data which was output from the original aggregate proof task + proof: number[]; + batch_instances: number[]; + shadow_instances?: number[]; + aux: number[]; + batch_started?: string; + batch_finished?: string; + internal_message?: string; + static_files_verification_data: StaticFileVerificationData; + status: Round1BatchProofStatus; +} + +export interface StaticFileVerificationData { + static_file_checksum: Uint8Array; +} + +export enum Round1BatchProofStatus { + Pending = "Pending", + Batched = "Batched", + Failed = "Failed", +} + +// Round2BatchProof is the task for the second round of aggregation +export interface Round2BatchProof { + _id?: any; + // _ids of round 1 batch proofs which will be/are aggregated in this round 2 batch proof + round_1_ids: string[]; + // flattened array of all underlying original aggregate proof task ids which are being aggregated in this round 2 batch proof + task_ids: string[]; + + // target_instances is the original aggregate proofs output batch instances + // it equivalent to each Round1BatchProof.batch_instances + target_instances: number[][]; + + // output of the round 1 batch proof as input to the round 2 batch proof + // Assigned when the Round2BatchProof document is created + proof: number[]; + batch_instances: number[]; + shadow_instances?: number[]; + aux: number[]; + // Extra Info + batch_started?: string; + batch_finished?: string; + internal_message?: string; + static_files_verification_data: StaticFileVerificationData; + status: Round2BatchProofStatus; +} + +export enum Round2BatchProofStatus { + Pending = "Pending", + Batched = "Batched", + Failed = "Failed", +} + +export interface FinalBatchProof { + _id?: any; + // _ids of round 2 id which is aggregated in this final batch proof + round_2_ids: string[]; + task_ids: string[]; + + // target_instances is the original aggregate proofs output batch instances + target_instances: number[][]; + // output of the round 2 batch proofs + proof: number[]; + batch_instances: number[]; + shadow_instances?: number[]; + // Used to generate solidity contract + aux: number[]; + batched_time?: string; + internal_message?: string; + static_files_verification_data: StaticFileVerificationData; + verifier_contracts: VerifierContracts[]; +} + +export type PaginatedQuery = T & PaginationQuery; + +export interface Round1BatchProofQuery { + id?: string; + task_id?: string; + status?: Round1BatchProofStatus; + circuit_size?: number; +} + +export interface Round2BatchProofQuery { + id?: string; + task_id?: string; + status?: Round2BatchProofStatus; + circuit_size?: number; +} + +export interface FinalBatchProofQuery { + id?: string; + round_2_id?: string; + task_id?: string; +} + +export interface PaginationQuery { + total?: number; + start?: number; } export interface TaskVerificationData { @@ -72,22 +180,28 @@ export type TaskStatus = | "Stale"; export enum AutoSubmitStatus { - InProgress = "InProgress", - Done = "Done", + Round1 = "Round1", + Round2 = "Round2", + Done = "Done", + Failed = "Failed", } +export type TaskMetadata = { + values: Record; +}; + export interface PaginationResult { data: T; total: number; } export enum ImageMetadataKeys { - ProvePaymentSrc = "ProvePaymentSrc", + ProvePaymentSrc = "ProvePaymentSrc", } export enum ImageMetadataValsProvePaymentSrc { - Default = "Default", - CreatorPay = "CreatorPay", + Default = "Default", + CreatorPay = "CreatorPay", } export interface BaseAddImageParams { @@ -116,12 +230,15 @@ export type AddImageParams = BaseAddImageParams & (WithInitialContext | WithoutInitialContext); export enum TaskMetadataKeys { - ProofSubmitMode = "ProofSubmitMode", + ProofSubmitMode = "ProofSubmitMode", + Round1BatchProofId = "Round1BatchProofTaskId", + Round2BatchProofId = "Round2BatchProofTaskId", + FinalBatchProofId = "FinalBatchProofId", } export enum TaskMetadataValsProofSubmitMode { - Manual = "Manual", - Auto = "Auto", + Manual = "Manual", + Auto = "Auto", } export interface BaseProvingParams { @@ -291,8 +408,8 @@ export interface Image { initial_context?: Uint8Array; status: string; checksum: ImageChecksum | null; - metadata : { - values : { [key: string]: string } + metadata: { + values: { [key: string]: string }; }; } From 1c42feb8bdf3567a6393932bc7b096552b49d8c0 Mon Sep 17 00:00:00 2001 From: Richard Hao Date: Thu, 9 May 2024 11:01:55 +1000 Subject: [PATCH 11/36] ZKWAS-259 (#67) * add prooftracker/batchverify * export * update * debug * try flatten * send tx * update types * update type for batchverify, update key names * fix exports --- dist/cjs/helper/util.d.ts | 41 ++++++++- dist/cjs/helper/util.js | 115 +++++++++++++++++++++--- dist/cjs/index.d.ts | 6 +- dist/cjs/index.js | 5 +- dist/cjs/interface/interface.d.ts | 22 ++++- dist/cjs/interface/interface.js | 14 ++- dist/mjs/helper/util.d.ts | 41 ++++++++- dist/mjs/helper/util.js | 113 +++++++++++++++++++++--- dist/mjs/index.d.ts | 6 +- dist/mjs/index.js | 4 +- dist/mjs/interface/interface.d.ts | 22 ++++- dist/mjs/interface/interface.js | 12 ++- src/helper/util.ts | 140 +++++++++++++++++++++++++++--- src/index.ts | 8 +- src/interface/interface.ts | 29 ++++++- 15 files changed, 518 insertions(+), 60 deletions(-) diff --git a/dist/cjs/helper/util.d.ts b/dist/cjs/helper/util.d.ts index 71cd68ac..8ef320a5 100644 --- a/dist/cjs/helper/util.d.ts +++ b/dist/cjs/helper/util.d.ts @@ -1,5 +1,5 @@ import BN from "bn.js"; -import { AddImageParams, ProvingParams, DeployParams, ResetImageParams, ModifyImageParams, VerifyProofParams, LogQuery, ContextHexString } from "../interface/interface.js"; +import { AddImageParams, ProvingParams, DeployParams, ResetImageParams, ModifyImageParams, VerifyProofParams, LogQuery, ContextHexString, VerifyBatchProofParams } from "../interface/interface.js"; import { Contract, Signer } from "ethers"; import { DelphinusWalletConnector, DelphinusBrowserConnector } from "web3subscriber/src/provider.js"; export declare class ZkWasmUtil { @@ -29,6 +29,43 @@ export declare class ZkWasmUtil { constant: boolean; })[]; }; + static batch_verifier_contract: { + contract_name: string; + abi: ({ + type: string; + inputs: { + internalType: string; + name: string; + type: string; + }[]; + name?: undefined; + outputs?: undefined; + stateMutability?: undefined; + anonymous?: undefined; + } | { + type: string; + name: string; + inputs: { + internalType: string; + name: string; + type: string; + }[]; + outputs: never[]; + stateMutability: string; + anonymous?: undefined; + } | { + type: string; + name: string; + inputs: { + name: string; + type: string; + indexed: boolean; + }[]; + anonymous: boolean; + outputs?: undefined; + stateMutability?: undefined; + })[]; + }; static hexToBNs(hexString: string): Array; static validateBytesInput(value: string): boolean; static validateI64HexInput(value: string): boolean; @@ -53,6 +90,8 @@ export declare class ZkWasmUtil { static bytesToBigIntArray(data: Uint8Array, chunksize?: number): BigInt[]; static composeVerifyContract(signer: DelphinusBrowserConnector | DelphinusWalletConnector, verifier_addr: string): import("web3subscriber/src/client.js").DelphinusContract | Promise; static verifyProof(verify_contract: Contract, params: VerifyProofParams): Promise; + static composeBatchVerifierContract(signer: DelphinusBrowserConnector | DelphinusWalletConnector, verifier_addr: string): import("web3subscriber/src/client.js").DelphinusContract | Promise; + static verifyBatchedProof(batch_verifier_contract: Contract, params: VerifyBatchProofParams): Promise; static signMessage(message: string, priv_key: string): Promise; static ERC20Contract(contractAddress: string, signer: Signer): Contract; static bytesToJSONString(data: Uint8Array): string; diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index 6e3f6831..d6010eff 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -247,20 +247,39 @@ class ZkWasmUtil { params.instances.forEach((instance) => { instances.push(this.bytesToBigIntArray(instance)); }); - // let instances = this.bytesToBigIntArray(params.instances); - // let args = ZkWasmUtil.parseArgs(params.instances).map((x) => - // x.toString(10) - // ); - // console.log("args are:", args); - // if (args.length == 0) { - // args = ["0x0"]; - // } - // // convert to BigInt array - // let bigIntArgs = args.map((x) => BigInt(x)); let result = yield verify_contract.verify.send(aggregate_proof, shadow_instances, aux, instances); return result; }); } + static composeBatchVerifierContract(signer, verifier_addr) { + return signer.getContractWithSigner(verifier_addr, this.batch_verifier_contract.abi); + } + static verifyBatchedProof(batch_verifier_contract, params) { + return __awaiter(this, void 0, void 0, function* () { + let membership_proof_index = params.membership_proof_index; + let verify_instance = this.bytesToBigIntArray(params.verify_instance); + let sibling_instances = []; + params.sibling_instances.forEach((instance) => { + // + sibling_instances.push(this.bytesToBigIntArray(instance)[0]); + }); + let target_instances = []; + params.target_instances.forEach((instance) => { + target_instances.push(this.bytesToBigIntArray(instance)); + }); + let round_1_shadow_instance = this.bytesToBigIntArray(params.round_1_shadow_instance); + // Add the round 1 shadow instance to the flattened sibling instances as this is the expected input format + // for the contract. (12 round 1 target instances + 1 round 1 shadow instance) + sibling_instances.push(round_1_shadow_instance[0]); + console.log("Verify Batch Proof Inputs"); + console.log("membership_proof_index: ", membership_proof_index); + console.log("verify_instance: ", verify_instance); + console.log("sibling_instances: ", [sibling_instances]); + console.log("target_instances: ", target_instances); + let result = yield batch_verifier_contract.check_verified_proof.send(membership_proof_index, verify_instance, [sibling_instances], target_instances); + return result; + }); + } static signMessage(message, priv_key) { return __awaiter(this, void 0, void 0, function* () { let wallet = new ethers_1.Wallet(priv_key, null); @@ -388,4 +407,80 @@ ZkWasmUtil.contract_abi = { }, ], }; +ZkWasmUtil.batch_verifier_contract = { + contract_name: "ProofTracker", + abi: [ + { + type: "constructor", + inputs: [ + { + internalType: "address", + name: "verifier_address", + type: "address", + }, + ], + }, + { + type: "function", + name: "check_verified_proof", + inputs: [ + { + internalType: "uint256[]", + name: "membership_proof_index", + type: "uint256[]", + }, + { + internalType: "uint256[]", + name: "verify_instance", + type: "uint256[]", + }, + { + internalType: "uint256[][]", + name: "sibling_instances", + type: "uint256[][]", + }, + { + internalType: "uint256[][]", + name: "target_instances", + type: "uint256[][]", + }, + ], + outputs: [], + stateMutability: "view", + }, + { + type: "function", + name: "register_proofs", + inputs: [ + { internalType: "uint256[]", name: "proof", type: "uint256[]" }, + { + internalType: "uint256[]", + name: "verify_instance", + type: "uint256[]", + }, + { internalType: "uint256[]", name: "aux", type: "uint256[]" }, + { + internalType: "uint256[][]", + name: "instances", + type: "uint256[][]", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "set_verifier", + inputs: [{ internalType: "address", name: "vaddr", type: "address" }], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "event", + name: "ProofAck", + inputs: [{ name: "hash", type: "uint256", indexed: false }], + anonymous: false, + }, + ], +}; ZkWasmUtil.MAX_CONTEXT_SIZE = 4096; diff --git a/dist/cjs/index.d.ts b/dist/cjs/index.d.ts index 3ca3808d..692b9afd 100644 --- a/dist/cjs/index.d.ts +++ b/dist/cjs/index.d.ts @@ -1,6 +1,6 @@ -import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, TaskMetadata } from "./interface/interface.js"; +import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, TaskMetadata, VerifyBatchProofParams, FinalProofStatus } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, }; -export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, }; +export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, VerifyBatchProofParams, }; diff --git a/dist/cjs/index.js b/dist/cjs/index.js index 3eaf1033..8c464880 100644 --- a/dist/cjs/index.js +++ b/dist/cjs/index.js @@ -1,13 +1,16 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.AutoSubmitStatus = exports.TaskMetadataValsProofSubmitMode = exports.TaskMetadataKeys = exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.InputContextType = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; +exports.FinalProofStatus = exports.Round2BatchProofStatus = exports.Round1BatchProofStatus = exports.AutoSubmitStatus = exports.TaskMetadataValsProofSubmitMode = exports.TaskMetadataKeys = exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.InputContextType = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; const interface_js_1 = require("./interface/interface.js"); Object.defineProperty(exports, "InputContextType", { enumerable: true, get: function () { return interface_js_1.InputContextType; } }); Object.defineProperty(exports, "ImageMetadataKeys", { enumerable: true, get: function () { return interface_js_1.ImageMetadataKeys; } }); Object.defineProperty(exports, "ImageMetadataValsProvePaymentSrc", { enumerable: true, get: function () { return interface_js_1.ImageMetadataValsProvePaymentSrc; } }); Object.defineProperty(exports, "TaskMetadataKeys", { enumerable: true, get: function () { return interface_js_1.TaskMetadataKeys; } }); Object.defineProperty(exports, "TaskMetadataValsProofSubmitMode", { enumerable: true, get: function () { return interface_js_1.TaskMetadataValsProofSubmitMode; } }); +Object.defineProperty(exports, "Round1BatchProofStatus", { enumerable: true, get: function () { return interface_js_1.Round1BatchProofStatus; } }); +Object.defineProperty(exports, "Round2BatchProofStatus", { enumerable: true, get: function () { return interface_js_1.Round2BatchProofStatus; } }); Object.defineProperty(exports, "AutoSubmitStatus", { enumerable: true, get: function () { return interface_js_1.AutoSubmitStatus; } }); +Object.defineProperty(exports, "FinalProofStatus", { enumerable: true, get: function () { return interface_js_1.FinalProofStatus; } }); const util_js_1 = require("./helper/util.js"); Object.defineProperty(exports, "ZkWasmUtil", { enumerable: true, get: function () { return util_js_1.ZkWasmUtil; } }); const endpoint_js_1 = require("./helper/endpoint.js"); diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index e86f5f52..7766ed85 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -95,6 +95,11 @@ export interface FinalBatchProof { internal_message?: string; static_files_verification_data: StaticFileVerificationData; verifier_contracts: VerifierContracts[]; + status: FinalProofStatus; +} +export declare enum FinalProofStatus { + ProofNotRegistered = "ProofNotRegistered", + ProofRegistered = "ProofRegistered" } export type PaginatedQuery = T & PaginationQuery; export interface Round1BatchProofQuery { @@ -113,6 +118,7 @@ export interface FinalBatchProofQuery { id?: string; round_2_id?: string; task_id?: string; + status?: FinalProofStatus; } export interface PaginationQuery { total?: number; @@ -125,6 +131,7 @@ export interface TaskVerificationData { export interface VerifierContracts { chain_id: number; aggregator_verifier: string; + batch_verifier: string; circuit_size: number; } export type TaskType = "Setup" | "Prove" | "Reset"; @@ -139,7 +146,8 @@ export type TaskStatus = "Pending" | "Processing" | "DryRunFailed" | "Done" | "F export declare enum AutoSubmitStatus { Round1 = "Round1", Round2 = "Round2", - Done = "Done", + Batched = "Batched", + RegisteredProof = "RegisteredProof", Failed = "Failed" } export type TaskMetadata = { @@ -178,8 +186,8 @@ export interface WithoutInitialContext { export type AddImageParams = BaseAddImageParams & (WithInitialContext | WithoutInitialContext); export declare enum TaskMetadataKeys { ProofSubmitMode = "ProofSubmitMode", - Round1BatchProofId = "Round1BatchProofTaskId", - Round2BatchProofId = "Round2BatchProofTaskId", + Round1BatchProofId = "Round1BatchProofId", + Round2BatchProofId = "Round2BatchProofId", FinalBatchProofId = "FinalBatchProofId" } export declare enum TaskMetadataValsProofSubmitMode { @@ -263,6 +271,13 @@ export interface VerifyProofParams { aux: Uint8Array; instances: Array; } +export interface VerifyBatchProofParams { + membership_proof_index: Array; + verify_instance: Uint8Array; + sibling_instances: Array; + round_1_shadow_instance: Uint8Array; + target_instances: Array; +} export interface LogQuery { id: string; user_address: string; @@ -294,6 +309,7 @@ export interface ContractDeployments { aggregator_config_address: string; aggregator_verifier_steps: string[]; aggregator_verifier: string; + batch_verifier: string; static_file_checksum: Uint8Array; } export interface ChainInfo { diff --git a/dist/cjs/interface/interface.js b/dist/cjs/interface/interface.js index 95e35cc5..fc2ec3e2 100644 --- a/dist/cjs/interface/interface.js +++ b/dist/cjs/interface/interface.js @@ -1,6 +1,6 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.TaskMetadataValsProofSubmitMode = exports.TaskMetadataKeys = exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.AutoSubmitStatus = exports.Round2BatchProofStatus = exports.Round1BatchProofStatus = exports.InputContextType = void 0; +exports.TaskMetadataValsProofSubmitMode = exports.TaskMetadataKeys = exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.AutoSubmitStatus = exports.FinalProofStatus = exports.Round2BatchProofStatus = exports.Round1BatchProofStatus = exports.InputContextType = void 0; var InputContextType; (function (InputContextType) { InputContextType["Custom"] = "Custom"; @@ -19,11 +19,17 @@ var Round2BatchProofStatus; Round2BatchProofStatus["Batched"] = "Batched"; Round2BatchProofStatus["Failed"] = "Failed"; })(Round2BatchProofStatus = exports.Round2BatchProofStatus || (exports.Round2BatchProofStatus = {})); +var FinalProofStatus; +(function (FinalProofStatus) { + FinalProofStatus["ProofNotRegistered"] = "ProofNotRegistered"; + FinalProofStatus["ProofRegistered"] = "ProofRegistered"; +})(FinalProofStatus = exports.FinalProofStatus || (exports.FinalProofStatus = {})); var AutoSubmitStatus; (function (AutoSubmitStatus) { AutoSubmitStatus["Round1"] = "Round1"; AutoSubmitStatus["Round2"] = "Round2"; - AutoSubmitStatus["Done"] = "Done"; + AutoSubmitStatus["Batched"] = "Batched"; + AutoSubmitStatus["RegisteredProof"] = "RegisteredProof"; AutoSubmitStatus["Failed"] = "Failed"; })(AutoSubmitStatus = exports.AutoSubmitStatus || (exports.AutoSubmitStatus = {})); var ImageMetadataKeys; @@ -38,8 +44,8 @@ var ImageMetadataValsProvePaymentSrc; var TaskMetadataKeys; (function (TaskMetadataKeys) { TaskMetadataKeys["ProofSubmitMode"] = "ProofSubmitMode"; - TaskMetadataKeys["Round1BatchProofId"] = "Round1BatchProofTaskId"; - TaskMetadataKeys["Round2BatchProofId"] = "Round2BatchProofTaskId"; + TaskMetadataKeys["Round1BatchProofId"] = "Round1BatchProofId"; + TaskMetadataKeys["Round2BatchProofId"] = "Round2BatchProofId"; TaskMetadataKeys["FinalBatchProofId"] = "FinalBatchProofId"; })(TaskMetadataKeys = exports.TaskMetadataKeys || (exports.TaskMetadataKeys = {})); var TaskMetadataValsProofSubmitMode; diff --git a/dist/mjs/helper/util.d.ts b/dist/mjs/helper/util.d.ts index 71cd68ac..8ef320a5 100644 --- a/dist/mjs/helper/util.d.ts +++ b/dist/mjs/helper/util.d.ts @@ -1,5 +1,5 @@ import BN from "bn.js"; -import { AddImageParams, ProvingParams, DeployParams, ResetImageParams, ModifyImageParams, VerifyProofParams, LogQuery, ContextHexString } from "../interface/interface.js"; +import { AddImageParams, ProvingParams, DeployParams, ResetImageParams, ModifyImageParams, VerifyProofParams, LogQuery, ContextHexString, VerifyBatchProofParams } from "../interface/interface.js"; import { Contract, Signer } from "ethers"; import { DelphinusWalletConnector, DelphinusBrowserConnector } from "web3subscriber/src/provider.js"; export declare class ZkWasmUtil { @@ -29,6 +29,43 @@ export declare class ZkWasmUtil { constant: boolean; })[]; }; + static batch_verifier_contract: { + contract_name: string; + abi: ({ + type: string; + inputs: { + internalType: string; + name: string; + type: string; + }[]; + name?: undefined; + outputs?: undefined; + stateMutability?: undefined; + anonymous?: undefined; + } | { + type: string; + name: string; + inputs: { + internalType: string; + name: string; + type: string; + }[]; + outputs: never[]; + stateMutability: string; + anonymous?: undefined; + } | { + type: string; + name: string; + inputs: { + name: string; + type: string; + indexed: boolean; + }[]; + anonymous: boolean; + outputs?: undefined; + stateMutability?: undefined; + })[]; + }; static hexToBNs(hexString: string): Array; static validateBytesInput(value: string): boolean; static validateI64HexInput(value: string): boolean; @@ -53,6 +90,8 @@ export declare class ZkWasmUtil { static bytesToBigIntArray(data: Uint8Array, chunksize?: number): BigInt[]; static composeVerifyContract(signer: DelphinusBrowserConnector | DelphinusWalletConnector, verifier_addr: string): import("web3subscriber/src/client.js").DelphinusContract | Promise; static verifyProof(verify_contract: Contract, params: VerifyProofParams): Promise; + static composeBatchVerifierContract(signer: DelphinusBrowserConnector | DelphinusWalletConnector, verifier_addr: string): import("web3subscriber/src/client.js").DelphinusContract | Promise; + static verifyBatchedProof(batch_verifier_contract: Contract, params: VerifyBatchProofParams): Promise; static signMessage(message: string, priv_key: string): Promise; static ERC20Contract(contractAddress: string, signer: Signer): Contract; static bytesToJSONString(data: Uint8Array): string; diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index 8eee8c1d..9e88c463 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -49,6 +49,82 @@ export class ZkWasmUtil { }, ], }; + static batch_verifier_contract = { + contract_name: "ProofTracker", + abi: [ + { + type: "constructor", + inputs: [ + { + internalType: "address", + name: "verifier_address", + type: "address", + }, + ], + }, + { + type: "function", + name: "check_verified_proof", + inputs: [ + { + internalType: "uint256[]", + name: "membership_proof_index", + type: "uint256[]", + }, + { + internalType: "uint256[]", + name: "verify_instance", + type: "uint256[]", + }, + { + internalType: "uint256[][]", + name: "sibling_instances", + type: "uint256[][]", + }, + { + internalType: "uint256[][]", + name: "target_instances", + type: "uint256[][]", + }, + ], + outputs: [], + stateMutability: "view", + }, + { + type: "function", + name: "register_proofs", + inputs: [ + { internalType: "uint256[]", name: "proof", type: "uint256[]" }, + { + internalType: "uint256[]", + name: "verify_instance", + type: "uint256[]", + }, + { internalType: "uint256[]", name: "aux", type: "uint256[]" }, + { + internalType: "uint256[][]", + name: "instances", + type: "uint256[][]", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "set_verifier", + inputs: [{ internalType: "address", name: "vaddr", type: "address" }], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "event", + name: "ProofAck", + inputs: [{ name: "hash", type: "uint256", indexed: false }], + anonymous: false, + }, + ], + }; static hexToBNs(hexString) { let bytes = new Array(Math.ceil(hexString.length / 16)); for (var i = 0; i < hexString.length; i += 16) { @@ -276,19 +352,36 @@ export class ZkWasmUtil { params.instances.forEach((instance) => { instances.push(this.bytesToBigIntArray(instance)); }); - // let instances = this.bytesToBigIntArray(params.instances); - // let args = ZkWasmUtil.parseArgs(params.instances).map((x) => - // x.toString(10) - // ); - // console.log("args are:", args); - // if (args.length == 0) { - // args = ["0x0"]; - // } - // // convert to BigInt array - // let bigIntArgs = args.map((x) => BigInt(x)); let result = await verify_contract.verify.send(aggregate_proof, shadow_instances, aux, instances); return result; } + static composeBatchVerifierContract(signer, verifier_addr) { + return signer.getContractWithSigner(verifier_addr, this.batch_verifier_contract.abi); + } + static async verifyBatchedProof(batch_verifier_contract, params) { + let membership_proof_index = params.membership_proof_index; + let verify_instance = this.bytesToBigIntArray(params.verify_instance); + let sibling_instances = []; + params.sibling_instances.forEach((instance) => { + // + sibling_instances.push(this.bytesToBigIntArray(instance)[0]); + }); + let target_instances = []; + params.target_instances.forEach((instance) => { + target_instances.push(this.bytesToBigIntArray(instance)); + }); + let round_1_shadow_instance = this.bytesToBigIntArray(params.round_1_shadow_instance); + // Add the round 1 shadow instance to the flattened sibling instances as this is the expected input format + // for the contract. (12 round 1 target instances + 1 round 1 shadow instance) + sibling_instances.push(round_1_shadow_instance[0]); + console.log("Verify Batch Proof Inputs"); + console.log("membership_proof_index: ", membership_proof_index); + console.log("verify_instance: ", verify_instance); + console.log("sibling_instances: ", [sibling_instances]); + console.log("target_instances: ", target_instances); + let result = await batch_verifier_contract.check_verified_proof.send(membership_proof_index, verify_instance, [sibling_instances], target_instances); + return result; + } static async signMessage(message, priv_key) { let wallet = new Wallet(priv_key, null); let signature = await wallet.signMessage(message); diff --git a/dist/mjs/index.d.ts b/dist/mjs/index.d.ts index 3ca3808d..692b9afd 100644 --- a/dist/mjs/index.d.ts +++ b/dist/mjs/index.d.ts @@ -1,6 +1,6 @@ -import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, TaskMetadata } from "./interface/interface.js"; +import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, TaskMetadata, VerifyBatchProofParams, FinalProofStatus } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, }; -export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, }; +export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, VerifyBatchProofParams, }; diff --git a/dist/mjs/index.js b/dist/mjs/index.js index d0cbeb9d..afccec0e 100644 --- a/dist/mjs/index.js +++ b/dist/mjs/index.js @@ -1,5 +1,5 @@ -import { InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, } from "./interface/interface.js"; +import { InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProofStatus, Round2BatchProofStatus, AutoSubmitStatus, FinalProofStatus, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, }; diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index e86f5f52..7766ed85 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -95,6 +95,11 @@ export interface FinalBatchProof { internal_message?: string; static_files_verification_data: StaticFileVerificationData; verifier_contracts: VerifierContracts[]; + status: FinalProofStatus; +} +export declare enum FinalProofStatus { + ProofNotRegistered = "ProofNotRegistered", + ProofRegistered = "ProofRegistered" } export type PaginatedQuery = T & PaginationQuery; export interface Round1BatchProofQuery { @@ -113,6 +118,7 @@ export interface FinalBatchProofQuery { id?: string; round_2_id?: string; task_id?: string; + status?: FinalProofStatus; } export interface PaginationQuery { total?: number; @@ -125,6 +131,7 @@ export interface TaskVerificationData { export interface VerifierContracts { chain_id: number; aggregator_verifier: string; + batch_verifier: string; circuit_size: number; } export type TaskType = "Setup" | "Prove" | "Reset"; @@ -139,7 +146,8 @@ export type TaskStatus = "Pending" | "Processing" | "DryRunFailed" | "Done" | "F export declare enum AutoSubmitStatus { Round1 = "Round1", Round2 = "Round2", - Done = "Done", + Batched = "Batched", + RegisteredProof = "RegisteredProof", Failed = "Failed" } export type TaskMetadata = { @@ -178,8 +186,8 @@ export interface WithoutInitialContext { export type AddImageParams = BaseAddImageParams & (WithInitialContext | WithoutInitialContext); export declare enum TaskMetadataKeys { ProofSubmitMode = "ProofSubmitMode", - Round1BatchProofId = "Round1BatchProofTaskId", - Round2BatchProofId = "Round2BatchProofTaskId", + Round1BatchProofId = "Round1BatchProofId", + Round2BatchProofId = "Round2BatchProofId", FinalBatchProofId = "FinalBatchProofId" } export declare enum TaskMetadataValsProofSubmitMode { @@ -263,6 +271,13 @@ export interface VerifyProofParams { aux: Uint8Array; instances: Array; } +export interface VerifyBatchProofParams { + membership_proof_index: Array; + verify_instance: Uint8Array; + sibling_instances: Array; + round_1_shadow_instance: Uint8Array; + target_instances: Array; +} export interface LogQuery { id: string; user_address: string; @@ -294,6 +309,7 @@ export interface ContractDeployments { aggregator_config_address: string; aggregator_verifier_steps: string[]; aggregator_verifier: string; + batch_verifier: string; static_file_checksum: Uint8Array; } export interface ChainInfo { diff --git a/dist/mjs/interface/interface.js b/dist/mjs/interface/interface.js index d1d2dc3f..f981a028 100644 --- a/dist/mjs/interface/interface.js +++ b/dist/mjs/interface/interface.js @@ -16,11 +16,17 @@ export var Round2BatchProofStatus; Round2BatchProofStatus["Batched"] = "Batched"; Round2BatchProofStatus["Failed"] = "Failed"; })(Round2BatchProofStatus || (Round2BatchProofStatus = {})); +export var FinalProofStatus; +(function (FinalProofStatus) { + FinalProofStatus["ProofNotRegistered"] = "ProofNotRegistered"; + FinalProofStatus["ProofRegistered"] = "ProofRegistered"; +})(FinalProofStatus || (FinalProofStatus = {})); export var AutoSubmitStatus; (function (AutoSubmitStatus) { AutoSubmitStatus["Round1"] = "Round1"; AutoSubmitStatus["Round2"] = "Round2"; - AutoSubmitStatus["Done"] = "Done"; + AutoSubmitStatus["Batched"] = "Batched"; + AutoSubmitStatus["RegisteredProof"] = "RegisteredProof"; AutoSubmitStatus["Failed"] = "Failed"; })(AutoSubmitStatus || (AutoSubmitStatus = {})); export var ImageMetadataKeys; @@ -35,8 +41,8 @@ export var ImageMetadataValsProvePaymentSrc; export var TaskMetadataKeys; (function (TaskMetadataKeys) { TaskMetadataKeys["ProofSubmitMode"] = "ProofSubmitMode"; - TaskMetadataKeys["Round1BatchProofId"] = "Round1BatchProofTaskId"; - TaskMetadataKeys["Round2BatchProofId"] = "Round2BatchProofTaskId"; + TaskMetadataKeys["Round1BatchProofId"] = "Round1BatchProofId"; + TaskMetadataKeys["Round2BatchProofId"] = "Round2BatchProofId"; TaskMetadataKeys["FinalBatchProofId"] = "FinalBatchProofId"; })(TaskMetadataKeys || (TaskMetadataKeys = {})); export var TaskMetadataValsProofSubmitMode; diff --git a/src/helper/util.ts b/src/helper/util.ts index e7383833..b5d3bc6c 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -10,6 +10,7 @@ import { LogQuery, ContextHexString, InputContextType, + VerifyBatchProofParams, } from "../interface/interface.js"; import { Contract, formatUnits, Signer, Wallet } from "ethers"; import { @@ -65,6 +66,83 @@ export class ZkWasmUtil { ], }; + static batch_verifier_contract = { + contract_name: "ProofTracker", + abi: [ + { + type: "constructor", + inputs: [ + { + internalType: "address", + name: "verifier_address", + type: "address", + }, + ], + }, + { + type: "function", + name: "check_verified_proof", + inputs: [ + { + internalType: "uint256[]", + name: "membership_proof_index", + type: "uint256[]", + }, + { + internalType: "uint256[]", + name: "verify_instance", + type: "uint256[]", + }, + { + internalType: "uint256[][]", + name: "sibling_instances", + type: "uint256[][]", + }, + { + internalType: "uint256[][]", + name: "target_instances", + type: "uint256[][]", + }, + ], + outputs: [], + stateMutability: "view", + }, + { + type: "function", + name: "register_proofs", + inputs: [ + { internalType: "uint256[]", name: "proof", type: "uint256[]" }, + { + internalType: "uint256[]", + name: "verify_instance", + type: "uint256[]", + }, + { internalType: "uint256[]", name: "aux", type: "uint256[]" }, + { + internalType: "uint256[][]", + name: "instances", + type: "uint256[][]", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "set_verifier", + inputs: [{ internalType: "address", name: "vaddr", type: "address" }], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "event", + name: "ProofAck", + inputs: [{ name: "hash", type: "uint256", indexed: false }], + anonymous: false, + }, + ], + }; + static hexToBNs(hexString: string): Array { let bytes = new Array(Math.ceil(hexString.length / 16)); for (var i = 0; i < hexString.length; i += 16) { @@ -344,16 +422,6 @@ export class ZkWasmUtil { params.instances.forEach((instance) => { instances.push(this.bytesToBigIntArray(instance)); }); - // let instances = this.bytesToBigIntArray(params.instances); - // let args = ZkWasmUtil.parseArgs(params.instances).map((x) => - // x.toString(10) - // ); - // console.log("args are:", args); - // if (args.length == 0) { - // args = ["0x0"]; - // } - // // convert to BigInt array - // let bigIntArgs = args.map((x) => BigInt(x)); let result = await verify_contract.verify.send( aggregate_proof, @@ -364,6 +432,58 @@ export class ZkWasmUtil { return result; } + static composeBatchVerifierContract( + signer: DelphinusBrowserConnector | DelphinusWalletConnector, + verifier_addr: string + ) { + return signer.getContractWithSigner( + verifier_addr, + this.batch_verifier_contract.abi + ); + } + + static async verifyBatchedProof( + batch_verifier_contract: Contract, + params: VerifyBatchProofParams + ) { + let membership_proof_index = params.membership_proof_index; + let verify_instance = this.bytesToBigIntArray(params.verify_instance); + + let sibling_instances: Array = []; + + params.sibling_instances.forEach((instance) => { + // + sibling_instances.push(this.bytesToBigIntArray(instance)[0]); + }); + + let target_instances: Array = []; + params.target_instances.forEach((instance) => { + target_instances.push(this.bytesToBigIntArray(instance)); + }); + + let round_1_shadow_instance = this.bytesToBigIntArray( + params.round_1_shadow_instance + ); + + // Add the round 1 shadow instance to the flattened sibling instances as this is the expected input format + // for the contract. (12 round 1 target instances + 1 round 1 shadow instance) + sibling_instances.push(round_1_shadow_instance[0]); + + console.log("Verify Batch Proof Inputs"); + console.log("membership_proof_index: ", membership_proof_index); + console.log("verify_instance: ", verify_instance); + console.log("sibling_instances: ", [sibling_instances]); + console.log("target_instances: ", target_instances); + + let result = await batch_verifier_contract.check_verified_proof.send( + membership_proof_index, + verify_instance, + [sibling_instances], + target_instances + ); + return result; + } + static async signMessage(message: string, priv_key: string) { let wallet = new Wallet(priv_key, null); let signature = await wallet.signMessage(message); diff --git a/src/index.ts b/src/index.ts index 0cff0d02..5513e6e4 100644 --- a/src/index.ts +++ b/src/index.ts @@ -54,6 +54,8 @@ import { PaginationQuery, AutoSubmitStatus, TaskMetadata, + VerifyBatchProofParams, + FinalProofStatus, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; @@ -70,6 +72,9 @@ export { TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, + Round1BatchProofStatus, + Round2BatchProofStatus, + FinalProofStatus, }; export type { @@ -113,12 +118,11 @@ export type { Round1BatchProof, Round2BatchProof, FinalBatchProof, - Round1BatchProofStatus, - Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, + VerifyBatchProofParams, }; diff --git a/src/interface/interface.ts b/src/interface/interface.ts index 1ac545d0..39e44832 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -121,6 +121,12 @@ export interface FinalBatchProof { internal_message?: string; static_files_verification_data: StaticFileVerificationData; verifier_contracts: VerifierContracts[]; + status: FinalProofStatus; +} + +export enum FinalProofStatus { + ProofNotRegistered = "ProofNotRegistered", + ProofRegistered = "ProofRegistered", } export type PaginatedQuery = T & PaginationQuery; @@ -143,6 +149,7 @@ export interface FinalBatchProofQuery { id?: string; round_2_id?: string; task_id?: string; + status?: FinalProofStatus; } export interface PaginationQuery { @@ -158,6 +165,7 @@ export interface TaskVerificationData { export interface VerifierContracts { chain_id: number; aggregator_verifier: string; + batch_verifier: string; circuit_size: number; } @@ -182,7 +190,8 @@ export type TaskStatus = export enum AutoSubmitStatus { Round1 = "Round1", Round2 = "Round2", - Done = "Done", + Batched = "Batched", + RegisteredProof = "RegisteredProof", Failed = "Failed", } @@ -231,8 +240,8 @@ export type AddImageParams = BaseAddImageParams & export enum TaskMetadataKeys { ProofSubmitMode = "ProofSubmitMode", - Round1BatchProofId = "Round1BatchProofTaskId", - Round2BatchProofId = "Round2BatchProofTaskId", + Round1BatchProofId = "Round1BatchProofId", + Round2BatchProofId = "Round2BatchProofId", FinalBatchProofId = "FinalBatchProofId", } @@ -331,11 +340,22 @@ export interface QueryParams { export interface VerifyProofParams { aggregate_proof: Uint8Array; shadow_instances: Uint8Array; - aux: Uint8Array; instances: Array; } +export interface VerifyBatchProofParams { + // Should be of length 1 + membership_proof_index: Array; + // Shadow instance of the aggregate proof + verify_instance: Uint8Array; + // Array of length 12, where the entries are (round 1 target instances) + sibling_instances: Array; + round_1_shadow_instance: Uint8Array; + // Single proof instance (base wasm image proof) + target_instances: Array; +} + export interface LogQuery { id: string; user_address: string; @@ -370,6 +390,7 @@ export interface ContractDeployments { aggregator_config_address: string; aggregator_verifier_steps: string[]; aggregator_verifier: string; + batch_verifier: string; static_file_checksum: Uint8Array; } // returned from zkwasm service server From 7773ffaecce4d51161bcd60f8896dff79a152747 Mon Sep 17 00:00:00 2001 From: Richard Hao Date: Mon, 13 May 2024 11:01:54 +1000 Subject: [PATCH 12/36] ZKWAS-261 (#68) * update readme and interfaces * readme * rm dupe --- README.md | 233 +++++++++++++++++++++++++++++- dist/cjs/helper/util.js | 4 +- dist/cjs/interface/interface.d.ts | 2 +- dist/mjs/helper/util.js | 4 +- dist/mjs/interface/interface.d.ts | 2 +- src/helper/util.ts | 4 +- src/interface/interface.ts | 2 +- 7 files changed, 239 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index daf40d23..1065abbe 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,7 @@ like: This example typescript code will add the wasm image to the zkwasm service. -``` +```typescript import { AddImageParams, WithSignature, @@ -74,7 +74,7 @@ let response = await helper.addNewWasmImage(task); This example typescript code will add proving tasks to the zkwasm service. -``` +```typescript import { ProvingParams, WithSignature, @@ -134,11 +134,159 @@ let task: WithSignature = { let response = await helper.addProvingTask(task); ``` +### Verifying a proof + +This example typescript code will verify a proof which utilises Delphinus' web3subscriber library. +You can also do this with `ethers.js` or `web3.js` given the ABI and address of the aggregator verifier contract. +the ABI can be accessed from the `ZkWasmUtil` class. + +```typescript +import { + VerifyProofParams, + ZkWasmUtil, + Task, + VerifyBatchProofParams, +} from "zkwasm-service-helper"; +import { withBrowserConnector } from "web3subscriber/src/client"; +import { DelphinusBrowserConnector } from "web3subscriber/src/provider"; + +async function VerifyProof() { + // Fetch a task from the playground service which contains the proof information + // See the example to build query function to fetch task details + const task: Task = await fetchTaskFromService(); + + await withBrowserConnector(async (connector: DelphinusBrowserConnector) => { + let chainidhex = "0x" + selectedChainId!.toString(16); + await connector.switchNet(chainidhex); + + let contract = await ZkWasmUtil.composeVerifyContract( + connector, + aggregator_verifier_address + ); + + // If the proof has no shadow instances, use the batch instances to try and verify instead. + // Mostly for legacy purposes. + // Proofs submitted with Auto Submit will not be verified using this method. + // See below for an example of verifying a proof which has been batched with the Auto Submitted Proof service. + let verify_instance = + task.shadow_instances.length === 0 + ? task.batch_instances + : task.shadow_instances; + + let proofParams: VerifyProofParams = { + aggregate_proof: task.proof, + shadow_instances: verify_instance, + aux: task.aux, + instances: [task.target_instances], // The target instances are wrapped in an array + }; + + let tx = await ZkWasmUtil.verifyProof( + contract.getEthersContract(), + proofParams + ); + // wait for tx to be mined, can add no. of confirmations as arg + await tx.wait(); + + console.log("transaction:", tx.hash); + }); +} +``` + +### Verifying a batched proof + +This example typescript code will verify a batched proof which utilises Delphinus' web3subscriber library. + +```typescript +import { + VerifyBatchProofParams, + ZkWasmUtil, + Task, + Round2BatchProof, + VerifyBatchProofParams, + AutoSubmitStatus, +} from "zkwasm-service-helper"; +import { withBrowserConnector } from "web3subscriber/src/client"; +import { DelphinusBrowserConnector } from "web3subscriber/src/provider"; + +async function VerifyBatchedProof() { + // Fetch a task from the playground service which contains the proof information + // See the example to build query function to fetch task details + const task: Task = await fetchAutoSubmittedTask(); + + // First we need to ensure that the Batched Round2/Final Proof has been registered on chain by the Auto Submit Service + const isRegistered = + task.auto_submit_status === AutoSubmitStatus.RegisteredProof; + + console.log("Is proof registered:", isRegistered); + // If the final batch proof has not been registered, we should not attempt to verify it as the transaction will fail. + + // We should then fetch the Round 1 Batch Output information given the task id + + const Round1Proof: Round2BatchProof = await fetchRound1Output( + task._id["$oid"] + ); + + // Convert the Number[] into bytes/Uint8Array + const round_1_target_instances: Array = + round_1_output.target_instances.map((x) => { + return new Uint8Array(x); + }); + + // Convert the Number[] into bytes/Uint8Array + const round_1_shadow_instances: Uint8Array = new Uint8Array( + round_1_output.shadow_instances! + ); + + // Find the index of this proof in the round 1 output by comparing task_ids + // This will be used to verify that this proof was included in a particular batch. + // If it does not exist, the verification will fail + const index = round_1_output.task_ids.findIndex( + (id) => id === task._id["$oid"] + ); + + await withBrowserConnector(async (connector: DelphinusBrowserConnector) => { + let chainidhex = "0x" + selectedChainId!.toString(16); + await connector.switchNet(chainidhex); + + let contract = await ZkWasmUtil.composeBatchVerifierContract( + connector, + aggregator_verifier_address + ); + + // The params are as follows: + // membership_proof_index: The index of the proof amongst the sibling instances + // verify_instance: The shadow instances of the initial task + // sibling_instances: The target_instances used in the same round 1 batch proof + // round_1_shadow_instance: The shadow instances of the round 1 batch proof + // target_instances: The target instances of the initial task + + let proof_info: VerifyBatchProofParams = { + membership_proof_index: [BigInt(index)], + verify_instance: task.shadow_instances, + sibling_instances: round_1_target_instances, + round_1_shadow_instance: round_1_shadow_instances, + target_instances: [task.instances], + }; + + let tx = await ZkWasmUtil.verifyBatchedProof( + contract.getEthersContract(), + proofParams + ); + // wait for tx to be mined, can add no. of confirmations as arg + await tx.wait(); + + console.log("transaction:", tx.hash); + }); +} + +verifyBatchedProof(); +``` + ### A example to query task details This example typescript code will query task details: -``` +```typescript import { ZkWasmServiceHelper, ZkWasmUtil, @@ -193,6 +341,85 @@ let helper = new ZkWasmServiceHelper(endpoint, "", ""); ); ``` +### Query Auto Submitted Batch Proofs + +This example typescript code will query task details: + +```typescript +import { + ZkWasmServiceHelper, + ZkWasmUtil, + Round1BatchProof, + Round1BatchProofQuery, + PaginationResult, + PaginatedQuery, + Round1BatchProofStatus, + Round2BatchProofStatus, + Task, +} from "zkwasm-service-helper"; +import BN from "bn.js"; + +const endpoint = ""https://rpc.zkwasmhub.com:8090"; +const taskid = "xxxx" + +let helper = new ZkWasmServiceHelper(endpoint, "", ""); + +// Query the Round 1 Queue to check the status of the first round of batch proofs +let round1QueueQuery: PaginatedQuery = { + task_id: taskid!, // Task id of the task that the batch proof is associated with + id: null, // null can also be empty string "" to ignore fields in the query filter + status: Round1BatchProofStatus.Batched, + circuit_size: null, // null or 22 since all images should be utilizing circuit size 22 +}; +helper.queryRound1BatchProofs(round1QueueQuery).then((res) => { + const response = res as PaginationResult; + const proof: Round1BatchProof = response.data[0]; + console.log("Proof details: "); + console.log(" ", proof); +}).catch((err) => { + console.log("queryRound1BatchProofs Error", err); +}).finally(() => + console.log("Finish queryRound1BatchProofs.") +); + +// Query Round 2 Queue to check the status of the second round of batch proofs +// This also contains the output of Round 1 batch proof items, which will be used as inputs for the Round 2 batch proof +let round2QueueQuery: PaginatedQuery = { + task_id: taskid!, // Find a Round 2 Proof item which contains this task id + id: null, // null can also be empty string "" to ignore fields in the query filter + status: Round2BatchProofStatus.Done, + circuit_size: null, // null or 22 since all images should be utilizing circuit size 22 +}; +helper.queryRound2BatchProofs(round2QueueQuery).then((res) => { + const response = res as PaginationResult; + const proof: Round2BatchProof = response.data[0]; + console.log("Proof details: "); + console.log(" ", proof); +}).catch((err) => { + console.log("queryRound2BatchProofs Error", err); +}).finally(() => + console.log("Finish queryRound2BatchProofs.") +); + +let finalBatchProofQuery: PaginatedQuery = { + task_id: taskid!, + round_2_id: null, // Can also be a round 2 id to find the associated Round 1 outputs. + id: null, // null can also be empty string "" to ignore fields in the query filter + status: FinalProofStatus.ProofRegistered, // ProofRegistered is the status of whether or not the final proof is registered on chain + // Which allows verification of underlying proofs. +}; +helper.queryFinalBatchProofs(round2QueueQuery).then((res) => { + const response = res as PaginationResult; + const proof: FinalBatchProof = response.data[0]; + console.log("Proof details: "); + console.log(" ", proof); +}).catch((err) => { + console.log("queryFinalBatchProofs Error", err); +}).finally(() => + console.log("Finish queryFinalBatchProofs.") +); +``` + ### Notes: md5 is case insensitive when communicate with our zkwasm service diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index d6010eff..b00cfb8b 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -241,13 +241,13 @@ class ZkWasmUtil { static verifyProof(verify_contract, params) { return __awaiter(this, void 0, void 0, function* () { let aggregate_proof = this.bytesToBigIntArray(params.aggregate_proof); - let shadow_instances = this.bytesToBigIntArray(params.shadow_instances); + let verify_instance = this.bytesToBigIntArray(params.verify_instance); let aux = this.bytesToBigIntArray(params.aux); let instances = []; params.instances.forEach((instance) => { instances.push(this.bytesToBigIntArray(instance)); }); - let result = yield verify_contract.verify.send(aggregate_proof, shadow_instances, aux, instances); + let result = yield verify_contract.verify.send(aggregate_proof, verify_instance, aux, instances); return result; }); } diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index 7766ed85..a956f4ec 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -267,7 +267,7 @@ export interface QueryParams { } export interface VerifyProofParams { aggregate_proof: Uint8Array; - shadow_instances: Uint8Array; + verify_instance: Uint8Array; aux: Uint8Array; instances: Array; } diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index 9e88c463..e737ffc0 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -346,13 +346,13 @@ export class ZkWasmUtil { } static async verifyProof(verify_contract, params) { let aggregate_proof = this.bytesToBigIntArray(params.aggregate_proof); - let shadow_instances = this.bytesToBigIntArray(params.shadow_instances); + let verify_instance = this.bytesToBigIntArray(params.verify_instance); let aux = this.bytesToBigIntArray(params.aux); let instances = []; params.instances.forEach((instance) => { instances.push(this.bytesToBigIntArray(instance)); }); - let result = await verify_contract.verify.send(aggregate_proof, shadow_instances, aux, instances); + let result = await verify_contract.verify.send(aggregate_proof, verify_instance, aux, instances); return result; } static composeBatchVerifierContract(signer, verifier_addr) { diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index 7766ed85..a956f4ec 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -267,7 +267,7 @@ export interface QueryParams { } export interface VerifyProofParams { aggregate_proof: Uint8Array; - shadow_instances: Uint8Array; + verify_instance: Uint8Array; aux: Uint8Array; instances: Array; } diff --git a/src/helper/util.ts b/src/helper/util.ts index b5d3bc6c..c79bf189 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -416,7 +416,7 @@ export class ZkWasmUtil { params: VerifyProofParams ) { let aggregate_proof = this.bytesToBigIntArray(params.aggregate_proof); - let shadow_instances = this.bytesToBigIntArray(params.shadow_instances); + let verify_instance = this.bytesToBigIntArray(params.verify_instance); let aux = this.bytesToBigIntArray(params.aux); let instances: Array = []; params.instances.forEach((instance) => { @@ -425,7 +425,7 @@ export class ZkWasmUtil { let result = await verify_contract.verify.send( aggregate_proof, - shadow_instances, + verify_instance, aux, instances ); diff --git a/src/interface/interface.ts b/src/interface/interface.ts index 39e44832..b38ad550 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -339,7 +339,7 @@ export interface QueryParams { export interface VerifyProofParams { aggregate_proof: Uint8Array; - shadow_instances: Uint8Array; + verify_instance: Uint8Array; aux: Uint8Array; instances: Array; } From b94be82ce22e5fd9a26765bfe706cf45e0f47935 Mon Sep 17 00:00:00 2001 From: Oscar Downing Date: Tue, 14 May 2024 12:41:23 +0530 Subject: [PATCH 13/36] ZKWAS-264: auto submit networks selection options (#69) --- dist/cjs/helper/util.js | 24 ++++++++++++++++++------ dist/cjs/interface/interface.d.ts | 3 ++- dist/cjs/interface/interface.js | 1 + dist/mjs/helper/util.js | 24 ++++++++++++++++++------ dist/mjs/interface/interface.d.ts | 3 ++- dist/mjs/interface/interface.js | 1 + src/helper/util.ts | 28 ++++++++++++++++++++++------ src/interface/interface.ts | 1 + 8 files changed, 65 insertions(+), 20 deletions(-) diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index b00cfb8b..8e82a538 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -126,8 +126,12 @@ class ZkWasmUtil { message += params.description_url; message += params.avator_url; message += params.circuit_size; - message += params.metadata_keys; - message += params.metadata_vals; + for (const key of params.metadata_keys) { + message += key; + } + for (const val of params.metadata_vals) { + message += val; + } // Additional params afterwards if (params.initial_context) { message += params.initial_context_md5; @@ -146,8 +150,12 @@ class ZkWasmUtil { for (const input of params.private_inputs) { message += input; } - message += params.metadata_keys; - message += params.metadata_vals; + for (const key of params.metadata_keys) { + message += key; + } + for (const val of params.metadata_vals) { + message += val; + } // Only handle input_context if selected input_context_type.Custom if (params.input_context_type === interface_js_1.InputContextType.Custom && params.input_context) { @@ -166,8 +174,12 @@ class ZkWasmUtil { message += params.md5; message += params.circuit_size; message += params.user_address; - message += params.metadata_keys; - message += params.metadata_vals; + for (const key of params.metadata_keys) { + message += key; + } + for (const val of params.metadata_vals) { + message += val; + } if (params.reset_context) { message += params.reset_context_md5; } diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index a956f4ec..de002d9d 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -158,7 +158,8 @@ export interface PaginationResult { total: number; } export declare enum ImageMetadataKeys { - ProvePaymentSrc = "ProvePaymentSrc" + ProvePaymentSrc = "ProvePaymentSrc", + AutoSubmitNetworks = "AutoSubmitNetworks" } export declare enum ImageMetadataValsProvePaymentSrc { Default = "Default", diff --git a/dist/cjs/interface/interface.js b/dist/cjs/interface/interface.js index fc2ec3e2..5252e26b 100644 --- a/dist/cjs/interface/interface.js +++ b/dist/cjs/interface/interface.js @@ -35,6 +35,7 @@ var AutoSubmitStatus; var ImageMetadataKeys; (function (ImageMetadataKeys) { ImageMetadataKeys["ProvePaymentSrc"] = "ProvePaymentSrc"; + ImageMetadataKeys["AutoSubmitNetworks"] = "AutoSubmitNetworks"; })(ImageMetadataKeys = exports.ImageMetadataKeys || (exports.ImageMetadataKeys = {})); var ImageMetadataValsProvePaymentSrc; (function (ImageMetadataValsProvePaymentSrc) { diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index e737ffc0..ee4d31fb 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -232,8 +232,12 @@ export class ZkWasmUtil { message += params.description_url; message += params.avator_url; message += params.circuit_size; - message += params.metadata_keys; - message += params.metadata_vals; + for (const key of params.metadata_keys) { + message += key; + } + for (const val of params.metadata_vals) { + message += val; + } // Additional params afterwards if (params.initial_context) { message += params.initial_context_md5; @@ -252,8 +256,12 @@ export class ZkWasmUtil { for (const input of params.private_inputs) { message += input; } - message += params.metadata_keys; - message += params.metadata_vals; + for (const key of params.metadata_keys) { + message += key; + } + for (const val of params.metadata_vals) { + message += val; + } // Only handle input_context if selected input_context_type.Custom if (params.input_context_type === InputContextType.Custom && params.input_context) { @@ -272,8 +280,12 @@ export class ZkWasmUtil { message += params.md5; message += params.circuit_size; message += params.user_address; - message += params.metadata_keys; - message += params.metadata_vals; + for (const key of params.metadata_keys) { + message += key; + } + for (const val of params.metadata_vals) { + message += val; + } if (params.reset_context) { message += params.reset_context_md5; } diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index a956f4ec..de002d9d 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -158,7 +158,8 @@ export interface PaginationResult { total: number; } export declare enum ImageMetadataKeys { - ProvePaymentSrc = "ProvePaymentSrc" + ProvePaymentSrc = "ProvePaymentSrc", + AutoSubmitNetworks = "AutoSubmitNetworks" } export declare enum ImageMetadataValsProvePaymentSrc { Default = "Default", diff --git a/dist/mjs/interface/interface.js b/dist/mjs/interface/interface.js index f981a028..a912814e 100644 --- a/dist/mjs/interface/interface.js +++ b/dist/mjs/interface/interface.js @@ -32,6 +32,7 @@ export var AutoSubmitStatus; export var ImageMetadataKeys; (function (ImageMetadataKeys) { ImageMetadataKeys["ProvePaymentSrc"] = "ProvePaymentSrc"; + ImageMetadataKeys["AutoSubmitNetworks"] = "AutoSubmitNetworks"; })(ImageMetadataKeys || (ImageMetadataKeys = {})); export var ImageMetadataValsProvePaymentSrc; (function (ImageMetadataValsProvePaymentSrc) { diff --git a/src/helper/util.ts b/src/helper/util.ts index c79bf189..52ebcfa5 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -264,8 +264,14 @@ export class ZkWasmUtil { message += params.description_url; message += params.avator_url; message += params.circuit_size; - message += params.metadata_keys; - message += params.metadata_vals; + + for (const key of params.metadata_keys) { + message += key; + } + for (const val of params.metadata_vals) { + message += val; + } + // Additional params afterwards if (params.initial_context) { message += params.initial_context_md5; @@ -288,8 +294,12 @@ export class ZkWasmUtil { message += input; } - message += params.metadata_keys; - message += params.metadata_vals; + for (const key of params.metadata_keys) { + message += key; + } + for (const val of params.metadata_vals) { + message += val; + } // Only handle input_context if selected input_context_type.Custom if ( @@ -314,8 +324,14 @@ export class ZkWasmUtil { message += params.md5; message += params.circuit_size; message += params.user_address; - message += params.metadata_keys; - message += params.metadata_vals; + + for (const key of params.metadata_keys) { + message += key; + } + for (const val of params.metadata_vals) { + message += val; + } + if (params.reset_context) { message += params.reset_context_md5; } diff --git a/src/interface/interface.ts b/src/interface/interface.ts index b38ad550..49888bb6 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -206,6 +206,7 @@ export interface PaginationResult { export enum ImageMetadataKeys { ProvePaymentSrc = "ProvePaymentSrc", + AutoSubmitNetworks = "AutoSubmitNetworks", } export enum ImageMetadataValsProvePaymentSrc { From 909ccc901d667bb645e106af1f3dde087998bbeb Mon Sep 17 00:00:00 2001 From: Oscar Downing Date: Mon, 20 May 2024 11:25:08 +0530 Subject: [PATCH 14/36] ZKWAS-266: add new fee for auto submit proof (#70) --- dist/cjs/interface/interface.d.ts | 1 + dist/mjs/interface/interface.d.ts | 1 + src/interface/interface.ts | 1 + 3 files changed, 3 insertions(+) diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index de002d9d..701e06a8 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -295,6 +295,7 @@ export interface AppConfig { task_fee_list: { setup_fee: string; prove_fee: string; + auto_submit_prove_fee_per_network: string; }; chain_info_list: Array; latest_server_checksum: Uint8Array; diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index de002d9d..701e06a8 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -295,6 +295,7 @@ export interface AppConfig { task_fee_list: { setup_fee: string; prove_fee: string; + auto_submit_prove_fee_per_network: string; }; chain_info_list: Array; latest_server_checksum: Uint8Array; diff --git a/src/interface/interface.ts b/src/interface/interface.ts index 49888bb6..39c15290 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -375,6 +375,7 @@ export interface AppConfig { task_fee_list: { setup_fee: string; prove_fee: string; + auto_submit_prove_fee_per_network: string; }; chain_info_list: Array; latest_server_checksum: Uint8Array; From dddeaad7c30f3b1a801cd1c8bc03c64f0a284b48 Mon Sep 17 00:00:00 2001 From: Richard Hao Date: Wed, 22 May 2024 22:06:09 +1000 Subject: [PATCH 15/36] ZKWAS-263 (#71) * update types * add chain id to query * auto submit networks in config * metadata type for batch data --- dist/cjs/index.d.ts | 4 ++-- dist/cjs/interface/interface.d.ts | 15 ++++++++++++++- dist/mjs/index.d.ts | 4 ++-- dist/mjs/interface/interface.d.ts | 15 ++++++++++++++- src/index.ts | 2 ++ src/interface/interface.ts | 16 +++++++++++++++- 6 files changed, 49 insertions(+), 7 deletions(-) diff --git a/dist/cjs/index.d.ts b/dist/cjs/index.d.ts index 692b9afd..3e6be830 100644 --- a/dist/cjs/index.d.ts +++ b/dist/cjs/index.d.ts @@ -1,6 +1,6 @@ -import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, TaskMetadata, VerifyBatchProofParams, FinalProofStatus } from "./interface/interface.js"; +import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, TaskMetadata, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, }; -export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, VerifyBatchProofParams, }; +export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index 701e06a8..e5c9ab0d 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -40,6 +40,10 @@ export interface Task { metadata: TaskMetadata; auto_submit_status?: AutoSubmitStatus; } +export interface AutoSubmitBatchMetadata { + chain_id: number; + id: string; +} export interface Round1BatchProof { _id?: any; task_id: string; @@ -52,6 +56,7 @@ export interface Round1BatchProof { batch_finished?: string; internal_message?: string; static_files_verification_data: StaticFileVerificationData; + auto_submit_network_chain_id: number; status: Round1BatchProofStatus; } export interface StaticFileVerificationData { @@ -74,6 +79,8 @@ export interface Round2BatchProof { batch_started?: string; batch_finished?: string; internal_message?: string; + auto_submit_network_chain_id: number; + verifier_contracts: VerifierContracts; static_files_verification_data: StaticFileVerificationData; status: Round2BatchProofStatus; } @@ -94,7 +101,9 @@ export interface FinalBatchProof { batched_time?: string; internal_message?: string; static_files_verification_data: StaticFileVerificationData; - verifier_contracts: VerifierContracts[]; + auto_submit_network_chain_id: number; + verifier_contracts: VerifierContracts; + registered_tx_hash: string | null; status: FinalProofStatus; } export declare enum FinalProofStatus { @@ -107,18 +116,21 @@ export interface Round1BatchProofQuery { task_id?: string; status?: Round1BatchProofStatus; circuit_size?: number; + chain_id?: number; } export interface Round2BatchProofQuery { id?: string; task_id?: string; status?: Round2BatchProofStatus; circuit_size?: number; + chain_id?: number; } export interface FinalBatchProofQuery { id?: string; round_2_id?: string; task_id?: string; status?: FinalProofStatus; + chain_id?: number; } export interface PaginationQuery { total?: number; @@ -303,6 +315,7 @@ export interface AppConfig { topup_token_data: TokenData; deployments: ContractDeployments[]; subscription_plans: SubscriptionParams[]; + supported_auto_submit_network_ids: number[]; } export interface ContractDeployments { chain_id: number; diff --git a/dist/mjs/index.d.ts b/dist/mjs/index.d.ts index 692b9afd..3e6be830 100644 --- a/dist/mjs/index.d.ts +++ b/dist/mjs/index.d.ts @@ -1,6 +1,6 @@ -import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, TaskMetadata, VerifyBatchProofParams, FinalProofStatus } from "./interface/interface.js"; +import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, TaskMetadata, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, }; -export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, VerifyBatchProofParams, }; +export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index 701e06a8..e5c9ab0d 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -40,6 +40,10 @@ export interface Task { metadata: TaskMetadata; auto_submit_status?: AutoSubmitStatus; } +export interface AutoSubmitBatchMetadata { + chain_id: number; + id: string; +} export interface Round1BatchProof { _id?: any; task_id: string; @@ -52,6 +56,7 @@ export interface Round1BatchProof { batch_finished?: string; internal_message?: string; static_files_verification_data: StaticFileVerificationData; + auto_submit_network_chain_id: number; status: Round1BatchProofStatus; } export interface StaticFileVerificationData { @@ -74,6 +79,8 @@ export interface Round2BatchProof { batch_started?: string; batch_finished?: string; internal_message?: string; + auto_submit_network_chain_id: number; + verifier_contracts: VerifierContracts; static_files_verification_data: StaticFileVerificationData; status: Round2BatchProofStatus; } @@ -94,7 +101,9 @@ export interface FinalBatchProof { batched_time?: string; internal_message?: string; static_files_verification_data: StaticFileVerificationData; - verifier_contracts: VerifierContracts[]; + auto_submit_network_chain_id: number; + verifier_contracts: VerifierContracts; + registered_tx_hash: string | null; status: FinalProofStatus; } export declare enum FinalProofStatus { @@ -107,18 +116,21 @@ export interface Round1BatchProofQuery { task_id?: string; status?: Round1BatchProofStatus; circuit_size?: number; + chain_id?: number; } export interface Round2BatchProofQuery { id?: string; task_id?: string; status?: Round2BatchProofStatus; circuit_size?: number; + chain_id?: number; } export interface FinalBatchProofQuery { id?: string; round_2_id?: string; task_id?: string; status?: FinalProofStatus; + chain_id?: number; } export interface PaginationQuery { total?: number; @@ -303,6 +315,7 @@ export interface AppConfig { topup_token_data: TokenData; deployments: ContractDeployments[]; subscription_plans: SubscriptionParams[]; + supported_auto_submit_network_ids: number[]; } export interface ContractDeployments { chain_id: number; diff --git a/src/index.ts b/src/index.ts index 5513e6e4..da820ff8 100644 --- a/src/index.ts +++ b/src/index.ts @@ -56,6 +56,7 @@ import { TaskMetadata, VerifyBatchProofParams, FinalProofStatus, + AutoSubmitBatchMetadata, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; @@ -125,4 +126,5 @@ export type { PaginationQuery, TaskMetadata, VerifyBatchProofParams, + AutoSubmitBatchMetadata, }; diff --git a/src/interface/interface.ts b/src/interface/interface.ts index 39c15290..e18b6e54 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -44,6 +44,11 @@ export interface Task { auto_submit_status?: AutoSubmitStatus; } +export interface AutoSubmitBatchMetadata { + chain_id: number; + id: string; +} + export interface Round1BatchProof { _id?: any; // The task id of the original aggregate proof task @@ -58,6 +63,7 @@ export interface Round1BatchProof { batch_finished?: string; internal_message?: string; static_files_verification_data: StaticFileVerificationData; + auto_submit_network_chain_id: number; status: Round1BatchProofStatus; } @@ -93,6 +99,8 @@ export interface Round2BatchProof { batch_started?: string; batch_finished?: string; internal_message?: string; + auto_submit_network_chain_id: number; + verifier_contracts: VerifierContracts; static_files_verification_data: StaticFileVerificationData; status: Round2BatchProofStatus; } @@ -120,7 +128,9 @@ export interface FinalBatchProof { batched_time?: string; internal_message?: string; static_files_verification_data: StaticFileVerificationData; - verifier_contracts: VerifierContracts[]; + auto_submit_network_chain_id: number; + verifier_contracts: VerifierContracts; + registered_tx_hash: string | null; status: FinalProofStatus; } @@ -136,6 +146,7 @@ export interface Round1BatchProofQuery { task_id?: string; status?: Round1BatchProofStatus; circuit_size?: number; + chain_id?: number; } export interface Round2BatchProofQuery { @@ -143,6 +154,7 @@ export interface Round2BatchProofQuery { task_id?: string; status?: Round2BatchProofStatus; circuit_size?: number; + chain_id?: number; } export interface FinalBatchProofQuery { @@ -150,6 +162,7 @@ export interface FinalBatchProofQuery { round_2_id?: string; task_id?: string; status?: FinalProofStatus; + chain_id?: number; } export interface PaginationQuery { @@ -383,6 +396,7 @@ export interface AppConfig { topup_token_data: TokenData; deployments: ContractDeployments[]; subscription_plans: SubscriptionParams[]; + supported_auto_submit_network_ids: number[]; } export interface ContractDeployments { From 935f758301a5253c64c1fb5ccb825c67dc8cf1db Mon Sep 17 00:00:00 2001 From: Richard Hao Date: Fri, 24 May 2024 20:01:24 +1000 Subject: [PATCH 16/36] ZKWAS-270 (#72) * rework metadata into fields * image interface update * update --- dist/cjs/helper/util.js | 25 ++++++----------- dist/cjs/index.d.ts | 6 ++--- dist/cjs/index.js | 8 +++--- dist/cjs/interface/interface.d.ts | 43 +++++++++++------------------ dist/cjs/interface/interface.js | 34 ++++++++--------------- dist/mjs/helper/util.js | 25 ++++++----------- dist/mjs/index.d.ts | 6 ++--- dist/mjs/index.js | 4 +-- dist/mjs/interface/interface.d.ts | 43 +++++++++++------------------ dist/mjs/interface/interface.js | 32 +++++++--------------- src/helper/util.ts | 27 +++++++------------ src/index.ts | 15 +++-------- src/interface/interface.ts | 45 ++++++++++++------------------- 13 files changed, 110 insertions(+), 203 deletions(-) diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index 8e82a538..2e92e340 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -126,16 +126,14 @@ class ZkWasmUtil { message += params.description_url; message += params.avator_url; message += params.circuit_size; - for (const key of params.metadata_keys) { - message += key; - } - for (const val of params.metadata_vals) { - message += val; - } // Additional params afterwards if (params.initial_context) { message += params.initial_context_md5; } + message += params.prove_payment_src; + for (const chainId of params.auto_submit_network_ids) { + message += chainId; + } return message; } static createProvingSignMessage(params) { @@ -150,12 +148,7 @@ class ZkWasmUtil { for (const input of params.private_inputs) { message += input; } - for (const key of params.metadata_keys) { - message += key; - } - for (const val of params.metadata_vals) { - message += val; - } + message += params.proof_submit_mode; // Only handle input_context if selected input_context_type.Custom if (params.input_context_type === interface_js_1.InputContextType.Custom && params.input_context) { @@ -174,11 +167,9 @@ class ZkWasmUtil { message += params.md5; message += params.circuit_size; message += params.user_address; - for (const key of params.metadata_keys) { - message += key; - } - for (const val of params.metadata_vals) { - message += val; + message += params.prove_payment_src; + for (const chainId of params.auto_submit_network_ids) { + message += chainId; } if (params.reset_context) { message += params.reset_context_md5; diff --git a/dist/cjs/index.d.ts b/dist/cjs/index.d.ts index 3e6be830..9f6f193e 100644 --- a/dist/cjs/index.d.ts +++ b/dist/cjs/index.d.ts @@ -1,6 +1,6 @@ -import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, TaskMetadata, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata } from "./interface/interface.js"; +import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, }; -export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; +export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; diff --git a/dist/cjs/index.js b/dist/cjs/index.js index 8c464880..f42348d1 100644 --- a/dist/cjs/index.js +++ b/dist/cjs/index.js @@ -1,16 +1,14 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.FinalProofStatus = exports.Round2BatchProofStatus = exports.Round1BatchProofStatus = exports.AutoSubmitStatus = exports.TaskMetadataValsProofSubmitMode = exports.TaskMetadataKeys = exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.InputContextType = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; +exports.ProvePaymentSrc = exports.ProofSubmitMode = exports.FinalProofStatus = exports.Round2BatchProofStatus = exports.Round1BatchProofStatus = exports.AutoSubmitStatus = exports.InputContextType = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; const interface_js_1 = require("./interface/interface.js"); Object.defineProperty(exports, "InputContextType", { enumerable: true, get: function () { return interface_js_1.InputContextType; } }); -Object.defineProperty(exports, "ImageMetadataKeys", { enumerable: true, get: function () { return interface_js_1.ImageMetadataKeys; } }); -Object.defineProperty(exports, "ImageMetadataValsProvePaymentSrc", { enumerable: true, get: function () { return interface_js_1.ImageMetadataValsProvePaymentSrc; } }); -Object.defineProperty(exports, "TaskMetadataKeys", { enumerable: true, get: function () { return interface_js_1.TaskMetadataKeys; } }); -Object.defineProperty(exports, "TaskMetadataValsProofSubmitMode", { enumerable: true, get: function () { return interface_js_1.TaskMetadataValsProofSubmitMode; } }); Object.defineProperty(exports, "Round1BatchProofStatus", { enumerable: true, get: function () { return interface_js_1.Round1BatchProofStatus; } }); Object.defineProperty(exports, "Round2BatchProofStatus", { enumerable: true, get: function () { return interface_js_1.Round2BatchProofStatus; } }); Object.defineProperty(exports, "AutoSubmitStatus", { enumerable: true, get: function () { return interface_js_1.AutoSubmitStatus; } }); Object.defineProperty(exports, "FinalProofStatus", { enumerable: true, get: function () { return interface_js_1.FinalProofStatus; } }); +Object.defineProperty(exports, "ProofSubmitMode", { enumerable: true, get: function () { return interface_js_1.ProofSubmitMode; } }); +Object.defineProperty(exports, "ProvePaymentSrc", { enumerable: true, get: function () { return interface_js_1.ProvePaymentSrc; } }); const util_js_1 = require("./helper/util.js"); Object.defineProperty(exports, "ZkWasmUtil", { enumerable: true, get: function () { return util_js_1.ZkWasmUtil; } }); const endpoint_js_1 = require("./helper/endpoint.js"); diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index e5c9ab0d..16aa6de3 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -37,13 +37,19 @@ export interface Task { internal_message?: string; task_verification_data: TaskVerificationData; debug_logs?: string; - metadata: TaskMetadata; + proof_submit_mode?: ProofSubmitMode; + batch_proof_data?: BatchProofData; auto_submit_status?: AutoSubmitStatus; } export interface AutoSubmitBatchMetadata { chain_id: number; id: string; } +export interface BatchProofData { + round_1_batch_ids?: AutoSubmitBatchMetadata[]; + round_2_batch_ids?: AutoSubmitBatchMetadata[]; + final_proof_batch_ids?: AutoSubmitBatchMetadata[]; +} export interface Round1BatchProof { _id?: any; task_id: string; @@ -162,18 +168,11 @@ export declare enum AutoSubmitStatus { RegisteredProof = "RegisteredProof", Failed = "Failed" } -export type TaskMetadata = { - values: Record; -}; export interface PaginationResult { data: T; total: number; } -export declare enum ImageMetadataKeys { - ProvePaymentSrc = "ProvePaymentSrc", - AutoSubmitNetworks = "AutoSubmitNetworks" -} -export declare enum ImageMetadataValsProvePaymentSrc { +export declare enum ProvePaymentSrc { Default = "Default", CreatorPay = "CreatorPay" } @@ -185,8 +184,8 @@ export interface BaseAddImageParams { description_url: string; avator_url: string; circuit_size: number; - metadata_keys: ImageMetadataKeys[]; - metadata_vals: string[]; + prove_payment_src: ProvePaymentSrc; + auto_submit_network_ids: number[]; } export interface WithInitialContext { initial_context: unknown; @@ -197,13 +196,7 @@ export interface WithoutInitialContext { initial_context_md5?: never; } export type AddImageParams = BaseAddImageParams & (WithInitialContext | WithoutInitialContext); -export declare enum TaskMetadataKeys { - ProofSubmitMode = "ProofSubmitMode", - Round1BatchProofId = "Round1BatchProofId", - Round2BatchProofId = "Round2BatchProofId", - FinalBatchProofId = "FinalBatchProofId" -} -export declare enum TaskMetadataValsProofSubmitMode { +export declare enum ProofSubmitMode { Manual = "Manual", Auto = "Auto" } @@ -212,8 +205,7 @@ export interface BaseProvingParams { md5: string; public_inputs: Array; private_inputs: Array; - metadata_keys: TaskMetadataKeys[]; - metadata_vals: string[]; + proof_submit_mode: ProofSubmitMode; } export interface WithCustomInputContextType { input_context_type: InputContextType.Custom; @@ -240,8 +232,8 @@ export interface BaseResetImageParams { md5: string; circuit_size: number; user_address: string; - metadata_keys: ImageMetadataKeys[]; - metadata_vals: string[]; + prove_payment_src: ProvePaymentSrc; + auto_submit_network_ids: number[]; } export interface WithResetContext { reset_context: unknown; @@ -359,11 +351,8 @@ export interface Image { initial_context?: Uint8Array; status: string; checksum: ImageChecksum | null; - metadata: { - values: { - [key: string]: string; - }; - }; + prove_payment_src: ProvePaymentSrc; + auto_submit_network_ids: number[]; } export interface ImageChecksum { x: Uint8Array; diff --git a/dist/cjs/interface/interface.js b/dist/cjs/interface/interface.js index 5252e26b..196d61ed 100644 --- a/dist/cjs/interface/interface.js +++ b/dist/cjs/interface/interface.js @@ -1,6 +1,6 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.TaskMetadataValsProofSubmitMode = exports.TaskMetadataKeys = exports.ImageMetadataValsProvePaymentSrc = exports.ImageMetadataKeys = exports.AutoSubmitStatus = exports.FinalProofStatus = exports.Round2BatchProofStatus = exports.Round1BatchProofStatus = exports.InputContextType = void 0; +exports.ProofSubmitMode = exports.ProvePaymentSrc = exports.AutoSubmitStatus = exports.FinalProofStatus = exports.Round2BatchProofStatus = exports.Round1BatchProofStatus = exports.InputContextType = void 0; var InputContextType; (function (InputContextType) { InputContextType["Custom"] = "Custom"; @@ -32,25 +32,13 @@ var AutoSubmitStatus; AutoSubmitStatus["RegisteredProof"] = "RegisteredProof"; AutoSubmitStatus["Failed"] = "Failed"; })(AutoSubmitStatus = exports.AutoSubmitStatus || (exports.AutoSubmitStatus = {})); -var ImageMetadataKeys; -(function (ImageMetadataKeys) { - ImageMetadataKeys["ProvePaymentSrc"] = "ProvePaymentSrc"; - ImageMetadataKeys["AutoSubmitNetworks"] = "AutoSubmitNetworks"; -})(ImageMetadataKeys = exports.ImageMetadataKeys || (exports.ImageMetadataKeys = {})); -var ImageMetadataValsProvePaymentSrc; -(function (ImageMetadataValsProvePaymentSrc) { - ImageMetadataValsProvePaymentSrc["Default"] = "Default"; - ImageMetadataValsProvePaymentSrc["CreatorPay"] = "CreatorPay"; -})(ImageMetadataValsProvePaymentSrc = exports.ImageMetadataValsProvePaymentSrc || (exports.ImageMetadataValsProvePaymentSrc = {})); -var TaskMetadataKeys; -(function (TaskMetadataKeys) { - TaskMetadataKeys["ProofSubmitMode"] = "ProofSubmitMode"; - TaskMetadataKeys["Round1BatchProofId"] = "Round1BatchProofId"; - TaskMetadataKeys["Round2BatchProofId"] = "Round2BatchProofId"; - TaskMetadataKeys["FinalBatchProofId"] = "FinalBatchProofId"; -})(TaskMetadataKeys = exports.TaskMetadataKeys || (exports.TaskMetadataKeys = {})); -var TaskMetadataValsProofSubmitMode; -(function (TaskMetadataValsProofSubmitMode) { - TaskMetadataValsProofSubmitMode["Manual"] = "Manual"; - TaskMetadataValsProofSubmitMode["Auto"] = "Auto"; -})(TaskMetadataValsProofSubmitMode = exports.TaskMetadataValsProofSubmitMode || (exports.TaskMetadataValsProofSubmitMode = {})); +var ProvePaymentSrc; +(function (ProvePaymentSrc) { + ProvePaymentSrc["Default"] = "Default"; + ProvePaymentSrc["CreatorPay"] = "CreatorPay"; +})(ProvePaymentSrc = exports.ProvePaymentSrc || (exports.ProvePaymentSrc = {})); +var ProofSubmitMode; +(function (ProofSubmitMode) { + ProofSubmitMode["Manual"] = "Manual"; + ProofSubmitMode["Auto"] = "Auto"; +})(ProofSubmitMode = exports.ProofSubmitMode || (exports.ProofSubmitMode = {})); diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index ee4d31fb..ec132978 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -232,16 +232,14 @@ export class ZkWasmUtil { message += params.description_url; message += params.avator_url; message += params.circuit_size; - for (const key of params.metadata_keys) { - message += key; - } - for (const val of params.metadata_vals) { - message += val; - } // Additional params afterwards if (params.initial_context) { message += params.initial_context_md5; } + message += params.prove_payment_src; + for (const chainId of params.auto_submit_network_ids) { + message += chainId; + } return message; } static createProvingSignMessage(params) { @@ -256,12 +254,7 @@ export class ZkWasmUtil { for (const input of params.private_inputs) { message += input; } - for (const key of params.metadata_keys) { - message += key; - } - for (const val of params.metadata_vals) { - message += val; - } + message += params.proof_submit_mode; // Only handle input_context if selected input_context_type.Custom if (params.input_context_type === InputContextType.Custom && params.input_context) { @@ -280,11 +273,9 @@ export class ZkWasmUtil { message += params.md5; message += params.circuit_size; message += params.user_address; - for (const key of params.metadata_keys) { - message += key; - } - for (const val of params.metadata_vals) { - message += val; + message += params.prove_payment_src; + for (const chainId of params.auto_submit_network_ids) { + message += chainId; } if (params.reset_context) { message += params.reset_context_md5; diff --git a/dist/mjs/index.d.ts b/dist/mjs/index.d.ts index 3e6be830..9f6f193e 100644 --- a/dist/mjs/index.d.ts +++ b/dist/mjs/index.d.ts @@ -1,6 +1,6 @@ -import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, TaskMetadata, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata } from "./interface/interface.js"; +import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, }; -export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, TaskMetadata, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; +export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; diff --git a/dist/mjs/index.js b/dist/mjs/index.js index afccec0e..34af54c7 100644 --- a/dist/mjs/index.js +++ b/dist/mjs/index.js @@ -1,5 +1,5 @@ -import { InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, Round1BatchProofStatus, Round2BatchProofStatus, AutoSubmitStatus, FinalProofStatus, } from "./interface/interface.js"; +import { InputContextType, Round1BatchProofStatus, Round2BatchProofStatus, AutoSubmitStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, ImageMetadataKeys, ImageMetadataValsProvePaymentSrc, TaskMetadataKeys, TaskMetadataValsProofSubmitMode, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index e5c9ab0d..16aa6de3 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -37,13 +37,19 @@ export interface Task { internal_message?: string; task_verification_data: TaskVerificationData; debug_logs?: string; - metadata: TaskMetadata; + proof_submit_mode?: ProofSubmitMode; + batch_proof_data?: BatchProofData; auto_submit_status?: AutoSubmitStatus; } export interface AutoSubmitBatchMetadata { chain_id: number; id: string; } +export interface BatchProofData { + round_1_batch_ids?: AutoSubmitBatchMetadata[]; + round_2_batch_ids?: AutoSubmitBatchMetadata[]; + final_proof_batch_ids?: AutoSubmitBatchMetadata[]; +} export interface Round1BatchProof { _id?: any; task_id: string; @@ -162,18 +168,11 @@ export declare enum AutoSubmitStatus { RegisteredProof = "RegisteredProof", Failed = "Failed" } -export type TaskMetadata = { - values: Record; -}; export interface PaginationResult { data: T; total: number; } -export declare enum ImageMetadataKeys { - ProvePaymentSrc = "ProvePaymentSrc", - AutoSubmitNetworks = "AutoSubmitNetworks" -} -export declare enum ImageMetadataValsProvePaymentSrc { +export declare enum ProvePaymentSrc { Default = "Default", CreatorPay = "CreatorPay" } @@ -185,8 +184,8 @@ export interface BaseAddImageParams { description_url: string; avator_url: string; circuit_size: number; - metadata_keys: ImageMetadataKeys[]; - metadata_vals: string[]; + prove_payment_src: ProvePaymentSrc; + auto_submit_network_ids: number[]; } export interface WithInitialContext { initial_context: unknown; @@ -197,13 +196,7 @@ export interface WithoutInitialContext { initial_context_md5?: never; } export type AddImageParams = BaseAddImageParams & (WithInitialContext | WithoutInitialContext); -export declare enum TaskMetadataKeys { - ProofSubmitMode = "ProofSubmitMode", - Round1BatchProofId = "Round1BatchProofId", - Round2BatchProofId = "Round2BatchProofId", - FinalBatchProofId = "FinalBatchProofId" -} -export declare enum TaskMetadataValsProofSubmitMode { +export declare enum ProofSubmitMode { Manual = "Manual", Auto = "Auto" } @@ -212,8 +205,7 @@ export interface BaseProvingParams { md5: string; public_inputs: Array; private_inputs: Array; - metadata_keys: TaskMetadataKeys[]; - metadata_vals: string[]; + proof_submit_mode: ProofSubmitMode; } export interface WithCustomInputContextType { input_context_type: InputContextType.Custom; @@ -240,8 +232,8 @@ export interface BaseResetImageParams { md5: string; circuit_size: number; user_address: string; - metadata_keys: ImageMetadataKeys[]; - metadata_vals: string[]; + prove_payment_src: ProvePaymentSrc; + auto_submit_network_ids: number[]; } export interface WithResetContext { reset_context: unknown; @@ -359,11 +351,8 @@ export interface Image { initial_context?: Uint8Array; status: string; checksum: ImageChecksum | null; - metadata: { - values: { - [key: string]: string; - }; - }; + prove_payment_src: ProvePaymentSrc; + auto_submit_network_ids: number[]; } export interface ImageChecksum { x: Uint8Array; diff --git a/dist/mjs/interface/interface.js b/dist/mjs/interface/interface.js index a912814e..3b813b8b 100644 --- a/dist/mjs/interface/interface.js +++ b/dist/mjs/interface/interface.js @@ -29,25 +29,13 @@ export var AutoSubmitStatus; AutoSubmitStatus["RegisteredProof"] = "RegisteredProof"; AutoSubmitStatus["Failed"] = "Failed"; })(AutoSubmitStatus || (AutoSubmitStatus = {})); -export var ImageMetadataKeys; -(function (ImageMetadataKeys) { - ImageMetadataKeys["ProvePaymentSrc"] = "ProvePaymentSrc"; - ImageMetadataKeys["AutoSubmitNetworks"] = "AutoSubmitNetworks"; -})(ImageMetadataKeys || (ImageMetadataKeys = {})); -export var ImageMetadataValsProvePaymentSrc; -(function (ImageMetadataValsProvePaymentSrc) { - ImageMetadataValsProvePaymentSrc["Default"] = "Default"; - ImageMetadataValsProvePaymentSrc["CreatorPay"] = "CreatorPay"; -})(ImageMetadataValsProvePaymentSrc || (ImageMetadataValsProvePaymentSrc = {})); -export var TaskMetadataKeys; -(function (TaskMetadataKeys) { - TaskMetadataKeys["ProofSubmitMode"] = "ProofSubmitMode"; - TaskMetadataKeys["Round1BatchProofId"] = "Round1BatchProofId"; - TaskMetadataKeys["Round2BatchProofId"] = "Round2BatchProofId"; - TaskMetadataKeys["FinalBatchProofId"] = "FinalBatchProofId"; -})(TaskMetadataKeys || (TaskMetadataKeys = {})); -export var TaskMetadataValsProofSubmitMode; -(function (TaskMetadataValsProofSubmitMode) { - TaskMetadataValsProofSubmitMode["Manual"] = "Manual"; - TaskMetadataValsProofSubmitMode["Auto"] = "Auto"; -})(TaskMetadataValsProofSubmitMode || (TaskMetadataValsProofSubmitMode = {})); +export var ProvePaymentSrc; +(function (ProvePaymentSrc) { + ProvePaymentSrc["Default"] = "Default"; + ProvePaymentSrc["CreatorPay"] = "CreatorPay"; +})(ProvePaymentSrc || (ProvePaymentSrc = {})); +export var ProofSubmitMode; +(function (ProofSubmitMode) { + ProofSubmitMode["Manual"] = "Manual"; + ProofSubmitMode["Auto"] = "Auto"; +})(ProofSubmitMode || (ProofSubmitMode = {})); diff --git a/src/helper/util.ts b/src/helper/util.ts index 52ebcfa5..d598bb17 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -265,17 +265,15 @@ export class ZkWasmUtil { message += params.avator_url; message += params.circuit_size; - for (const key of params.metadata_keys) { - message += key; - } - for (const val of params.metadata_vals) { - message += val; - } - // Additional params afterwards if (params.initial_context) { message += params.initial_context_md5; } + + message += params.prove_payment_src; + for (const chainId of params.auto_submit_network_ids) { + message += chainId; + } return message; } @@ -294,12 +292,7 @@ export class ZkWasmUtil { message += input; } - for (const key of params.metadata_keys) { - message += key; - } - for (const val of params.metadata_vals) { - message += val; - } + message += params.proof_submit_mode; // Only handle input_context if selected input_context_type.Custom if ( @@ -325,11 +318,9 @@ export class ZkWasmUtil { message += params.circuit_size; message += params.user_address; - for (const key of params.metadata_keys) { - message += key; - } - for (const val of params.metadata_vals) { - message += val; + message += params.prove_payment_src; + for (const chainId of params.auto_submit_network_ids) { + message += chainId; } if (params.reset_context) { diff --git a/src/index.ts b/src/index.ts index da820ff8..7b47f874 100644 --- a/src/index.ts +++ b/src/index.ts @@ -14,7 +14,6 @@ import { User, UserQueryParams, PaymentParams, - SubscriptionDuration, SubscriptionParams, Subscription, SubscriptionType, @@ -38,10 +37,6 @@ import { WithoutInitialContext, WithoutInputContextType, WithoutResetContext, - ImageMetadataKeys, - ImageMetadataValsProvePaymentSrc, - TaskMetadataKeys, - TaskMetadataValsProofSubmitMode, Round1BatchProof, Round2BatchProof, FinalBatchProof, @@ -53,10 +48,11 @@ import { PaginatedQuery, PaginationQuery, AutoSubmitStatus, - TaskMetadata, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, + ProofSubmitMode, + ProvePaymentSrc, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; @@ -68,14 +64,12 @@ export { ZkWasmServiceHelper, ZkWasmUtil, InputContextType, - ImageMetadataKeys, - ImageMetadataValsProvePaymentSrc, - TaskMetadataKeys, - TaskMetadataValsProofSubmitMode, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, + ProofSubmitMode, + ProvePaymentSrc, }; export type { @@ -124,7 +118,6 @@ export type { FinalBatchProofQuery, PaginatedQuery, PaginationQuery, - TaskMetadata, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; diff --git a/src/interface/interface.ts b/src/interface/interface.ts index e18b6e54..e05fd25e 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -40,7 +40,8 @@ export interface Task { internal_message?: string; task_verification_data: TaskVerificationData; debug_logs?: string; - metadata: TaskMetadata; + proof_submit_mode?: ProofSubmitMode; + batch_proof_data?: BatchProofData; auto_submit_status?: AutoSubmitStatus; } @@ -49,6 +50,12 @@ export interface AutoSubmitBatchMetadata { id: string; } +export interface BatchProofData { + round_1_batch_ids?: AutoSubmitBatchMetadata[]; + round_2_batch_ids?: AutoSubmitBatchMetadata[]; + final_proof_batch_ids?: AutoSubmitBatchMetadata[]; +} + export interface Round1BatchProof { _id?: any; // The task id of the original aggregate proof task @@ -208,21 +215,12 @@ export enum AutoSubmitStatus { Failed = "Failed", } -export type TaskMetadata = { - values: Record; -}; - export interface PaginationResult { data: T; total: number; } -export enum ImageMetadataKeys { - ProvePaymentSrc = "ProvePaymentSrc", - AutoSubmitNetworks = "AutoSubmitNetworks", -} - -export enum ImageMetadataValsProvePaymentSrc { +export enum ProvePaymentSrc { Default = "Default", CreatorPay = "CreatorPay", } @@ -235,8 +233,8 @@ export interface BaseAddImageParams { description_url: string; avator_url: string; circuit_size: number; - metadata_keys: ImageMetadataKeys[]; - metadata_vals: string[]; + prove_payment_src: ProvePaymentSrc; + auto_submit_network_ids: number[]; } export interface WithInitialContext { @@ -252,14 +250,7 @@ export interface WithoutInitialContext { export type AddImageParams = BaseAddImageParams & (WithInitialContext | WithoutInitialContext); -export enum TaskMetadataKeys { - ProofSubmitMode = "ProofSubmitMode", - Round1BatchProofId = "Round1BatchProofId", - Round2BatchProofId = "Round2BatchProofId", - FinalBatchProofId = "FinalBatchProofId", -} - -export enum TaskMetadataValsProofSubmitMode { +export enum ProofSubmitMode { Manual = "Manual", Auto = "Auto", } @@ -269,8 +260,7 @@ export interface BaseProvingParams { md5: string; public_inputs: Array; private_inputs: Array; - metadata_keys: TaskMetadataKeys[]; - metadata_vals: string[]; + proof_submit_mode: ProofSubmitMode; } export interface WithCustomInputContextType { @@ -308,8 +298,8 @@ export interface BaseResetImageParams { md5: string; circuit_size: number; user_address: string; - metadata_keys: ImageMetadataKeys[]; - metadata_vals: string[]; + prove_payment_src: ProvePaymentSrc; + auto_submit_network_ids: number[]; } export interface WithResetContext { @@ -445,9 +435,8 @@ export interface Image { initial_context?: Uint8Array; status: string; checksum: ImageChecksum | null; - metadata: { - values: { [key: string]: string }; - }; + prove_payment_src: ProvePaymentSrc; + auto_submit_network_ids: number[]; } export interface ImageChecksum { From 4d610955b8dbb7ae75d47fc616e0cbd9a0e6e916 Mon Sep 17 00:00:00 2001 From: Richard Hao Date: Fri, 24 May 2024 21:27:46 +1000 Subject: [PATCH 17/36] update readme (#74) * update readme * update --- README.md | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 1065abbe..174d6b84 100644 --- a/README.md +++ b/README.md @@ -25,7 +25,8 @@ import { AddImageParams, WithSignature, ZkWasmUtil, - zkWasmServiceHelper + zkWasmServiceHelper, + ProvePaymentSrc, } from "zkwasm-service-helper"; const endpoint = ""https://rpc.zkwasmhub.com:8090"; @@ -44,6 +45,15 @@ let info: AddImageParams = { description_url: "", avator_url: "", circuit_size: circuitSize, + + // Determines whether the credits will be deducted from the user supplying proof requests (default) or the user who created the image + // Currently Enum values are Default and CreatorPay + prove_payment_src: ProvePaymentSrc.Default, + + // Networks which the auto submit service will batch and submit the proof to. + // Unsupported networks will be rejected. + // If empty array, Auto Submitted proofs will be rejected. + auto_submit_network_ids: [97, 1, 11155111] }; // Optional Initial Context information @@ -92,11 +102,17 @@ let helper = new ZkWasmServiceHelper(endpoint, "", ""); let pb_inputs: Array = helper.parseProvingTaskInput(public_inputs); let priv_inputs: Array = helper.parseProvingTaskInput(private_inputs); +// Use the helper Enum type to determine the proof submit mode +let proofSubmitMode = ProofSubmitMode.Auto ? ProofSubmitMode.Auto : ProofSubmitMode.Manual; + let info: ProvingParams = { user_address: user_addr.toLowerCase(), md5: image_md5, public_inputs: pb_inputs, private_inputs: priv_inputs, + // Whether the proof will be batched and verified through the auto submit service or manually submitted. + // If the field is not specified, the default value will be ProofSubmitMode.Manual and the proof will not be batched. + proof_submit_mode: proofSubmitMode, }; // Context type for proof task. If none provided, will default to InputContextType.ImageCurrent in the server and use the image's current context From bed7505d8465150eb3b5dc54cc81e2c17c28f892 Mon Sep 17 00:00:00 2001 From: yymone Date: Fri, 31 May 2024 16:32:10 +1000 Subject: [PATCH 18/36] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 174d6b84..2fc6d212 100644 --- a/README.md +++ b/README.md @@ -25,7 +25,7 @@ import { AddImageParams, WithSignature, ZkWasmUtil, - zkWasmServiceHelper, + ZkWasmServiceHelper, ProvePaymentSrc, } from "zkwasm-service-helper"; @@ -89,7 +89,7 @@ import { ProvingParams, WithSignature, ZkWasmUtil, - zkWasmServiceHelper + ZkWasmServiceHelper } from "zkwasm-service-helper"; const endpoint = ""https://rpc.zkwasmhub.com:8090"; From 6432ff57da5151541a8843c7a0547a26b93e7a16 Mon Sep 17 00:00:00 2001 From: akayi07 Date: Sun, 2 Jun 2024 05:54:31 +0800 Subject: [PATCH 19/36] add import assertions to mjs --- addhybridpackage.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/addhybridpackage.sh b/addhybridpackage.sh index 0be1f33d..2dfb6c13 100644 --- a/addhybridpackage.sh +++ b/addhybridpackage.sh @@ -22,4 +22,7 @@ find src -name '*.d.ts' -exec cp {} dist/cjs \; mkdir -p dist/cjs/abi mkdir -p dist/mjs/abi find src/abi -name '*.json' -exec cp {} dist/cjs/abi \; -find src/abi -name '*.json' -exec cp {} dist/mjs/abi \; \ No newline at end of file +find src/abi -name '*.json' -exec cp {} dist/mjs/abi \; + +# add import assertions to mjs +sed -i 's/import ERC20 from \"..\/abi\/ERC20.json\"/import ERC20 from \"..\/abi\/ERC20.json\" assert { type: \"json\" }/g' dist/mjs/helper/util.js From d1dea9daad7a0a90d4b5fdba254685c6013f2a0e Mon Sep 17 00:00:00 2001 From: Richard Hao Date: Mon, 3 Jun 2024 17:07:25 +1000 Subject: [PATCH 20/36] ZKWAS-283 (#76) * add reduced task * add user addr * separate endpoint * rename --- dist/cjs/helper/task.d.ts | 3 +- dist/cjs/helper/task.js | 46 ++++++++++++++++++++++++ dist/cjs/index.d.ts | 4 +-- dist/cjs/interface/interface.d.ts | 12 +++++++ dist/mjs/helper/task.d.ts | 3 +- dist/mjs/helper/task.js | 44 +++++++++++++++++++++++ dist/mjs/index.d.ts | 4 +-- dist/mjs/interface/interface.d.ts | 12 +++++++ src/helper/task.ts | 58 +++++++++++++++++++++++++++++++ src/index.ts | 2 ++ src/interface/interface.ts | 13 +++++++ 11 files changed, 195 insertions(+), 6 deletions(-) diff --git a/dist/cjs/helper/task.d.ts b/dist/cjs/helper/task.d.ts index a1cee621..a89c66b2 100644 --- a/dist/cjs/helper/task.d.ts +++ b/dist/cjs/helper/task.d.ts @@ -1,4 +1,4 @@ -import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, Round1BatchProofQuery, Round2BatchProofQuery, Round2BatchProof, Round1BatchProof, FinalBatchProofQuery, FinalBatchProof } from "../interface/interface.js"; +import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, Round1BatchProofQuery, Round2BatchProofQuery, Round2BatchProof, Round1BatchProof, FinalBatchProofQuery, FinalBatchProof, ConciseTask } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; export declare class ZkWasmServiceHelper { endpoint: ZkWasmServiceEndpoint; @@ -12,6 +12,7 @@ export declare class ZkWasmServiceHelper { queryConfig(): Promise; loadStatistics(): Promise; loadTasks(query: QueryParams): Promise>; + loadTaskList(query: QueryParams): Promise>; queryRound1BatchProofs(query: PaginatedQuery): Promise>; queryRound2BatchProofs(query: PaginatedQuery): Promise>; queryFinalBatchProofs(query: PaginatedQuery): Promise>; diff --git a/dist/cjs/helper/task.js b/dist/cjs/helper/task.js index 59fd012a..98dfdf8b 100644 --- a/dist/cjs/helper/task.js +++ b/dist/cjs/helper/task.js @@ -169,6 +169,52 @@ class ZkWasmServiceHelper { return tasks; }); } + loadTaskList(query) { + return __awaiter(this, void 0, void 0, function* () { + let headers = { "Content-Type": "application/json" }; + let queryJson = JSON.parse("{}"); + // Validate query params + if (query.start != null && query.start < 0) { + throw new Error("start must be positive"); + } + if (query.total != null && query.total <= 0) { + throw new Error("total must be positive"); + } + if (query.id != null && query.id != "") { + // Validate it is a hex string (mongodb objectid) + if (!util_js_1.ZkWasmUtil.isHexString(query.id)) { + throw new Error("id must be a hex string or "); + } + } + if (query.user_address != null && query.user_address != "") { + // Validate it is a hex string (ethereum address) + if (!ethers_1.ethers.isAddress(query.user_address)) { + throw new Error("user_address must be a valid ethereum address"); + } + } + if (query.md5 != null && query.md5 != "") { + // Validate it is a hex string (md5) + if (!util_js_1.ZkWasmUtil.isHexString(query.md5)) { + throw new Error("md5 must be a hex string"); + } + } + //build query JSON + let objKeys = Object.keys(query); + objKeys.forEach((key) => { + if (query[key] != "" && query[key] != null) + queryJson[key] = query[key]; + }); + if (this.endpoint.enable_logs) { + console.log("params:", query); + console.log("json", queryJson); + } + let tasks = yield this.endpoint.invokeRequest("GET", `/tasklist`, queryJson); + if (this.endpoint.enable_logs) { + console.log("loading task board!"); + } + return tasks; + }); + } queryRound1BatchProofs(query) { return __awaiter(this, void 0, void 0, function* () { let proofData = yield this.endpoint.invokeRequest("GET", TaskEndpoint.ROUND_1_BATCH, JSON.parse(JSON.stringify(query))); diff --git a/dist/cjs/index.d.ts b/dist/cjs/index.d.ts index 9f6f193e..a3fd21be 100644 --- a/dist/cjs/index.d.ts +++ b/dist/cjs/index.d.ts @@ -1,6 +1,6 @@ -import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc } from "./interface/interface.js"; +import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; -export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; +export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index 16aa6de3..3fff752b 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -41,6 +41,18 @@ export interface Task { batch_proof_data?: BatchProofData; auto_submit_status?: AutoSubmitStatus; } +export interface ConciseTask { + _id: any; + user_address: string; + md5: string; + task_type: string; + status: TaskStatus; + submit_time: string; + process_started?: string; + process_finished?: string; + proof_submit_mode?: ProofSubmitMode; + auto_submit_status?: AutoSubmitStatus; +} export interface AutoSubmitBatchMetadata { chain_id: number; id: string; diff --git a/dist/mjs/helper/task.d.ts b/dist/mjs/helper/task.d.ts index a1cee621..a89c66b2 100644 --- a/dist/mjs/helper/task.d.ts +++ b/dist/mjs/helper/task.d.ts @@ -1,4 +1,4 @@ -import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, Round1BatchProofQuery, Round2BatchProofQuery, Round2BatchProof, Round1BatchProof, FinalBatchProofQuery, FinalBatchProof } from "../interface/interface.js"; +import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, Round1BatchProofQuery, Round2BatchProofQuery, Round2BatchProof, Round1BatchProof, FinalBatchProofQuery, FinalBatchProof, ConciseTask } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; export declare class ZkWasmServiceHelper { endpoint: ZkWasmServiceEndpoint; @@ -12,6 +12,7 @@ export declare class ZkWasmServiceHelper { queryConfig(): Promise; loadStatistics(): Promise; loadTasks(query: QueryParams): Promise>; + loadTaskList(query: QueryParams): Promise>; queryRound1BatchProofs(query: PaginatedQuery): Promise>; queryRound2BatchProofs(query: PaginatedQuery): Promise>; queryFinalBatchProofs(query: PaginatedQuery): Promise>; diff --git a/dist/mjs/helper/task.js b/dist/mjs/helper/task.js index 68046612..a84aeed1 100644 --- a/dist/mjs/helper/task.js +++ b/dist/mjs/helper/task.js @@ -126,6 +126,50 @@ export class ZkWasmServiceHelper { } return tasks; } + async loadTaskList(query) { + let headers = { "Content-Type": "application/json" }; + let queryJson = JSON.parse("{}"); + // Validate query params + if (query.start != null && query.start < 0) { + throw new Error("start must be positive"); + } + if (query.total != null && query.total <= 0) { + throw new Error("total must be positive"); + } + if (query.id != null && query.id != "") { + // Validate it is a hex string (mongodb objectid) + if (!ZkWasmUtil.isHexString(query.id)) { + throw new Error("id must be a hex string or "); + } + } + if (query.user_address != null && query.user_address != "") { + // Validate it is a hex string (ethereum address) + if (!ethers.isAddress(query.user_address)) { + throw new Error("user_address must be a valid ethereum address"); + } + } + if (query.md5 != null && query.md5 != "") { + // Validate it is a hex string (md5) + if (!ZkWasmUtil.isHexString(query.md5)) { + throw new Error("md5 must be a hex string"); + } + } + //build query JSON + let objKeys = Object.keys(query); + objKeys.forEach((key) => { + if (query[key] != "" && query[key] != null) + queryJson[key] = query[key]; + }); + if (this.endpoint.enable_logs) { + console.log("params:", query); + console.log("json", queryJson); + } + let tasks = await this.endpoint.invokeRequest("GET", `/tasklist`, queryJson); + if (this.endpoint.enable_logs) { + console.log("loading task board!"); + } + return tasks; + } async queryRound1BatchProofs(query) { let proofData = await this.endpoint.invokeRequest("GET", TaskEndpoint.ROUND_1_BATCH, JSON.parse(JSON.stringify(query))); if (this.endpoint.enable_logs) { diff --git a/dist/mjs/index.d.ts b/dist/mjs/index.d.ts index 9f6f193e..a3fd21be 100644 --- a/dist/mjs/index.d.ts +++ b/dist/mjs/index.d.ts @@ -1,6 +1,6 @@ -import { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc } from "./interface/interface.js"; +import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; -export type { Task, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; +export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index 16aa6de3..3fff752b 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -41,6 +41,18 @@ export interface Task { batch_proof_data?: BatchProofData; auto_submit_status?: AutoSubmitStatus; } +export interface ConciseTask { + _id: any; + user_address: string; + md5: string; + task_type: string; + status: TaskStatus; + submit_time: string; + process_started?: string; + process_finished?: string; + proof_submit_mode?: ProofSubmitMode; + auto_submit_status?: AutoSubmitStatus; +} export interface AutoSubmitBatchMetadata { chain_id: number; id: string; diff --git a/src/helper/task.ts b/src/helper/task.ts index 0c63f3a5..965fb361 100644 --- a/src/helper/task.ts +++ b/src/helper/task.ts @@ -30,6 +30,7 @@ import { Round1BatchProof, FinalBatchProofQuery, FinalBatchProof, + ConciseTask, } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; import { ethers } from "ethers"; @@ -207,6 +208,63 @@ export class ZkWasmServiceHelper { return tasks; } + async loadTaskList( + query: QueryParams + ): Promise> { + let headers = { "Content-Type": "application/json" }; + let queryJson = JSON.parse("{}"); + + // Validate query params + if (query.start != null && query.start < 0) { + throw new Error("start must be positive"); + } + if (query.total != null && query.total <= 0) { + throw new Error("total must be positive"); + } + + if (query.id != null && query.id != "") { + // Validate it is a hex string (mongodb objectid) + if (!ZkWasmUtil.isHexString(query.id)) { + throw new Error("id must be a hex string or "); + } + } + + if (query.user_address != null && query.user_address != "") { + // Validate it is a hex string (ethereum address) + if (!ethers.isAddress(query.user_address)) { + throw new Error("user_address must be a valid ethereum address"); + } + } + + if (query.md5 != null && query.md5 != "") { + // Validate it is a hex string (md5) + if (!ZkWasmUtil.isHexString(query.md5)) { + throw new Error("md5 must be a hex string"); + } + } + + //build query JSON + let objKeys = Object.keys(query) as Array; + objKeys.forEach((key) => { + if (query[key] != "" && query[key] != null) queryJson[key] = query[key]; + }); + + if (this.endpoint.enable_logs) { + console.log("params:", query); + console.log("json", queryJson); + } + + let tasks = await this.endpoint.invokeRequest( + "GET", + `/tasklist`, + queryJson + ); + if (this.endpoint.enable_logs) { + console.log("loading task board!"); + } + return tasks; + } + async queryRound1BatchProofs( query: PaginatedQuery ): Promise> { diff --git a/src/index.ts b/src/index.ts index 7b47f874..c06d6596 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,5 +1,6 @@ import { Task, + ConciseTask, ProvingParams, DeployParams, QueryParams, @@ -74,6 +75,7 @@ export { export type { Task, + ConciseTask, ProvingParams, DeployParams, QueryParams, diff --git a/src/interface/interface.ts b/src/interface/interface.ts index e05fd25e..7eaa1b3d 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -45,6 +45,19 @@ export interface Task { auto_submit_status?: AutoSubmitStatus; } +export interface ConciseTask { + _id: any; + user_address: string; + md5: string; + task_type: string; + status: TaskStatus; + submit_time: string; + process_started?: string; + process_finished?: string; + proof_submit_mode?: ProofSubmitMode; + auto_submit_status?: AutoSubmitStatus; +} + export interface AutoSubmitBatchMetadata { chain_id: number; id: string; From 34f4824a7df2b3414c64f4d5a4d9ea6bc22bf6c8 Mon Sep 17 00:00:00 2001 From: rhaoio Date: Wed, 12 Jun 2024 12:22:54 +1000 Subject: [PATCH 21/36] try with blob --- dist/cjs/helper/util.d.ts | 1 + dist/cjs/helper/util.js | 6 ++++++ dist/mjs/helper/util.d.ts | 1 + dist/mjs/helper/util.js | 6 ++++++ src/helper/util.ts | 7 +++++++ 5 files changed, 21 insertions(+) diff --git a/dist/cjs/helper/util.d.ts b/dist/cjs/helper/util.d.ts index 8ef320a5..e5afa24c 100644 --- a/dist/cjs/helper/util.d.ts +++ b/dist/cjs/helper/util.d.ts @@ -98,6 +98,7 @@ export declare class ZkWasmUtil { static loadContextFileFromPath(filePath: string): Promise; static loadContexFileAsBytes(filePath: string): Promise; static browserLoadContextFileAsBytes(file: File): Promise; + static bytesToTempFile(data: Uint8Array): Blob; static MAX_CONTEXT_SIZE: number; static validateContextBytes(data: Uint8Array): boolean; } diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index 2e92e340..31ff86a6 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -353,6 +353,12 @@ class ZkWasmUtil { }); }); } + // Convert Bytes into a temporary file, as it will be submitted through multipart to a server, file does not need to be saved + static bytesToTempFile(data) { + this.validateContextBytes(data); + let blob = new Blob([data]); + return blob; + } // Validate bytes are a multiple of 8 bytes (64 bits) and length less than 4KB static validateContextBytes(data) { if (data.length > this.MAX_CONTEXT_SIZE) { diff --git a/dist/mjs/helper/util.d.ts b/dist/mjs/helper/util.d.ts index 8ef320a5..e5afa24c 100644 --- a/dist/mjs/helper/util.d.ts +++ b/dist/mjs/helper/util.d.ts @@ -98,6 +98,7 @@ export declare class ZkWasmUtil { static loadContextFileFromPath(filePath: string): Promise; static loadContexFileAsBytes(filePath: string): Promise; static browserLoadContextFileAsBytes(file: File): Promise; + static bytesToTempFile(data: Uint8Array): Blob; static MAX_CONTEXT_SIZE: number; static validateContextBytes(data: Uint8Array): boolean; } diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index ec132978..a21665dd 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -447,6 +447,12 @@ export class ZkWasmUtil { reader.readAsArrayBuffer(file); }); } + // Convert Bytes into a temporary file, as it will be submitted through multipart to a server, file does not need to be saved + static bytesToTempFile(data) { + this.validateContextBytes(data); + let blob = new Blob([data]); + return blob; + } static MAX_CONTEXT_SIZE = 4096; // Validate bytes are a multiple of 8 bytes (64 bits) and length less than 4KB static validateContextBytes(data) { diff --git a/src/helper/util.ts b/src/helper/util.ts index d598bb17..eef0870d 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -567,6 +567,13 @@ export class ZkWasmUtil { }); } + // Convert Bytes into a temporary file, as it will be submitted through multipart to a server, file does not need to be saved + static bytesToTempFile(data: Uint8Array): Blob { + this.validateContextBytes(data); + let blob = new Blob([data]); + return blob; + } + static MAX_CONTEXT_SIZE = 4096; // Validate bytes are a multiple of 8 bytes (64 bits) and length less than 4KB From 0f0205d0b70e8bcd624ca8559fe192298fe98f0a Mon Sep 17 00:00:00 2001 From: rhaoio Date: Wed, 12 Jun 2024 12:30:07 +1000 Subject: [PATCH 22/36] try import blob for nodejs --- dist/cjs/helper/util.js | 12 +++++++++++- dist/mjs/helper/util.js | 12 +++++++++++- src/helper/util.ts | 13 ++++++++++++- 3 files changed, 34 insertions(+), 3 deletions(-) diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index 31ff86a6..b57e8b0f 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -356,7 +356,17 @@ class ZkWasmUtil { // Convert Bytes into a temporary file, as it will be submitted through multipart to a server, file does not need to be saved static bytesToTempFile(data) { this.validateContextBytes(data); - let blob = new Blob([data]); + let blob; + if (typeof Blob === "undefined") { + // Node.js environment + const { Blob } = require("buffer"); + const buffer = Buffer.from(data); + blob = new Blob([buffer]); + } + else { + // Browser environment + blob = new Blob([data]); + } return blob; } // Validate bytes are a multiple of 8 bytes (64 bits) and length less than 4KB diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index a21665dd..b492a1a3 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -450,7 +450,17 @@ export class ZkWasmUtil { // Convert Bytes into a temporary file, as it will be submitted through multipart to a server, file does not need to be saved static bytesToTempFile(data) { this.validateContextBytes(data); - let blob = new Blob([data]); + let blob; + if (typeof Blob === "undefined") { + // Node.js environment + const { Blob } = require("buffer"); + const buffer = Buffer.from(data); + blob = new Blob([buffer]); + } + else { + // Browser environment + blob = new Blob([data]); + } return blob; } static MAX_CONTEXT_SIZE = 4096; diff --git a/src/helper/util.ts b/src/helper/util.ts index eef0870d..98685bb3 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -570,7 +570,18 @@ export class ZkWasmUtil { // Convert Bytes into a temporary file, as it will be submitted through multipart to a server, file does not need to be saved static bytesToTempFile(data: Uint8Array): Blob { this.validateContextBytes(data); - let blob = new Blob([data]); + let blob: Blob; + + if (typeof Blob === "undefined") { + // Node.js environment + const { Blob } = require("buffer"); + const buffer = Buffer.from(data); + blob = new Blob([buffer]); + } else { + // Browser environment + blob = new Blob([data]); + } + return blob; } From b3c3ae0fe9c5fb4e035f6692e1d617272f7fcf0d Mon Sep 17 00:00:00 2001 From: rhaoio Date: Wed, 12 Jun 2024 12:39:04 +1000 Subject: [PATCH 23/36] try as buffer --- dist/cjs/helper/util.d.ts | 3 ++- dist/cjs/helper/util.js | 49 ++++++++++++++++++++++++++++----------- dist/mjs/helper/util.d.ts | 3 ++- dist/mjs/helper/util.js | 12 ++++------ src/helper/util.ts | 15 ++++++------ 5 files changed, 52 insertions(+), 30 deletions(-) diff --git a/dist/cjs/helper/util.d.ts b/dist/cjs/helper/util.d.ts index e5afa24c..10ab7954 100644 --- a/dist/cjs/helper/util.d.ts +++ b/dist/cjs/helper/util.d.ts @@ -1,3 +1,4 @@ +/// import BN from "bn.js"; import { AddImageParams, ProvingParams, DeployParams, ResetImageParams, ModifyImageParams, VerifyProofParams, LogQuery, ContextHexString, VerifyBatchProofParams } from "../interface/interface.js"; import { Contract, Signer } from "ethers"; @@ -98,7 +99,7 @@ export declare class ZkWasmUtil { static loadContextFileFromPath(filePath: string): Promise; static loadContexFileAsBytes(filePath: string): Promise; static browserLoadContextFileAsBytes(file: File): Promise; - static bytesToTempFile(data: Uint8Array): Blob; + static bytesToTempFile(data: Uint8Array): Promise; static MAX_CONTEXT_SIZE: number; static validateContextBytes(data: Uint8Array): boolean; } diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index b57e8b0f..c80362a5 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -1,4 +1,27 @@ "use strict"; +var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); +}) : (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + o[k2] = m[k]; +})); +var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); +}) : function(o, v) { + o["default"] = v; +}); +var __importStar = (this && this.__importStar) || function (mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + __setModuleDefault(result, mod); + return result; +}; var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } return new (P || (P = Promise))(function (resolve, reject) { @@ -355,19 +378,19 @@ class ZkWasmUtil { } // Convert Bytes into a temporary file, as it will be submitted through multipart to a server, file does not need to be saved static bytesToTempFile(data) { - this.validateContextBytes(data); - let blob; - if (typeof Blob === "undefined") { - // Node.js environment - const { Blob } = require("buffer"); - const buffer = Buffer.from(data); - blob = new Blob([buffer]); - } - else { - // Browser environment - blob = new Blob([data]); - } - return blob; + return __awaiter(this, void 0, void 0, function* () { + this.validateContextBytes(data); + if (typeof window === "undefined") { + // Node.js environment + const { Buffer } = yield Promise.resolve().then(() => __importStar(require("buffer"))); + const buffer = Buffer.from(data); + return buffer; + } + else { + // Browser environment + throw new Error("File creation in the browser is not supported by this function."); + } + }); } // Validate bytes are a multiple of 8 bytes (64 bits) and length less than 4KB static validateContextBytes(data) { diff --git a/dist/mjs/helper/util.d.ts b/dist/mjs/helper/util.d.ts index e5afa24c..10ab7954 100644 --- a/dist/mjs/helper/util.d.ts +++ b/dist/mjs/helper/util.d.ts @@ -1,3 +1,4 @@ +/// import BN from "bn.js"; import { AddImageParams, ProvingParams, DeployParams, ResetImageParams, ModifyImageParams, VerifyProofParams, LogQuery, ContextHexString, VerifyBatchProofParams } from "../interface/interface.js"; import { Contract, Signer } from "ethers"; @@ -98,7 +99,7 @@ export declare class ZkWasmUtil { static loadContextFileFromPath(filePath: string): Promise; static loadContexFileAsBytes(filePath: string): Promise; static browserLoadContextFileAsBytes(file: File): Promise; - static bytesToTempFile(data: Uint8Array): Blob; + static bytesToTempFile(data: Uint8Array): Promise; static MAX_CONTEXT_SIZE: number; static validateContextBytes(data: Uint8Array): boolean; } diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index b492a1a3..c39edf0a 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -448,20 +448,18 @@ export class ZkWasmUtil { }); } // Convert Bytes into a temporary file, as it will be submitted through multipart to a server, file does not need to be saved - static bytesToTempFile(data) { + static async bytesToTempFile(data) { this.validateContextBytes(data); - let blob; - if (typeof Blob === "undefined") { + if (typeof window === "undefined") { // Node.js environment - const { Blob } = require("buffer"); + const { Buffer } = await import("buffer"); const buffer = Buffer.from(data); - blob = new Blob([buffer]); + return buffer; } else { // Browser environment - blob = new Blob([data]); + throw new Error("File creation in the browser is not supported by this function."); } - return blob; } static MAX_CONTEXT_SIZE = 4096; // Validate bytes are a multiple of 8 bytes (64 bits) and length less than 4KB diff --git a/src/helper/util.ts b/src/helper/util.ts index 98685bb3..fca1c4c4 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -568,21 +568,20 @@ export class ZkWasmUtil { } // Convert Bytes into a temporary file, as it will be submitted through multipart to a server, file does not need to be saved - static bytesToTempFile(data: Uint8Array): Blob { + static async bytesToTempFile(data: Uint8Array): Promise { this.validateContextBytes(data); - let blob: Blob; - if (typeof Blob === "undefined") { + if (typeof window === "undefined") { // Node.js environment - const { Blob } = require("buffer"); + const { Buffer } = await import("buffer"); const buffer = Buffer.from(data); - blob = new Blob([buffer]); + return buffer; } else { // Browser environment - blob = new Blob([data]); + throw new Error( + "File creation in the browser is not supported by this function." + ); } - - return blob; } static MAX_CONTEXT_SIZE = 4096; From 9bdddaad2f3c5e409311fa4e3b0e85633999c160 Mon Sep 17 00:00:00 2001 From: rhaoio Date: Wed, 12 Jun 2024 12:51:20 +1000 Subject: [PATCH 24/36] readme + extra fn --- README.md | 126 ++++++++++++++++++++++---------------- dist/cjs/helper/util.d.ts | 1 + dist/cjs/helper/util.js | 15 ++++- dist/mjs/helper/util.d.ts | 1 + dist/mjs/helper/util.js | 13 +++- src/helper/util.ts | 16 ++++- 6 files changed, 116 insertions(+), 56 deletions(-) diff --git a/README.md b/README.md index 2fc6d212..bbd7019f 100644 --- a/README.md +++ b/README.md @@ -89,65 +89,85 @@ import { ProvingParams, WithSignature, ZkWasmUtil, - ZkWasmServiceHelper + ZkWasmServiceHelper, + ProofSubmitMode, + InputContextType, + WithCustomInputContextType, } from "zkwasm-service-helper"; -const endpoint = ""https://rpc.zkwasmhub.com:8090"; -const image_md5 = "xxxx"; -const public_inputs = "0x22:i64 0x21:i64"; -const private_inputs = ""; -const user_addr = "0xaaaaaa"; - -let helper = new ZkWasmServiceHelper(endpoint, "", ""); -let pb_inputs: Array = helper.parseProvingTaskInput(public_inputs); -let priv_inputs: Array = helper.parseProvingTaskInput(private_inputs); - -// Use the helper Enum type to determine the proof submit mode -let proofSubmitMode = ProofSubmitMode.Auto ? ProofSubmitMode.Auto : ProofSubmitMode.Manual; - -let info: ProvingParams = { - user_address: user_addr.toLowerCase(), - md5: image_md5, - public_inputs: pb_inputs, - private_inputs: priv_inputs, - // Whether the proof will be batched and verified through the auto submit service or manually submitted. - // If the field is not specified, the default value will be ProofSubmitMode.Manual and the proof will not be batched. - proof_submit_mode: proofSubmitMode, -}; - -// Context type for proof task. If none provided, will default to InputContextType.ImageCurrent in the server and use the image's current context -let selectedInputContextType = InputContextType.ImageCurrent; - -// For Custom Context, upload a binary file first containing the context. -if (selectedInputContextType === InputContextType.Custom) { +async function AddNewProofTask() { + const endpoint = "https://rpc.zkwasmhub.com:8090"; + const image_md5 = "xxxxx"; + const public_inputs = "0x22:i64 0x21:i64"; + const private_inputs = ""; + const user_addr = ""; + const privateKey = ""; + + let helper = new ZkWasmServiceHelper(endpoint, "", ""); + let pb_inputs: Array = ZkWasmUtil.validateInputs(public_inputs); + let priv_inputs: Array = ZkWasmUtil.validateInputs(private_inputs); + + // Use the helper Enum type to determine the proof submit mode + let proofSubmitMode = ProofSubmitMode.Auto + ? ProofSubmitMode.Auto + : ProofSubmitMode.Manual; + + let info: ProvingParams = { + user_address: user_addr.toLowerCase(), + md5: image_md5, + public_inputs: pb_inputs, + private_inputs: priv_inputs, + // Whether the proof will be batched and verified through the auto submit service or manually submitted. + // If the field is not specified, the default value will be ProofSubmitMode.Manual and the proof will not be batched. + proof_submit_mode: proofSubmitMode, + }; - let contextFile = await ZkWasmUtil.loadContexFileAsBytes(""); + // Context type for proof task. If none provided, will default to InputContextType.ImageCurrent in the server and use the image's current context + let selectedInputContextType = InputContextType.Custom; + + // For Custom Context, upload a binary file first containing the context. + if (selectedInputContextType === InputContextType.Custom) { + // Load bytes into Tempfile/Buffer type - Server side example with NodeJS + const contextBytes = new Uint8Array(64); + contextBytes.fill(1); + ZkWasmUtil.validateContextBytes(contextBytes); + let bytesFile = await ZkWasmUtil.bytesToTempFile(contextBytes); + let context_info: WithCustomInputContextType = { + input_context: bytesFile, + input_context_md5: ZkWasmUtil.convertToMd5(contextBytes), + input_context_type: selectedInputContextType, + }; - let context_info: WithCustomInputContextType = { - input_context: contextFile, - input_context_md5: ZkWasmUtil.convertToMd5(contextFile), - input_context_type: selectedInputContextType, + // // LOADING AS FILE DIRECTLY - Browser side example + // let contextFile = await ZkWasmUtil.loadContexFileAsBytes(""); + + // let context_info: WithCustomInputContextType = { + // input_context: contextFile, + // input_context_md5: ZkWasmUtil.convertToMd5(contextFile), + // input_context_type: selectedInputContextType, + // }; + info = { ...info, ...context_info }; + } else { + info = { ...info, input_context_type: selectedInputContextType }; + } + let msgString = ZkWasmUtil.createProvingSignMessage(info); + + let signature: string; + try { + signature = await ZkWasmUtil.signMessage(msgString, privateKey); + } catch (e: unknown) { + console.log("error signing message", e); + return; + } + + let task: WithSignature = { + ...info, + signature: signature, }; - info = { ...info, ...context_info }; -} else { - info = { ...info, input_context_type: selectedInputContextType }; -} -let msgString = ZkWasmUtil.createProvingSignMessage(info); - -let signature: string; -try { - signature = await ZkWasmUtil.signMessage(msgString, priv); -} catch (e: unknown) { - console.log("error signing message", e); - return; -} -let task: WithSignature = { - ...info, - signature: signature, -}; - -let response = await helper.addProvingTask(task); + let response = await helper.addProvingTask(task); + console.log(response); +} ``` ### Verifying a proof diff --git a/dist/cjs/helper/util.d.ts b/dist/cjs/helper/util.d.ts index 10ab7954..62bf7baa 100644 --- a/dist/cjs/helper/util.d.ts +++ b/dist/cjs/helper/util.d.ts @@ -100,6 +100,7 @@ export declare class ZkWasmUtil { static loadContexFileAsBytes(filePath: string): Promise; static browserLoadContextFileAsBytes(file: File): Promise; static bytesToTempFile(data: Uint8Array): Promise; + static bytesToFile(data: Uint8Array): Promise; static MAX_CONTEXT_SIZE: number; static validateContextBytes(data: Uint8Array): boolean; } diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index c80362a5..da66854c 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -376,7 +376,7 @@ class ZkWasmUtil { }); }); } - // Convert Bytes into a temporary file, as it will be submitted through multipart to a server, file does not need to be saved + // Convert Bytes into a temporary file (Buffer for nodejs), as it will be submitted through multipart to a server, file does not need to be saved static bytesToTempFile(data) { return __awaiter(this, void 0, void 0, function* () { this.validateContextBytes(data); @@ -392,6 +392,19 @@ class ZkWasmUtil { } }); } + static bytesToFile(data) { + return __awaiter(this, void 0, void 0, function* () { + this.validateContextBytes(data); + if (typeof window === "undefined") { + throw new Error("File creation in NodeJS env is not supported by this function."); + } + else { + // Browser environment + const blob = new Blob([data]); + return new File([blob], "context.bin"); + } + }); + } // Validate bytes are a multiple of 8 bytes (64 bits) and length less than 4KB static validateContextBytes(data) { if (data.length > this.MAX_CONTEXT_SIZE) { diff --git a/dist/mjs/helper/util.d.ts b/dist/mjs/helper/util.d.ts index 10ab7954..62bf7baa 100644 --- a/dist/mjs/helper/util.d.ts +++ b/dist/mjs/helper/util.d.ts @@ -100,6 +100,7 @@ export declare class ZkWasmUtil { static loadContexFileAsBytes(filePath: string): Promise; static browserLoadContextFileAsBytes(file: File): Promise; static bytesToTempFile(data: Uint8Array): Promise; + static bytesToFile(data: Uint8Array): Promise; static MAX_CONTEXT_SIZE: number; static validateContextBytes(data: Uint8Array): boolean; } diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index c39edf0a..ed354422 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -447,7 +447,7 @@ export class ZkWasmUtil { reader.readAsArrayBuffer(file); }); } - // Convert Bytes into a temporary file, as it will be submitted through multipart to a server, file does not need to be saved + // Convert Bytes into a temporary file (Buffer for nodejs), as it will be submitted through multipart to a server, file does not need to be saved static async bytesToTempFile(data) { this.validateContextBytes(data); if (typeof window === "undefined") { @@ -461,6 +461,17 @@ export class ZkWasmUtil { throw new Error("File creation in the browser is not supported by this function."); } } + static async bytesToFile(data) { + this.validateContextBytes(data); + if (typeof window === "undefined") { + throw new Error("File creation in NodeJS env is not supported by this function."); + } + else { + // Browser environment + const blob = new Blob([data]); + return new File([blob], "context.bin"); + } + } static MAX_CONTEXT_SIZE = 4096; // Validate bytes are a multiple of 8 bytes (64 bits) and length less than 4KB static validateContextBytes(data) { diff --git a/src/helper/util.ts b/src/helper/util.ts index fca1c4c4..33455b99 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -567,7 +567,7 @@ export class ZkWasmUtil { }); } - // Convert Bytes into a temporary file, as it will be submitted through multipart to a server, file does not need to be saved + // Convert Bytes into a temporary file (Buffer for nodejs), as it will be submitted through multipart to a server, file does not need to be saved static async bytesToTempFile(data: Uint8Array): Promise { this.validateContextBytes(data); @@ -584,6 +584,20 @@ export class ZkWasmUtil { } } + static async bytesToFile(data: Uint8Array): Promise { + this.validateContextBytes(data); + + if (typeof window === "undefined") { + throw new Error( + "File creation in NodeJS env is not supported by this function." + ); + } else { + // Browser environment + const blob = new Blob([data]); + return new File([blob], "context.bin"); + } + } + static MAX_CONTEXT_SIZE = 4096; // Validate bytes are a multiple of 8 bytes (64 bits) and length less than 4KB From 7cc8c2b421148ca4a659e013502de07d13938ed3 Mon Sep 17 00:00:00 2001 From: Yimin Yu Date: Mon, 17 Jun 2024 13:19:01 +0800 Subject: [PATCH 25/36] Revert wrongly add unsupported assert {type} feature for typescript 4.x --- addhybridpackage.sh | 3 --- 1 file changed, 3 deletions(-) diff --git a/addhybridpackage.sh b/addhybridpackage.sh index 2dfb6c13..eb794515 100644 --- a/addhybridpackage.sh +++ b/addhybridpackage.sh @@ -23,6 +23,3 @@ mkdir -p dist/cjs/abi mkdir -p dist/mjs/abi find src/abi -name '*.json' -exec cp {} dist/cjs/abi \; find src/abi -name '*.json' -exec cp {} dist/mjs/abi \; - -# add import assertions to mjs -sed -i 's/import ERC20 from \"..\/abi\/ERC20.json\"/import ERC20 from \"..\/abi\/ERC20.json\" assert { type: \"json\" }/g' dist/mjs/helper/util.js From ac5aaaa9e1abff7f6d97b6acc56ddc691731c511 Mon Sep 17 00:00:00 2001 From: Yimin Yu Date: Mon, 17 Jun 2024 14:51:49 +0800 Subject: [PATCH 26/36] use file read --- dist/cjs/helper/util.js | 7 +++++-- dist/mjs/helper/util.js | 5 ++++- src/helper/util.ts | 5 ++++- 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index da66854c..eff7fa42 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -40,7 +40,10 @@ const bn_js_1 = __importDefault(require("bn.js")); const ts_md5_1 = require("ts-md5"); const interface_js_1 = require("../interface/interface.js"); const ethers_1 = require("ethers"); -const ERC20_json_1 = __importDefault(require("../abi/ERC20.json")); +//import ERC20 from "../abi/ERC20.json"; +const fs_1 = __importDefault(require("fs")); +const ERC20String = fs_1.default.readFileSync('../abi/ERC20.json', 'utf-8'); +const ERC20 = JSON.parse(ERC20String); class ZkWasmUtil { static hexToBNs(hexString) { let bytes = new Array(Math.ceil(hexString.length / 16)); @@ -314,7 +317,7 @@ class ZkWasmUtil { }); } static ERC20Contract(contractAddress, signer) { - return new ethers_1.Contract(contractAddress, ERC20_json_1.default, signer); + return new ethers_1.Contract(contractAddress, ERC20, signer); } static bytesToJSONString(data) { const bufferView = new Uint8Array(data); diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index ed354422..8a4f366f 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -2,7 +2,10 @@ import BN from "bn.js"; import { Md5 } from "ts-md5"; import { InputContextType, } from "../interface/interface.js"; import { Contract, formatUnits, Wallet } from "ethers"; -import ERC20 from "../abi/ERC20.json"; +//import ERC20 from "../abi/ERC20.json"; +import fs from 'fs'; +const ERC20String = fs.readFileSync('../abi/ERC20.json', 'utf-8'); +const ERC20 = JSON.parse(ERC20String); export class ZkWasmUtil { static contract_abi = { contractName: "AggregatorVerifier", diff --git a/src/helper/util.ts b/src/helper/util.ts index 33455b99..ee93614d 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -17,7 +17,10 @@ import { DelphinusWalletConnector, DelphinusBrowserConnector, } from "web3subscriber/src/provider.js"; -import ERC20 from "../abi/ERC20.json"; +//import ERC20 from "../abi/ERC20.json"; +import fs from 'fs'; +const ERC20String = fs.readFileSync('../abi/ERC20.json', 'utf-8'); +const ERC20 = JSON.parse(ERC20String); export class ZkWasmUtil { static contract_abi = { From 11ecb56559866a700e8a42eabe66cd9efd42d5aa Mon Sep 17 00:00:00 2001 From: Yimin Yu Date: Mon, 17 Jun 2024 15:23:49 +0800 Subject: [PATCH 27/36] change json to string --- dist/cjs/abi/ERC20.d.ts | 4 + dist/cjs/abi/ERC20.js | 229 ++++++++++++++++++++++++++++++++++++++++ dist/cjs/abi/ERC20.json | 222 -------------------------------------- dist/cjs/helper/util.js | 8 +- dist/cjs/index.d.ts | 3 +- dist/cjs/index.js | 4 +- dist/mjs/abi/ERC20.d.ts | 4 + dist/mjs/abi/ERC20.js | 225 +++++++++++++++++++++++++++++++++++++++ dist/mjs/abi/ERC20.json | 222 -------------------------------------- dist/mjs/helper/util.js | 8 +- dist/mjs/index.d.ts | 3 +- dist/mjs/index.js | 3 +- src/abi/ERC20.json | 222 -------------------------------------- src/abi/ERC20.ts | 226 +++++++++++++++++++++++++++++++++++++++ src/helper/util.ts | 8 +- src/index.ts | 2 + 16 files changed, 708 insertions(+), 685 deletions(-) create mode 100644 dist/cjs/abi/ERC20.d.ts create mode 100644 dist/cjs/abi/ERC20.js delete mode 100644 dist/cjs/abi/ERC20.json create mode 100644 dist/mjs/abi/ERC20.d.ts create mode 100644 dist/mjs/abi/ERC20.js delete mode 100644 dist/mjs/abi/ERC20.json delete mode 100644 src/abi/ERC20.json create mode 100644 src/abi/ERC20.ts diff --git a/dist/cjs/abi/ERC20.d.ts b/dist/cjs/abi/ERC20.d.ts new file mode 100644 index 00000000..763ad170 --- /dev/null +++ b/dist/cjs/abi/ERC20.d.ts @@ -0,0 +1,4 @@ +export declare class ERC20Lib { + static ERC20String: string; + static ERC20: any; +} diff --git a/dist/cjs/abi/ERC20.js b/dist/cjs/abi/ERC20.js new file mode 100644 index 00000000..6d68b5df --- /dev/null +++ b/dist/cjs/abi/ERC20.js @@ -0,0 +1,229 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.ERC20Lib = void 0; +class ERC20Lib { +} +exports.ERC20Lib = ERC20Lib; +ERC20Lib.ERC20String = `[ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_spender", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_from", + "type": "address" + }, + { + "name": "_to", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_owner", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "balance", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_to", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_owner", + "type": "address" + }, + { + "name": "_spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + } + ]`; +ERC20Lib.ERC20 = JSON.parse(ERC20Lib.ERC20String); diff --git a/dist/cjs/abi/ERC20.json b/dist/cjs/abi/ERC20.json deleted file mode 100644 index 405d6b36..00000000 --- a/dist/cjs/abi/ERC20.json +++ /dev/null @@ -1,222 +0,0 @@ -[ - { - "constant": true, - "inputs": [], - "name": "name", - "outputs": [ - { - "name": "", - "type": "string" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { - "name": "_spender", - "type": "address" - }, - { - "name": "_value", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "name": "", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { - "name": "_from", - "type": "address" - }, - { - "name": "_to", - "type": "address" - }, - { - "name": "_value", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "decimals", - "outputs": [ - { - "name": "", - "type": "uint8" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { - "name": "_owner", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "name": "balance", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "symbol", - "outputs": [ - { - "name": "", - "type": "string" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { - "name": "_to", - "type": "address" - }, - { - "name": "_value", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { - "name": "_owner", - "type": "address" - }, - { - "name": "_spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "name": "", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "payable": true, - "stateMutability": "payable", - "type": "fallback" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "name": "from", - "type": "address" - }, - { - "indexed": true, - "name": "to", - "type": "address" - }, - { - "indexed": false, - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - } -] diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index eff7fa42..5c3a9692 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -40,10 +40,8 @@ const bn_js_1 = __importDefault(require("bn.js")); const ts_md5_1 = require("ts-md5"); const interface_js_1 = require("../interface/interface.js"); const ethers_1 = require("ethers"); -//import ERC20 from "../abi/ERC20.json"; -const fs_1 = __importDefault(require("fs")); -const ERC20String = fs_1.default.readFileSync('../abi/ERC20.json', 'utf-8'); -const ERC20 = JSON.parse(ERC20String); +//import ERC20 from "../abi/ERC20"; +const ERC20_js_1 = require("../abi/ERC20.js"); class ZkWasmUtil { static hexToBNs(hexString) { let bytes = new Array(Math.ceil(hexString.length / 16)); @@ -317,7 +315,7 @@ class ZkWasmUtil { }); } static ERC20Contract(contractAddress, signer) { - return new ethers_1.Contract(contractAddress, ERC20, signer); + return new ethers_1.Contract(contractAddress, ERC20_js_1.ERC20Lib.ERC20, signer); } static bytesToJSONString(data) { const bufferView = new Uint8Array(data); diff --git a/dist/cjs/index.d.ts b/dist/cjs/index.d.ts index a3fd21be..69dd8eae 100644 --- a/dist/cjs/index.d.ts +++ b/dist/cjs/index.d.ts @@ -2,5 +2,6 @@ import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProo import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; +import { ERC20Lib } from "abi/ERC20.js"; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; diff --git a/dist/cjs/index.js b/dist/cjs/index.js index f42348d1..c95ad41f 100644 --- a/dist/cjs/index.js +++ b/dist/cjs/index.js @@ -1,6 +1,6 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.ProvePaymentSrc = exports.ProofSubmitMode = exports.FinalProofStatus = exports.Round2BatchProofStatus = exports.Round1BatchProofStatus = exports.AutoSubmitStatus = exports.InputContextType = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; +exports.ProvePaymentSrc = exports.ProofSubmitMode = exports.FinalProofStatus = exports.Round2BatchProofStatus = exports.Round1BatchProofStatus = exports.AutoSubmitStatus = exports.InputContextType = exports.ERC20Lib = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; const interface_js_1 = require("./interface/interface.js"); Object.defineProperty(exports, "InputContextType", { enumerable: true, get: function () { return interface_js_1.InputContextType; } }); Object.defineProperty(exports, "Round1BatchProofStatus", { enumerable: true, get: function () { return interface_js_1.Round1BatchProofStatus; } }); @@ -15,3 +15,5 @@ const endpoint_js_1 = require("./helper/endpoint.js"); Object.defineProperty(exports, "ZkWasmServiceEndpoint", { enumerable: true, get: function () { return endpoint_js_1.ZkWasmServiceEndpoint; } }); const task_js_1 = require("./helper/task.js"); Object.defineProperty(exports, "ZkWasmServiceHelper", { enumerable: true, get: function () { return task_js_1.ZkWasmServiceHelper; } }); +const ERC20_js_1 = require("abi/ERC20.js"); +Object.defineProperty(exports, "ERC20Lib", { enumerable: true, get: function () { return ERC20_js_1.ERC20Lib; } }); diff --git a/dist/mjs/abi/ERC20.d.ts b/dist/mjs/abi/ERC20.d.ts new file mode 100644 index 00000000..763ad170 --- /dev/null +++ b/dist/mjs/abi/ERC20.d.ts @@ -0,0 +1,4 @@ +export declare class ERC20Lib { + static ERC20String: string; + static ERC20: any; +} diff --git a/dist/mjs/abi/ERC20.js b/dist/mjs/abi/ERC20.js new file mode 100644 index 00000000..ed315b3e --- /dev/null +++ b/dist/mjs/abi/ERC20.js @@ -0,0 +1,225 @@ +export class ERC20Lib { + static ERC20String = `[ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_spender", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_from", + "type": "address" + }, + { + "name": "_to", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_owner", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "balance", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_to", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_owner", + "type": "address" + }, + { + "name": "_spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + } + ]`; + static ERC20 = JSON.parse(ERC20Lib.ERC20String); +} diff --git a/dist/mjs/abi/ERC20.json b/dist/mjs/abi/ERC20.json deleted file mode 100644 index 405d6b36..00000000 --- a/dist/mjs/abi/ERC20.json +++ /dev/null @@ -1,222 +0,0 @@ -[ - { - "constant": true, - "inputs": [], - "name": "name", - "outputs": [ - { - "name": "", - "type": "string" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { - "name": "_spender", - "type": "address" - }, - { - "name": "_value", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "name": "", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { - "name": "_from", - "type": "address" - }, - { - "name": "_to", - "type": "address" - }, - { - "name": "_value", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "decimals", - "outputs": [ - { - "name": "", - "type": "uint8" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { - "name": "_owner", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "name": "balance", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "symbol", - "outputs": [ - { - "name": "", - "type": "string" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { - "name": "_to", - "type": "address" - }, - { - "name": "_value", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { - "name": "_owner", - "type": "address" - }, - { - "name": "_spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "name": "", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "payable": true, - "stateMutability": "payable", - "type": "fallback" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "name": "from", - "type": "address" - }, - { - "indexed": true, - "name": "to", - "type": "address" - }, - { - "indexed": false, - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - } -] diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index 8a4f366f..9b0797b4 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -2,10 +2,8 @@ import BN from "bn.js"; import { Md5 } from "ts-md5"; import { InputContextType, } from "../interface/interface.js"; import { Contract, formatUnits, Wallet } from "ethers"; -//import ERC20 from "../abi/ERC20.json"; -import fs from 'fs'; -const ERC20String = fs.readFileSync('../abi/ERC20.json', 'utf-8'); -const ERC20 = JSON.parse(ERC20String); +//import ERC20 from "../abi/ERC20"; +import { ERC20Lib } from "../abi/ERC20.js"; export class ZkWasmUtil { static contract_abi = { contractName: "AggregatorVerifier", @@ -394,7 +392,7 @@ export class ZkWasmUtil { return signature; } static ERC20Contract(contractAddress, signer) { - return new Contract(contractAddress, ERC20, signer); + return new Contract(contractAddress, ERC20Lib.ERC20, signer); } static bytesToJSONString(data) { const bufferView = new Uint8Array(data); diff --git a/dist/mjs/index.d.ts b/dist/mjs/index.d.ts index a3fd21be..69dd8eae 100644 --- a/dist/mjs/index.d.ts +++ b/dist/mjs/index.d.ts @@ -2,5 +2,6 @@ import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProo import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; +import { ERC20Lib } from "abi/ERC20.js"; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; diff --git a/dist/mjs/index.js b/dist/mjs/index.js index 34af54c7..284a515a 100644 --- a/dist/mjs/index.js +++ b/dist/mjs/index.js @@ -2,4 +2,5 @@ import { InputContextType, Round1BatchProofStatus, Round2BatchProofStatus, AutoS import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; +import { ERC20Lib } from "abi/ERC20.js"; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; diff --git a/src/abi/ERC20.json b/src/abi/ERC20.json deleted file mode 100644 index 405d6b36..00000000 --- a/src/abi/ERC20.json +++ /dev/null @@ -1,222 +0,0 @@ -[ - { - "constant": true, - "inputs": [], - "name": "name", - "outputs": [ - { - "name": "", - "type": "string" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { - "name": "_spender", - "type": "address" - }, - { - "name": "_value", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "name": "", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { - "name": "_from", - "type": "address" - }, - { - "name": "_to", - "type": "address" - }, - { - "name": "_value", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "decimals", - "outputs": [ - { - "name": "", - "type": "uint8" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { - "name": "_owner", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "name": "balance", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "symbol", - "outputs": [ - { - "name": "", - "type": "string" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { - "name": "_to", - "type": "address" - }, - { - "name": "_value", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { - "name": "_owner", - "type": "address" - }, - { - "name": "_spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "name": "", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "payable": true, - "stateMutability": "payable", - "type": "fallback" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "name": "from", - "type": "address" - }, - { - "indexed": true, - "name": "to", - "type": "address" - }, - { - "indexed": false, - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - } -] diff --git a/src/abi/ERC20.ts b/src/abi/ERC20.ts new file mode 100644 index 00000000..6008509e --- /dev/null +++ b/src/abi/ERC20.ts @@ -0,0 +1,226 @@ +export class ERC20Lib { + static ERC20String = `[ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_spender", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_from", + "type": "address" + }, + { + "name": "_to", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_owner", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "balance", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_to", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_owner", + "type": "address" + }, + { + "name": "_spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + } + ]`; + + static ERC20 = JSON.parse(ERC20Lib.ERC20String); +} \ No newline at end of file diff --git a/src/helper/util.ts b/src/helper/util.ts index ee93614d..b1ed5b0e 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -17,10 +17,8 @@ import { DelphinusWalletConnector, DelphinusBrowserConnector, } from "web3subscriber/src/provider.js"; -//import ERC20 from "../abi/ERC20.json"; -import fs from 'fs'; -const ERC20String = fs.readFileSync('../abi/ERC20.json', 'utf-8'); -const ERC20 = JSON.parse(ERC20String); +//import ERC20 from "../abi/ERC20"; +import { ERC20Lib } from "../abi/ERC20.js" export class ZkWasmUtil { static contract_abi = { @@ -501,7 +499,7 @@ export class ZkWasmUtil { } static ERC20Contract(contractAddress: string, signer: Signer) { - return new Contract(contractAddress, ERC20, signer); + return new Contract(contractAddress, ERC20Lib.ERC20, signer); } static bytesToJSONString(data: Uint8Array): string { diff --git a/src/index.ts b/src/index.ts index c06d6596..2f6578a6 100644 --- a/src/index.ts +++ b/src/index.ts @@ -59,11 +59,13 @@ import { import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; +import { ERC20Lib } from "abi/ERC20.js"; export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, + ERC20Lib, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, From 40a29a13275beae78c51c42319282a31290f5145 Mon Sep 17 00:00:00 2001 From: Yimin Yu Date: Mon, 17 Jun 2024 15:29:50 +0800 Subject: [PATCH 28/36] fix path --- dist/cjs/index.d.ts | 2 +- dist/cjs/index.js | 2 +- dist/mjs/index.d.ts | 2 +- dist/mjs/index.js | 2 +- src/index.ts | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/dist/cjs/index.d.ts b/dist/cjs/index.d.ts index 69dd8eae..7877d9da 100644 --- a/dist/cjs/index.d.ts +++ b/dist/cjs/index.d.ts @@ -2,6 +2,6 @@ import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProo import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -import { ERC20Lib } from "abi/ERC20.js"; +import { ERC20Lib } from "./abi/ERC20.js"; export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; diff --git a/dist/cjs/index.js b/dist/cjs/index.js index c95ad41f..1286336b 100644 --- a/dist/cjs/index.js +++ b/dist/cjs/index.js @@ -15,5 +15,5 @@ const endpoint_js_1 = require("./helper/endpoint.js"); Object.defineProperty(exports, "ZkWasmServiceEndpoint", { enumerable: true, get: function () { return endpoint_js_1.ZkWasmServiceEndpoint; } }); const task_js_1 = require("./helper/task.js"); Object.defineProperty(exports, "ZkWasmServiceHelper", { enumerable: true, get: function () { return task_js_1.ZkWasmServiceHelper; } }); -const ERC20_js_1 = require("abi/ERC20.js"); +const ERC20_js_1 = require("./abi/ERC20.js"); Object.defineProperty(exports, "ERC20Lib", { enumerable: true, get: function () { return ERC20_js_1.ERC20Lib; } }); diff --git a/dist/mjs/index.d.ts b/dist/mjs/index.d.ts index 69dd8eae..7877d9da 100644 --- a/dist/mjs/index.d.ts +++ b/dist/mjs/index.d.ts @@ -2,6 +2,6 @@ import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProo import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -import { ERC20Lib } from "abi/ERC20.js"; +import { ERC20Lib } from "./abi/ERC20.js"; export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; diff --git a/dist/mjs/index.js b/dist/mjs/index.js index 284a515a..231024d0 100644 --- a/dist/mjs/index.js +++ b/dist/mjs/index.js @@ -2,5 +2,5 @@ import { InputContextType, Round1BatchProofStatus, Round2BatchProofStatus, AutoS import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -import { ERC20Lib } from "abi/ERC20.js"; +import { ERC20Lib } from "./abi/ERC20.js"; export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; diff --git a/src/index.ts b/src/index.ts index 2f6578a6..75c82031 100644 --- a/src/index.ts +++ b/src/index.ts @@ -59,7 +59,7 @@ import { import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; -import { ERC20Lib } from "abi/ERC20.js"; +import { ERC20Lib } from "./abi/ERC20.js"; export { ZkWasmServiceEndpoint, From 211f1773eb5bc3b695bbf302fc383ed98e13e334 Mon Sep 17 00:00:00 2001 From: Richard Hao Date: Thu, 27 Jun 2024 15:00:29 +1000 Subject: [PATCH 29/36] ZKWAS-306 (#80) * stats update * query update * endpoint name * fix type --- dist/cjs/helper/task.d.ts | 3 ++- dist/cjs/helper/task.js | 11 +++++++++++ dist/cjs/index.d.ts | 4 ++-- dist/cjs/interface/interface.d.ts | 17 +++++++++++++++++ dist/mjs/helper/task.d.ts | 3 ++- dist/mjs/helper/task.js | 9 +++++++++ dist/mjs/index.d.ts | 4 ++-- dist/mjs/interface/interface.d.ts | 17 +++++++++++++++++ src/helper/task.ts | 20 ++++++++++++++++++++ src/index.ts | 4 ++++ src/interface/interface.ts | 19 +++++++++++++++++++ 11 files changed, 105 insertions(+), 6 deletions(-) diff --git a/dist/cjs/helper/task.d.ts b/dist/cjs/helper/task.d.ts index a89c66b2..1ba6cae0 100644 --- a/dist/cjs/helper/task.d.ts +++ b/dist/cjs/helper/task.d.ts @@ -1,4 +1,4 @@ -import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, Round1BatchProofQuery, Round2BatchProofQuery, Round2BatchProof, Round1BatchProof, FinalBatchProofQuery, FinalBatchProof, ConciseTask } from "../interface/interface.js"; +import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, Round1BatchProofQuery, Round2BatchProofQuery, Round2BatchProof, Round1BatchProof, FinalBatchProofQuery, FinalBatchProof, ConciseTask, NodeStatistics, NodeStatisticsQueryParams } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; export declare class ZkWasmServiceHelper { endpoint: ZkWasmServiceEndpoint; @@ -11,6 +11,7 @@ export declare class ZkWasmServiceHelper { queryDepositHistory(history_query: TxHistoryQueryParams): Promise>; queryConfig(): Promise; loadStatistics(): Promise; + queryNodeStatistics(query: NodeStatisticsQueryParams): Promise; loadTasks(query: QueryParams): Promise>; loadTaskList(query: QueryParams): Promise>; queryRound1BatchProofs(query: PaginatedQuery): Promise>; diff --git a/dist/cjs/helper/task.js b/dist/cjs/helper/task.js index 98dfdf8b..0032de0a 100644 --- a/dist/cjs/helper/task.js +++ b/dist/cjs/helper/task.js @@ -123,6 +123,17 @@ class ZkWasmServiceHelper { }; }); } + queryNodeStatistics(query) { + return __awaiter(this, void 0, void 0, function* () { + let headers = { "Content-Type": "application/json" }; + let queryJson = JSON.parse(JSON.stringify(query)); + let res = yield this.endpoint.invokeRequest("GET", `/node_statistics`, queryJson); + if (this.endpoint.enable_logs) { + console.log("loading node statistics"); + } + return res; + }); + } loadTasks(query) { return __awaiter(this, void 0, void 0, function* () { let headers = { "Content-Type": "application/json" }; diff --git a/dist/cjs/index.d.ts b/dist/cjs/index.d.ts index 7877d9da..81088a29 100644 --- a/dist/cjs/index.d.ts +++ b/dist/cjs/index.d.ts @@ -1,7 +1,7 @@ -import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc } from "./interface/interface.js"; +import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; import { ERC20Lib } from "./abi/ERC20.js"; export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; -export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; +export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, }; diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index 3fff752b..cde3caee 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -4,6 +4,23 @@ export interface Statistics { totalTasks: number; totalDeployed: number; } +export interface NodeStatistics { + address: string; + statistics: { + successful_tasks: number; + failed_tasks: number; + total_tasks: number; + timed_out_count: number; + last_timed_out: string; + last_successful_proof_task_time: string; + last_successful_proof_processing_time: number; + }; +} +export interface NodeStatisticsQueryParams { + address?: string; + start?: number; + total?: number; +} export declare enum InputContextType { Custom = "Custom", ImageInitial = "ImageInitial", diff --git a/dist/mjs/helper/task.d.ts b/dist/mjs/helper/task.d.ts index a89c66b2..1ba6cae0 100644 --- a/dist/mjs/helper/task.d.ts +++ b/dist/mjs/helper/task.d.ts @@ -1,4 +1,4 @@ -import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, Round1BatchProofQuery, Round2BatchProofQuery, Round2BatchProof, Round1BatchProof, FinalBatchProofQuery, FinalBatchProof, ConciseTask } from "../interface/interface.js"; +import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, Round1BatchProofQuery, Round2BatchProofQuery, Round2BatchProof, Round1BatchProof, FinalBatchProofQuery, FinalBatchProof, ConciseTask, NodeStatistics, NodeStatisticsQueryParams } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; export declare class ZkWasmServiceHelper { endpoint: ZkWasmServiceEndpoint; @@ -11,6 +11,7 @@ export declare class ZkWasmServiceHelper { queryDepositHistory(history_query: TxHistoryQueryParams): Promise>; queryConfig(): Promise; loadStatistics(): Promise; + queryNodeStatistics(query: NodeStatisticsQueryParams): Promise; loadTasks(query: QueryParams): Promise>; loadTaskList(query: QueryParams): Promise>; queryRound1BatchProofs(query: PaginatedQuery): Promise>; diff --git a/dist/mjs/helper/task.js b/dist/mjs/helper/task.js index a84aeed1..41b75282 100644 --- a/dist/mjs/helper/task.js +++ b/dist/mjs/helper/task.js @@ -82,6 +82,15 @@ export class ZkWasmServiceHelper { totalDeployed: st.total_deployed, }; } + async queryNodeStatistics(query) { + let headers = { "Content-Type": "application/json" }; + let queryJson = JSON.parse(JSON.stringify(query)); + let res = await this.endpoint.invokeRequest("GET", `/node_statistics`, queryJson); + if (this.endpoint.enable_logs) { + console.log("loading node statistics"); + } + return res; + } async loadTasks(query) { let headers = { "Content-Type": "application/json" }; let queryJson = JSON.parse("{}"); diff --git a/dist/mjs/index.d.ts b/dist/mjs/index.d.ts index 7877d9da..81088a29 100644 --- a/dist/mjs/index.d.ts +++ b/dist/mjs/index.d.ts @@ -1,7 +1,7 @@ -import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc } from "./interface/interface.js"; +import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; import { ERC20Lib } from "./abi/ERC20.js"; export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; -export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, }; +export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, }; diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index 3fff752b..cde3caee 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -4,6 +4,23 @@ export interface Statistics { totalTasks: number; totalDeployed: number; } +export interface NodeStatistics { + address: string; + statistics: { + successful_tasks: number; + failed_tasks: number; + total_tasks: number; + timed_out_count: number; + last_timed_out: string; + last_successful_proof_task_time: string; + last_successful_proof_processing_time: number; + }; +} +export interface NodeStatisticsQueryParams { + address?: string; + start?: number; + total?: number; +} export declare enum InputContextType { Custom = "Custom", ImageInitial = "ImageInitial", diff --git a/src/helper/task.ts b/src/helper/task.ts index 965fb361..e1ce7e62 100644 --- a/src/helper/task.ts +++ b/src/helper/task.ts @@ -31,6 +31,8 @@ import { FinalBatchProofQuery, FinalBatchProof, ConciseTask, + NodeStatistics, + NodeStatisticsQueryParams, } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; import { ethers } from "ethers"; @@ -157,6 +159,24 @@ export class ZkWasmServiceHelper { }; } + async queryNodeStatistics( + query: NodeStatisticsQueryParams + ): Promise { + let headers = { "Content-Type": "application/json" }; + let queryJson = JSON.parse(JSON.stringify(query)); + + let res = await this.endpoint.invokeRequest( + "GET", + `/node_statistics`, + queryJson + ); + if (this.endpoint.enable_logs) { + console.log("loading node statistics"); + } + + return res as NodeStatistics[]; + } + async loadTasks(query: QueryParams): Promise> { let headers = { "Content-Type": "application/json" }; let queryJson = JSON.parse("{}"); diff --git a/src/index.ts b/src/index.ts index 75c82031..fc51d735 100644 --- a/src/index.ts +++ b/src/index.ts @@ -54,6 +54,8 @@ import { AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, + NodeStatistics, + NodeStatisticsQueryParams, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; @@ -124,4 +126,6 @@ export type { PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, + NodeStatistics, + NodeStatisticsQueryParams, }; diff --git a/src/interface/interface.ts b/src/interface/interface.ts index 7eaa1b3d..97cab012 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -5,6 +5,25 @@ export interface Statistics { totalDeployed: number; } +export interface NodeStatistics { + address: string; + statistics: { + successful_tasks: number; + failed_tasks: number; + total_tasks: number; + timed_out_count: number; + last_timed_out: string; + last_successful_proof_task_time: string; + last_successful_proof_processing_time: number; + }; +} + +export interface NodeStatisticsQueryParams { + address?: string; + start?: number; + total?: number; +} + export enum InputContextType { Custom = "Custom", ImageInitial = "ImageInitial", From 58d5c9aafd7c317e0db9d33024ca0ae14ca45097 Mon Sep 17 00:00:00 2001 From: Richard Hao Date: Tue, 2 Jul 2024 11:12:18 +1000 Subject: [PATCH 30/36] ZKWAS-289 (#81) * update load file for nodejs env * use buffer * try with md5 from uint8array * fix sig with initial context * add examples and update readme --- README.md | 445 +- dist/cjs/helper/task.js | 2 +- dist/cjs/helper/util.d.ts | 2 +- dist/cjs/helper/util.js | 19 +- dist/mjs/helper/task.js | 2 +- dist/mjs/helper/util.d.ts | 2 +- dist/mjs/helper/util.js | 19 +- examples/.gitignore | 1 + examples/build.sh | 3 + examples/package-lock.json | 9735 ++++++++++++++++++ examples/package.json | 23 + examples/src/config.ts | 19 + examples/src/files/context.data | Bin 0 -> 8 bytes examples/src/files/image.wasm | Bin 0 -> 129 bytes examples/src/queries/autosubmit.ts | 80 + examples/src/queries/task.ts | 54 + examples/src/tasks/addNewImage.ts | 69 + examples/src/tasks/submitProofTask.ts | 94 + examples/src/verify/verifyAutoSubmitProof.ts | 124 + examples/src/verify/verifyProof.ts | 92 + examples/tsconfig.json | 14 + src/helper/task.ts | 2 +- src/helper/util.ts | 29 +- 23 files changed, 10370 insertions(+), 460 deletions(-) create mode 100644 examples/.gitignore create mode 100644 examples/build.sh create mode 100644 examples/package-lock.json create mode 100644 examples/package.json create mode 100644 examples/src/config.ts create mode 100644 examples/src/files/context.data create mode 100644 examples/src/files/image.wasm create mode 100644 examples/src/queries/autosubmit.ts create mode 100644 examples/src/queries/task.ts create mode 100644 examples/src/tasks/addNewImage.ts create mode 100644 examples/src/tasks/submitProofTask.ts create mode 100644 examples/src/verify/verifyAutoSubmitProof.ts create mode 100644 examples/src/verify/verifyProof.ts create mode 100644 examples/tsconfig.json diff --git a/README.md b/README.md index bbd7019f..a9435fcb 100644 --- a/README.md +++ b/README.md @@ -16,446 +16,35 @@ like: - async addNewWasmImage(task: WithSignature); - async addProvingTask(task: WithSignature); -### A example to add new wasm image +## Examples -This example typescript code will add the wasm image to the zkwasm service. +There are several examples of how to use this lib in the `examples` folder. -```typescript -import { - AddImageParams, - WithSignature, - ZkWasmUtil, - ZkWasmServiceHelper, - ProvePaymentSrc, -} from "zkwasm-service-helper"; +## How to run the examples -const endpoint = ""https://rpc.zkwasmhub.com:8090"; -let helper = new ZkWasmServiceHelper(endpoint, "", ""); -let imagePath = "/home/user/a.wasm"; -let fileSelected: Buffer = fs.readFileSync(imagePath); -let md5 = ZkWasmUtil.convertToMd5( - fileSelected as Uint8Array - ); - -let info: AddImageParams = { - name: fileSelected.name, - image_md5: md5, - image: fileSelected, - user_address: account!.address.toLowerCase(), - description_url: "", - avator_url: "", - circuit_size: circuitSize, - - // Determines whether the credits will be deducted from the user supplying proof requests (default) or the user who created the image - // Currently Enum values are Default and CreatorPay - prove_payment_src: ProvePaymentSrc.Default, - - // Networks which the auto submit service will batch and submit the proof to. - // Unsupported networks will be rejected. - // If empty array, Auto Submitted proofs will be rejected. - auto_submit_network_ids: [97, 1, 11155111] - }; - -// Optional Initial Context information - -// Upload a binary file first -let contextFile = await ZkWasmUtil.loadContexFileAsBytes(""); - -if (contextFile) { - let context_info: WithInitialContext = { - initial_context: contextFile, - initial_context_md5: ZkWasmUtil.convertToMd5(contextFile), - }; - info = { ...info, ...context_info }; -} - -let msg = ZkWasmUtil.createAddImageSignMessage(info); -let signature: string = await ZkWasmUtil.signMessage(msgString, priv); //Need user private key to sign the msg -let task: WithSignature = { - ...info, - signature, - }; - -let response = await helper.addNewWasmImage(task); +### 0. Change to the examples directory as the current working directory +```bash +cd examples ``` -### A example to add proving tasks - -This example typescript code will add proving tasks to the zkwasm service. - -```typescript -import { - ProvingParams, - WithSignature, - ZkWasmUtil, - ZkWasmServiceHelper, - ProofSubmitMode, - InputContextType, - WithCustomInputContextType, -} from "zkwasm-service-helper"; - -async function AddNewProofTask() { - const endpoint = "https://rpc.zkwasmhub.com:8090"; - const image_md5 = "xxxxx"; - const public_inputs = "0x22:i64 0x21:i64"; - const private_inputs = ""; - const user_addr = ""; - const privateKey = ""; - - let helper = new ZkWasmServiceHelper(endpoint, "", ""); - let pb_inputs: Array = ZkWasmUtil.validateInputs(public_inputs); - let priv_inputs: Array = ZkWasmUtil.validateInputs(private_inputs); - - // Use the helper Enum type to determine the proof submit mode - let proofSubmitMode = ProofSubmitMode.Auto - ? ProofSubmitMode.Auto - : ProofSubmitMode.Manual; - - let info: ProvingParams = { - user_address: user_addr.toLowerCase(), - md5: image_md5, - public_inputs: pb_inputs, - private_inputs: priv_inputs, - // Whether the proof will be batched and verified through the auto submit service or manually submitted. - // If the field is not specified, the default value will be ProofSubmitMode.Manual and the proof will not be batched. - proof_submit_mode: proofSubmitMode, - }; - - // Context type for proof task. If none provided, will default to InputContextType.ImageCurrent in the server and use the image's current context - let selectedInputContextType = InputContextType.Custom; - - // For Custom Context, upload a binary file first containing the context. - if (selectedInputContextType === InputContextType.Custom) { - // Load bytes into Tempfile/Buffer type - Server side example with NodeJS - const contextBytes = new Uint8Array(64); - contextBytes.fill(1); - ZkWasmUtil.validateContextBytes(contextBytes); - let bytesFile = await ZkWasmUtil.bytesToTempFile(contextBytes); - let context_info: WithCustomInputContextType = { - input_context: bytesFile, - input_context_md5: ZkWasmUtil.convertToMd5(contextBytes), - input_context_type: selectedInputContextType, - }; +### 1. Install dependencies - // // LOADING AS FILE DIRECTLY - Browser side example - // let contextFile = await ZkWasmUtil.loadContexFileAsBytes(""); - - // let context_info: WithCustomInputContextType = { - // input_context: contextFile, - // input_context_md5: ZkWasmUtil.convertToMd5(contextFile), - // input_context_type: selectedInputContextType, - // }; - info = { ...info, ...context_info }; - } else { - info = { ...info, input_context_type: selectedInputContextType }; - } - let msgString = ZkWasmUtil.createProvingSignMessage(info); - - let signature: string; - try { - signature = await ZkWasmUtil.signMessage(msgString, privateKey); - } catch (e: unknown) { - console.log("error signing message", e); - return; - } - - let task: WithSignature = { - ...info, - signature: signature, - }; - - let response = await helper.addProvingTask(task); - console.log(response); -} +```bash +npm install ``` -### Verifying a proof - -This example typescript code will verify a proof which utilises Delphinus' web3subscriber library. -You can also do this with `ethers.js` or `web3.js` given the ABI and address of the aggregator verifier contract. -the ABI can be accessed from the `ZkWasmUtil` class. - -```typescript -import { - VerifyProofParams, - ZkWasmUtil, - Task, - VerifyBatchProofParams, -} from "zkwasm-service-helper"; -import { withBrowserConnector } from "web3subscriber/src/client"; -import { DelphinusBrowserConnector } from "web3subscriber/src/provider"; - -async function VerifyProof() { - // Fetch a task from the playground service which contains the proof information - // See the example to build query function to fetch task details - const task: Task = await fetchTaskFromService(); - - await withBrowserConnector(async (connector: DelphinusBrowserConnector) => { - let chainidhex = "0x" + selectedChainId!.toString(16); - await connector.switchNet(chainidhex); +### 2. Use your own values for the following: - let contract = await ZkWasmUtil.composeVerifyContract( - connector, - aggregator_verifier_address - ); +- Update your data in the `config.ts` file with your private key and address of the zkwasm playground service. +- Update the `config.ts` with web3 information you want to use such as chain id and provider url etc. - // If the proof has no shadow instances, use the batch instances to try and verify instead. - // Mostly for legacy purposes. - // Proofs submitted with Auto Submit will not be verified using this method. - // See below for an example of verifying a proof which has been batched with the Auto Submitted Proof service. - let verify_instance = - task.shadow_instances.length === 0 - ? task.batch_instances - : task.shadow_instances; +- Within each script you want to run, you will also need to update values for querying and submitting tasks such as task ids. - let proofParams: VerifyProofParams = { - aggregate_proof: task.proof, - shadow_instances: verify_instance, - aux: task.aux, - instances: [task.target_instances], // The target instances are wrapped in an array - }; +### 3. Run the example you want to run. - let tx = await ZkWasmUtil.verifyProof( - contract.getEthersContract(), - proofParams - ); - // wait for tx to be mined, can add no. of confirmations as arg - await tx.wait(); +Currently only the scripts under `src/tasks` and `src/verify` are runnable. The `queries` are merely examples which are used in these executable scripts. - console.log("transaction:", tx.hash); - }); -} +```bash +npx tsx src/tasks/addNewImage.ts ``` - -### Verifying a batched proof - -This example typescript code will verify a batched proof which utilises Delphinus' web3subscriber library. - -```typescript -import { - VerifyBatchProofParams, - ZkWasmUtil, - Task, - Round2BatchProof, - VerifyBatchProofParams, - AutoSubmitStatus, -} from "zkwasm-service-helper"; -import { withBrowserConnector } from "web3subscriber/src/client"; -import { DelphinusBrowserConnector } from "web3subscriber/src/provider"; - -async function VerifyBatchedProof() { - // Fetch a task from the playground service which contains the proof information - // See the example to build query function to fetch task details - const task: Task = await fetchAutoSubmittedTask(); - - // First we need to ensure that the Batched Round2/Final Proof has been registered on chain by the Auto Submit Service - const isRegistered = - task.auto_submit_status === AutoSubmitStatus.RegisteredProof; - - console.log("Is proof registered:", isRegistered); - // If the final batch proof has not been registered, we should not attempt to verify it as the transaction will fail. - - // We should then fetch the Round 1 Batch Output information given the task id - - const Round1Proof: Round2BatchProof = await fetchRound1Output( - task._id["$oid"] - ); - - // Convert the Number[] into bytes/Uint8Array - const round_1_target_instances: Array = - round_1_output.target_instances.map((x) => { - return new Uint8Array(x); - }); - - // Convert the Number[] into bytes/Uint8Array - const round_1_shadow_instances: Uint8Array = new Uint8Array( - round_1_output.shadow_instances! - ); - - // Find the index of this proof in the round 1 output by comparing task_ids - // This will be used to verify that this proof was included in a particular batch. - // If it does not exist, the verification will fail - const index = round_1_output.task_ids.findIndex( - (id) => id === task._id["$oid"] - ); - - await withBrowserConnector(async (connector: DelphinusBrowserConnector) => { - let chainidhex = "0x" + selectedChainId!.toString(16); - await connector.switchNet(chainidhex); - - let contract = await ZkWasmUtil.composeBatchVerifierContract( - connector, - aggregator_verifier_address - ); - - // The params are as follows: - // membership_proof_index: The index of the proof amongst the sibling instances - // verify_instance: The shadow instances of the initial task - // sibling_instances: The target_instances used in the same round 1 batch proof - // round_1_shadow_instance: The shadow instances of the round 1 batch proof - // target_instances: The target instances of the initial task - - let proof_info: VerifyBatchProofParams = { - membership_proof_index: [BigInt(index)], - verify_instance: task.shadow_instances, - sibling_instances: round_1_target_instances, - round_1_shadow_instance: round_1_shadow_instances, - target_instances: [task.instances], - }; - - let tx = await ZkWasmUtil.verifyBatchedProof( - contract.getEthersContract(), - proofParams - ); - // wait for tx to be mined, can add no. of confirmations as arg - await tx.wait(); - - console.log("transaction:", tx.hash); - }); -} - -verifyBatchedProof(); -``` - -### A example to query task details - -This example typescript code will query task details: - -```typescript -import { - ZkWasmServiceHelper, - ZkWasmUtil, - QueryParams, - PaginationResult, - Task, -} from "zkwasm-service-helper"; -import BN from "bn.js"; - -const endpoint = ""https://rpc.zkwasmhub.com:8090"; -const taskid = "xxxx" - -let helper = new ZkWasmServiceHelper(endpoint, "", ""); - let args: QueryParams = { - id: taskid!, - user_address: null, // null can also be empty string "" to ignore fields in the query filter - tasktype: null, - taskstatus: null, - }; - helper.loadTasks(args).then((res) => { - const tasks = res as PaginationResult; - const task: Task = tasks.data[0]; - let aggregate_proof = ZkWasmUtil.bytesToBN(task.proof); - let instances = ZkWasmUtil.bytesToBN(task.instances); - let batchInstances = ZkWasmUtil.bytesToBN(task.batch_instances); - let aux = ZkWasmUtil.bytesToBN(task.aux); - let fee = task.task_fee && ZkWasmUtil.convertAmount(task.task_fee); - - console.log("Task details: "); - console.log(" ", task); - console.log(" proof:"); - aggregate_proof.map((proof: BN, index) => { - console.log(" 0x", proof.toString("hex")); - }); - console.log(" batch_instacne:"); - batchInstances.map((ins: BN, index) => { - console.log(" 0x", ins.toString("hex")); - }); - console.log(" instacne:"); - instances.map((ins: BN, index) => { - console.log(" 0x", ins.toString("hex")); - }); - console.log(" aux:"); - aux.map((aux: BN, index) => { - console.log(" 0x", aux.toString("hex")); - }); - console.log(" fee:", fee); - }).catch((err) => { - console.log("queryTask Error", err); - }).finally(() => - console.log("Finish queryTask.") - ); -``` - -### Query Auto Submitted Batch Proofs - -This example typescript code will query task details: - -```typescript -import { - ZkWasmServiceHelper, - ZkWasmUtil, - Round1BatchProof, - Round1BatchProofQuery, - PaginationResult, - PaginatedQuery, - Round1BatchProofStatus, - Round2BatchProofStatus, - Task, -} from "zkwasm-service-helper"; -import BN from "bn.js"; - -const endpoint = ""https://rpc.zkwasmhub.com:8090"; -const taskid = "xxxx" - -let helper = new ZkWasmServiceHelper(endpoint, "", ""); - -// Query the Round 1 Queue to check the status of the first round of batch proofs -let round1QueueQuery: PaginatedQuery = { - task_id: taskid!, // Task id of the task that the batch proof is associated with - id: null, // null can also be empty string "" to ignore fields in the query filter - status: Round1BatchProofStatus.Batched, - circuit_size: null, // null or 22 since all images should be utilizing circuit size 22 -}; -helper.queryRound1BatchProofs(round1QueueQuery).then((res) => { - const response = res as PaginationResult; - const proof: Round1BatchProof = response.data[0]; - console.log("Proof details: "); - console.log(" ", proof); -}).catch((err) => { - console.log("queryRound1BatchProofs Error", err); -}).finally(() => - console.log("Finish queryRound1BatchProofs.") -); - -// Query Round 2 Queue to check the status of the second round of batch proofs -// This also contains the output of Round 1 batch proof items, which will be used as inputs for the Round 2 batch proof -let round2QueueQuery: PaginatedQuery = { - task_id: taskid!, // Find a Round 2 Proof item which contains this task id - id: null, // null can also be empty string "" to ignore fields in the query filter - status: Round2BatchProofStatus.Done, - circuit_size: null, // null or 22 since all images should be utilizing circuit size 22 -}; -helper.queryRound2BatchProofs(round2QueueQuery).then((res) => { - const response = res as PaginationResult; - const proof: Round2BatchProof = response.data[0]; - console.log("Proof details: "); - console.log(" ", proof); -}).catch((err) => { - console.log("queryRound2BatchProofs Error", err); -}).finally(() => - console.log("Finish queryRound2BatchProofs.") -); - -let finalBatchProofQuery: PaginatedQuery = { - task_id: taskid!, - round_2_id: null, // Can also be a round 2 id to find the associated Round 1 outputs. - id: null, // null can also be empty string "" to ignore fields in the query filter - status: FinalProofStatus.ProofRegistered, // ProofRegistered is the status of whether or not the final proof is registered on chain - // Which allows verification of underlying proofs. -}; -helper.queryFinalBatchProofs(round2QueueQuery).then((res) => { - const response = res as PaginationResult; - const proof: FinalBatchProof = response.data[0]; - console.log("Proof details: "); - console.log(" ", proof); -}).catch((err) => { - console.log("queryFinalBatchProofs Error", err); -}).finally(() => - console.log("Finish queryFinalBatchProofs.") -); -``` - -### Notes: - -md5 is case insensitive when communicate with our zkwasm service diff --git a/dist/cjs/helper/task.js b/dist/cjs/helper/task.js index 0032de0a..9bddf343 100644 --- a/dist/cjs/helper/task.js +++ b/dist/cjs/helper/task.js @@ -293,7 +293,7 @@ class ZkWasmServiceHelper { return __awaiter(this, void 0, void 0, function* () { let response = yield this.sendRequestWithSignature("POST", TaskEndpoint.PROVE, task, true); if (this.endpoint.enable_logs) { - console.log("get addProvingTask response:", response.toString()); + console.log("get addProvingTask response:", response); } return response; }); diff --git a/dist/cjs/helper/util.d.ts b/dist/cjs/helper/util.d.ts index 62bf7baa..86ffb70f 100644 --- a/dist/cjs/helper/util.d.ts +++ b/dist/cjs/helper/util.d.ts @@ -97,7 +97,7 @@ export declare class ZkWasmUtil { static ERC20Contract(contractAddress: string, signer: Signer): Contract; static bytesToJSONString(data: Uint8Array): string; static loadContextFileFromPath(filePath: string): Promise; - static loadContexFileAsBytes(filePath: string): Promise; + static loadContexFileAsBytes(filePath: string): Promise<[Buffer, string]>; static browserLoadContextFileAsBytes(file: File): Promise; static bytesToTempFile(data: Uint8Array): Promise; static bytesToFile(data: Uint8Array): Promise; diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index 5c3a9692..23a6635a 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -150,14 +150,14 @@ class ZkWasmUtil { message += params.description_url; message += params.avator_url; message += params.circuit_size; - // Additional params afterwards - if (params.initial_context) { - message += params.initial_context_md5; - } message += params.prove_payment_src; for (const chainId of params.auto_submit_network_ids) { message += chainId; } + // Additional params afterwards + if (params.initial_context) { + message += params.initial_context_md5; + } return message; } static createProvingSignMessage(params) { @@ -326,9 +326,11 @@ class ZkWasmUtil { return __awaiter(this, void 0, void 0, function* () { if (typeof window === "undefined") { // We are in Node.js - const fs = require("fs"); - //const fs = await import("fs").then((module) => module.promises); - return fs.readFile(filePath, "utf8"); + const fs = yield Promise.resolve().then(() => __importStar(require("fs/promises"))); + const file = yield fs.readFile(filePath, { + encoding: "utf-8", + }); + return file; } else { // Browser environment @@ -343,7 +345,8 @@ class ZkWasmUtil { const fileContents = yield this.loadContextFileFromPath(filePath); let bytes = new TextEncoder().encode(fileContents); this.validateContextBytes(bytes); - return bytes; + const md5 = this.convertToMd5(bytes); + return [Buffer.from(bytes), md5]; } catch (err) { throw err; diff --git a/dist/mjs/helper/task.js b/dist/mjs/helper/task.js index 41b75282..4a319f6e 100644 --- a/dist/mjs/helper/task.js +++ b/dist/mjs/helper/task.js @@ -231,7 +231,7 @@ export class ZkWasmServiceHelper { async addProvingTask(task) { let response = await this.sendRequestWithSignature("POST", TaskEndpoint.PROVE, task, true); if (this.endpoint.enable_logs) { - console.log("get addProvingTask response:", response.toString()); + console.log("get addProvingTask response:", response); } return response; } diff --git a/dist/mjs/helper/util.d.ts b/dist/mjs/helper/util.d.ts index 62bf7baa..86ffb70f 100644 --- a/dist/mjs/helper/util.d.ts +++ b/dist/mjs/helper/util.d.ts @@ -97,7 +97,7 @@ export declare class ZkWasmUtil { static ERC20Contract(contractAddress: string, signer: Signer): Contract; static bytesToJSONString(data: Uint8Array): string; static loadContextFileFromPath(filePath: string): Promise; - static loadContexFileAsBytes(filePath: string): Promise; + static loadContexFileAsBytes(filePath: string): Promise<[Buffer, string]>; static browserLoadContextFileAsBytes(file: File): Promise; static bytesToTempFile(data: Uint8Array): Promise; static bytesToFile(data: Uint8Array): Promise; diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index 9b0797b4..8af23ff5 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -233,14 +233,14 @@ export class ZkWasmUtil { message += params.description_url; message += params.avator_url; message += params.circuit_size; - // Additional params afterwards - if (params.initial_context) { - message += params.initial_context_md5; - } message += params.prove_payment_src; for (const chainId of params.auto_submit_network_ids) { message += chainId; } + // Additional params afterwards + if (params.initial_context) { + message += params.initial_context_md5; + } return message; } static createProvingSignMessage(params) { @@ -402,9 +402,11 @@ export class ZkWasmUtil { static async loadContextFileFromPath(filePath) { if (typeof window === "undefined") { // We are in Node.js - const fs = require("fs"); - //const fs = await import("fs").then((module) => module.promises); - return fs.readFile(filePath, "utf8"); + const fs = await import("fs/promises"); + const file = await fs.readFile(filePath, { + encoding: "utf-8", + }); + return file; } else { // Browser environment @@ -417,7 +419,8 @@ export class ZkWasmUtil { const fileContents = await this.loadContextFileFromPath(filePath); let bytes = new TextEncoder().encode(fileContents); this.validateContextBytes(bytes); - return bytes; + const md5 = this.convertToMd5(bytes); + return [Buffer.from(bytes), md5]; } catch (err) { throw err; diff --git a/examples/.gitignore b/examples/.gitignore new file mode 100644 index 00000000..40b878db --- /dev/null +++ b/examples/.gitignore @@ -0,0 +1 @@ +node_modules/ \ No newline at end of file diff --git a/examples/build.sh b/examples/build.sh new file mode 100644 index 00000000..150f9633 --- /dev/null +++ b/examples/build.sh @@ -0,0 +1,3 @@ +cd node_modules/web3subscriber +npm run prepare +cd - diff --git a/examples/package-lock.json b/examples/package-lock.json new file mode 100644 index 00000000..10ef807d --- /dev/null +++ b/examples/package-lock.json @@ -0,0 +1,9735 @@ +{ + "name": "zkwasm-service-helper-examples", + "version": "1.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "zkwasm-service-helper-examples", + "version": "1.0.0", + "dependencies": { + "tsx": "^4.16.0", + "zkwasm-service-helper": "https://github.com/DelphinusLab/zkWasm-service-helper#zkwas-289" + }, + "devDependencies": { + "@babel/core": "^7.23.9", + "@babel/preset-env": "^7.23.9", + "@babel/preset-typescript": "^7.23.3", + "@types/jest": "^29.5.12", + "@types/node": "^18.11.17", + "babel-jest": "^29.7.0", + "jest": "^29.7.0", + "typescript": "^4.3.4" + } + }, + "node_modules/@adraffy/ens-normalize": { + "version": "1.10.1", + "resolved": "https://registry.npmjs.org/@adraffy/ens-normalize/-/ens-normalize-1.10.1.tgz", + "integrity": "sha512-96Z2IP3mYmF1Xg2cDm8f1gWGf/HUVedQ3FMifV4kG/PQ4yEP51xDtRAEfhVNt5f/uzpNkZHwWQuUcu6D6K+Ekw==" + }, + "node_modules/@ampproject/remapping": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.3.0.tgz", + "integrity": "sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==", + "dev": true, + "dependencies": { + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.24" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@aws-crypto/sha256-browser": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/@aws-crypto/sha256-browser/-/sha256-browser-5.2.0.tgz", + "integrity": "sha512-AXfN/lGotSQwu6HNcEsIASo7kWXZ5HYWvfOmSNKDsEqC4OashTp8alTmaz+F7TC2L083SFv5RdB+qU3Vs1kZqw==", + "optional": true, + "dependencies": { + "@aws-crypto/sha256-js": "^5.2.0", + "@aws-crypto/supports-web-crypto": "^5.2.0", + "@aws-crypto/util": "^5.2.0", + "@aws-sdk/types": "^3.222.0", + "@aws-sdk/util-locate-window": "^3.0.0", + "@smithy/util-utf8": "^2.0.0", + "tslib": "^2.6.2" + } + }, + "node_modules/@aws-crypto/sha256-browser/node_modules/@smithy/is-array-buffer": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-2.2.0.tgz", + "integrity": "sha512-GGP3O9QFD24uGeAXYUjwSTXARoqpZykHadOmA8G5vfJPK0/DC67qa//0qvqrJzL1xc8WQWX7/yc7fwudjPHPhA==", + "optional": true, + "dependencies": { + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/@aws-crypto/sha256-browser/node_modules/@smithy/util-buffer-from": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-2.2.0.tgz", + "integrity": "sha512-IJdWBbTcMQ6DA0gdNhh/BwrLkDR+ADW5Kr1aZmd4k3DIF6ezMV4R2NIAmT08wQJ3yUK82thHWmC/TnK/wpMMIA==", + "optional": true, + "dependencies": { + "@smithy/is-array-buffer": "^2.2.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/@aws-crypto/sha256-browser/node_modules/@smithy/util-utf8": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-2.3.0.tgz", + "integrity": "sha512-R8Rdn8Hy72KKcebgLiv8jQcQkXoLMOGGv5uI1/k0l+snqkOzQ1R0ChUBCxWMlBsFMekWjq0wRudIweFs7sKT5A==", + "optional": true, + "dependencies": { + "@smithy/util-buffer-from": "^2.2.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/@aws-crypto/sha256-browser/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-crypto/sha256-js": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/@aws-crypto/sha256-js/-/sha256-js-5.2.0.tgz", + "integrity": "sha512-FFQQyu7edu4ufvIZ+OadFpHHOt+eSTBaYaki44c+akjg7qZg9oOQeLlk77F6tSYqjDAFClrHJk9tMf0HdVyOvA==", + "optional": true, + "dependencies": { + "@aws-crypto/util": "^5.2.0", + "@aws-sdk/types": "^3.222.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-crypto/sha256-js/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-crypto/supports-web-crypto": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/@aws-crypto/supports-web-crypto/-/supports-web-crypto-5.2.0.tgz", + "integrity": "sha512-iAvUotm021kM33eCdNfwIN//F77/IADDSs58i+MDaOqFrVjZo9bAal0NK7HurRuWLLpF1iLX7gbWrjHjeo+YFg==", + "optional": true, + "dependencies": { + "tslib": "^2.6.2" + } + }, + "node_modules/@aws-crypto/supports-web-crypto/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-crypto/util": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/@aws-crypto/util/-/util-5.2.0.tgz", + "integrity": "sha512-4RkU9EsI6ZpBve5fseQlGNUWKMa1RLPQ1dnjnQoe07ldfIzcsGb5hC5W0Dm7u423KWzawlrpbjXBrXCEv9zazQ==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "^3.222.0", + "@smithy/util-utf8": "^2.0.0", + "tslib": "^2.6.2" + } + }, + "node_modules/@aws-crypto/util/node_modules/@smithy/is-array-buffer": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-2.2.0.tgz", + "integrity": "sha512-GGP3O9QFD24uGeAXYUjwSTXARoqpZykHadOmA8G5vfJPK0/DC67qa//0qvqrJzL1xc8WQWX7/yc7fwudjPHPhA==", + "optional": true, + "dependencies": { + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/@aws-crypto/util/node_modules/@smithy/util-buffer-from": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-2.2.0.tgz", + "integrity": "sha512-IJdWBbTcMQ6DA0gdNhh/BwrLkDR+ADW5Kr1aZmd4k3DIF6ezMV4R2NIAmT08wQJ3yUK82thHWmC/TnK/wpMMIA==", + "optional": true, + "dependencies": { + "@smithy/is-array-buffer": "^2.2.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/@aws-crypto/util/node_modules/@smithy/util-utf8": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-2.3.0.tgz", + "integrity": "sha512-R8Rdn8Hy72KKcebgLiv8jQcQkXoLMOGGv5uI1/k0l+snqkOzQ1R0ChUBCxWMlBsFMekWjq0wRudIweFs7sKT5A==", + "optional": true, + "dependencies": { + "@smithy/util-buffer-from": "^2.2.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/@aws-crypto/util/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/client-cognito-identity": { + "version": "3.606.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/client-cognito-identity/-/client-cognito-identity-3.606.0.tgz", + "integrity": "sha512-CJ3kovUg7HAn3trqo0WxVw3PJoaHxiGU1U+Ok8Vx/sL81+auyyiasT09M/NcchRqwAooKvUi44sVD0ih7Zi9Nw==", + "optional": true, + "dependencies": { + "@aws-crypto/sha256-browser": "5.2.0", + "@aws-crypto/sha256-js": "5.2.0", + "@aws-sdk/client-sso-oidc": "3.606.0", + "@aws-sdk/client-sts": "3.606.0", + "@aws-sdk/core": "3.598.0", + "@aws-sdk/credential-provider-node": "3.600.0", + "@aws-sdk/middleware-host-header": "3.598.0", + "@aws-sdk/middleware-logger": "3.598.0", + "@aws-sdk/middleware-recursion-detection": "3.598.0", + "@aws-sdk/middleware-user-agent": "3.598.0", + "@aws-sdk/region-config-resolver": "3.598.0", + "@aws-sdk/types": "3.598.0", + "@aws-sdk/util-endpoints": "3.598.0", + "@aws-sdk/util-user-agent-browser": "3.598.0", + "@aws-sdk/util-user-agent-node": "3.598.0", + "@smithy/config-resolver": "^3.0.2", + "@smithy/core": "^2.2.1", + "@smithy/fetch-http-handler": "^3.0.2", + "@smithy/hash-node": "^3.0.1", + "@smithy/invalid-dependency": "^3.0.1", + "@smithy/middleware-content-length": "^3.0.1", + "@smithy/middleware-endpoint": "^3.0.2", + "@smithy/middleware-retry": "^3.0.4", + "@smithy/middleware-serde": "^3.0.1", + "@smithy/middleware-stack": "^3.0.1", + "@smithy/node-config-provider": "^3.1.1", + "@smithy/node-http-handler": "^3.0.1", + "@smithy/protocol-http": "^4.0.1", + "@smithy/smithy-client": "^3.1.2", + "@smithy/types": "^3.1.0", + "@smithy/url-parser": "^3.0.1", + "@smithy/util-base64": "^3.0.0", + "@smithy/util-body-length-browser": "^3.0.0", + "@smithy/util-body-length-node": "^3.0.0", + "@smithy/util-defaults-mode-browser": "^3.0.4", + "@smithy/util-defaults-mode-node": "^3.0.4", + "@smithy/util-endpoints": "^2.0.2", + "@smithy/util-middleware": "^3.0.1", + "@smithy/util-retry": "^3.0.1", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/client-cognito-identity/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/client-sso": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/client-sso/-/client-sso-3.598.0.tgz", + "integrity": "sha512-nOI5lqPYa+YZlrrzwAJywJSw3MKVjvu6Ge2fCqQUNYMfxFB0NAaDFnl0EPjXi+sEbtCuz/uWE77poHbqiZ+7Iw==", + "optional": true, + "dependencies": { + "@aws-crypto/sha256-browser": "5.2.0", + "@aws-crypto/sha256-js": "5.2.0", + "@aws-sdk/core": "3.598.0", + "@aws-sdk/middleware-host-header": "3.598.0", + "@aws-sdk/middleware-logger": "3.598.0", + "@aws-sdk/middleware-recursion-detection": "3.598.0", + "@aws-sdk/middleware-user-agent": "3.598.0", + "@aws-sdk/region-config-resolver": "3.598.0", + "@aws-sdk/types": "3.598.0", + "@aws-sdk/util-endpoints": "3.598.0", + "@aws-sdk/util-user-agent-browser": "3.598.0", + "@aws-sdk/util-user-agent-node": "3.598.0", + "@smithy/config-resolver": "^3.0.2", + "@smithy/core": "^2.2.1", + "@smithy/fetch-http-handler": "^3.0.2", + "@smithy/hash-node": "^3.0.1", + "@smithy/invalid-dependency": "^3.0.1", + "@smithy/middleware-content-length": "^3.0.1", + "@smithy/middleware-endpoint": "^3.0.2", + "@smithy/middleware-retry": "^3.0.4", + "@smithy/middleware-serde": "^3.0.1", + "@smithy/middleware-stack": "^3.0.1", + "@smithy/node-config-provider": "^3.1.1", + "@smithy/node-http-handler": "^3.0.1", + "@smithy/protocol-http": "^4.0.1", + "@smithy/smithy-client": "^3.1.2", + "@smithy/types": "^3.1.0", + "@smithy/url-parser": "^3.0.1", + "@smithy/util-base64": "^3.0.0", + "@smithy/util-body-length-browser": "^3.0.0", + "@smithy/util-body-length-node": "^3.0.0", + "@smithy/util-defaults-mode-browser": "^3.0.4", + "@smithy/util-defaults-mode-node": "^3.0.4", + "@smithy/util-endpoints": "^2.0.2", + "@smithy/util-middleware": "^3.0.1", + "@smithy/util-retry": "^3.0.1", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/client-sso-oidc": { + "version": "3.606.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/client-sso-oidc/-/client-sso-oidc-3.606.0.tgz", + "integrity": "sha512-gL1FHPS6hwgMNS/A+Qh5bUyHOeRVOqdb7c6+i+9gR3wtGvt2lvoSm8w5DhS08Xiiacz2AqYRDEapp0xuyCrbBQ==", + "optional": true, + "dependencies": { + "@aws-crypto/sha256-browser": "5.2.0", + "@aws-crypto/sha256-js": "5.2.0", + "@aws-sdk/core": "3.598.0", + "@aws-sdk/credential-provider-node": "3.600.0", + "@aws-sdk/middleware-host-header": "3.598.0", + "@aws-sdk/middleware-logger": "3.598.0", + "@aws-sdk/middleware-recursion-detection": "3.598.0", + "@aws-sdk/middleware-user-agent": "3.598.0", + "@aws-sdk/region-config-resolver": "3.598.0", + "@aws-sdk/types": "3.598.0", + "@aws-sdk/util-endpoints": "3.598.0", + "@aws-sdk/util-user-agent-browser": "3.598.0", + "@aws-sdk/util-user-agent-node": "3.598.0", + "@smithy/config-resolver": "^3.0.2", + "@smithy/core": "^2.2.1", + "@smithy/fetch-http-handler": "^3.0.2", + "@smithy/hash-node": "^3.0.1", + "@smithy/invalid-dependency": "^3.0.1", + "@smithy/middleware-content-length": "^3.0.1", + "@smithy/middleware-endpoint": "^3.0.2", + "@smithy/middleware-retry": "^3.0.4", + "@smithy/middleware-serde": "^3.0.1", + "@smithy/middleware-stack": "^3.0.1", + "@smithy/node-config-provider": "^3.1.1", + "@smithy/node-http-handler": "^3.0.1", + "@smithy/protocol-http": "^4.0.1", + "@smithy/smithy-client": "^3.1.2", + "@smithy/types": "^3.1.0", + "@smithy/url-parser": "^3.0.1", + "@smithy/util-base64": "^3.0.0", + "@smithy/util-body-length-browser": "^3.0.0", + "@smithy/util-body-length-node": "^3.0.0", + "@smithy/util-defaults-mode-browser": "^3.0.4", + "@smithy/util-defaults-mode-node": "^3.0.4", + "@smithy/util-endpoints": "^2.0.2", + "@smithy/util-middleware": "^3.0.1", + "@smithy/util-retry": "^3.0.1", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + }, + "peerDependencies": { + "@aws-sdk/client-sts": "^3.606.0" + } + }, + "node_modules/@aws-sdk/client-sso-oidc/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/client-sso/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/client-sts": { + "version": "3.606.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/client-sts/-/client-sts-3.606.0.tgz", + "integrity": "sha512-b11mAhjrkm3MMiAPoMGcmd6vsaz2120lg8rHG/NZCo9vB1K6Kc7WP+a1Q05TRMseer2egTtpWJfn44aVO97VqA==", + "optional": true, + "dependencies": { + "@aws-crypto/sha256-browser": "5.2.0", + "@aws-crypto/sha256-js": "5.2.0", + "@aws-sdk/client-sso-oidc": "3.606.0", + "@aws-sdk/core": "3.598.0", + "@aws-sdk/credential-provider-node": "3.600.0", + "@aws-sdk/middleware-host-header": "3.598.0", + "@aws-sdk/middleware-logger": "3.598.0", + "@aws-sdk/middleware-recursion-detection": "3.598.0", + "@aws-sdk/middleware-user-agent": "3.598.0", + "@aws-sdk/region-config-resolver": "3.598.0", + "@aws-sdk/types": "3.598.0", + "@aws-sdk/util-endpoints": "3.598.0", + "@aws-sdk/util-user-agent-browser": "3.598.0", + "@aws-sdk/util-user-agent-node": "3.598.0", + "@smithy/config-resolver": "^3.0.2", + "@smithy/core": "^2.2.1", + "@smithy/fetch-http-handler": "^3.0.2", + "@smithy/hash-node": "^3.0.1", + "@smithy/invalid-dependency": "^3.0.1", + "@smithy/middleware-content-length": "^3.0.1", + "@smithy/middleware-endpoint": "^3.0.2", + "@smithy/middleware-retry": "^3.0.4", + "@smithy/middleware-serde": "^3.0.1", + "@smithy/middleware-stack": "^3.0.1", + "@smithy/node-config-provider": "^3.1.1", + "@smithy/node-http-handler": "^3.0.1", + "@smithy/protocol-http": "^4.0.1", + "@smithy/smithy-client": "^3.1.2", + "@smithy/types": "^3.1.0", + "@smithy/url-parser": "^3.0.1", + "@smithy/util-base64": "^3.0.0", + "@smithy/util-body-length-browser": "^3.0.0", + "@smithy/util-body-length-node": "^3.0.0", + "@smithy/util-defaults-mode-browser": "^3.0.4", + "@smithy/util-defaults-mode-node": "^3.0.4", + "@smithy/util-endpoints": "^2.0.2", + "@smithy/util-middleware": "^3.0.1", + "@smithy/util-retry": "^3.0.1", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/client-sts/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/core": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/core/-/core-3.598.0.tgz", + "integrity": "sha512-HaSjt7puO5Cc7cOlrXFCW0rtA0BM9lvzjl56x0A20Pt+0wxXGeTOZZOkXQIepbrFkV2e/HYukuT9e99vXDm59g==", + "optional": true, + "dependencies": { + "@smithy/core": "^2.2.1", + "@smithy/protocol-http": "^4.0.1", + "@smithy/signature-v4": "^3.1.0", + "@smithy/smithy-client": "^3.1.2", + "@smithy/types": "^3.1.0", + "fast-xml-parser": "4.2.5", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/core/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/credential-provider-cognito-identity": { + "version": "3.606.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-cognito-identity/-/credential-provider-cognito-identity-3.606.0.tgz", + "integrity": "sha512-4wGvXilFLkozs4/dMnn9NvxZbL9oyyReoF9aR3kGUZ0QVO8cCBp/Zkr8IXZifhVBo9/esJdMFnR9lEXR7Yuleg==", + "optional": true, + "dependencies": { + "@aws-sdk/client-cognito-identity": "3.606.0", + "@aws-sdk/types": "3.598.0", + "@smithy/property-provider": "^3.1.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/credential-provider-cognito-identity/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/credential-provider-env": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-env/-/credential-provider-env-3.598.0.tgz", + "integrity": "sha512-vi1khgn7yXzLCcgSIzQrrtd2ilUM0dWodxj3PQ6BLfP0O+q1imO3hG1nq7DVyJtq7rFHs6+9N8G4mYvTkxby2w==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@smithy/property-provider": "^3.1.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/credential-provider-env/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/credential-provider-http": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-http/-/credential-provider-http-3.598.0.tgz", + "integrity": "sha512-N7cIafi4HVlQvEgvZSo1G4T9qb/JMLGMdBsDCT5XkeJrF0aptQWzTFH0jIdZcLrMYvzPcuEyO3yCBe6cy/ba0g==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@smithy/fetch-http-handler": "^3.0.2", + "@smithy/node-http-handler": "^3.0.1", + "@smithy/property-provider": "^3.1.1", + "@smithy/protocol-http": "^4.0.1", + "@smithy/smithy-client": "^3.1.2", + "@smithy/types": "^3.1.0", + "@smithy/util-stream": "^3.0.2", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/credential-provider-http/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/credential-provider-ini": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-ini/-/credential-provider-ini-3.598.0.tgz", + "integrity": "sha512-/ppcIVUbRwDIwJDoYfp90X3+AuJo2mvE52Y1t2VSrvUovYn6N4v95/vXj6LS8CNDhz2jvEJYmu+0cTMHdhI6eA==", + "optional": true, + "dependencies": { + "@aws-sdk/credential-provider-env": "3.598.0", + "@aws-sdk/credential-provider-http": "3.598.0", + "@aws-sdk/credential-provider-process": "3.598.0", + "@aws-sdk/credential-provider-sso": "3.598.0", + "@aws-sdk/credential-provider-web-identity": "3.598.0", + "@aws-sdk/types": "3.598.0", + "@smithy/credential-provider-imds": "^3.1.1", + "@smithy/property-provider": "^3.1.1", + "@smithy/shared-ini-file-loader": "^3.1.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + }, + "peerDependencies": { + "@aws-sdk/client-sts": "^3.598.0" + } + }, + "node_modules/@aws-sdk/credential-provider-ini/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/credential-provider-node": { + "version": "3.600.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-node/-/credential-provider-node-3.600.0.tgz", + "integrity": "sha512-1pC7MPMYD45J7yFjA90SxpR0yaSvy+yZiq23aXhAPZLYgJBAxHLu0s0mDCk/piWGPh8+UGur5K0bVdx4B1D5hw==", + "optional": true, + "dependencies": { + "@aws-sdk/credential-provider-env": "3.598.0", + "@aws-sdk/credential-provider-http": "3.598.0", + "@aws-sdk/credential-provider-ini": "3.598.0", + "@aws-sdk/credential-provider-process": "3.598.0", + "@aws-sdk/credential-provider-sso": "3.598.0", + "@aws-sdk/credential-provider-web-identity": "3.598.0", + "@aws-sdk/types": "3.598.0", + "@smithy/credential-provider-imds": "^3.1.1", + "@smithy/property-provider": "^3.1.1", + "@smithy/shared-ini-file-loader": "^3.1.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/credential-provider-node/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/credential-provider-process": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-process/-/credential-provider-process-3.598.0.tgz", + "integrity": "sha512-rM707XbLW8huMk722AgjVyxu2tMZee++fNA8TJVNgs1Ma02Wx6bBrfIvlyK0rCcIRb0WdQYP6fe3Xhiu4e8IBA==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@smithy/property-provider": "^3.1.1", + "@smithy/shared-ini-file-loader": "^3.1.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/credential-provider-process/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/credential-provider-sso": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-sso/-/credential-provider-sso-3.598.0.tgz", + "integrity": "sha512-5InwUmrAuqQdOOgxTccRayMMkSmekdLk6s+az9tmikq0QFAHUCtofI+/fllMXSR9iL6JbGYi1940+EUmS4pHJA==", + "optional": true, + "dependencies": { + "@aws-sdk/client-sso": "3.598.0", + "@aws-sdk/token-providers": "3.598.0", + "@aws-sdk/types": "3.598.0", + "@smithy/property-provider": "^3.1.1", + "@smithy/shared-ini-file-loader": "^3.1.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/credential-provider-sso/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/credential-provider-web-identity": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-web-identity/-/credential-provider-web-identity-3.598.0.tgz", + "integrity": "sha512-GV5GdiMbz5Tz9JO4NJtRoFXjW0GPEujA0j+5J/B723rTN+REHthJu48HdBKouHGhdzkDWkkh1bu52V02Wprw8w==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@smithy/property-provider": "^3.1.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + }, + "peerDependencies": { + "@aws-sdk/client-sts": "^3.598.0" + } + }, + "node_modules/@aws-sdk/credential-provider-web-identity/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/credential-providers": { + "version": "3.606.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-providers/-/credential-providers-3.606.0.tgz", + "integrity": "sha512-34hswGNDWBFvp4Hi4Gv9DIJ4Ks0Nbg8w3emFsPVHLqqI6X2Wd0hJTf+mi1kMhy/AQXt5LisKLw6wjNIKD2+KGg==", + "optional": true, + "dependencies": { + "@aws-sdk/client-cognito-identity": "3.606.0", + "@aws-sdk/client-sso": "3.598.0", + "@aws-sdk/client-sts": "3.606.0", + "@aws-sdk/credential-provider-cognito-identity": "3.606.0", + "@aws-sdk/credential-provider-env": "3.598.0", + "@aws-sdk/credential-provider-http": "3.598.0", + "@aws-sdk/credential-provider-ini": "3.598.0", + "@aws-sdk/credential-provider-node": "3.600.0", + "@aws-sdk/credential-provider-process": "3.598.0", + "@aws-sdk/credential-provider-sso": "3.598.0", + "@aws-sdk/credential-provider-web-identity": "3.598.0", + "@aws-sdk/types": "3.598.0", + "@smithy/credential-provider-imds": "^3.1.1", + "@smithy/property-provider": "^3.1.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/credential-providers/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/middleware-host-header": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-host-header/-/middleware-host-header-3.598.0.tgz", + "integrity": "sha512-WiaG059YBQwQraNejLIi0gMNkX7dfPZ8hDIhvMr5aVPRbaHH8AYF3iNSsXYCHvA2Cfa1O9haYXsuMF9flXnCmA==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@smithy/protocol-http": "^4.0.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/middleware-host-header/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/middleware-logger": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-logger/-/middleware-logger-3.598.0.tgz", + "integrity": "sha512-bxBjf/VYiu3zfu8SYM2S9dQQc3tz5uBAOcPz/Bt8DyyK3GgOpjhschH/2XuUErsoUO1gDJqZSdGOmuHGZQn00Q==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/middleware-logger/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/middleware-recursion-detection": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-recursion-detection/-/middleware-recursion-detection-3.598.0.tgz", + "integrity": "sha512-vjT9BeFY9FeN0f8hm2l6F53tI0N5bUq6RcDkQXKNabXBnQxKptJRad6oP2X5y3FoVfBLOuDkQgiC2940GIPxtQ==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@smithy/protocol-http": "^4.0.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/middleware-recursion-detection/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/middleware-user-agent": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-user-agent/-/middleware-user-agent-3.598.0.tgz", + "integrity": "sha512-4tjESlHG5B5MdjUaLK7tQs/miUtHbb6deauQx8ryqSBYOhfHVgb1ZnzvQR0bTrhpqUg0WlybSkDaZAICf9xctg==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@aws-sdk/util-endpoints": "3.598.0", + "@smithy/protocol-http": "^4.0.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/middleware-user-agent/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/region-config-resolver": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/region-config-resolver/-/region-config-resolver-3.598.0.tgz", + "integrity": "sha512-oYXhmTokSav4ytmWleCr3rs/1nyvZW/S0tdi6X7u+dLNL5Jee+uMxWGzgOrWK6wrQOzucLVjS4E/wA11Kv2GTw==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@smithy/node-config-provider": "^3.1.1", + "@smithy/types": "^3.1.0", + "@smithy/util-config-provider": "^3.0.0", + "@smithy/util-middleware": "^3.0.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/region-config-resolver/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/token-providers": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/token-providers/-/token-providers-3.598.0.tgz", + "integrity": "sha512-TKY1EVdHVBnZqpyxyTHdpZpa1tUpb6nxVeRNn1zWG8QB5MvH4ALLd/jR+gtmWDNQbIG4cVuBOZFVL8hIYicKTA==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@smithy/property-provider": "^3.1.1", + "@smithy/shared-ini-file-loader": "^3.1.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + }, + "peerDependencies": { + "@aws-sdk/client-sso-oidc": "^3.598.0" + } + }, + "node_modules/@aws-sdk/token-providers/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/types": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.598.0.tgz", + "integrity": "sha512-742uRl6z7u0LFmZwDrFP6r1wlZcgVPw+/TilluDJmCAR8BgRw3IR+743kUXKBGd8QZDRW2n6v/PYsi/AWCDDMQ==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/types/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/util-endpoints": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/util-endpoints/-/util-endpoints-3.598.0.tgz", + "integrity": "sha512-Qo9UoiVVZxcOEdiOMZg3xb1mzkTxrhd4qSlg5QQrfWPJVx/QOg+Iy0NtGxPtHtVZNHZxohYwDwV/tfsnDSE2gQ==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@smithy/types": "^3.1.0", + "@smithy/util-endpoints": "^2.0.2", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/util-endpoints/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/util-locate-window": { + "version": "3.568.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/util-locate-window/-/util-locate-window-3.568.0.tgz", + "integrity": "sha512-3nh4TINkXYr+H41QaPelCceEB2FXP3fxp93YZXB/kqJvX0U9j0N0Uk45gvsjmEPzG8XxkPEeLIfT2I1M7A6Lig==", + "optional": true, + "dependencies": { + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@aws-sdk/util-locate-window/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/util-user-agent-browser": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/util-user-agent-browser/-/util-user-agent-browser-3.598.0.tgz", + "integrity": "sha512-36Sxo6F+ykElaL1mWzWjlg+1epMpSe8obwhCN1yGE7Js9ywy5U6k6l+A3q3YM9YRbm740sNxncbwLklMvuhTKw==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@smithy/types": "^3.1.0", + "bowser": "^2.11.0", + "tslib": "^2.6.2" + } + }, + "node_modules/@aws-sdk/util-user-agent-browser/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@aws-sdk/util-user-agent-node": { + "version": "3.598.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/util-user-agent-node/-/util-user-agent-node-3.598.0.tgz", + "integrity": "sha512-oyWGcOlfTdzkC6SVplyr0AGh54IMrDxbhg5RxJ5P+V4BKfcDoDcZV9xenUk9NsOi9MuUjxMumb9UJGkDhM1m0A==", + "optional": true, + "dependencies": { + "@aws-sdk/types": "3.598.0", + "@smithy/node-config-provider": "^3.1.1", + "@smithy/types": "^3.1.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + }, + "peerDependencies": { + "aws-crt": ">=1.0.0" + }, + "peerDependenciesMeta": { + "aws-crt": { + "optional": true + } + } + }, + "node_modules/@aws-sdk/util-user-agent-node/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@babel/code-frame": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.24.7.tgz", + "integrity": "sha512-BcYH1CVJBO9tvyIZ2jVeXgSIMvGZ2FDRvDdOIVQyuklNKSsx+eppDEBq/g47Ayw+RqNFE+URvOShmf+f/qwAlA==", + "dev": true, + "dependencies": { + "@babel/highlight": "^7.24.7", + "picocolors": "^1.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/compat-data": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.24.7.tgz", + "integrity": "sha512-qJzAIcv03PyaWqxRgO4mSU3lihncDT296vnyuE2O8uA4w3UHWI4S3hgeZd1L8W1Bft40w9JxJ2b412iDUFFRhw==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/core": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.24.7.tgz", + "integrity": "sha512-nykK+LEK86ahTkX/3TgauT0ikKoNCfKHEaZYTUVupJdTLzGNvrblu4u6fa7DhZONAltdf8e662t/abY8idrd/g==", + "dev": true, + "dependencies": { + "@ampproject/remapping": "^2.2.0", + "@babel/code-frame": "^7.24.7", + "@babel/generator": "^7.24.7", + "@babel/helper-compilation-targets": "^7.24.7", + "@babel/helper-module-transforms": "^7.24.7", + "@babel/helpers": "^7.24.7", + "@babel/parser": "^7.24.7", + "@babel/template": "^7.24.7", + "@babel/traverse": "^7.24.7", + "@babel/types": "^7.24.7", + "convert-source-map": "^2.0.0", + "debug": "^4.1.0", + "gensync": "^1.0.0-beta.2", + "json5": "^2.2.3", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/babel" + } + }, + "node_modules/@babel/generator": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.24.7.tgz", + "integrity": "sha512-oipXieGC3i45Y1A41t4tAqpnEZWgB/lC6Ehh6+rOviR5XWpTtMmLN+fGjz9vOiNRt0p6RtO6DtD0pdU3vpqdSA==", + "dev": true, + "dependencies": { + "@babel/types": "^7.24.7", + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25", + "jsesc": "^2.5.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-annotate-as-pure": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.24.7.tgz", + "integrity": "sha512-BaDeOonYvhdKw+JoMVkAixAAJzG2jVPIwWoKBPdYuY9b452e2rPuI9QPYh3KpofZ3pW2akOmwZLOiOsHMiqRAg==", + "dev": true, + "dependencies": { + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-builder-binary-assignment-operator-visitor": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.24.7.tgz", + "integrity": "sha512-xZeCVVdwb4MsDBkkyZ64tReWYrLRHlMN72vP7Bdm3OUOuyFZExhsHUUnuWnm2/XOlAJzR0LfPpB56WXZn0X/lA==", + "dev": true, + "dependencies": { + "@babel/traverse": "^7.24.7", + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-compilation-targets": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.24.7.tgz", + "integrity": "sha512-ctSdRHBi20qWOfy27RUb4Fhp07KSJ3sXcuSvTrXrc4aG8NSYDo1ici3Vhg9bg69y5bj0Mr1lh0aeEgTvc12rMg==", + "dev": true, + "dependencies": { + "@babel/compat-data": "^7.24.7", + "@babel/helper-validator-option": "^7.24.7", + "browserslist": "^4.22.2", + "lru-cache": "^5.1.1", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-create-class-features-plugin": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.24.7.tgz", + "integrity": "sha512-kTkaDl7c9vO80zeX1rJxnuRpEsD5tA81yh11X1gQo+PhSti3JS+7qeZo9U4RHobKRiFPKaGK3svUAeb8D0Q7eg==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.24.7", + "@babel/helper-environment-visitor": "^7.24.7", + "@babel/helper-function-name": "^7.24.7", + "@babel/helper-member-expression-to-functions": "^7.24.7", + "@babel/helper-optimise-call-expression": "^7.24.7", + "@babel/helper-replace-supers": "^7.24.7", + "@babel/helper-skip-transparent-expression-wrappers": "^7.24.7", + "@babel/helper-split-export-declaration": "^7.24.7", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-create-regexp-features-plugin": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.24.7.tgz", + "integrity": "sha512-03TCmXy2FtXJEZfbXDTSqq1fRJArk7lX9DOFC/47VthYcxyIOx+eXQmdo6DOQvrbpIix+KfXwvuXdFDZHxt+rA==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.24.7", + "regexpu-core": "^5.3.1", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-define-polyfill-provider": { + "version": "0.6.2", + "resolved": "https://registry.npmjs.org/@babel/helper-define-polyfill-provider/-/helper-define-polyfill-provider-0.6.2.tgz", + "integrity": "sha512-LV76g+C502biUK6AyZ3LK10vDpDyCzZnhZFXkH1L75zHPj68+qc8Zfpx2th+gzwA2MzyK+1g/3EPl62yFnVttQ==", + "dev": true, + "dependencies": { + "@babel/helper-compilation-targets": "^7.22.6", + "@babel/helper-plugin-utils": "^7.22.5", + "debug": "^4.1.1", + "lodash.debounce": "^4.0.8", + "resolve": "^1.14.2" + }, + "peerDependencies": { + "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" + } + }, + "node_modules/@babel/helper-environment-visitor": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.24.7.tgz", + "integrity": "sha512-DoiN84+4Gnd0ncbBOM9AZENV4a5ZiL39HYMyZJGZ/AZEykHYdJw0wW3kdcsh9/Kn+BRXHLkkklZ51ecPKmI1CQ==", + "dev": true, + "dependencies": { + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-function-name": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.24.7.tgz", + "integrity": "sha512-FyoJTsj/PEUWu1/TYRiXTIHc8lbw+TDYkZuoE43opPS5TrI7MyONBE1oNvfguEXAD9yhQRrVBnXdXzSLQl9XnA==", + "dev": true, + "dependencies": { + "@babel/template": "^7.24.7", + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-hoist-variables": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.24.7.tgz", + "integrity": "sha512-MJJwhkoGy5c4ehfoRyrJ/owKeMl19U54h27YYftT0o2teQ3FJ3nQUf/I3LlJsX4l3qlw7WRXUmiyajvHXoTubQ==", + "dev": true, + "dependencies": { + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-member-expression-to-functions": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.24.7.tgz", + "integrity": "sha512-LGeMaf5JN4hAT471eJdBs/GK1DoYIJ5GCtZN/EsL6KUiiDZOvO/eKE11AMZJa2zP4zk4qe9V2O/hxAmkRc8p6w==", + "dev": true, + "dependencies": { + "@babel/traverse": "^7.24.7", + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-imports": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.24.7.tgz", + "integrity": "sha512-8AyH3C+74cgCVVXow/myrynrAGv+nTVg5vKu2nZph9x7RcRwzmh0VFallJuFTZ9mx6u4eSdXZfcOzSqTUm0HCA==", + "dev": true, + "dependencies": { + "@babel/traverse": "^7.24.7", + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-transforms": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.24.7.tgz", + "integrity": "sha512-1fuJEwIrp+97rM4RWdO+qrRsZlAeL1lQJoPqtCYWv0NL115XM93hIH4CSRln2w52SqvmY5hqdtauB6QFCDiZNQ==", + "dev": true, + "dependencies": { + "@babel/helper-environment-visitor": "^7.24.7", + "@babel/helper-module-imports": "^7.24.7", + "@babel/helper-simple-access": "^7.24.7", + "@babel/helper-split-export-declaration": "^7.24.7", + "@babel/helper-validator-identifier": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-optimise-call-expression": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.24.7.tgz", + "integrity": "sha512-jKiTsW2xmWwxT1ixIdfXUZp+P5yURx2suzLZr5Hi64rURpDYdMW0pv+Uf17EYk2Rd428Lx4tLsnjGJzYKDM/6A==", + "dev": true, + "dependencies": { + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-plugin-utils": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.24.7.tgz", + "integrity": "sha512-Rq76wjt7yz9AAc1KnlRKNAi/dMSVWgDRx43FHoJEbcYU6xOWaE2dVPwcdTukJrjxS65GITyfbvEYHvkirZ6uEg==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-remap-async-to-generator": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.24.7.tgz", + "integrity": "sha512-9pKLcTlZ92hNZMQfGCHImUpDOlAgkkpqalWEeftW5FBya75k8Li2ilerxkM/uBEj01iBZXcCIB/bwvDYgWyibA==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.24.7", + "@babel/helper-environment-visitor": "^7.24.7", + "@babel/helper-wrap-function": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-replace-supers": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.24.7.tgz", + "integrity": "sha512-qTAxxBM81VEyoAY0TtLrx1oAEJc09ZK67Q9ljQToqCnA+55eNwCORaxlKyu+rNfX86o8OXRUSNUnrtsAZXM9sg==", + "dev": true, + "dependencies": { + "@babel/helper-environment-visitor": "^7.24.7", + "@babel/helper-member-expression-to-functions": "^7.24.7", + "@babel/helper-optimise-call-expression": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-simple-access": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.24.7.tgz", + "integrity": "sha512-zBAIvbCMh5Ts+b86r/CjU+4XGYIs+R1j951gxI3KmmxBMhCg4oQMsv6ZXQ64XOm/cvzfU1FmoCyt6+owc5QMYg==", + "dev": true, + "dependencies": { + "@babel/traverse": "^7.24.7", + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-skip-transparent-expression-wrappers": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.24.7.tgz", + "integrity": "sha512-IO+DLT3LQUElMbpzlatRASEyQtfhSE0+m465v++3jyyXeBTBUjtVZg28/gHeV5mrTJqvEKhKroBGAvhW+qPHiQ==", + "dev": true, + "dependencies": { + "@babel/traverse": "^7.24.7", + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-split-export-declaration": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.24.7.tgz", + "integrity": "sha512-oy5V7pD+UvfkEATUKvIjvIAH/xCzfsFVw7ygW2SI6NClZzquT+mwdTfgfdbUiceh6iQO0CHtCPsyze/MZ2YbAA==", + "dev": true, + "dependencies": { + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-string-parser": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.24.7.tgz", + "integrity": "sha512-7MbVt6xrwFQbunH2DNQsAP5sTGxfqQtErvBIvIMi6EQnbgUOuVYanvREcmFrOPhoXBrTtjhhP+lW+o5UfK+tDg==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-identifier": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.24.7.tgz", + "integrity": "sha512-rR+PBcQ1SMQDDyF6X0wxtG8QyLCgUB0eRAGguqRLfkCA87l7yAP7ehq8SNj96OOGTO8OBV70KhuFYcIkHXOg0w==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-option": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.24.7.tgz", + "integrity": "sha512-yy1/KvjhV/ZCL+SM7hBrvnZJ3ZuT9OuZgIJAGpPEToANvc3iM6iDvBnRjtElWibHU6n8/LPR/EjX9EtIEYO3pw==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-wrap-function": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-wrap-function/-/helper-wrap-function-7.24.7.tgz", + "integrity": "sha512-N9JIYk3TD+1vq/wn77YnJOqMtfWhNewNE+DJV4puD2X7Ew9J4JvrzrFDfTfyv5EgEXVy9/Wt8QiOErzEmv5Ifw==", + "dev": true, + "dependencies": { + "@babel/helper-function-name": "^7.24.7", + "@babel/template": "^7.24.7", + "@babel/traverse": "^7.24.7", + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helpers": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.24.7.tgz", + "integrity": "sha512-NlmJJtvcw72yRJRcnCmGvSi+3jDEg8qFu3z0AFoymmzLx5ERVWyzd9kVXr7Th9/8yIJi2Zc6av4Tqz3wFs8QWg==", + "dev": true, + "dependencies": { + "@babel/template": "^7.24.7", + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/highlight": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.24.7.tgz", + "integrity": "sha512-EStJpq4OuY8xYfhGVXngigBJRWxftKX9ksiGDnmlY3o7B/V7KIAc9X4oiK87uPJSc/vs5L869bem5fhZa8caZw==", + "dev": true, + "dependencies": { + "@babel/helper-validator-identifier": "^7.24.7", + "chalk": "^2.4.2", + "js-tokens": "^4.0.0", + "picocolors": "^1.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/parser": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.24.7.tgz", + "integrity": "sha512-9uUYRm6OqQrCqQdG1iCBwBPZgN8ciDBro2nIOFaiRz1/BCxaI7CNvQbDHvsArAC7Tw9Hda/B3U+6ui9u4HWXPw==", + "dev": true, + "bin": { + "parser": "bin/babel-parser.js" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/plugin-bugfix-firefox-class-in-computed-class-key": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-firefox-class-in-computed-class-key/-/plugin-bugfix-firefox-class-in-computed-class-key-7.24.7.tgz", + "integrity": "sha512-TiT1ss81W80eQsN+722OaeQMY/G4yTb4G9JrqeiDADs3N8lbPMGldWi9x8tyqCW5NLx1Jh2AvkE6r6QvEltMMQ==", + "dev": true, + "dependencies": { + "@babel/helper-environment-visitor": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression/-/plugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.24.7.tgz", + "integrity": "sha512-unaQgZ/iRu/By6tsjMZzpeBZjChYfLYry6HrEXPoz3KmfF0sVBQ1l8zKMQ4xRGLWVsjuvB8nQfjNP/DcfEOCsg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.24.7.tgz", + "integrity": "sha512-+izXIbke1T33mY4MSNnrqhPXDz01WYhEf3yF5NbnUtkiNnm+XBZJl3kNfoK6NKmYlz/D07+l2GWVK/QfDkNCuQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/helper-skip-transparent-expression-wrappers": "^7.24.7", + "@babel/plugin-transform-optional-chaining": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.13.0" + } + }, + "node_modules/@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly/-/plugin-bugfix-v8-static-class-fields-redefine-readonly-7.24.7.tgz", + "integrity": "sha512-utA4HuR6F4Vvcr+o4DnjL8fCOlgRFGbeeBEGNg3ZTrLFw6VWG5XmUrvcQ0FjIYMU2ST4XcR2Wsp7t9qOAPnxMg==", + "dev": true, + "dependencies": { + "@babel/helper-environment-visitor": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-proposal-private-property-in-object": { + "version": "7.21.0-placeholder-for-preset-env.2", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-private-property-in-object/-/plugin-proposal-private-property-in-object-7.21.0-placeholder-for-preset-env.2.tgz", + "integrity": "sha512-SOSkfJDddaM7mak6cPEpswyTRnuRltl429hMraQEglW+OkovnCzsiszTmsrlY//qLFjCpQDFRvjdm2wA5pPm9w==", + "dev": true, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-async-generators": { + "version": "7.8.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", + "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-bigint": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-bigint/-/plugin-syntax-bigint-7.8.3.tgz", + "integrity": "sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-class-properties": { + "version": "7.12.13", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz", + "integrity": "sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.12.13" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-class-static-block": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-static-block/-/plugin-syntax-class-static-block-7.14.5.tgz", + "integrity": "sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-dynamic-import": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz", + "integrity": "sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-export-namespace-from": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-export-namespace-from/-/plugin-syntax-export-namespace-from-7.8.3.tgz", + "integrity": "sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.3" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-import-assertions": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-assertions/-/plugin-syntax-import-assertions-7.24.7.tgz", + "integrity": "sha512-Ec3NRUMoi8gskrkBe3fNmEQfxDvY8bgfQpz6jlk/41kX9eUjvpyqWU7PBP/pLAvMaSQjbMNKJmvX57jP+M6bPg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-import-attributes": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-attributes/-/plugin-syntax-import-attributes-7.24.7.tgz", + "integrity": "sha512-hbX+lKKeUMGihnK8nvKqmXBInriT3GVjzXKFriV3YC6APGxMbP8RZNFwy91+hocLXq90Mta+HshoB31802bb8A==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-import-meta": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz", + "integrity": "sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-json-strings": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", + "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-jsx": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.24.7.tgz", + "integrity": "sha512-6ddciUPe/mpMnOKv/U+RSd2vvVy+Yw/JfBB0ZHYjEZt9NLHmCUylNYlsbqCCS1Bffjlb0fCwC9Vqz+sBz6PsiQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-logical-assignment-operators": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz", + "integrity": "sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-nullish-coalescing-operator": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", + "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-numeric-separator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", + "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-object-rest-spread": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", + "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-optional-catch-binding": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", + "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-optional-chaining": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", + "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-private-property-in-object": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-private-property-in-object/-/plugin-syntax-private-property-in-object-7.14.5.tgz", + "integrity": "sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-top-level-await": { + "version": "7.14.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz", + "integrity": "sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-typescript": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.24.7.tgz", + "integrity": "sha512-c/+fVeJBB0FeKsFvwytYiUD+LBvhHjGSI0g446PRGdSVGZLRNArBUno2PETbAly3tpiNAQR5XaZ+JslxkotsbA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-unicode-sets-regex": { + "version": "7.18.6", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-unicode-sets-regex/-/plugin-syntax-unicode-sets-regex-7.18.6.tgz", + "integrity": "sha512-727YkEAPwSIQTv5im8QHz3upqp92JTWhidIC81Tdx4VJYIte/VndKf1qKrfnnhPLiPghStWfvC/iFaMCQu7Nqg==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.18.6", + "@babel/helper-plugin-utils": "^7.18.6" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-transform-arrow-functions": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.24.7.tgz", + "integrity": "sha512-Dt9LQs6iEY++gXUwY03DNFat5C2NbO48jj+j/bSAz6b3HgPs39qcPiYt77fDObIcFwj3/C2ICX9YMwGflUoSHQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-async-generator-functions": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-generator-functions/-/plugin-transform-async-generator-functions-7.24.7.tgz", + "integrity": "sha512-o+iF77e3u7ZS4AoAuJvapz9Fm001PuD2V3Lp6OSE4FYQke+cSewYtnek+THqGRWyQloRCyvWL1OkyfNEl9vr/g==", + "dev": true, + "dependencies": { + "@babel/helper-environment-visitor": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/helper-remap-async-to-generator": "^7.24.7", + "@babel/plugin-syntax-async-generators": "^7.8.4" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-async-to-generator": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.24.7.tgz", + "integrity": "sha512-SQY01PcJfmQ+4Ash7NE+rpbLFbmqA2GPIgqzxfFTL4t1FKRq4zTms/7htKpoCUI9OcFYgzqfmCdH53s6/jn5fA==", + "dev": true, + "dependencies": { + "@babel/helper-module-imports": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/helper-remap-async-to-generator": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-block-scoped-functions": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.24.7.tgz", + "integrity": "sha512-yO7RAz6EsVQDaBH18IDJcMB1HnrUn2FJ/Jslc/WtPPWcjhpUJXU/rjbwmluzp7v/ZzWcEhTMXELnnsz8djWDwQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-block-scoping": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.24.7.tgz", + "integrity": "sha512-Nd5CvgMbWc+oWzBsuaMcbwjJWAcp5qzrbg69SZdHSP7AMY0AbWFqFO0WTFCA1jxhMCwodRwvRec8k0QUbZk7RQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-class-properties": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-class-properties/-/plugin-transform-class-properties-7.24.7.tgz", + "integrity": "sha512-vKbfawVYayKcSeSR5YYzzyXvsDFWU2mD8U5TFeXtbCPLFUqe7GyCgvO6XDHzje862ODrOwy6WCPmKeWHbCFJ4w==", + "dev": true, + "dependencies": { + "@babel/helper-create-class-features-plugin": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-class-static-block": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-class-static-block/-/plugin-transform-class-static-block-7.24.7.tgz", + "integrity": "sha512-HMXK3WbBPpZQufbMG4B46A90PkuuhN9vBCb5T8+VAHqvAqvcLi+2cKoukcpmUYkszLhScU3l1iudhrks3DggRQ==", + "dev": true, + "dependencies": { + "@babel/helper-create-class-features-plugin": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/plugin-syntax-class-static-block": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.12.0" + } + }, + "node_modules/@babel/plugin-transform-classes": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-classes/-/plugin-transform-classes-7.24.7.tgz", + "integrity": "sha512-CFbbBigp8ln4FU6Bpy6g7sE8B/WmCmzvivzUC6xDAdWVsjYTXijpuuGJmYkAaoWAzcItGKT3IOAbxRItZ5HTjw==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.24.7", + "@babel/helper-compilation-targets": "^7.24.7", + "@babel/helper-environment-visitor": "^7.24.7", + "@babel/helper-function-name": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/helper-replace-supers": "^7.24.7", + "@babel/helper-split-export-declaration": "^7.24.7", + "globals": "^11.1.0" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-computed-properties": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.24.7.tgz", + "integrity": "sha512-25cS7v+707Gu6Ds2oY6tCkUwsJ9YIDbggd9+cu9jzzDgiNq7hR/8dkzxWfKWnTic26vsI3EsCXNd4iEB6e8esQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/template": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-destructuring": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.24.7.tgz", + "integrity": "sha512-19eJO/8kdCQ9zISOf+SEUJM/bAUIsvY3YDnXZTupUCQ8LgrWnsG/gFB9dvXqdXnRXMAM8fvt7b0CBKQHNGy1mw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-dotall-regex": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.24.7.tgz", + "integrity": "sha512-ZOA3W+1RRTSWvyqcMJDLqbchh7U4NRGqwRfFSVbOLS/ePIP4vHB5e8T8eXcuqyN1QkgKyj5wuW0lcS85v4CrSw==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-duplicate-keys": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.24.7.tgz", + "integrity": "sha512-JdYfXyCRihAe46jUIliuL2/s0x0wObgwwiGxw/UbgJBr20gQBThrokO4nYKgWkD7uBaqM7+9x5TU7NkExZJyzw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-dynamic-import": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-dynamic-import/-/plugin-transform-dynamic-import-7.24.7.tgz", + "integrity": "sha512-sc3X26PhZQDb3JhORmakcbvkeInvxz+A8oda99lj7J60QRuPZvNAk9wQlTBS1ZynelDrDmTU4pw1tyc5d5ZMUg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/plugin-syntax-dynamic-import": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-exponentiation-operator": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.24.7.tgz", + "integrity": "sha512-Rqe/vSc9OYgDajNIK35u7ot+KeCoetqQYFXM4Epf7M7ez3lWlOjrDjrwMei6caCVhfdw+mIKD4cgdGNy5JQotQ==", + "dev": true, + "dependencies": { + "@babel/helper-builder-binary-assignment-operator-visitor": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-export-namespace-from": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-export-namespace-from/-/plugin-transform-export-namespace-from-7.24.7.tgz", + "integrity": "sha512-v0K9uNYsPL3oXZ/7F9NNIbAj2jv1whUEtyA6aujhekLs56R++JDQuzRcP2/z4WX5Vg/c5lE9uWZA0/iUoFhLTA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/plugin-syntax-export-namespace-from": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-for-of": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.24.7.tgz", + "integrity": "sha512-wo9ogrDG1ITTTBsy46oGiN1dS9A7MROBTcYsfS8DtsImMkHk9JXJ3EWQM6X2SUw4x80uGPlwj0o00Uoc6nEE3g==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/helper-skip-transparent-expression-wrappers": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-function-name": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.24.7.tgz", + "integrity": "sha512-U9FcnA821YoILngSmYkW6FjyQe2TyZD5pHt4EVIhmcTkrJw/3KqcrRSxuOo5tFZJi7TE19iDyI1u+weTI7bn2w==", + "dev": true, + "dependencies": { + "@babel/helper-compilation-targets": "^7.24.7", + "@babel/helper-function-name": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-json-strings": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-json-strings/-/plugin-transform-json-strings-7.24.7.tgz", + "integrity": "sha512-2yFnBGDvRuxAaE/f0vfBKvtnvvqU8tGpMHqMNpTN2oWMKIR3NqFkjaAgGwawhqK/pIN2T3XdjGPdaG0vDhOBGw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/plugin-syntax-json-strings": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-literals": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-literals/-/plugin-transform-literals-7.24.7.tgz", + "integrity": "sha512-vcwCbb4HDH+hWi8Pqenwnjy+UiklO4Kt1vfspcQYFhJdpthSnW8XvWGyDZWKNVrVbVViI/S7K9PDJZiUmP2fYQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-logical-assignment-operators": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-logical-assignment-operators/-/plugin-transform-logical-assignment-operators-7.24.7.tgz", + "integrity": "sha512-4D2tpwlQ1odXmTEIFWy9ELJcZHqrStlzK/dAOWYyxX3zT0iXQB6banjgeOJQXzEc4S0E0a5A+hahxPaEFYftsw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-member-expression-literals": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.24.7.tgz", + "integrity": "sha512-T/hRC1uqrzXMKLQ6UCwMT85S3EvqaBXDGf0FaMf4446Qx9vKwlghvee0+uuZcDUCZU5RuNi4781UQ7R308zzBw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-modules-amd": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.24.7.tgz", + "integrity": "sha512-9+pB1qxV3vs/8Hdmz/CulFB8w2tuu6EB94JZFsjdqxQokwGa9Unap7Bo2gGBGIvPmDIVvQrom7r5m/TCDMURhg==", + "dev": true, + "dependencies": { + "@babel/helper-module-transforms": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-modules-commonjs": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.24.7.tgz", + "integrity": "sha512-iFI8GDxtevHJ/Z22J5xQpVqFLlMNstcLXh994xifFwxxGslr2ZXXLWgtBeLctOD63UFDArdvN6Tg8RFw+aEmjQ==", + "dev": true, + "dependencies": { + "@babel/helper-module-transforms": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/helper-simple-access": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-modules-systemjs": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.24.7.tgz", + "integrity": "sha512-GYQE0tW7YoaN13qFh3O1NCY4MPkUiAH3fiF7UcV/I3ajmDKEdG3l+UOcbAm4zUE3gnvUU+Eni7XrVKo9eO9auw==", + "dev": true, + "dependencies": { + "@babel/helper-hoist-variables": "^7.24.7", + "@babel/helper-module-transforms": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/helper-validator-identifier": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-modules-umd": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.24.7.tgz", + "integrity": "sha512-3aytQvqJ/h9z4g8AsKPLvD4Zqi2qT+L3j7XoFFu1XBlZWEl2/1kWnhmAbxpLgPrHSY0M6UA02jyTiwUVtiKR6A==", + "dev": true, + "dependencies": { + "@babel/helper-module-transforms": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-named-capturing-groups-regex": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.24.7.tgz", + "integrity": "sha512-/jr7h/EWeJtk1U/uz2jlsCioHkZk1JJZVcc8oQsJ1dUlaJD83f4/6Zeh2aHt9BIFokHIsSeDfhUmju0+1GPd6g==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-transform-new-target": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.24.7.tgz", + "integrity": "sha512-RNKwfRIXg4Ls/8mMTza5oPF5RkOW8Wy/WgMAp1/F1yZ8mMbtwXW+HDoJiOsagWrAhI5f57Vncrmr9XeT4CVapA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-nullish-coalescing-operator": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-nullish-coalescing-operator/-/plugin-transform-nullish-coalescing-operator-7.24.7.tgz", + "integrity": "sha512-Ts7xQVk1OEocqzm8rHMXHlxvsfZ0cEF2yomUqpKENHWMF4zKk175Y4q8H5knJes6PgYad50uuRmt3UJuhBw8pQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-numeric-separator": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-numeric-separator/-/plugin-transform-numeric-separator-7.24.7.tgz", + "integrity": "sha512-e6q1TiVUzvH9KRvicuxdBTUj4AdKSRwzIyFFnfnezpCfP2/7Qmbb8qbU2j7GODbl4JMkblitCQjKYUaX/qkkwA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/plugin-syntax-numeric-separator": "^7.10.4" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-object-rest-spread": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-rest-spread/-/plugin-transform-object-rest-spread-7.24.7.tgz", + "integrity": "sha512-4QrHAr0aXQCEFni2q4DqKLD31n2DL+RxcwnNjDFkSG0eNQ/xCavnRkfCUjsyqGC2OviNJvZOF/mQqZBw7i2C5Q==", + "dev": true, + "dependencies": { + "@babel/helper-compilation-targets": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/plugin-syntax-object-rest-spread": "^7.8.3", + "@babel/plugin-transform-parameters": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-object-super": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.24.7.tgz", + "integrity": "sha512-A/vVLwN6lBrMFmMDmPPz0jnE6ZGx7Jq7d6sT/Ev4H65RER6pZ+kczlf1DthF5N0qaPHBsI7UXiE8Zy66nmAovg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/helper-replace-supers": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-optional-catch-binding": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-optional-catch-binding/-/plugin-transform-optional-catch-binding-7.24.7.tgz", + "integrity": "sha512-uLEndKqP5BfBbC/5jTwPxLh9kqPWWgzN/f8w6UwAIirAEqiIVJWWY312X72Eub09g5KF9+Zn7+hT7sDxmhRuKA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-optional-chaining": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-optional-chaining/-/plugin-transform-optional-chaining-7.24.7.tgz", + "integrity": "sha512-tK+0N9yd4j+x/4hxF3F0e0fu/VdcxU18y5SevtyM/PCFlQvXbR0Zmlo2eBrKtVipGNFzpq56o8WsIIKcJFUCRQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/helper-skip-transparent-expression-wrappers": "^7.24.7", + "@babel/plugin-syntax-optional-chaining": "^7.8.3" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-parameters": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.24.7.tgz", + "integrity": "sha512-yGWW5Rr+sQOhK0Ot8hjDJuxU3XLRQGflvT4lhlSY0DFvdb3TwKaY26CJzHtYllU0vT9j58hc37ndFPsqT1SrzA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-private-methods": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-private-methods/-/plugin-transform-private-methods-7.24.7.tgz", + "integrity": "sha512-COTCOkG2hn4JKGEKBADkA8WNb35TGkkRbI5iT845dB+NyqgO8Hn+ajPbSnIQznneJTa3d30scb6iz/DhH8GsJQ==", + "dev": true, + "dependencies": { + "@babel/helper-create-class-features-plugin": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-private-property-in-object": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-private-property-in-object/-/plugin-transform-private-property-in-object-7.24.7.tgz", + "integrity": "sha512-9z76mxwnwFxMyxZWEgdgECQglF2Q7cFLm0kMf8pGwt+GSJsY0cONKj/UuO4bOH0w/uAel3ekS4ra5CEAyJRmDA==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.24.7", + "@babel/helper-create-class-features-plugin": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/plugin-syntax-private-property-in-object": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-property-literals": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.24.7.tgz", + "integrity": "sha512-EMi4MLQSHfd2nrCqQEWxFdha2gBCqU4ZcCng4WBGZ5CJL4bBRW0ptdqqDdeirGZcpALazVVNJqRmsO8/+oNCBA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-regenerator": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.24.7.tgz", + "integrity": "sha512-lq3fvXPdimDrlg6LWBoqj+r/DEWgONuwjuOuQCSYgRroXDH/IdM1C0IZf59fL5cHLpjEH/O6opIRBbqv7ELnuA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "regenerator-transform": "^0.15.2" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-reserved-words": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.24.7.tgz", + "integrity": "sha512-0DUq0pHcPKbjFZCfTss/pGkYMfy3vFWydkUBd9r0GHpIyfs2eCDENvqadMycRS9wZCXR41wucAfJHJmwA0UmoQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-shorthand-properties": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.24.7.tgz", + "integrity": "sha512-KsDsevZMDsigzbA09+vacnLpmPH4aWjcZjXdyFKGzpplxhbeB4wYtury3vglQkg6KM/xEPKt73eCjPPf1PgXBA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-spread": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-spread/-/plugin-transform-spread-7.24.7.tgz", + "integrity": "sha512-x96oO0I09dgMDxJaANcRyD4ellXFLLiWhuwDxKZX5g2rWP1bTPkBSwCYv96VDXVT1bD9aPj8tppr5ITIh8hBng==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/helper-skip-transparent-expression-wrappers": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-sticky-regex": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.24.7.tgz", + "integrity": "sha512-kHPSIJc9v24zEml5geKg9Mjx5ULpfncj0wRpYtxbvKyTtHCYDkVE3aHQ03FrpEo4gEe2vrJJS1Y9CJTaThA52g==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-template-literals": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.24.7.tgz", + "integrity": "sha512-AfDTQmClklHCOLxtGoP7HkeMw56k1/bTQjwsfhL6pppo/M4TOBSq+jjBUBLmV/4oeFg4GWMavIl44ZeCtmmZTw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-typeof-symbol": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.24.7.tgz", + "integrity": "sha512-VtR8hDy7YLB7+Pet9IarXjg/zgCMSF+1mNS/EQEiEaUPoFXCVsHG64SIxcaaI2zJgRiv+YmgaQESUfWAdbjzgg==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-typescript": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.24.7.tgz", + "integrity": "sha512-iLD3UNkgx2n/HrjBesVbYX6j0yqn/sJktvbtKKgcaLIQ4bTTQ8obAypc1VpyHPD2y4Phh9zHOaAt8e/L14wCpw==", + "dev": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.24.7", + "@babel/helper-create-class-features-plugin": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/plugin-syntax-typescript": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-unicode-escapes": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.24.7.tgz", + "integrity": "sha512-U3ap1gm5+4edc2Q/P+9VrBNhGkfnf+8ZqppY71Bo/pzZmXhhLdqgaUl6cuB07O1+AQJtCLfaOmswiNbSQ9ivhw==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-unicode-property-regex": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-property-regex/-/plugin-transform-unicode-property-regex-7.24.7.tgz", + "integrity": "sha512-uH2O4OV5M9FZYQrwc7NdVmMxQJOCCzFeYudlZSzUAHRFeOujQefa92E74TQDVskNHCzOXoigEuoyzHDhaEaK5w==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-unicode-regex": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.24.7.tgz", + "integrity": "sha512-hlQ96MBZSAXUq7ltkjtu3FJCCSMx/j629ns3hA3pXnBXjanNP0LHi+JpPeA81zaWgVK1VGH95Xuy7u0RyQ8kMg==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-unicode-sets-regex": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-sets-regex/-/plugin-transform-unicode-sets-regex-7.24.7.tgz", + "integrity": "sha512-2G8aAvF4wy1w/AGZkemprdGMRg5o6zPNhbHVImRz3lss55TYCBd6xStN19rt8XJHq20sqV0JbyWjOWwQRwV/wg==", + "dev": true, + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/preset-env": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.24.7.tgz", + "integrity": "sha512-1YZNsc+y6cTvWlDHidMBsQZrZfEFjRIo/BZCT906PMdzOyXtSLTgqGdrpcuTDCXyd11Am5uQULtDIcCfnTc8fQ==", + "dev": true, + "dependencies": { + "@babel/compat-data": "^7.24.7", + "@babel/helper-compilation-targets": "^7.24.7", + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/helper-validator-option": "^7.24.7", + "@babel/plugin-bugfix-firefox-class-in-computed-class-key": "^7.24.7", + "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": "^7.24.7", + "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": "^7.24.7", + "@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly": "^7.24.7", + "@babel/plugin-proposal-private-property-in-object": "7.21.0-placeholder-for-preset-env.2", + "@babel/plugin-syntax-async-generators": "^7.8.4", + "@babel/plugin-syntax-class-properties": "^7.12.13", + "@babel/plugin-syntax-class-static-block": "^7.14.5", + "@babel/plugin-syntax-dynamic-import": "^7.8.3", + "@babel/plugin-syntax-export-namespace-from": "^7.8.3", + "@babel/plugin-syntax-import-assertions": "^7.24.7", + "@babel/plugin-syntax-import-attributes": "^7.24.7", + "@babel/plugin-syntax-import-meta": "^7.10.4", + "@babel/plugin-syntax-json-strings": "^7.8.3", + "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3", + "@babel/plugin-syntax-numeric-separator": "^7.10.4", + "@babel/plugin-syntax-object-rest-spread": "^7.8.3", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.3", + "@babel/plugin-syntax-optional-chaining": "^7.8.3", + "@babel/plugin-syntax-private-property-in-object": "^7.14.5", + "@babel/plugin-syntax-top-level-await": "^7.14.5", + "@babel/plugin-syntax-unicode-sets-regex": "^7.18.6", + "@babel/plugin-transform-arrow-functions": "^7.24.7", + "@babel/plugin-transform-async-generator-functions": "^7.24.7", + "@babel/plugin-transform-async-to-generator": "^7.24.7", + "@babel/plugin-transform-block-scoped-functions": "^7.24.7", + "@babel/plugin-transform-block-scoping": "^7.24.7", + "@babel/plugin-transform-class-properties": "^7.24.7", + "@babel/plugin-transform-class-static-block": "^7.24.7", + "@babel/plugin-transform-classes": "^7.24.7", + "@babel/plugin-transform-computed-properties": "^7.24.7", + "@babel/plugin-transform-destructuring": "^7.24.7", + "@babel/plugin-transform-dotall-regex": "^7.24.7", + "@babel/plugin-transform-duplicate-keys": "^7.24.7", + "@babel/plugin-transform-dynamic-import": "^7.24.7", + "@babel/plugin-transform-exponentiation-operator": "^7.24.7", + "@babel/plugin-transform-export-namespace-from": "^7.24.7", + "@babel/plugin-transform-for-of": "^7.24.7", + "@babel/plugin-transform-function-name": "^7.24.7", + "@babel/plugin-transform-json-strings": "^7.24.7", + "@babel/plugin-transform-literals": "^7.24.7", + "@babel/plugin-transform-logical-assignment-operators": "^7.24.7", + "@babel/plugin-transform-member-expression-literals": "^7.24.7", + "@babel/plugin-transform-modules-amd": "^7.24.7", + "@babel/plugin-transform-modules-commonjs": "^7.24.7", + "@babel/plugin-transform-modules-systemjs": "^7.24.7", + "@babel/plugin-transform-modules-umd": "^7.24.7", + "@babel/plugin-transform-named-capturing-groups-regex": "^7.24.7", + "@babel/plugin-transform-new-target": "^7.24.7", + "@babel/plugin-transform-nullish-coalescing-operator": "^7.24.7", + "@babel/plugin-transform-numeric-separator": "^7.24.7", + "@babel/plugin-transform-object-rest-spread": "^7.24.7", + "@babel/plugin-transform-object-super": "^7.24.7", + "@babel/plugin-transform-optional-catch-binding": "^7.24.7", + "@babel/plugin-transform-optional-chaining": "^7.24.7", + "@babel/plugin-transform-parameters": "^7.24.7", + "@babel/plugin-transform-private-methods": "^7.24.7", + "@babel/plugin-transform-private-property-in-object": "^7.24.7", + "@babel/plugin-transform-property-literals": "^7.24.7", + "@babel/plugin-transform-regenerator": "^7.24.7", + "@babel/plugin-transform-reserved-words": "^7.24.7", + "@babel/plugin-transform-shorthand-properties": "^7.24.7", + "@babel/plugin-transform-spread": "^7.24.7", + "@babel/plugin-transform-sticky-regex": "^7.24.7", + "@babel/plugin-transform-template-literals": "^7.24.7", + "@babel/plugin-transform-typeof-symbol": "^7.24.7", + "@babel/plugin-transform-unicode-escapes": "^7.24.7", + "@babel/plugin-transform-unicode-property-regex": "^7.24.7", + "@babel/plugin-transform-unicode-regex": "^7.24.7", + "@babel/plugin-transform-unicode-sets-regex": "^7.24.7", + "@babel/preset-modules": "0.1.6-no-external-plugins", + "babel-plugin-polyfill-corejs2": "^0.4.10", + "babel-plugin-polyfill-corejs3": "^0.10.4", + "babel-plugin-polyfill-regenerator": "^0.6.1", + "core-js-compat": "^3.31.0", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-modules": { + "version": "0.1.6-no-external-plugins", + "resolved": "https://registry.npmjs.org/@babel/preset-modules/-/preset-modules-0.1.6-no-external-plugins.tgz", + "integrity": "sha512-HrcgcIESLm9aIR842yhJ5RWan/gebQUJ6E/E5+rf0y9o6oj7w0Br+sWuL6kEQ/o/AdfvR1Je9jG18/gnpwjEyA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.0.0", + "@babel/types": "^7.4.4", + "esutils": "^2.0.2" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0 || ^8.0.0-0 <8.0.0" + } + }, + "node_modules/@babel/preset-typescript": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/preset-typescript/-/preset-typescript-7.24.7.tgz", + "integrity": "sha512-SyXRe3OdWwIwalxDg5UtJnJQO+YPcTfwiIY2B0Xlddh9o7jpWLvv8X1RthIeDOxQ+O1ML5BLPCONToObyVQVuQ==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.24.7", + "@babel/helper-validator-option": "^7.24.7", + "@babel/plugin-syntax-jsx": "^7.24.7", + "@babel/plugin-transform-modules-commonjs": "^7.24.7", + "@babel/plugin-transform-typescript": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/regjsgen": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/@babel/regjsgen/-/regjsgen-0.8.0.tgz", + "integrity": "sha512-x/rqGMdzj+fWZvCOYForTghzbtqPDZ5gPwaoNGHdgDfF2QA/XZbCBp4Moo5scrkAMPhB7z26XM/AaHuIJdgauA==", + "dev": true + }, + "node_modules/@babel/runtime": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.24.7.tgz", + "integrity": "sha512-UwgBRMjJP+xv857DCngvqXI3Iq6J4v0wXmwc6sapg+zyhbwmQX67LUEFrkK5tbyJ30jGuG3ZvWpBiB9LCy1kWw==", + "dependencies": { + "regenerator-runtime": "^0.14.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/template": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.24.7.tgz", + "integrity": "sha512-jYqfPrU9JTF0PmPy1tLYHW4Mp4KlgxJD9l2nP9fD6yT/ICi554DmrWBAEYpIelzjHf1msDP3PxJIRt/nFNfBig==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.24.7", + "@babel/parser": "^7.24.7", + "@babel/types": "^7.24.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/traverse": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.24.7.tgz", + "integrity": "sha512-yb65Ed5S/QAcewNPh0nZczy9JdYXkkAbIsEo+P7BE7yO3txAY30Y/oPa3QkQ5It3xVG2kpKMg9MsdxZaO31uKA==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.24.7", + "@babel/generator": "^7.24.7", + "@babel/helper-environment-visitor": "^7.24.7", + "@babel/helper-function-name": "^7.24.7", + "@babel/helper-hoist-variables": "^7.24.7", + "@babel/helper-split-export-declaration": "^7.24.7", + "@babel/parser": "^7.24.7", + "@babel/types": "^7.24.7", + "debug": "^4.3.1", + "globals": "^11.1.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/types": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.24.7.tgz", + "integrity": "sha512-XEFXSlxiG5td2EJRe8vOmRbaXVgfcBlszKujvVmWIK/UpywWljQCfzAv3RQCGujWQ1RD4YYWEAqDXfuJiy8f5Q==", + "dev": true, + "dependencies": { + "@babel/helper-string-parser": "^7.24.7", + "@babel/helper-validator-identifier": "^7.24.7", + "to-fast-properties": "^2.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@bcoe/v8-coverage": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz", + "integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==", + "dev": true + }, + "node_modules/@cspotcode/source-map-support": { + "version": "0.8.1", + "resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz", + "integrity": "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==", + "dev": true, + "optional": true, + "peer": true, + "dependencies": { + "@jridgewell/trace-mapping": "0.3.9" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/@cspotcode/source-map-support/node_modules/@jridgewell/trace-mapping": { + "version": "0.3.9", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz", + "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==", + "dev": true, + "optional": true, + "peer": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.0.3", + "@jridgewell/sourcemap-codec": "^1.4.10" + } + }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.21.5.tgz", + "integrity": "sha512-1SDgH6ZSPTlggy1yI6+Dbkiz8xzpHJEVAlF/AM1tHPLsf5STom9rwtjE4hKAF20FfXXNTFqEYXyJNWh1GiZedQ==", + "cpu": [ + "ppc64" + ], + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.21.5.tgz", + "integrity": "sha512-vCPvzSjpPHEi1siZdlvAlsPxXl7WbOVUBBAowWug4rJHb68Ox8KualB+1ocNvT5fjv6wpkX6o/iEpbDrf68zcg==", + "cpu": [ + "arm" + ], + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.21.5.tgz", + "integrity": "sha512-c0uX9VAUBQ7dTDCjq+wdyGLowMdtR/GoC2U5IYk/7D1H1JYC0qseD7+11iMP2mRLN9RcCMRcjC4YMclCzGwS/A==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.21.5.tgz", + "integrity": "sha512-D7aPRUUNHRBwHxzxRvp856rjUHRFW1SdQATKXH2hqA0kAZb1hKmi02OpYRacl0TxIGz/ZmXWlbZgjwWYaCakTA==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.21.5.tgz", + "integrity": "sha512-DwqXqZyuk5AiWWf3UfLiRDJ5EDd49zg6O9wclZ7kUMv2WRFr4HKjXp/5t8JZ11QbQfUS6/cRCKGwYhtNAY88kQ==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.21.5.tgz", + "integrity": "sha512-se/JjF8NlmKVG4kNIuyWMV/22ZaerB+qaSi5MdrXtd6R08kvs2qCN4C09miupktDitvh8jRFflwGFBQcxZRjbw==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.21.5.tgz", + "integrity": "sha512-5JcRxxRDUJLX8JXp/wcBCy3pENnCgBR9bN6JsY4OmhfUtIHe3ZW0mawA7+RDAcMLrMIZaf03NlQiX9DGyB8h4g==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.21.5.tgz", + "integrity": "sha512-J95kNBj1zkbMXtHVH29bBriQygMXqoVQOQYA+ISs0/2l3T9/kj42ow2mpqerRBxDJnmkUDCaQT/dfNXWX/ZZCQ==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.21.5.tgz", + "integrity": "sha512-bPb5AHZtbeNGjCKVZ9UGqGwo8EUu4cLq68E95A53KlxAPRmUyYv2D6F0uUI65XisGOL1hBP5mTronbgo+0bFcA==", + "cpu": [ + "arm" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.21.5.tgz", + "integrity": "sha512-ibKvmyYzKsBeX8d8I7MH/TMfWDXBF3db4qM6sy+7re0YXya+K1cem3on9XgdT2EQGMu4hQyZhan7TeQ8XkGp4Q==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.21.5.tgz", + "integrity": "sha512-YvjXDqLRqPDl2dvRODYmmhz4rPeVKYvppfGYKSNGdyZkA01046pLWyRKKI3ax8fbJoK5QbxblURkwK/MWY18Tg==", + "cpu": [ + "ia32" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.21.5.tgz", + "integrity": "sha512-uHf1BmMG8qEvzdrzAqg2SIG/02+4/DHB6a9Kbya0XDvwDEKCoC8ZRWI5JJvNdUjtciBGFQ5PuBlpEOXQj+JQSg==", + "cpu": [ + "loong64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.21.5.tgz", + "integrity": "sha512-IajOmO+KJK23bj52dFSNCMsz1QP1DqM6cwLUv3W1QwyxkyIWecfafnI555fvSGqEKwjMXVLokcV5ygHW5b3Jbg==", + "cpu": [ + "mips64el" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.21.5.tgz", + "integrity": "sha512-1hHV/Z4OEfMwpLO8rp7CvlhBDnjsC3CttJXIhBi+5Aj5r+MBvy4egg7wCbe//hSsT+RvDAG7s81tAvpL2XAE4w==", + "cpu": [ + "ppc64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.21.5.tgz", + "integrity": "sha512-2HdXDMd9GMgTGrPWnJzP2ALSokE/0O5HhTUvWIbD3YdjME8JwvSCnNGBnTThKGEB91OZhzrJ4qIIxk/SBmyDDA==", + "cpu": [ + "riscv64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.21.5.tgz", + "integrity": "sha512-zus5sxzqBJD3eXxwvjN1yQkRepANgxE9lgOW2qLnmr8ikMTphkjgXu1HR01K4FJg8h1kEEDAqDcZQtbrRnB41A==", + "cpu": [ + "s390x" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.21.5.tgz", + "integrity": "sha512-1rYdTpyv03iycF1+BhzrzQJCdOuAOtaqHTWJZCWvijKD2N5Xu0TtVC8/+1faWqcP9iBCWOmjmhoH94dH82BxPQ==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.21.5.tgz", + "integrity": "sha512-Woi2MXzXjMULccIwMnLciyZH4nCIMpWQAs049KEeMvOcNADVxo0UBIQPfSmxB3CWKedngg7sWZdLvLczpe0tLg==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.21.5.tgz", + "integrity": "sha512-HLNNw99xsvx12lFBUwoT8EVCsSvRNDVxNpjZ7bPn947b8gJPzeHWyNVhFsaerc0n3TsbOINvRP2byTZ5LKezow==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.21.5.tgz", + "integrity": "sha512-6+gjmFpfy0BHU5Tpptkuh8+uw3mnrvgs+dSPQXQOv3ekbordwnzTVEb4qnIvQcYXq6gzkyTnoZ9dZG+D4garKg==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.21.5.tgz", + "integrity": "sha512-Z0gOTd75VvXqyq7nsl93zwahcTROgqvuAcYDUr+vOv8uHhNSKROyU961kgtCD1e95IqPKSQKH7tBTslnS3tA8A==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.21.5.tgz", + "integrity": "sha512-SWXFF1CL2RVNMaVs+BBClwtfZSvDgtL//G/smwAc5oVK/UPu2Gu9tIaRgFmYFFKrmg3SyAjSrElf0TiJ1v8fYA==", + "cpu": [ + "ia32" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.21.5.tgz", + "integrity": "sha512-tQd/1efJuzPC6rCFwEvLtci/xNFcTZknmXs98FYDfGE4wP9ClFV98nyKrzJKVPMhdDnjzLhdUyMX4PsQAPjwIw==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@istanbuljs/load-nyc-config": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz", + "integrity": "sha512-VjeHSlIzpv/NyD3N0YuHfXOPDIixcA1q2ZV98wsMqcYlPmv2n3Yb2lYP9XMElnaFVXg5A7YLTeLu6V84uQDjmQ==", + "dev": true, + "dependencies": { + "camelcase": "^5.3.1", + "find-up": "^4.1.0", + "get-package-type": "^0.1.0", + "js-yaml": "^3.13.1", + "resolve-from": "^5.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@istanbuljs/schema": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/@istanbuljs/schema/-/schema-0.1.3.tgz", + "integrity": "sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/console": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/console/-/console-29.7.0.tgz", + "integrity": "sha512-5Ni4CU7XHQi32IJ398EEP4RrB8eV09sXP2ROqD4bksHrnTree52PsxvX8tpL8LvTZ3pFzXyPbNQReSN41CAhOg==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0", + "slash": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/console/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@jest/console/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/@jest/console/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/@jest/console/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/@jest/console/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/console/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/core": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/core/-/core-29.7.0.tgz", + "integrity": "sha512-n7aeXWKMnGtDA48y8TLWJPJmLmmZ642Ceo78cYWEpiD7FzDgmNDV/GCVRorPABdXLJZ/9wzzgZAlHjXjxDHGsg==", + "dev": true, + "dependencies": { + "@jest/console": "^29.7.0", + "@jest/reporters": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "ansi-escapes": "^4.2.1", + "chalk": "^4.0.0", + "ci-info": "^3.2.0", + "exit": "^0.1.2", + "graceful-fs": "^4.2.9", + "jest-changed-files": "^29.7.0", + "jest-config": "^29.7.0", + "jest-haste-map": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-regex-util": "^29.6.3", + "jest-resolve": "^29.7.0", + "jest-resolve-dependencies": "^29.7.0", + "jest-runner": "^29.7.0", + "jest-runtime": "^29.7.0", + "jest-snapshot": "^29.7.0", + "jest-util": "^29.7.0", + "jest-validate": "^29.7.0", + "jest-watcher": "^29.7.0", + "micromatch": "^4.0.4", + "pretty-format": "^29.7.0", + "slash": "^3.0.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } + } + }, + "node_modules/@jest/core/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@jest/core/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/@jest/core/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/@jest/core/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/@jest/core/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/core/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/environment": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.7.0.tgz", + "integrity": "sha512-aQIfHDq33ExsN4jP1NWGXhxgQ/wixs60gDiKO+XVMd8Mn0NWPWgc34ZQDTb2jKaUWQ7MuwoitXAsN2XVXNMpAw==", + "dev": true, + "dependencies": { + "@jest/fake-timers": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "jest-mock": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/expect": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.7.0.tgz", + "integrity": "sha512-8uMeAMycttpva3P1lBHB8VciS9V0XAr3GymPpipdyQXbBcuhkLQOSe8E/p92RyAdToS6ZD1tFkX+CkhoECE0dQ==", + "dev": true, + "dependencies": { + "expect": "^29.7.0", + "jest-snapshot": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/expect-utils": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.7.0.tgz", + "integrity": "sha512-GlsNBWiFQFCVi9QVSx7f5AgMeLxe9YCCs5PuP2O2LdjDAA8Jh9eX7lA1Jq/xdXw3Wb3hyvlFNfZIfcRetSzYcA==", + "dev": true, + "dependencies": { + "jest-get-type": "^29.6.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/fake-timers": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.7.0.tgz", + "integrity": "sha512-q4DH1Ha4TTFPdxLsqDXK1d3+ioSL7yL5oCMJZgDYm6i+6CygW5E5xVr/D1HdsGxjt1ZWSfUAs9OxSB/BNelWrQ==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "@sinonjs/fake-timers": "^10.0.2", + "@types/node": "*", + "jest-message-util": "^29.7.0", + "jest-mock": "^29.7.0", + "jest-util": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/globals": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/globals/-/globals-29.7.0.tgz", + "integrity": "sha512-mpiz3dutLbkW2MNFubUGUEVLkTGiqW6yLVTA+JbP6fI6J5iL9Y0Nlg8k95pcF8ctKwCS7WVxteBs29hhfAotzQ==", + "dev": true, + "dependencies": { + "@jest/environment": "^29.7.0", + "@jest/expect": "^29.7.0", + "@jest/types": "^29.6.3", + "jest-mock": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/reporters": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-29.7.0.tgz", + "integrity": "sha512-DApq0KJbJOEzAFYjHADNNxAE3KbhxQB1y5Kplb5Waqw6zVbuWatSnMjE5gs8FUgEPmNsnZA3NCWl9NG0ia04Pg==", + "dev": true, + "dependencies": { + "@bcoe/v8-coverage": "^0.2.3", + "@jest/console": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "@jridgewell/trace-mapping": "^0.3.18", + "@types/node": "*", + "chalk": "^4.0.0", + "collect-v8-coverage": "^1.0.0", + "exit": "^0.1.2", + "glob": "^7.1.3", + "graceful-fs": "^4.2.9", + "istanbul-lib-coverage": "^3.0.0", + "istanbul-lib-instrument": "^6.0.0", + "istanbul-lib-report": "^3.0.0", + "istanbul-lib-source-maps": "^4.0.0", + "istanbul-reports": "^3.1.3", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0", + "jest-worker": "^29.7.0", + "slash": "^3.0.0", + "string-length": "^4.0.1", + "strip-ansi": "^6.0.0", + "v8-to-istanbul": "^9.0.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } + } + }, + "node_modules/@jest/reporters/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@jest/reporters/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/@jest/reporters/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/@jest/reporters/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/@jest/reporters/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/reporters/node_modules/istanbul-lib-instrument": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-6.0.3.tgz", + "integrity": "sha512-Vtgk7L/R2JHyyGW07spoFlB8/lpjiOLTjMdms6AFMraYt3BaJauod/NGrfnVG/y4Ix1JEuMRPDPEj2ua+zz1/Q==", + "dev": true, + "dependencies": { + "@babel/core": "^7.23.9", + "@babel/parser": "^7.23.9", + "@istanbuljs/schema": "^0.1.3", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^7.5.4" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@jest/reporters/node_modules/semver": { + "version": "7.6.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz", + "integrity": "sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@jest/reporters/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/schemas": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", + "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", + "dev": true, + "dependencies": { + "@sinclair/typebox": "^0.27.8" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/source-map": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/source-map/-/source-map-29.6.3.tgz", + "integrity": "sha512-MHjT95QuipcPrpLM+8JMSzFx6eHp5Bm+4XeFDJlwsvVBjmKNiIAvasGK2fxz2WbGRlnvqehFbh07MMa7n3YJnw==", + "dev": true, + "dependencies": { + "@jridgewell/trace-mapping": "^0.3.18", + "callsites": "^3.0.0", + "graceful-fs": "^4.2.9" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/test-result": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/test-result/-/test-result-29.7.0.tgz", + "integrity": "sha512-Fdx+tv6x1zlkJPcWXmMDAG2HBnaR9XPSd5aDWQVsfrZmLVT3lU1cwyxLgRmXR9yrq4NBoEm9BMsfgFzTQAbJYA==", + "dev": true, + "dependencies": { + "@jest/console": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/istanbul-lib-coverage": "^2.0.0", + "collect-v8-coverage": "^1.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/test-sequencer": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/test-sequencer/-/test-sequencer-29.7.0.tgz", + "integrity": "sha512-GQwJ5WZVrKnOJuiYiAF52UNUJXgTZx1NHjFSEB0qEMmSZKAkdMoIzw/Cj6x6NF4AvV23AUqDpFzQkN/eYCYTxw==", + "dev": true, + "dependencies": { + "@jest/test-result": "^29.7.0", + "graceful-fs": "^4.2.9", + "jest-haste-map": "^29.7.0", + "slash": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/transform": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/@jest/transform/-/transform-29.7.0.tgz", + "integrity": "sha512-ok/BTPFzFKVMwO5eOHRrvnBVHdRy9IrsrW1GpMaQ9MCnilNLXQKmAX8s1YXDFaai9xJpac2ySzV0YeRRECr2Vw==", + "dev": true, + "dependencies": { + "@babel/core": "^7.11.6", + "@jest/types": "^29.6.3", + "@jridgewell/trace-mapping": "^0.3.18", + "babel-plugin-istanbul": "^6.1.1", + "chalk": "^4.0.0", + "convert-source-map": "^2.0.0", + "fast-json-stable-stringify": "^2.1.0", + "graceful-fs": "^4.2.9", + "jest-haste-map": "^29.7.0", + "jest-regex-util": "^29.6.3", + "jest-util": "^29.7.0", + "micromatch": "^4.0.4", + "pirates": "^4.0.4", + "slash": "^3.0.0", + "write-file-atomic": "^4.0.2" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/transform/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@jest/transform/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/@jest/transform/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/@jest/transform/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/@jest/transform/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/transform/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/types": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.3.tgz", + "integrity": "sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==", + "dev": true, + "dependencies": { + "@jest/schemas": "^29.6.3", + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^3.0.0", + "@types/node": "*", + "@types/yargs": "^17.0.8", + "chalk": "^4.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/types/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@jest/types/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/@jest/types/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/@jest/types/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/@jest/types/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/types/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jridgewell/gen-mapping": { + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", + "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", + "dev": true, + "dependencies": { + "@jridgewell/set-array": "^1.2.1", + "@jridgewell/sourcemap-codec": "^1.4.10", + "@jridgewell/trace-mapping": "^0.3.24" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", + "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", + "dev": true, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/set-array": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", + "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", + "dev": true, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.4.15", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz", + "integrity": "sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==", + "dev": true + }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/@mongodb-js/saslprep": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/@mongodb-js/saslprep/-/saslprep-1.1.7.tgz", + "integrity": "sha512-dCHW/oEX0KJ4NjDULBo3JiOaK5+6axtpBbS+ao2ZInoAL9/YRQLhXzSNAFz7hP4nzLkIqsfYAK/PDE3+XHny0Q==", + "optional": true, + "dependencies": { + "sparse-bitfield": "^3.0.3" + } + }, + "node_modules/@noble/curves": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.2.0.tgz", + "integrity": "sha512-oYclrNgRaM9SsBUBVbb8M6DTV7ZHRTKugureoYEncY5c65HOmRzvSiTE3y5CYaPYJA/GVkrhXEoF0M3Ya9PMnw==", + "dependencies": { + "@noble/hashes": "1.3.2" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@noble/hashes": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.2.tgz", + "integrity": "sha512-MVC8EAQp7MvEcm30KWENFjgR+Mkmf+D189XJTkFIlwohU5hcBbn1ZkKq7KVTi2Hme3PMGF390DaL52beVrIihQ==", + "engines": { + "node": ">= 16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@polkadot/util": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/@polkadot/util/-/util-1.8.1.tgz", + "integrity": "sha512-sFpr+JLCG9d+epjboXsmJ1qcKa96r8ZYzXmVo8+aPzI/9jKKyez6Unox/dnfnpKppZB2nJuLcsxQm6nocp2Caw==", + "dependencies": { + "@babel/runtime": "^7.7.7", + "@types/bn.js": "^4.11.6", + "bn.js": "^4.11.8", + "camelcase": "^5.3.1", + "chalk": "^3.0.0", + "ip-regex": "^4.1.0", + "moment": "^2.24.0" + } + }, + "node_modules/@polkadot/util-crypto": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/@polkadot/util-crypto/-/util-crypto-1.8.1.tgz", + "integrity": "sha512-ypUs10hV1HPvYc0ZsEu+LTGSEh0rkr0as/FUh7+Z9v3Bxibn3aO+EOxJPQuDbZZ59FSMRmc9SeOSa0wn9ddrnw==", + "dependencies": { + "@babel/runtime": "^7.7.7", + "@polkadot/util": "^1.8.1", + "@polkadot/wasm-crypto": "^0.14.1", + "@types/bip39": "^2.4.2", + "@types/bs58": "^4.0.0", + "@types/pbkdf2": "^3.0.0", + "@types/secp256k1": "^3.5.0", + "@types/xxhashjs": "^0.2.1", + "base-x": "3.0.5", + "bip39": "^2.5.0", + "blakejs": "^1.1.0", + "bs58": "^4.0.1", + "js-sha3": "^0.8.0", + "secp256k1": "^3.8.0", + "tweetnacl": "^1.0.1", + "xxhashjs": "^0.2.2" + } + }, + "node_modules/@polkadot/util/node_modules/@types/bn.js": { + "version": "4.11.6", + "resolved": "https://registry.npmjs.org/@types/bn.js/-/bn.js-4.11.6.tgz", + "integrity": "sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@polkadot/util/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@polkadot/util/node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" + }, + "node_modules/@polkadot/util/node_modules/chalk": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", + "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@polkadot/util/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/@polkadot/util/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/@polkadot/util/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/@polkadot/util/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@polkadot/wasm-crypto": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/@polkadot/wasm-crypto/-/wasm-crypto-0.14.1.tgz", + "integrity": "sha512-Xng7L2Z8TNZa/5g6pot4O06Jf0ohQRZdvfl8eQL+E/L2mcqJYC1IjkMxJBSBuQEV7hisWzh9mHOy5WCcgPk29Q==", + "peerDependencies": { + "@polkadot/util": "*" + } + }, + "node_modules/@sinclair/typebox": { + "version": "0.27.8", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", + "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", + "dev": true + }, + "node_modules/@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", + "dev": true, + "dependencies": { + "type-detect": "4.0.8" + } + }, + "node_modules/@sinonjs/fake-timers": { + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-10.3.0.tgz", + "integrity": "sha512-V4BG07kuYSUkTCSBHG8G8TNhM+F19jXFWnQtzj+we8DrkpSBCee9Z3Ms8yiGer/dlmhe35/Xdgyo3/0rQKg7YA==", + "dev": true, + "dependencies": { + "@sinonjs/commons": "^3.0.0" + } + }, + "node_modules/@smithy/abort-controller": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/@smithy/abort-controller/-/abort-controller-3.1.1.tgz", + "integrity": "sha512-MBJBiidoe+0cTFhyxT8g+9g7CeVccLM0IOKKUMCNQ1CNMJ/eIfoo0RTfVrXOONEI1UCN1W+zkiHSbzUNE9dZtQ==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/abort-controller/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/config-resolver": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@smithy/config-resolver/-/config-resolver-3.0.4.tgz", + "integrity": "sha512-VwiOk7TwXoE7NlNguV/aPq1hFH72tqkHCw8eWXbr2xHspRyyv9DLpLXhq+Ieje+NwoqXrY0xyQjPXdOE6cGcHA==", + "optional": true, + "dependencies": { + "@smithy/node-config-provider": "^3.1.3", + "@smithy/types": "^3.3.0", + "@smithy/util-config-provider": "^3.0.0", + "@smithy/util-middleware": "^3.0.3", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/config-resolver/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/core": { + "version": "2.2.4", + "resolved": "https://registry.npmjs.org/@smithy/core/-/core-2.2.4.tgz", + "integrity": "sha512-qdY3LpMOUyLM/gfjjMQZui+UTNS7kBRDWlvyIhVOql5dn2J3isk9qUTBtQ1CbDH8MTugHis1zu3h4rH+Qmmh4g==", + "optional": true, + "dependencies": { + "@smithy/middleware-endpoint": "^3.0.4", + "@smithy/middleware-retry": "^3.0.7", + "@smithy/middleware-serde": "^3.0.3", + "@smithy/protocol-http": "^4.0.3", + "@smithy/smithy-client": "^3.1.5", + "@smithy/types": "^3.3.0", + "@smithy/util-middleware": "^3.0.3", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/core/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/credential-provider-imds": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/@smithy/credential-provider-imds/-/credential-provider-imds-3.1.3.tgz", + "integrity": "sha512-U1Yrv6hx/mRK6k8AncuI6jLUx9rn0VVSd9NPEX6pyYFBfkSkChOc/n4zUb8alHUVg83TbI4OdZVo1X0Zfj3ijA==", + "optional": true, + "dependencies": { + "@smithy/node-config-provider": "^3.1.3", + "@smithy/property-provider": "^3.1.3", + "@smithy/types": "^3.3.0", + "@smithy/url-parser": "^3.0.3", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/credential-provider-imds/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/fetch-http-handler": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@smithy/fetch-http-handler/-/fetch-http-handler-3.2.0.tgz", + "integrity": "sha512-vFvDxMrc6sO5Atec8PaISckMcAwsCrRhYxwUylg97bRT2KZoumOF7qk5+6EVUtuM1IG9AJV5aqXnHln9ZdXHpg==", + "optional": true, + "dependencies": { + "@smithy/protocol-http": "^4.0.3", + "@smithy/querystring-builder": "^3.0.3", + "@smithy/types": "^3.3.0", + "@smithy/util-base64": "^3.0.0", + "tslib": "^2.6.2" + } + }, + "node_modules/@smithy/fetch-http-handler/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/hash-node": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/hash-node/-/hash-node-3.0.3.tgz", + "integrity": "sha512-2ctBXpPMG+B3BtWSGNnKELJ7SH9e4TNefJS0cd2eSkOOROeBnnVBnAy9LtJ8tY4vUEoe55N4CNPxzbWvR39iBw==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.3.0", + "@smithy/util-buffer-from": "^3.0.0", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/hash-node/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/invalid-dependency": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/invalid-dependency/-/invalid-dependency-3.0.3.tgz", + "integrity": "sha512-ID1eL/zpDULmHJbflb864k72/SNOZCADRc9i7Exq3RUNJw6raWUSlFEQ+3PX3EYs++bTxZB2dE9mEHTQLv61tw==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + } + }, + "node_modules/@smithy/invalid-dependency/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/is-array-buffer": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/is-array-buffer/-/is-array-buffer-3.0.0.tgz", + "integrity": "sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==", + "optional": true, + "dependencies": { + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/is-array-buffer/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/middleware-content-length": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/middleware-content-length/-/middleware-content-length-3.0.3.tgz", + "integrity": "sha512-Dbz2bzexReYIQDWMr+gZhpwBetNXzbhnEMhYKA6urqmojO14CsXjnsoPYO8UL/xxcawn8ZsuVU61ElkLSltIUQ==", + "optional": true, + "dependencies": { + "@smithy/protocol-http": "^4.0.3", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/middleware-content-length/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/middleware-endpoint": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@smithy/middleware-endpoint/-/middleware-endpoint-3.0.4.tgz", + "integrity": "sha512-whUJMEPwl3ANIbXjBXZVdJNgfV2ZU8ayln7xUM47rXL2txuenI7jQ/VFFwCzy5lCmXScjp6zYtptW5Evud8e9g==", + "optional": true, + "dependencies": { + "@smithy/middleware-serde": "^3.0.3", + "@smithy/node-config-provider": "^3.1.3", + "@smithy/shared-ini-file-loader": "^3.1.3", + "@smithy/types": "^3.3.0", + "@smithy/url-parser": "^3.0.3", + "@smithy/util-middleware": "^3.0.3", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/middleware-endpoint/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/middleware-retry": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/@smithy/middleware-retry/-/middleware-retry-3.0.7.tgz", + "integrity": "sha512-f5q7Y09G+2h5ivkSx5CHvlAT4qRR3jBFEsfXyQ9nFNiWQlr8c48blnu5cmbTQ+p1xmIO14UXzKoF8d7Tm0Gsjw==", + "optional": true, + "dependencies": { + "@smithy/node-config-provider": "^3.1.3", + "@smithy/protocol-http": "^4.0.3", + "@smithy/service-error-classification": "^3.0.3", + "@smithy/smithy-client": "^3.1.5", + "@smithy/types": "^3.3.0", + "@smithy/util-middleware": "^3.0.3", + "@smithy/util-retry": "^3.0.3", + "tslib": "^2.6.2", + "uuid": "^9.0.1" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/middleware-retry/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/middleware-serde": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/middleware-serde/-/middleware-serde-3.0.3.tgz", + "integrity": "sha512-puUbyJQBcg9eSErFXjKNiGILJGtiqmuuNKEYNYfUD57fUl4i9+mfmThtQhvFXU0hCVG0iEJhvQUipUf+/SsFdA==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/middleware-serde/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/middleware-stack": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/middleware-stack/-/middleware-stack-3.0.3.tgz", + "integrity": "sha512-r4klY9nFudB0r9UdSMaGSyjyQK5adUyPnQN/ZM6M75phTxOdnc/AhpvGD1fQUvgmqjQEBGCwpnPbDm8pH5PapA==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/middleware-stack/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/node-config-provider": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/@smithy/node-config-provider/-/node-config-provider-3.1.3.tgz", + "integrity": "sha512-rxdpAZczzholz6CYZxtqDu/aKTxATD5DAUDVj7HoEulq+pDSQVWzbg0btZDlxeFfa6bb2b5tUvgdX5+k8jUqcg==", + "optional": true, + "dependencies": { + "@smithy/property-provider": "^3.1.3", + "@smithy/shared-ini-file-loader": "^3.1.3", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/node-config-provider/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/node-http-handler": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/@smithy/node-http-handler/-/node-http-handler-3.1.1.tgz", + "integrity": "sha512-L71NLyPeP450r2J/mfu1jMc//Z1YnqJt2eSNw7uhiItaONnBLDA68J5jgxq8+MBDsYnFwNAIc7dBG1ImiWBiwg==", + "optional": true, + "dependencies": { + "@smithy/abort-controller": "^3.1.1", + "@smithy/protocol-http": "^4.0.3", + "@smithy/querystring-builder": "^3.0.3", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/node-http-handler/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/property-provider": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/@smithy/property-provider/-/property-provider-3.1.3.tgz", + "integrity": "sha512-zahyOVR9Q4PEoguJ/NrFP4O7SMAfYO1HLhB18M+q+Z4KFd4V2obiMnlVoUFzFLSPeVt1POyNWneHHrZaTMoc/g==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/property-provider/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/protocol-http": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@smithy/protocol-http/-/protocol-http-4.0.3.tgz", + "integrity": "sha512-x5jmrCWwQlx+Zv4jAtc33ijJ+vqqYN+c/ZkrnpvEe/uDas7AT7A/4Rc2CdfxgWv4WFGmEqODIrrUToPN6DDkGw==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/protocol-http/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/querystring-builder": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/querystring-builder/-/querystring-builder-3.0.3.tgz", + "integrity": "sha512-vyWckeUeesFKzCDaRwWLUA1Xym9McaA6XpFfAK5qI9DKJ4M33ooQGqvM4J+LalH4u/Dq9nFiC8U6Qn1qi0+9zw==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.3.0", + "@smithy/util-uri-escape": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/querystring-builder/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/querystring-parser": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/querystring-parser/-/querystring-parser-3.0.3.tgz", + "integrity": "sha512-zahM1lQv2YjmznnfQsWbYojFe55l0SLG/988brlLv1i8z3dubloLF+75ATRsqPBboUXsW6I9CPGE5rQgLfY0vQ==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/querystring-parser/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/service-error-classification": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/service-error-classification/-/service-error-classification-3.0.3.tgz", + "integrity": "sha512-Jn39sSl8cim/VlkLsUhRFq/dKDnRUFlfRkvhOJaUbLBXUsLRLNf9WaxDv/z9BjuQ3A6k/qE8af1lsqcwm7+DaQ==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.3.0" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/shared-ini-file-loader": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/@smithy/shared-ini-file-loader/-/shared-ini-file-loader-3.1.3.tgz", + "integrity": "sha512-Z8Y3+08vgoDgl4HENqNnnzSISAaGrF2RoKupoC47u2wiMp+Z8P/8mDh1CL8+8ujfi2U5naNvopSBmP/BUj8b5w==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/shared-ini-file-loader/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/signature-v4": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@smithy/signature-v4/-/signature-v4-3.1.2.tgz", + "integrity": "sha512-3BcPylEsYtD0esM4Hoyml/+s7WP2LFhcM3J2AGdcL2vx9O60TtfpDOL72gjb4lU8NeRPeKAwR77YNyyGvMbuEA==", + "optional": true, + "dependencies": { + "@smithy/is-array-buffer": "^3.0.0", + "@smithy/types": "^3.3.0", + "@smithy/util-hex-encoding": "^3.0.0", + "@smithy/util-middleware": "^3.0.3", + "@smithy/util-uri-escape": "^3.0.0", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/signature-v4/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/smithy-client": { + "version": "3.1.5", + "resolved": "https://registry.npmjs.org/@smithy/smithy-client/-/smithy-client-3.1.5.tgz", + "integrity": "sha512-x9bL9Mx2CT2P1OiUlHM+ZNpbVU6TgT32f9CmTRzqIHA7M4vYrROCWEoC3o4xHNJASoGd4Opos3cXYPgh+/m4Ww==", + "optional": true, + "dependencies": { + "@smithy/middleware-endpoint": "^3.0.4", + "@smithy/middleware-stack": "^3.0.3", + "@smithy/protocol-http": "^4.0.3", + "@smithy/types": "^3.3.0", + "@smithy/util-stream": "^3.0.5", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/smithy-client/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/types": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/@smithy/types/-/types-3.3.0.tgz", + "integrity": "sha512-IxvBBCTFDHbVoK7zIxqA1ZOdc4QfM5HM7rGleCuHi7L1wnKv5Pn69xXJQ9hgxH60ZVygH9/JG0jRgtUncE3QUA==", + "optional": true, + "dependencies": { + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/types/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/url-parser": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/url-parser/-/url-parser-3.0.3.tgz", + "integrity": "sha512-pw3VtZtX2rg+s6HMs6/+u9+hu6oY6U7IohGhVNnjbgKy86wcIsSZwgHrFR+t67Uyxvp4Xz3p3kGXXIpTNisq8A==", + "optional": true, + "dependencies": { + "@smithy/querystring-parser": "^3.0.3", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + } + }, + "node_modules/@smithy/url-parser/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-base64": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-base64/-/util-base64-3.0.0.tgz", + "integrity": "sha512-Kxvoh5Qtt0CDsfajiZOCpJxgtPHXOKwmM+Zy4waD43UoEMA+qPxxa98aE/7ZhdnBFZFXMOiBR5xbcaMhLtznQQ==", + "optional": true, + "dependencies": { + "@smithy/util-buffer-from": "^3.0.0", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-base64/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-body-length-browser": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-body-length-browser/-/util-body-length-browser-3.0.0.tgz", + "integrity": "sha512-cbjJs2A1mLYmqmyVl80uoLTJhAcfzMOyPgjwAYusWKMdLeNtzmMz9YxNl3/jRLoxSS3wkqkf0jwNdtXWtyEBaQ==", + "optional": true, + "dependencies": { + "tslib": "^2.6.2" + } + }, + "node_modules/@smithy/util-body-length-browser/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-body-length-node": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-body-length-node/-/util-body-length-node-3.0.0.tgz", + "integrity": "sha512-Tj7pZ4bUloNUP6PzwhN7K386tmSmEET9QtQg0TgdNOnxhZvCssHji+oZTUIuzxECRfG8rdm2PMw2WCFs6eIYkA==", + "optional": true, + "dependencies": { + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-body-length-node/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-buffer-from": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-buffer-from/-/util-buffer-from-3.0.0.tgz", + "integrity": "sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==", + "optional": true, + "dependencies": { + "@smithy/is-array-buffer": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-buffer-from/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-config-provider": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-config-provider/-/util-config-provider-3.0.0.tgz", + "integrity": "sha512-pbjk4s0fwq3Di/ANL+rCvJMKM5bzAQdE5S/6RL5NXgMExFAi6UgQMPOm5yPaIWPpr+EOXKXRonJ3FoxKf4mCJQ==", + "optional": true, + "dependencies": { + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-config-provider/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-defaults-mode-browser": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/@smithy/util-defaults-mode-browser/-/util-defaults-mode-browser-3.0.7.tgz", + "integrity": "sha512-Q2txLyvQyGfmjsaDbVV7Sg8psefpFcrnlGapDzXGFRPFKRBeEg6OvFK8FljqjeHSaCZ6/UuzQExUPqBR/2qlDA==", + "optional": true, + "dependencies": { + "@smithy/property-provider": "^3.1.3", + "@smithy/smithy-client": "^3.1.5", + "@smithy/types": "^3.3.0", + "bowser": "^2.11.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">= 10.0.0" + } + }, + "node_modules/@smithy/util-defaults-mode-browser/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-defaults-mode-node": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/@smithy/util-defaults-mode-node/-/util-defaults-mode-node-3.0.7.tgz", + "integrity": "sha512-F4Qcj1fG6MGi2BSWCslfsMSwllws/WzYONBGtLybyY+halAcXdWhcew+mej8M5SKd5hqPYp4f7b+ABQEaeytgg==", + "optional": true, + "dependencies": { + "@smithy/config-resolver": "^3.0.4", + "@smithy/credential-provider-imds": "^3.1.3", + "@smithy/node-config-provider": "^3.1.3", + "@smithy/property-provider": "^3.1.3", + "@smithy/smithy-client": "^3.1.5", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">= 10.0.0" + } + }, + "node_modules/@smithy/util-defaults-mode-node/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-endpoints": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/@smithy/util-endpoints/-/util-endpoints-2.0.4.tgz", + "integrity": "sha512-ZAtNf+vXAsgzgRutDDiklU09ZzZiiV/nATyqde4Um4priTmasDH+eLpp3tspL0hS2dEootyFMhu1Y6Y+tzpWBQ==", + "optional": true, + "dependencies": { + "@smithy/node-config-provider": "^3.1.3", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-endpoints/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-hex-encoding": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-hex-encoding/-/util-hex-encoding-3.0.0.tgz", + "integrity": "sha512-eFndh1WEK5YMUYvy3lPlVmYY/fZcQE1D8oSf41Id2vCeIkKJXPcYDCZD+4+xViI6b1XSd7tE+s5AmXzz5ilabQ==", + "optional": true, + "dependencies": { + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-hex-encoding/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-middleware": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/util-middleware/-/util-middleware-3.0.3.tgz", + "integrity": "sha512-l+StyYYK/eO3DlVPbU+4Bi06Jjal+PFLSMmlWM1BEwyLxZ3aKkf1ROnoIakfaA7mC6uw3ny7JBkau4Yc+5zfWw==", + "optional": true, + "dependencies": { + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-middleware/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-retry": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@smithy/util-retry/-/util-retry-3.0.3.tgz", + "integrity": "sha512-AFw+hjpbtVApzpNDhbjNG5NA3kyoMs7vx0gsgmlJF4s+yz1Zlepde7J58zpIRIsdjc+emhpAITxA88qLkPF26w==", + "optional": true, + "dependencies": { + "@smithy/service-error-classification": "^3.0.3", + "@smithy/types": "^3.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-retry/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-stream": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/@smithy/util-stream/-/util-stream-3.0.5.tgz", + "integrity": "sha512-xC3L5PKMAT/Bh8fmHNXP9sdQ4+4aKVUU3EEJ2CF/lLk7R+wtMJM+v/1B4en7jO++Wa5spGzFDBCl0QxgbUc5Ug==", + "optional": true, + "dependencies": { + "@smithy/fetch-http-handler": "^3.2.0", + "@smithy/node-http-handler": "^3.1.1", + "@smithy/types": "^3.3.0", + "@smithy/util-base64": "^3.0.0", + "@smithy/util-buffer-from": "^3.0.0", + "@smithy/util-hex-encoding": "^3.0.0", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-stream/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-uri-escape": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-uri-escape/-/util-uri-escape-3.0.0.tgz", + "integrity": "sha512-LqR7qYLgZTD7nWLBecUi4aqolw8Mhza9ArpNEQ881MJJIU2sE5iHCK6TdyqqzcDLy0OPe10IY4T8ctVdtynubg==", + "optional": true, + "dependencies": { + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-uri-escape/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@smithy/util-utf8": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@smithy/util-utf8/-/util-utf8-3.0.0.tgz", + "integrity": "sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==", + "optional": true, + "dependencies": { + "@smithy/util-buffer-from": "^3.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/@smithy/util-utf8/node_modules/tslib": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.3.tgz", + "integrity": "sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ==", + "optional": true + }, + "node_modules/@tsconfig/node10": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.11.tgz", + "integrity": "sha512-DcRjDCujK/kCk/cUe8Xz8ZSpm8mS3mNNpta+jGCA6USEDfktlNvm1+IuZ9eTcDbNk41BHwpHHeW+N1lKCz4zOw==", + "dev": true, + "optional": true, + "peer": true + }, + "node_modules/@tsconfig/node12": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.11.tgz", + "integrity": "sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==", + "dev": true, + "optional": true, + "peer": true + }, + "node_modules/@tsconfig/node14": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.3.tgz", + "integrity": "sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==", + "dev": true, + "optional": true, + "peer": true + }, + "node_modules/@tsconfig/node16": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.4.tgz", + "integrity": "sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==", + "dev": true, + "optional": true, + "peer": true + }, + "node_modules/@types/babel__core": { + "version": "7.20.5", + "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.20.5.tgz", + "integrity": "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==", + "dev": true, + "dependencies": { + "@babel/parser": "^7.20.7", + "@babel/types": "^7.20.7", + "@types/babel__generator": "*", + "@types/babel__template": "*", + "@types/babel__traverse": "*" + } + }, + "node_modules/@types/babel__generator": { + "version": "7.6.8", + "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.6.8.tgz", + "integrity": "sha512-ASsj+tpEDsEiFr1arWrlN6V3mdfjRMZt6LtK/Vp/kreFLnr5QH5+DhvD5nINYZXzwJvXeGq+05iUXcAzVrqWtw==", + "dev": true, + "dependencies": { + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__template": { + "version": "7.4.4", + "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.4.4.tgz", + "integrity": "sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==", + "dev": true, + "dependencies": { + "@babel/parser": "^7.1.0", + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__traverse": { + "version": "7.20.6", + "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.20.6.tgz", + "integrity": "sha512-r1bzfrm0tomOI8g1SzvCaQHo6Lcv6zu0EA+W2kHrt8dyrHQxGzBBL4kdkzIS+jBMV+EYcMAEAqXqYaLJq5rOZg==", + "dev": true, + "dependencies": { + "@babel/types": "^7.20.7" + } + }, + "node_modules/@types/bip39": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/@types/bip39/-/bip39-2.4.2.tgz", + "integrity": "sha512-Vo9lqOIRq8uoIzEVrV87ZvcIM0PN9t0K3oYZ/CS61fIYKCBdOIM7mlWzXuRvSXrDtVa1uUO2w1cdfufxTC0bzg==", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/bn.js": { + "version": "5.1.5", + "resolved": "https://registry.npmjs.org/@types/bn.js/-/bn.js-5.1.5.tgz", + "integrity": "sha512-V46N0zwKRF5Q00AZ6hWtN0T8gGmDUaUzLWQvHFo5yThtVwK/VCenFY3wXVbOvNfajEpsTfQM4IN9k/d6gUVX3A==", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/bs58": { + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/@types/bs58/-/bs58-4.0.4.tgz", + "integrity": "sha512-0IEpMFXXQi2zXaXl9GJ3sRwQo0uEkD+yFOv+FnAU5lkPtcu6h61xb7jc2CFPEZ5BUOaiP13ThuGc9HD4R8lR5g==", + "dependencies": { + "@types/node": "*", + "base-x": "^3.0.6" + } + }, + "node_modules/@types/bs58/node_modules/base-x": { + "version": "3.0.9", + "resolved": "https://registry.npmjs.org/base-x/-/base-x-3.0.9.tgz", + "integrity": "sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ==", + "dependencies": { + "safe-buffer": "^5.0.1" + } + }, + "node_modules/@types/graceful-fs": { + "version": "4.1.9", + "resolved": "https://registry.npmjs.org/@types/graceful-fs/-/graceful-fs-4.1.9.tgz", + "integrity": "sha512-olP3sd1qOEe5dXTSaFvQG+02VdRXcdytWLAZsAq1PecU8uqQAhkrnbli7DagjtXKW/Bl7YJbUsa8MPcuc8LHEQ==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/istanbul-lib-coverage": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", + "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", + "dev": true + }, + "node_modules/@types/istanbul-lib-report": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.3.tgz", + "integrity": "sha512-NQn7AHQnk/RSLOxrBbGyJM/aVQ+pjj5HCgasFxc0K/KhoATfQ/47AyUl15I2yBUpihjmas+a+VJBOqecrFH+uA==", + "dev": true, + "dependencies": { + "@types/istanbul-lib-coverage": "*" + } + }, + "node_modules/@types/istanbul-reports": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", + "dev": true, + "dependencies": { + "@types/istanbul-lib-report": "*" + } + }, + "node_modules/@types/jest": { + "version": "29.5.12", + "resolved": "https://registry.npmjs.org/@types/jest/-/jest-29.5.12.tgz", + "integrity": "sha512-eDC8bTvT/QhYdxJAulQikueigY5AsdBRH2yDKW3yveW7svY3+DzN84/2NUgkw10RTiJbWqZrTtoGVdYlvFJdLw==", + "dev": true, + "dependencies": { + "expect": "^29.0.0", + "pretty-format": "^29.0.0" + } + }, + "node_modules/@types/node": { + "version": "18.19.39", + "resolved": "https://registry.npmjs.org/@types/node/-/node-18.19.39.tgz", + "integrity": "sha512-nPwTRDKUctxw3di5b4TfT3I0sWDiWoPQCZjXhvdkINntwr8lcoVCKsTgnXeRubKIlfnV+eN/HYk6Jb40tbcEAQ==", + "dependencies": { + "undici-types": "~5.26.4" + } + }, + "node_modules/@types/pbkdf2": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@types/pbkdf2/-/pbkdf2-3.1.2.tgz", + "integrity": "sha512-uRwJqmiXmh9++aSu1VNEn3iIxWOhd8AHXNSdlaLfdAAdSTY9jYVeGWnzejM3dvrkbqE3/hyQkQQ29IFATEGlew==", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/secp256k1": { + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/@types/secp256k1/-/secp256k1-3.5.3.tgz", + "integrity": "sha512-NGcsPDR0P+Q71O63e2ayshmiZGAwCOa/cLJzOIuhOiDvmbvrCIiVtEpqdCJGogG92Bnr6tw/6lqVBsRMEl15OQ==", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/stack-utils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", + "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", + "dev": true + }, + "node_modules/@types/webidl-conversions": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/@types/webidl-conversions/-/webidl-conversions-7.0.3.tgz", + "integrity": "sha512-CiJJvcRtIgzadHCYXw7dqEnMNRjhGZlYK05Mj9OyktqV8uVT8fD2BFOB7S1uwBE3Kj2Z+4UyPmFw/Ixgw/LAlA==" + }, + "node_modules/@types/whatwg-url": { + "version": "8.2.2", + "resolved": "https://registry.npmjs.org/@types/whatwg-url/-/whatwg-url-8.2.2.tgz", + "integrity": "sha512-FtQu10RWgn3D9U4aazdwIE2yzphmTJREDqNdODHrbrZmmMqI0vMheC/6NE/J1Yveaj8H+ela+YwWTjq5PGmuhA==", + "dependencies": { + "@types/node": "*", + "@types/webidl-conversions": "*" + } + }, + "node_modules/@types/xxhashjs": { + "version": "0.2.4", + "resolved": "https://registry.npmjs.org/@types/xxhashjs/-/xxhashjs-0.2.4.tgz", + "integrity": "sha512-E2+ZoJY2JjmVPN0iQM5gJvZkk98O2PYXSi6HrciEk3EKF34+mauEk/HgwTeCz+2r8HXHMKpucrwy4qTT12OPaQ==", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/yargs": { + "version": "17.0.32", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.32.tgz", + "integrity": "sha512-xQ67Yc/laOG5uMfX/093MRlGGCIBzZMarVa+gfNKJxWAIgykYpVGkBdbqEzGDDfCrVUj6Hiff4mTZ5BA6TmAog==", + "dev": true, + "dependencies": { + "@types/yargs-parser": "*" + } + }, + "node_modules/@types/yargs-parser": { + "version": "21.0.3", + "resolved": "https://registry.npmjs.org/@types/yargs-parser/-/yargs-parser-21.0.3.tgz", + "integrity": "sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ==", + "dev": true + }, + "node_modules/acorn": { + "version": "8.12.0", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.12.0.tgz", + "integrity": "sha512-RTvkC4w+KNXrM39/lWCUaG0IbRkWdCv7W/IOW9oU6SawyxulvkQy5HQPVTKxEjczcUvapcrw3cFx/60VN/NRNw==", + "dev": true, + "optional": true, + "peer": true, + "bin": { + "acorn": "bin/acorn" + }, + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/acorn-walk": { + "version": "8.3.3", + "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.3.3.tgz", + "integrity": "sha512-MxXdReSRhGO7VlFe1bRG/oI7/mdLV9B9JJT0N8vZOhF7gFRR5l3M8W9G8JxmKV+JC5mGqJ0QvqfSOLsCPa4nUw==", + "dev": true, + "optional": true, + "peer": true, + "dependencies": { + "acorn": "^8.11.0" + }, + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/aes-js": { + "version": "4.0.0-beta.5", + "resolved": "https://registry.npmjs.org/aes-js/-/aes-js-4.0.0-beta.5.tgz", + "integrity": "sha512-G965FqalsNyrPqgEGON7nIx1e/OVENSgiEIzyC63haUMuvNnwIgIjMs52hlTCKhkBny7A2ORNlfY9Zu+jmGk1Q==" + }, + "node_modules/ansi-escapes": { + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", + "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", + "dev": true, + "dependencies": { + "type-fest": "^0.21.3" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "dependencies": { + "color-convert": "^1.9.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", + "dev": true, + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/arg": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", + "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", + "dev": true, + "optional": true, + "peer": true + }, + "node_modules/argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "dependencies": { + "sprintf-js": "~1.0.2" + } + }, + "node_modules/asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==" + }, + "node_modules/axios": { + "version": "1.7.2", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.7.2.tgz", + "integrity": "sha512-2A8QhOMrbomlDuiLeK9XibIBzuHeRcqqNOHp0Cyp5EoJ1IFDh+XZH3A6BkXtv0K4gFGCI0Y4BM7B1wOEi0Rmgw==", + "dependencies": { + "follow-redirects": "^1.15.6", + "form-data": "^4.0.0", + "proxy-from-env": "^1.1.0" + } + }, + "node_modules/babel-jest": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-29.7.0.tgz", + "integrity": "sha512-BrvGY3xZSwEcCzKvKsCi2GgHqDqsYkOP4/by5xCgIwGXQxIEh+8ew3gmrE1y7XRR6LHZIj6yLYnUi/mm2KXKBg==", + "dev": true, + "dependencies": { + "@jest/transform": "^29.7.0", + "@types/babel__core": "^7.1.14", + "babel-plugin-istanbul": "^6.1.1", + "babel-preset-jest": "^29.6.3", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.9", + "slash": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "@babel/core": "^7.8.0" + } + }, + "node_modules/babel-jest/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/babel-jest/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/babel-jest/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/babel-jest/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/babel-jest/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/babel-jest/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/babel-plugin-istanbul": { + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-6.1.1.tgz", + "integrity": "sha512-Y1IQok9821cC9onCx5otgFfRm7Lm+I+wwxOx738M/WLPZ9Q42m4IG5W0FNX8WLL2gYMZo3JkuXIH2DOpWM+qwA==", + "dev": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.0.0", + "@istanbuljs/load-nyc-config": "^1.0.0", + "@istanbuljs/schema": "^0.1.2", + "istanbul-lib-instrument": "^5.0.4", + "test-exclude": "^6.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/babel-plugin-jest-hoist": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-29.6.3.tgz", + "integrity": "sha512-ESAc/RJvGTFEzRwOTT4+lNDk/GNHMkKbNzsvT0qKRfDyyYTskxB5rnU2njIDYVxXCBHHEI1c0YwHob3WaYujOg==", + "dev": true, + "dependencies": { + "@babel/template": "^7.3.3", + "@babel/types": "^7.3.3", + "@types/babel__core": "^7.1.14", + "@types/babel__traverse": "^7.0.6" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/babel-plugin-polyfill-corejs2": { + "version": "0.4.11", + "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-corejs2/-/babel-plugin-polyfill-corejs2-0.4.11.tgz", + "integrity": "sha512-sMEJ27L0gRHShOh5G54uAAPaiCOygY/5ratXuiyb2G46FmlSpc9eFCzYVyDiPxfNbwzA7mYahmjQc5q+CZQ09Q==", + "dev": true, + "dependencies": { + "@babel/compat-data": "^7.22.6", + "@babel/helper-define-polyfill-provider": "^0.6.2", + "semver": "^6.3.1" + }, + "peerDependencies": { + "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" + } + }, + "node_modules/babel-plugin-polyfill-corejs3": { + "version": "0.10.4", + "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-corejs3/-/babel-plugin-polyfill-corejs3-0.10.4.tgz", + "integrity": "sha512-25J6I8NGfa5YkCDogHRID3fVCadIR8/pGl1/spvCkzb6lVn6SR3ojpx9nOn9iEBcUsjY24AmdKm5khcfKdylcg==", + "dev": true, + "dependencies": { + "@babel/helper-define-polyfill-provider": "^0.6.1", + "core-js-compat": "^3.36.1" + }, + "peerDependencies": { + "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" + } + }, + "node_modules/babel-plugin-polyfill-regenerator": { + "version": "0.6.2", + "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-regenerator/-/babel-plugin-polyfill-regenerator-0.6.2.tgz", + "integrity": "sha512-2R25rQZWP63nGwaAswvDazbPXfrM3HwVoBXK6HcqeKrSrL/JqcC/rDcf95l4r7LXLyxDXc8uQDa064GubtCABg==", + "dev": true, + "dependencies": { + "@babel/helper-define-polyfill-provider": "^0.6.2" + }, + "peerDependencies": { + "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" + } + }, + "node_modules/babel-preset-current-node-syntax": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.0.1.tgz", + "integrity": "sha512-M7LQ0bxarkxQoN+vz5aJPsLBn77n8QgTFmo8WK0/44auK2xlCXrYcUxHFxgU7qW5Yzw/CjmLRK2uJzaCd7LvqQ==", + "dev": true, + "dependencies": { + "@babel/plugin-syntax-async-generators": "^7.8.4", + "@babel/plugin-syntax-bigint": "^7.8.3", + "@babel/plugin-syntax-class-properties": "^7.8.3", + "@babel/plugin-syntax-import-meta": "^7.8.3", + "@babel/plugin-syntax-json-strings": "^7.8.3", + "@babel/plugin-syntax-logical-assignment-operators": "^7.8.3", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3", + "@babel/plugin-syntax-numeric-separator": "^7.8.3", + "@babel/plugin-syntax-object-rest-spread": "^7.8.3", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.3", + "@babel/plugin-syntax-optional-chaining": "^7.8.3", + "@babel/plugin-syntax-top-level-await": "^7.8.3" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/babel-preset-jest": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/babel-preset-jest/-/babel-preset-jest-29.6.3.tgz", + "integrity": "sha512-0B3bhxR6snWXJZtR/RliHTDPRgn1sNHOR0yVtq/IiQFyuOVjFS+wuio/R4gSNkyYmKmJB4wGZv2NZanmKmTnNA==", + "dev": true, + "dependencies": { + "babel-plugin-jest-hoist": "^29.6.3", + "babel-preset-current-node-syntax": "^1.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", + "dev": true + }, + "node_modules/base-x": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/base-x/-/base-x-3.0.5.tgz", + "integrity": "sha512-C3picSgzPSLE+jW3tcBzJoGwitOtazb5B+5YmAxZm2ybmTi9LNgAtDO/jjVEBZwHoXmDBZ9m/IELj3elJVRBcA==", + "dependencies": { + "safe-buffer": "^5.0.1" + } + }, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/bindings": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz", + "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", + "dependencies": { + "file-uri-to-path": "1.0.0" + } + }, + "node_modules/bip39": { + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/bip39/-/bip39-2.6.0.tgz", + "integrity": "sha512-RrnQRG2EgEoqO24ea+Q/fftuPUZLmrEM3qNhhGsA3PbaXaCW791LTzPuVyx/VprXQcTbPJ3K3UeTna8ZnVl2sg==", + "dependencies": { + "create-hash": "^1.1.0", + "pbkdf2": "^3.0.9", + "randombytes": "^2.0.1", + "safe-buffer": "^5.0.1", + "unorm": "^1.3.3" + } + }, + "node_modules/bip66": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/bip66/-/bip66-1.1.5.tgz", + "integrity": "sha512-nemMHz95EmS38a26XbbdxIYj5csHd3RMP3H5bwQknX0WYHF01qhpufP42mLOwVICuH2JmhIhXiWs89MfUGL7Xw==", + "dependencies": { + "safe-buffer": "^5.0.1" + } + }, + "node_modules/blakejs": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/blakejs/-/blakejs-1.2.1.tgz", + "integrity": "sha512-QXUSXI3QVc/gJME0dBpXrag1kbzOqCjCX8/b54ntNyW6sjtoqxqRk3LTmXzaJoh71zMsDCjM+47jS7XiwN/+fQ==" + }, + "node_modules/bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + }, + "node_modules/bowser": { + "version": "2.11.0", + "resolved": "https://registry.npmjs.org/bowser/-/bowser-2.11.0.tgz", + "integrity": "sha512-AlcaJBi/pqqJBIQ8U9Mcpc9i8Aqxn88Skv5d+xBX006BY5u8N3mGLHa5Lgppa7L/HfwgwLgZ6NYs+Ag6uUmJRA==", + "optional": true + }, + "node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/braces": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", + "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", + "dev": true, + "dependencies": { + "fill-range": "^7.1.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/brorand": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", + "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" + }, + "node_modules/browserify-aes": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/browserify-aes/-/browserify-aes-1.2.0.tgz", + "integrity": "sha512-+7CHXqGuspUn/Sl5aO7Ea0xWGAtETPXNSAjHo48JfLdPWcMng33Xe4znFvQweqc/uzk5zSOI3H52CYnjCfb5hA==", + "dependencies": { + "buffer-xor": "^1.0.3", + "cipher-base": "^1.0.0", + "create-hash": "^1.1.0", + "evp_bytestokey": "^1.0.3", + "inherits": "^2.0.1", + "safe-buffer": "^5.0.1" + } + }, + "node_modules/browserslist": { + "version": "4.23.1", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.23.1.tgz", + "integrity": "sha512-TUfofFo/KsK/bWZ9TWQ5O26tsWW4Uhmt8IYklbnUa70udB6P2wA7w7o4PY4muaEPBQaAX+CEnmmIA41NVHtPVw==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "caniuse-lite": "^1.0.30001629", + "electron-to-chromium": "^1.4.796", + "node-releases": "^2.0.14", + "update-browserslist-db": "^1.0.16" + }, + "bin": { + "browserslist": "cli.js" + }, + "engines": { + "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" + } + }, + "node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/bser": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/bser/-/bser-2.1.1.tgz", + "integrity": "sha512-gQxTNE/GAfIIrmHLUE3oJyp5FO6HRBfhjnw4/wMmA63ZGDJnWBmgY/lyQBpnDUkGmAhbSe39tx2d/iTOAfglwQ==", + "dev": true, + "dependencies": { + "node-int64": "^0.4.0" + } + }, + "node_modules/bson": { + "version": "4.7.2", + "resolved": "https://registry.npmjs.org/bson/-/bson-4.7.2.tgz", + "integrity": "sha512-Ry9wCtIZ5kGqkJoi6aD8KjxFZEx78guTQDnpXWiNthsxzrxAK/i8E6pCHAIZTbaEFWcOCvbecMukfK7XUvyLpQ==", + "dependencies": { + "buffer": "^5.6.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, + "node_modules/buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", + "dev": true + }, + "node_modules/buffer-xor": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/buffer-xor/-/buffer-xor-1.0.3.tgz", + "integrity": "sha512-571s0T7nZWK6vB67HI5dyUF7wXiNcfaPPPTl6zYCNApANjIvYJTg7hlud/+cJpdAhS7dVzqMLmfhfHR3rAcOjQ==" + }, + "node_modules/callsites": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", + "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", + "engines": { + "node": ">=6" + } + }, + "node_modules/caniuse-lite": { + "version": "1.0.30001639", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001639.tgz", + "integrity": "sha512-eFHflNTBIlFwP2AIKaYuBQN/apnUoKNhBdza8ZnW/h2di4LCZ4xFqYlxUxo+LQ76KFI1PGcC1QDxMbxTZpSCAg==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ] + }, + "node_modules/chalk": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "dev": true, + "dependencies": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/char-regex": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/char-regex/-/char-regex-1.0.2.tgz", + "integrity": "sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/ci-info": { + "version": "3.9.0", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", + "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], + "engines": { + "node": ">=8" + } + }, + "node_modules/cipher-base": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/cipher-base/-/cipher-base-1.0.4.tgz", + "integrity": "sha512-Kkht5ye6ZGmwv40uUDZztayT2ThLQGfnj/T71N/XzeZeo3nf8foyW7zGTsPYkEya3m5f3cAypH+qe7YOrM1U2Q==", + "dependencies": { + "inherits": "^2.0.1", + "safe-buffer": "^5.0.1" + } + }, + "node_modules/cjs-module-lexer": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/cjs-module-lexer/-/cjs-module-lexer-1.3.1.tgz", + "integrity": "sha512-a3KdPAANPbNE4ZUv9h6LckSl9zLsYOP4MBmhIPkRaeyybt+r4UghLvq+xw/YwUcC1gqylCkL4rdVs3Lwupjm4Q==", + "dev": true + }, + "node_modules/cliui": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", + "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", + "dependencies": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.1", + "wrap-ansi": "^7.0.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/co": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz", + "integrity": "sha512-QVb0dM5HvG+uaxitm8wONl7jltx8dqhfU33DcqtOZcLSVIKSDDLDi7+0LbAKiyI8hD9u42m2YxXSkMGWThaecQ==", + "dev": true, + "engines": { + "iojs": ">= 1.0.0", + "node": ">= 0.12.0" + } + }, + "node_modules/collect-v8-coverage": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/collect-v8-coverage/-/collect-v8-coverage-1.0.2.tgz", + "integrity": "sha512-lHl4d5/ONEbLlJvaJNtsF/Lz+WvB07u2ycqTYbdrq7UypDXailES4valYb2eWiJFxZlVmpGekfqoxQhzyFdT4Q==", + "dev": true + }, + "node_modules/color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dev": true, + "dependencies": { + "color-name": "1.1.3" + } + }, + "node_modules/color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", + "dev": true + }, + "node_modules/combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "dependencies": { + "delayed-stream": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==", + "dev": true + }, + "node_modules/convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "dev": true + }, + "node_modules/core-js-compat": { + "version": "3.37.1", + "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.37.1.tgz", + "integrity": "sha512-9TNiImhKvQqSUkOvk/mMRZzOANTiEVC7WaBNhHcKM7x+/5E1l5NvsysR19zuDQScE8k+kfQXWRN3AtS/eOSHpg==", + "dev": true, + "dependencies": { + "browserslist": "^4.23.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/create-hash": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/create-hash/-/create-hash-1.2.0.tgz", + "integrity": "sha512-z00bCGNHDG8mHAkP7CtT1qVu+bFQUPjYq/4Iv3C3kWjTFV10zIjfSoeqXo9Asws8gwSHDGj/hl2u4OGIjapeCg==", + "dependencies": { + "cipher-base": "^1.0.1", + "inherits": "^2.0.1", + "md5.js": "^1.3.4", + "ripemd160": "^2.0.1", + "sha.js": "^2.4.0" + } + }, + "node_modules/create-hmac": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/create-hmac/-/create-hmac-1.1.7.tgz", + "integrity": "sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg==", + "dependencies": { + "cipher-base": "^1.0.3", + "create-hash": "^1.1.0", + "inherits": "^2.0.1", + "ripemd160": "^2.0.0", + "safe-buffer": "^5.0.1", + "sha.js": "^2.4.8" + } + }, + "node_modules/create-jest": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/create-jest/-/create-jest-29.7.0.tgz", + "integrity": "sha512-Adz2bdH0Vq3F53KEMJOoftQFutWCukm6J24wbPWRO4k1kMY7gS7ds/uoJkNuV8wDCtWWnuwGcJwpWcih+zEW1Q==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "chalk": "^4.0.0", + "exit": "^0.1.2", + "graceful-fs": "^4.2.9", + "jest-config": "^29.7.0", + "jest-util": "^29.7.0", + "prompts": "^2.0.1" + }, + "bin": { + "create-jest": "bin/create-jest.js" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/create-jest/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/create-jest/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/create-jest/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/create-jest/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/create-jest/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/create-jest/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/create-require": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz", + "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", + "dev": true, + "optional": true, + "peer": true + }, + "node_modules/cross-spawn": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", + "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "dev": true, + "dependencies": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/cuint": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/cuint/-/cuint-0.2.2.tgz", + "integrity": "sha512-d4ZVpCW31eWwCMe1YT3ur7mUDnTXbgwyzaL320DrcRT45rfjYxkt5QWLrmOJ+/UEAI2+fQgKe/fCjR8l4TpRgw==" + }, + "node_modules/debug": { + "version": "4.3.5", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.5.tgz", + "integrity": "sha512-pt0bNEmneDIvdL1Xsd9oDQ/wrQRkXDT4AUWlNZNPKvW5x/jyO9VFXkJUP07vQ2upmw5PlaITaPKc31jK13V+jg==", + "dev": true, + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/dedent": { + "version": "1.5.3", + "resolved": "https://registry.npmjs.org/dedent/-/dedent-1.5.3.tgz", + "integrity": "sha512-NHQtfOOW68WD8lgypbLA5oT+Bt0xXJhiYvoR6SmmNXZfpzOGXwdKWmcwG8N7PwVVWV3eF/68nmD9BaJSsTBhyQ==", + "dev": true, + "peerDependencies": { + "babel-plugin-macros": "^3.1.0" + }, + "peerDependenciesMeta": { + "babel-plugin-macros": { + "optional": true + } + } + }, + "node_modules/deepmerge": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz", + "integrity": "sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/detect-newline": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/detect-newline/-/detect-newline-3.1.0.tgz", + "integrity": "sha512-TLz+x/vEXm/Y7P7wn1EJFNLxYpUD4TgMosxY6fAVJUnJMbupHBOncxyWUG9OpTaH9EBD7uFI5LfEgmMOc54DsA==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/diff": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", + "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", + "dev": true, + "optional": true, + "peer": true, + "engines": { + "node": ">=0.3.1" + } + }, + "node_modules/diff-sequences": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/diff-sequences/-/diff-sequences-29.6.3.tgz", + "integrity": "sha512-EjePK1srD3P08o2j4f0ExnylqRs5B9tJjcp9t1krH2qRi8CCdsYfwe9JgSLurFBWwq4uOlipzfk5fHNvwFKr8Q==", + "dev": true, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/drbg.js": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/drbg.js/-/drbg.js-1.0.1.tgz", + "integrity": "sha512-F4wZ06PvqxYLFEZKkFxTDcns9oFNk34hvmJSEwdzsxVQ8YI5YaxtACgQatkYgv2VI2CFkUd2Y+xosPQnHv809g==", + "dependencies": { + "browserify-aes": "^1.0.6", + "create-hash": "^1.1.2", + "create-hmac": "^1.1.4" + }, + "engines": { + "node": ">=0.10" + } + }, + "node_modules/electron-to-chromium": { + "version": "1.4.815", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.815.tgz", + "integrity": "sha512-OvpTT2ItpOXJL7IGcYakRjHCt8L5GrrN/wHCQsRB4PQa1X9fe+X9oen245mIId7s14xvArCGSTIq644yPUKKLg==", + "dev": true + }, + "node_modules/elliptic": { + "version": "6.5.5", + "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.5.tgz", + "integrity": "sha512-7EjbcmUm17NQFu4Pmgmq2olYMj8nwMnpcddByChSUjArp8F5DQWcIcpriwO4ZToLNAJig0yiyjswfyGNje/ixw==", + "dependencies": { + "bn.js": "^4.11.9", + "brorand": "^1.1.0", + "hash.js": "^1.0.0", + "hmac-drbg": "^1.0.1", + "inherits": "^2.0.4", + "minimalistic-assert": "^1.0.1", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "node_modules/elliptic/node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" + }, + "node_modules/emittery": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/emittery/-/emittery-0.13.1.tgz", + "integrity": "sha512-DeWwawk6r5yR9jFgnDKYt4sLS0LmHJJi3ZOnb5/JdbYwj3nW+FxQnHIjhBKz8YLC7oRNPVM9NQ47I3CVx34eqQ==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sindresorhus/emittery?sponsor=1" + } + }, + "node_modules/emoji-regex": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==" + }, + "node_modules/error-ex": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", + "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", + "dev": true, + "dependencies": { + "is-arrayish": "^0.2.1" + } + }, + "node_modules/esbuild": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.21.5.tgz", + "integrity": "sha512-mg3OPMV4hXywwpoDxu3Qda5xCKQi+vCTZq8S9J/EpkhB2HzKXq4SNFZE3+NK93JYxc8VMSep+lOUSC/RVKaBqw==", + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=12" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.21.5", + "@esbuild/android-arm": "0.21.5", + "@esbuild/android-arm64": "0.21.5", + "@esbuild/android-x64": "0.21.5", + "@esbuild/darwin-arm64": "0.21.5", + "@esbuild/darwin-x64": "0.21.5", + "@esbuild/freebsd-arm64": "0.21.5", + "@esbuild/freebsd-x64": "0.21.5", + "@esbuild/linux-arm": "0.21.5", + "@esbuild/linux-arm64": "0.21.5", + "@esbuild/linux-ia32": "0.21.5", + "@esbuild/linux-loong64": "0.21.5", + "@esbuild/linux-mips64el": "0.21.5", + "@esbuild/linux-ppc64": "0.21.5", + "@esbuild/linux-riscv64": "0.21.5", + "@esbuild/linux-s390x": "0.21.5", + "@esbuild/linux-x64": "0.21.5", + "@esbuild/netbsd-x64": "0.21.5", + "@esbuild/openbsd-x64": "0.21.5", + "@esbuild/sunos-x64": "0.21.5", + "@esbuild/win32-arm64": "0.21.5", + "@esbuild/win32-ia32": "0.21.5", + "@esbuild/win32-x64": "0.21.5" + } + }, + "node_modules/escalade": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.2.tgz", + "integrity": "sha512-ErCHMCae19vR8vQGe50xIsVomy19rg6gFu3+r3jkEO46suLMWBksvVyoGgQV+jOfl84ZSOSlmv6Gxa89PmTGmA==", + "engines": { + "node": ">=6" + } + }, + "node_modules/escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", + "dev": true, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true, + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/esutils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", + "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/ethers": { + "version": "6.13.1", + "resolved": "https://registry.npmjs.org/ethers/-/ethers-6.13.1.tgz", + "integrity": "sha512-hdJ2HOxg/xx97Lm9HdCWk949BfYqYWpyw4//78SiwOLgASyfrNszfMUNB2joKjvGUdwhHfaiMMFFwacVVoLR9A==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/ethers-io/" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@adraffy/ens-normalize": "1.10.1", + "@noble/curves": "1.2.0", + "@noble/hashes": "1.3.2", + "@types/node": "18.15.13", + "aes-js": "4.0.0-beta.5", + "tslib": "2.4.0", + "ws": "8.17.1" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/ethers/node_modules/@types/node": { + "version": "18.15.13", + "resolved": "https://registry.npmjs.org/@types/node/-/node-18.15.13.tgz", + "integrity": "sha512-N+0kuo9KgrUQ1Sn/ifDXsvg0TTleP7rIy4zOBGECxAljqvqfqpTfzx0Q1NUedOixRMBfe2Whhb056a42cWs26Q==" + }, + "node_modules/evp_bytestokey": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/evp_bytestokey/-/evp_bytestokey-1.0.3.tgz", + "integrity": "sha512-/f2Go4TognH/KvCISP7OUsHn85hT9nUkxxA9BEWxFn+Oj9o8ZNLm/40hdlgSLyuOimsrTKLUMEorQexp/aPQeA==", + "dependencies": { + "md5.js": "^1.3.4", + "safe-buffer": "^5.1.1" + } + }, + "node_modules/execa": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", + "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "dev": true, + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/exit": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/exit/-/exit-0.1.2.tgz", + "integrity": "sha512-Zk/eNKV2zbjpKzrsQ+n1G6poVbErQxJ0LBOJXaKZ1EViLzH+hrLu9cdXI4zw9dBQJslwBEpbQ2P1oS7nDxs6jQ==", + "dev": true, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/expect": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/expect/-/expect-29.7.0.tgz", + "integrity": "sha512-2Zks0hf1VLFYI1kbh0I5jP3KHHyCHpkfyHBzsSXRFgl/Bg9mWYfMW8oD+PdMPlEwy5HNsR9JutYy6pMeOh61nw==", + "dev": true, + "dependencies": { + "@jest/expect-utils": "^29.7.0", + "jest-get-type": "^29.6.3", + "jest-matcher-utils": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/fast-json-stable-stringify": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", + "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", + "dev": true + }, + "node_modules/fast-xml-parser": { + "version": "4.2.5", + "resolved": "https://registry.npmjs.org/fast-xml-parser/-/fast-xml-parser-4.2.5.tgz", + "integrity": "sha512-B9/wizE4WngqQftFPmdaMYlXoJlJOYxGQOanC77fq9k8+Z0v5dDSVh+3glErdIROP//s/jgb7ZuxKfB8nVyo0g==", + "funding": [ + { + "type": "paypal", + "url": "https://paypal.me/naturalintelligence" + }, + { + "type": "github", + "url": "https://github.com/sponsors/NaturalIntelligence" + } + ], + "optional": true, + "dependencies": { + "strnum": "^1.0.5" + }, + "bin": { + "fxparser": "src/cli/cli.js" + } + }, + "node_modules/fb-watchman": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-2.0.2.tgz", + "integrity": "sha512-p5161BqbuCaSnB8jIbzQHOlpgsPmK5rJVDfDKO91Axs5NC1uu3HRQm6wt9cd9/+GtQQIO53JdGXXoyDpTAsgYA==", + "dev": true, + "dependencies": { + "bser": "2.1.1" + } + }, + "node_modules/file-uri-to-path": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", + "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==" + }, + "node_modules/fill-range": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", + "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", + "dev": true, + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/find-up": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", + "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "dev": true, + "dependencies": { + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/follow-redirects": { + "version": "1.15.6", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.6.tgz", + "integrity": "sha512-wWN62YITEaOpSK584EZXJafH1AGpO8RVgElfkuXbTOrPX4fIfOyEpW/CsiNd8JdYrAoOvafRTOEnvsO++qCqFA==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/RubenVerborgh" + } + ], + "engines": { + "node": ">=4.0" + }, + "peerDependenciesMeta": { + "debug": { + "optional": true + } + } + }, + "node_modules/form-data": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", + "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", + "dependencies": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "mime-types": "^2.1.12" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==", + "dev": true + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/function-bind": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/gensync": { + "version": "1.0.0-beta.2", + "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", + "integrity": "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", + "engines": { + "node": "6.* || 8.* || >= 10.*" + } + }, + "node_modules/get-package-type": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", + "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==", + "dev": true, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/get-stream": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/get-tsconfig": { + "version": "4.7.5", + "resolved": "https://registry.npmjs.org/get-tsconfig/-/get-tsconfig-4.7.5.tgz", + "integrity": "sha512-ZCuZCnlqNzjb4QprAzXKdpp/gh6KTxSJuw3IBsPnV/7fV4NxC9ckB+vPTt8w7fJA0TaSD7c55BR47JD6MEDyDw==", + "dependencies": { + "resolve-pkg-maps": "^1.0.0" + }, + "funding": { + "url": "https://github.com/privatenumber/get-tsconfig?sponsor=1" + } + }, + "node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "deprecated": "Glob versions prior to v9 are no longer supported", + "dev": true, + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/globals": { + "version": "11.12.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", + "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", + "dev": true + }, + "node_modules/has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/hash-base": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/hash-base/-/hash-base-3.1.0.tgz", + "integrity": "sha512-1nmYp/rhMDiE7AYkDw+lLwlAzz0AntGIe51F3RfFfEqyQ3feY2eI/NcwC6umIQVOASPMsWJLJScWKSSvzL9IVA==", + "dependencies": { + "inherits": "^2.0.4", + "readable-stream": "^3.6.0", + "safe-buffer": "^5.2.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/hash.js": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz", + "integrity": "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==", + "dependencies": { + "inherits": "^2.0.3", + "minimalistic-assert": "^1.0.1" + } + }, + "node_modules/hasown": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", + "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", + "dev": true, + "dependencies": { + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/hmac-drbg": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", + "integrity": "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==", + "dependencies": { + "hash.js": "^1.0.3", + "minimalistic-assert": "^1.0.0", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "node_modules/html-escaper": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-2.0.2.tgz", + "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", + "dev": true + }, + "node_modules/human-signals": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", + "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", + "dev": true, + "engines": { + "node": ">=10.17.0" + } + }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/import-local": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/import-local/-/import-local-3.1.0.tgz", + "integrity": "sha512-ASB07uLtnDs1o6EHjKpX34BKYDSqnFerfTOJL2HvMqF70LnxpjkzDB8J44oT9pu4AMPkQwf8jl6szgvNd2tRIg==", + "dev": true, + "dependencies": { + "pkg-dir": "^4.2.0", + "resolve-cwd": "^3.0.0" + }, + "bin": { + "import-local-fixture": "fixtures/cli.js" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/imurmurhash": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", + "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", + "dev": true, + "engines": { + "node": ">=0.8.19" + } + }, + "node_modules/inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", + "deprecated": "This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.", + "dev": true, + "dependencies": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "node_modules/ip-address": { + "version": "9.0.5", + "resolved": "https://registry.npmjs.org/ip-address/-/ip-address-9.0.5.tgz", + "integrity": "sha512-zHtQzGojZXTwZTHQqra+ETKd4Sn3vgi7uBmlPoXVWZqYvuKmtI0l/VZTjqGmJY9x88GGOaZ9+G9ES8hC4T4X8g==", + "dependencies": { + "jsbn": "1.1.0", + "sprintf-js": "^1.1.3" + }, + "engines": { + "node": ">= 12" + } + }, + "node_modules/ip-address/node_modules/sprintf-js": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.1.3.tgz", + "integrity": "sha512-Oo+0REFV59/rz3gfJNKQiBlwfHaSESl1pcGyABQsnnIfWOFt6JNj5gCog2U6MLZ//IGYD+nA8nI+mTShREReaA==" + }, + "node_modules/ip-regex": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ip-regex/-/ip-regex-4.3.0.tgz", + "integrity": "sha512-B9ZWJxHHOHUhUjCPrMpLD4xEq35bUTClHM1S6CBU5ixQnkZmwipwgc96vAd7AAGM9TGHvJR+Uss+/Ak6UphK+Q==", + "engines": { + "node": ">=8" + } + }, + "node_modules/is-arrayish": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", + "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==", + "dev": true + }, + "node_modules/is-core-module": { + "version": "2.14.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.14.0.tgz", + "integrity": "sha512-a5dFJih5ZLYlRtDc0dZWP7RiKr6xIKzmn/oAYCDvdLThadVgyJwlaoQPmRtMSpz+rk0OGAgIu+TcM9HUF0fk1A==", + "dev": true, + "dependencies": { + "hasown": "^2.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "engines": { + "node": ">=8" + } + }, + "node_modules/is-generator-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-generator-fn/-/is-generator-fn-2.1.0.tgz", + "integrity": "sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true, + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", + "dev": true, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", + "dev": true + }, + "node_modules/istanbul-lib-coverage": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.2.tgz", + "integrity": "sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-instrument": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-5.2.1.tgz", + "integrity": "sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg==", + "dev": true, + "dependencies": { + "@babel/core": "^7.12.3", + "@babel/parser": "^7.14.7", + "@istanbuljs/schema": "^0.1.2", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^6.3.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-report": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-3.0.1.tgz", + "integrity": "sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw==", + "dev": true, + "dependencies": { + "istanbul-lib-coverage": "^3.0.0", + "make-dir": "^4.0.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/istanbul-lib-report/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-report/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-source-maps": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz", + "integrity": "sha512-n3s8EwkdFIJCG3BPKBYvskgXGoy88ARzvegkitk60NxRdwltLOTaH7CUiMRXvwYorl0Q712iEjcWB+fK/MrWVw==", + "dev": true, + "dependencies": { + "debug": "^4.1.1", + "istanbul-lib-coverage": "^3.0.0", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/istanbul-reports": { + "version": "3.1.7", + "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-3.1.7.tgz", + "integrity": "sha512-BewmUXImeuRk2YY0PVbxgKAysvhRPUQE0h5QRM++nVWyubKGV0l8qQ5op8+B2DOmwSe63Jivj0BjkPQVf8fP5g==", + "dev": true, + "dependencies": { + "html-escaper": "^2.0.0", + "istanbul-lib-report": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest/-/jest-29.7.0.tgz", + "integrity": "sha512-NIy3oAFp9shda19hy4HK0HRTWKtPJmGdnvywu01nOqNC2vZg+Z+fvJDxpMQA88eb2I9EcafcdjYgsDthnYTvGw==", + "dev": true, + "dependencies": { + "@jest/core": "^29.7.0", + "@jest/types": "^29.6.3", + "import-local": "^3.0.2", + "jest-cli": "^29.7.0" + }, + "bin": { + "jest": "bin/jest.js" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } + } + }, + "node_modules/jest-changed-files": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-changed-files/-/jest-changed-files-29.7.0.tgz", + "integrity": "sha512-fEArFiwf1BpQ+4bXSprcDc3/x4HSzL4al2tozwVpDFpsxALjLYdyiIK4e5Vz66GQJIbXJ82+35PtysofptNX2w==", + "dev": true, + "dependencies": { + "execa": "^5.0.0", + "jest-util": "^29.7.0", + "p-limit": "^3.1.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-circus": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-circus/-/jest-circus-29.7.0.tgz", + "integrity": "sha512-3E1nCMgipcTkCocFwM90XXQab9bS+GMsjdpmPrlelaxwD93Ad8iVEjX/vvHPdLPnFf+L40u+5+iutRdA1N9myw==", + "dev": true, + "dependencies": { + "@jest/environment": "^29.7.0", + "@jest/expect": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "co": "^4.6.0", + "dedent": "^1.0.0", + "is-generator-fn": "^2.0.0", + "jest-each": "^29.7.0", + "jest-matcher-utils": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-runtime": "^29.7.0", + "jest-snapshot": "^29.7.0", + "jest-util": "^29.7.0", + "p-limit": "^3.1.0", + "pretty-format": "^29.7.0", + "pure-rand": "^6.0.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-circus/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-circus/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-circus/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-circus/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-circus/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-circus/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-cli": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.7.0.tgz", + "integrity": "sha512-OVVobw2IubN/GSYsxETi+gOe7Ka59EFMR/twOU3Jb2GnKKeMGJB5SGUUrEz3SFVmJASUdZUzy83sLNNQ2gZslg==", + "dev": true, + "dependencies": { + "@jest/core": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/types": "^29.6.3", + "chalk": "^4.0.0", + "create-jest": "^29.7.0", + "exit": "^0.1.2", + "import-local": "^3.0.2", + "jest-config": "^29.7.0", + "jest-util": "^29.7.0", + "jest-validate": "^29.7.0", + "yargs": "^17.3.1" + }, + "bin": { + "jest": "bin/jest.js" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "node-notifier": "^8.0.1 || ^9.0.0 || ^10.0.0" + }, + "peerDependenciesMeta": { + "node-notifier": { + "optional": true + } + } + }, + "node_modules/jest-cli/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-cli/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-cli/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-cli/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-cli/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-cli/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-config": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-config/-/jest-config-29.7.0.tgz", + "integrity": "sha512-uXbpfeQ7R6TZBqI3/TxCU4q4ttk3u0PJeC+E0zbfSoSjq6bJ7buBPxzQPL0ifrkY4DNu4JUdk0ImlBUYi840eQ==", + "dev": true, + "dependencies": { + "@babel/core": "^7.11.6", + "@jest/test-sequencer": "^29.7.0", + "@jest/types": "^29.6.3", + "babel-jest": "^29.7.0", + "chalk": "^4.0.0", + "ci-info": "^3.2.0", + "deepmerge": "^4.2.2", + "glob": "^7.1.3", + "graceful-fs": "^4.2.9", + "jest-circus": "^29.7.0", + "jest-environment-node": "^29.7.0", + "jest-get-type": "^29.6.3", + "jest-regex-util": "^29.6.3", + "jest-resolve": "^29.7.0", + "jest-runner": "^29.7.0", + "jest-util": "^29.7.0", + "jest-validate": "^29.7.0", + "micromatch": "^4.0.4", + "parse-json": "^5.2.0", + "pretty-format": "^29.7.0", + "slash": "^3.0.0", + "strip-json-comments": "^3.1.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "@types/node": "*", + "ts-node": ">=9.0.0" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "ts-node": { + "optional": true + } + } + }, + "node_modules/jest-config/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-config/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-config/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-config/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-config/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-config/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-diff": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.7.0.tgz", + "integrity": "sha512-LMIgiIrhigmPrs03JHpxUh2yISK3vLFPkAodPeo0+BuF7wA2FoQbkEg1u8gBYBThncu7e1oEDUfIXVuTqLRUjw==", + "dev": true, + "dependencies": { + "chalk": "^4.0.0", + "diff-sequences": "^29.6.3", + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-diff/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-diff/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-diff/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-diff/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-diff/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-diff/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-docblock": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-29.7.0.tgz", + "integrity": "sha512-q617Auw3A612guyaFgsbFeYpNP5t2aoUNLwBUbc/0kD1R4t9ixDbyFTHd1nok4epoVFpr7PmeWHrhvuV3XaJ4g==", + "dev": true, + "dependencies": { + "detect-newline": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-each": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-29.7.0.tgz", + "integrity": "sha512-gns+Er14+ZrEoC5fhOfYCY1LOHHr0TI+rQUHZS8Ttw2l7gl+80eHc/gFf2Ktkw0+SIACDTeWvpFcv3B04VembQ==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "chalk": "^4.0.0", + "jest-get-type": "^29.6.3", + "jest-util": "^29.7.0", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-each/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-each/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-each/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-each/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-each/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-each/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-environment-node": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-environment-node/-/jest-environment-node-29.7.0.tgz", + "integrity": "sha512-DOSwCRqXirTOyheM+4d5YZOrWcdu0LNZ87ewUoywbcb2XR4wKgqiG8vNeYwhjFMbEkfju7wx2GYH0P2gevGvFw==", + "dev": true, + "dependencies": { + "@jest/environment": "^29.7.0", + "@jest/fake-timers": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "jest-mock": "^29.7.0", + "jest-util": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-get-type": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/jest-get-type/-/jest-get-type-29.6.3.tgz", + "integrity": "sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw==", + "dev": true, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-haste-map": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-haste-map/-/jest-haste-map-29.7.0.tgz", + "integrity": "sha512-fP8u2pyfqx0K1rGn1R9pyE0/KTn+G7PxktWidOBTqFPLYX0b9ksaMFkhK5vrS3DVun09pckLdlx90QthlW7AmA==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "@types/graceful-fs": "^4.1.3", + "@types/node": "*", + "anymatch": "^3.0.3", + "fb-watchman": "^2.0.0", + "graceful-fs": "^4.2.9", + "jest-regex-util": "^29.6.3", + "jest-util": "^29.7.0", + "jest-worker": "^29.7.0", + "micromatch": "^4.0.4", + "walker": "^1.0.8" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "optionalDependencies": { + "fsevents": "^2.3.2" + } + }, + "node_modules/jest-leak-detector": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-29.7.0.tgz", + "integrity": "sha512-kYA8IJcSYtST2BY9I+SMC32nDpBT3J2NvWJx8+JCuCdl/CR1I4EKUJROiP8XtCcxqgTTBGJNdbB1A8XRKbTetw==", + "dev": true, + "dependencies": { + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-matcher-utils": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-29.7.0.tgz", + "integrity": "sha512-sBkD+Xi9DtcChsI3L3u0+N0opgPYnCRPtGcQYrgXmR+hmt/fYfWAL0xRXYU8eWOdfuLgBe0YCW3AFtnRLagq/g==", + "dev": true, + "dependencies": { + "chalk": "^4.0.0", + "jest-diff": "^29.7.0", + "jest-get-type": "^29.6.3", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-matcher-utils/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-matcher-utils/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-matcher-utils/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-matcher-utils/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-matcher-utils/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-matcher-utils/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-message-util": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-29.7.0.tgz", + "integrity": "sha512-GBEV4GRADeP+qtB2+6u61stea8mGcOT4mCtrYISZwfu9/ISHFJ/5zOMXYbpBE9RsS5+Gb63DW4FgmnKJ79Kf6w==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.12.13", + "@jest/types": "^29.6.3", + "@types/stack-utils": "^2.0.0", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.9", + "micromatch": "^4.0.4", + "pretty-format": "^29.7.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-message-util/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-message-util/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-message-util/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-message-util/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-message-util/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-message-util/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-mock": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-29.7.0.tgz", + "integrity": "sha512-ITOMZn+UkYS4ZFh83xYAOzWStloNzJFO2s8DWrE4lhtGD+AorgnbkiKERe4wQVBydIGPx059g6riW5Btp6Llnw==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "@types/node": "*", + "jest-util": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-pnp-resolver": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/jest-pnp-resolver/-/jest-pnp-resolver-1.2.3.tgz", + "integrity": "sha512-+3NpwQEnRoIBtx4fyhblQDPgJI0H1IEIkX7ShLUjPGA7TtUTvI1oiKi3SR4oBR0hQhQR80l4WAe5RrXBwWMA8w==", + "dev": true, + "engines": { + "node": ">=6" + }, + "peerDependencies": { + "jest-resolve": "*" + }, + "peerDependenciesMeta": { + "jest-resolve": { + "optional": true + } + } + }, + "node_modules/jest-regex-util": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-29.6.3.tgz", + "integrity": "sha512-KJJBsRCyyLNWCNBOvZyRDnAIfUiRJ8v+hOBQYGn8gDyF3UegwiP4gwRR3/SDa42g1YbVycTidUF3rKjyLFDWbg==", + "dev": true, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-resolve": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-resolve/-/jest-resolve-29.7.0.tgz", + "integrity": "sha512-IOVhZSrg+UvVAshDSDtHyFCCBUl/Q3AAJv8iZ6ZjnZ74xzvwuzLXid9IIIPgTnY62SJjfuupMKZsZQRsCvxEgA==", + "dev": true, + "dependencies": { + "chalk": "^4.0.0", + "graceful-fs": "^4.2.9", + "jest-haste-map": "^29.7.0", + "jest-pnp-resolver": "^1.2.2", + "jest-util": "^29.7.0", + "jest-validate": "^29.7.0", + "resolve": "^1.20.0", + "resolve.exports": "^2.0.0", + "slash": "^3.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-resolve-dependencies": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-resolve-dependencies/-/jest-resolve-dependencies-29.7.0.tgz", + "integrity": "sha512-un0zD/6qxJ+S0et7WxeI3H5XSe9lTBBR7bOHCHXkKR6luG5mwDDlIzVQ0V5cZCuoTgEdcdwzTghYkTWfubi+nA==", + "dev": true, + "dependencies": { + "jest-regex-util": "^29.6.3", + "jest-snapshot": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-resolve/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-resolve/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-resolve/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-resolve/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-resolve/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-resolve/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-runner": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-runner/-/jest-runner-29.7.0.tgz", + "integrity": "sha512-fsc4N6cPCAahybGBfTRcq5wFR6fpLznMg47sY5aDpsoejOcVYFb07AHuSnR0liMcPTgBsA3ZJL6kFOjPdoNipQ==", + "dev": true, + "dependencies": { + "@jest/console": "^29.7.0", + "@jest/environment": "^29.7.0", + "@jest/test-result": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "emittery": "^0.13.1", + "graceful-fs": "^4.2.9", + "jest-docblock": "^29.7.0", + "jest-environment-node": "^29.7.0", + "jest-haste-map": "^29.7.0", + "jest-leak-detector": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-resolve": "^29.7.0", + "jest-runtime": "^29.7.0", + "jest-util": "^29.7.0", + "jest-watcher": "^29.7.0", + "jest-worker": "^29.7.0", + "p-limit": "^3.1.0", + "source-map-support": "0.5.13" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-runner/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-runner/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-runner/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-runner/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-runner/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-runner/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-runtime": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-runtime/-/jest-runtime-29.7.0.tgz", + "integrity": "sha512-gUnLjgwdGqW7B4LvOIkbKs9WGbn+QLqRQQ9juC6HndeDiezIwhDP+mhMwHWCEcfQ5RUXa6OPnFF8BJh5xegwwQ==", + "dev": true, + "dependencies": { + "@jest/environment": "^29.7.0", + "@jest/fake-timers": "^29.7.0", + "@jest/globals": "^29.7.0", + "@jest/source-map": "^29.6.3", + "@jest/test-result": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "cjs-module-lexer": "^1.0.0", + "collect-v8-coverage": "^1.0.0", + "glob": "^7.1.3", + "graceful-fs": "^4.2.9", + "jest-haste-map": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-mock": "^29.7.0", + "jest-regex-util": "^29.6.3", + "jest-resolve": "^29.7.0", + "jest-snapshot": "^29.7.0", + "jest-util": "^29.7.0", + "slash": "^3.0.0", + "strip-bom": "^4.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-runtime/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-runtime/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-runtime/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-runtime/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-runtime/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-runtime/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-snapshot": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-snapshot/-/jest-snapshot-29.7.0.tgz", + "integrity": "sha512-Rm0BMWtxBcioHr1/OX5YCP8Uov4riHvKPknOGs804Zg9JGZgmIBkbtlxJC/7Z4msKYVbIJtfU+tKb8xlYNfdkw==", + "dev": true, + "dependencies": { + "@babel/core": "^7.11.6", + "@babel/generator": "^7.7.2", + "@babel/plugin-syntax-jsx": "^7.7.2", + "@babel/plugin-syntax-typescript": "^7.7.2", + "@babel/types": "^7.3.3", + "@jest/expect-utils": "^29.7.0", + "@jest/transform": "^29.7.0", + "@jest/types": "^29.6.3", + "babel-preset-current-node-syntax": "^1.0.0", + "chalk": "^4.0.0", + "expect": "^29.7.0", + "graceful-fs": "^4.2.9", + "jest-diff": "^29.7.0", + "jest-get-type": "^29.6.3", + "jest-matcher-utils": "^29.7.0", + "jest-message-util": "^29.7.0", + "jest-util": "^29.7.0", + "natural-compare": "^1.4.0", + "pretty-format": "^29.7.0", + "semver": "^7.5.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-snapshot/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-snapshot/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-snapshot/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-snapshot/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-snapshot/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-snapshot/node_modules/semver": { + "version": "7.6.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz", + "integrity": "sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/jest-snapshot/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-util": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.7.0.tgz", + "integrity": "sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "@types/node": "*", + "chalk": "^4.0.0", + "ci-info": "^3.2.0", + "graceful-fs": "^4.2.9", + "picomatch": "^2.2.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-util/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-util/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-util/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-util/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-util/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-util/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-validate": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.7.0.tgz", + "integrity": "sha512-ZB7wHqaRGVw/9hST/OuFUReG7M8vKeq0/J2egIGLdvjHCmYqGARhzXmtgi+gVeZ5uXFF219aOc3Ls2yLg27tkw==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "camelcase": "^6.2.0", + "chalk": "^4.0.0", + "jest-get-type": "^29.6.3", + "leven": "^3.1.0", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-validate/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-validate/node_modules/camelcase": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", + "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/jest-validate/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-validate/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-validate/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-validate/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-validate/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-watcher": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-29.7.0.tgz", + "integrity": "sha512-49Fg7WXkU3Vl2h6LbLtMQ/HyB6rXSIX7SqvBLQmssRBGN9I0PNvPmAmCWSOY6SOvrjhI/F7/bGAv9RtnsPA03g==", + "dev": true, + "dependencies": { + "@jest/test-result": "^29.7.0", + "@jest/types": "^29.6.3", + "@types/node": "*", + "ansi-escapes": "^4.2.1", + "chalk": "^4.0.0", + "emittery": "^0.13.1", + "jest-util": "^29.7.0", + "string-length": "^4.0.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-watcher/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-watcher/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-watcher/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-watcher/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/jest-watcher/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-watcher/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-worker": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-29.7.0.tgz", + "integrity": "sha512-eIz2msL/EzL9UFTFFx7jBTkeZfku0yUAyZZZmJ93H2TYEiroIx2PQjEXcwYtYl8zXCxb+PAmA2hLIt/6ZEkPHw==", + "dev": true, + "dependencies": { + "@types/node": "*", + "jest-util": "^29.7.0", + "merge-stream": "^2.0.0", + "supports-color": "^8.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-worker/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-worker/node_modules/supports-color": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", + "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/supports-color?sponsor=1" + } + }, + "node_modules/js-sha3": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz", + "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" + }, + "node_modules/js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "dev": true + }, + "node_modules/js-yaml": { + "version": "3.14.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", + "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", + "dev": true, + "dependencies": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, + "node_modules/jsbn": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-1.1.0.tgz", + "integrity": "sha512-4bYVV3aAMtDTTu4+xsDYa6sy9GyJ69/amsu9sYF2zqjiEoZA5xJi3BrfX3uY+/IekIu7MwdObdbDWpoZdBv3/A==" + }, + "node_modules/jsesc": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", + "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", + "dev": true, + "bin": { + "jsesc": "bin/jsesc" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/json-parse-even-better-errors": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", + "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", + "dev": true + }, + "node_modules/json5": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", + "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", + "dev": true, + "bin": { + "json5": "lib/cli.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/kleur": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/kleur/-/kleur-3.0.3.tgz", + "integrity": "sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/leven": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", + "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/lines-and-columns": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", + "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==", + "dev": true + }, + "node_modules/locate-path": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", + "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "dev": true, + "dependencies": { + "p-locate": "^4.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/lodash.debounce": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/lodash.debounce/-/lodash.debounce-4.0.8.tgz", + "integrity": "sha512-FT1yDzDYEoYWhnSGnpE/4Kj1fLZkDFyqRb7fNt6FdYOSxlUWAtp42Eh6Wb0rGIv/m9Bgo7x4GhQbm5Ys4SG5ow==", + "dev": true + }, + "node_modules/lru-cache": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", + "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==", + "dev": true, + "dependencies": { + "yallist": "^3.0.2" + } + }, + "node_modules/make-dir": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-4.0.0.tgz", + "integrity": "sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw==", + "dev": true, + "dependencies": { + "semver": "^7.5.3" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/make-dir/node_modules/semver": { + "version": "7.6.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz", + "integrity": "sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/make-error": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", + "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", + "dev": true, + "optional": true, + "peer": true + }, + "node_modules/makeerror": { + "version": "1.0.12", + "resolved": "https://registry.npmjs.org/makeerror/-/makeerror-1.0.12.tgz", + "integrity": "sha512-JmqCvUhmt43madlpFzG4BQzG2Z3m6tvQDNKdClZnO3VbIudJYmxsT0FNJMeiB2+JTSlTQTSbU8QdesVmwJcmLg==", + "dev": true, + "dependencies": { + "tmpl": "1.0.5" + } + }, + "node_modules/md5.js": { + "version": "1.3.5", + "resolved": "https://registry.npmjs.org/md5.js/-/md5.js-1.3.5.tgz", + "integrity": "sha512-xitP+WxNPcTTOgnTJcrhM0xvdPepipPSf3I8EIpGKeFLjt3PlJLIDG3u8EX53ZIubkb+5U2+3rELYpEhHhzdkg==", + "dependencies": { + "hash-base": "^3.0.0", + "inherits": "^2.0.1", + "safe-buffer": "^5.1.2" + } + }, + "node_modules/memory-pager": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/memory-pager/-/memory-pager-1.5.0.tgz", + "integrity": "sha512-ZS4Bp4r/Zoeq6+NLJpP+0Zzm0pR8whtGPf1XExKLJBAczGMnSi3It14OiNCStjQjM6NU1okjQGSxgEZN8eBYKg==", + "optional": true + }, + "node_modules/merge-stream": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", + "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", + "dev": true + }, + "node_modules/micromatch": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.7.tgz", + "integrity": "sha512-LPP/3KorzCwBxfeUuZmaR6bG2kdeHSbe0P2tY3FLRU4vYrjYz5hI4QZwV0njUx3jeuKe67YukQ1LSPZBKDqO/Q==", + "dev": true, + "dependencies": { + "braces": "^3.0.3", + "picomatch": "^2.3.1" + }, + "engines": { + "node": ">=8.6" + } + }, + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/minimalistic-assert": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", + "integrity": "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==" + }, + "node_modules/minimalistic-crypto-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", + "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" + }, + "node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/moment": { + "version": "2.30.1", + "resolved": "https://registry.npmjs.org/moment/-/moment-2.30.1.tgz", + "integrity": "sha512-uEmtNhbDOrWPFS+hdjFCBfy9f2YoyzRpwcl+DqpC6taX21FzsTLQVbMV/W7PzNSX6x/bhC1zA3c2UQ5NzH6how==", + "engines": { + "node": "*" + } + }, + "node_modules/mongodb": { + "version": "4.17.2", + "resolved": "https://registry.npmjs.org/mongodb/-/mongodb-4.17.2.tgz", + "integrity": "sha512-mLV7SEiov2LHleRJPMPrK2PMyhXFZt2UQLC4VD4pnth3jMjYKHhtqfwwkkvS/NXuo/Fp3vbhaNcXrIDaLRb9Tg==", + "dependencies": { + "bson": "^4.7.2", + "mongodb-connection-string-url": "^2.6.0", + "socks": "^2.7.1" + }, + "engines": { + "node": ">=12.9.0" + }, + "optionalDependencies": { + "@aws-sdk/credential-providers": "^3.186.0", + "@mongodb-js/saslprep": "^1.1.0" + } + }, + "node_modules/mongodb-connection-string-url": { + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/mongodb-connection-string-url/-/mongodb-connection-string-url-2.6.0.tgz", + "integrity": "sha512-WvTZlI9ab0QYtTYnuMLgobULWhokRjtC7db9LtcVfJ+Hsnyr5eo6ZtNAt3Ly24XZScGMelOcGtm7lSn0332tPQ==", + "dependencies": { + "@types/whatwg-url": "^8.2.1", + "whatwg-url": "^11.0.0" + } + }, + "node_modules/ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node_modules/nan": { + "version": "2.20.0", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.20.0.tgz", + "integrity": "sha512-bk3gXBZDGILuuo/6sKtr0DQmSThYHLtNCdSdXk9YkxD/jK6X2vmCyyXBBxyqZ4XcnzTyYEAThfX3DCEnLf6igw==" + }, + "node_modules/natural-compare": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", + "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", + "dev": true + }, + "node_modules/node-int64": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", + "integrity": "sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw==", + "dev": true + }, + "node_modules/node-releases": { + "version": "2.0.14", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.14.tgz", + "integrity": "sha512-y10wOWt8yZpqXmOgRo77WaHEmhYQYGNA6y421PKsKYWEK8aW+cqAphborZDhqfyKrbZEN92CN1X2KbafY2s7Yw==", + "dev": true + }, + "node_modules/normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm-run-path": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", + "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", + "dev": true, + "dependencies": { + "path-key": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "dev": true, + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/onetime": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", + "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", + "dev": true, + "dependencies": { + "mimic-fn": "^2.1.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-limit": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", + "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", + "dev": true, + "dependencies": { + "yocto-queue": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-locate": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", + "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "dev": true, + "dependencies": { + "p-limit": "^2.2.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/p-locate/node_modules/p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "dependencies": { + "p-try": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/parse-json": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", + "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", + "dev": true, + "dependencies": { + "@babel/code-frame": "^7.0.0", + "error-ex": "^1.3.1", + "json-parse-even-better-errors": "^2.3.0", + "lines-and-columns": "^1.1.6" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", + "dev": true + }, + "node_modules/pbkdf2": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/pbkdf2/-/pbkdf2-3.1.2.tgz", + "integrity": "sha512-iuh7L6jA7JEGu2WxDwtQP1ddOpaJNC4KlDEFfdQajSGgGPNi4OyDc2R7QnbY2bR9QjBVGwgvTdNJZoE7RaxUMA==", + "dependencies": { + "create-hash": "^1.1.2", + "create-hmac": "^1.1.4", + "ripemd160": "^2.0.1", + "safe-buffer": "^5.0.1", + "sha.js": "^2.4.8" + }, + "engines": { + "node": ">=0.12" + } + }, + "node_modules/picocolors": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.1.tgz", + "integrity": "sha512-anP1Z8qwhkbmu7MFP5iTt+wQKXgwzf7zTyGlcdzabySa9vd0Xt392U0rVmz9poOaBj0uHJKyyo9/upk0HrEQew==", + "dev": true + }, + "node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/pirates": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/pirates/-/pirates-4.0.6.tgz", + "integrity": "sha512-saLsH7WeYYPiD25LDuLRRY/i+6HaPYr6G1OUlN39otzkSTxKnubR9RTxS3/Kk50s1g2JTgFwWQDQyplC5/SHZg==", + "dev": true, + "engines": { + "node": ">= 6" + } + }, + "node_modules/pkg-dir": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-4.2.0.tgz", + "integrity": "sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==", + "dev": true, + "dependencies": { + "find-up": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/pretty-format": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-29.7.0.tgz", + "integrity": "sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==", + "dev": true, + "dependencies": { + "@jest/schemas": "^29.6.3", + "ansi-styles": "^5.0.0", + "react-is": "^18.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/pretty-format/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/prompts": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/prompts/-/prompts-2.4.2.tgz", + "integrity": "sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==", + "dev": true, + "dependencies": { + "kleur": "^3.0.3", + "sisteransi": "^1.0.5" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/proxy-from-env": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.1.0.tgz", + "integrity": "sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg==" + }, + "node_modules/punycode": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", + "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", + "engines": { + "node": ">=6" + } + }, + "node_modules/pure-rand": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/pure-rand/-/pure-rand-6.1.0.tgz", + "integrity": "sha512-bVWawvoZoBYpp6yIoQtQXHZjmz35RSVHnUOTefl8Vcjr8snTPY1wnpSPMWekcFwbxI6gtmT7rSYPFvz71ldiOA==", + "dev": true, + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/dubzzz" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/fast-check" + } + ] + }, + "node_modules/randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "dependencies": { + "safe-buffer": "^5.1.0" + } + }, + "node_modules/react-is": { + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", + "dev": true + }, + "node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/regenerate": { + "version": "1.4.2", + "resolved": "https://registry.npmjs.org/regenerate/-/regenerate-1.4.2.tgz", + "integrity": "sha512-zrceR/XhGYU/d/opr2EKO7aRHUeiBI8qjtfHqADTwZd6Szfy16la6kqD0MIUs5z5hx6AaKa+PixpPrR289+I0A==", + "dev": true + }, + "node_modules/regenerate-unicode-properties": { + "version": "10.1.1", + "resolved": "https://registry.npmjs.org/regenerate-unicode-properties/-/regenerate-unicode-properties-10.1.1.tgz", + "integrity": "sha512-X007RyZLsCJVVrjgEFVpLUTZwyOZk3oiL75ZcuYjlIWd6rNJtOjkBwQc5AsRrpbKVkxN6sklw/k/9m2jJYOf8Q==", + "dev": true, + "dependencies": { + "regenerate": "^1.4.2" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==" + }, + "node_modules/regenerator-transform": { + "version": "0.15.2", + "resolved": "https://registry.npmjs.org/regenerator-transform/-/regenerator-transform-0.15.2.tgz", + "integrity": "sha512-hfMp2BoF0qOk3uc5V20ALGDS2ddjQaLrdl7xrGXvAIow7qeWRM2VA2HuCHkUKk9slq3VwEwLNK3DFBqDfPGYtg==", + "dev": true, + "dependencies": { + "@babel/runtime": "^7.8.4" + } + }, + "node_modules/regexpu-core": { + "version": "5.3.2", + "resolved": "https://registry.npmjs.org/regexpu-core/-/regexpu-core-5.3.2.tgz", + "integrity": "sha512-RAM5FlZz+Lhmo7db9L298p2vHP5ZywrVXmVXpmAD9GuL5MPH6t9ROw1iA/wfHkQ76Qe7AaPF0nGuim96/IrQMQ==", + "dev": true, + "dependencies": { + "@babel/regjsgen": "^0.8.0", + "regenerate": "^1.4.2", + "regenerate-unicode-properties": "^10.1.0", + "regjsparser": "^0.9.1", + "unicode-match-property-ecmascript": "^2.0.0", + "unicode-match-property-value-ecmascript": "^2.1.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/regjsparser": { + "version": "0.9.1", + "resolved": "https://registry.npmjs.org/regjsparser/-/regjsparser-0.9.1.tgz", + "integrity": "sha512-dQUtn90WanSNl+7mQKcXAgZxvUe7Z0SqXlgzv0za4LwiUhyzBC58yQO3liFoUgu8GiJVInAhJjkj1N0EtQ5nkQ==", + "dev": true, + "dependencies": { + "jsesc": "~0.5.0" + }, + "bin": { + "regjsparser": "bin/parser" + } + }, + "node_modules/regjsparser/node_modules/jsesc": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-0.5.0.tgz", + "integrity": "sha512-uZz5UnB7u4T9LvwmFqXii7pZSouaRPorGs5who1Ip7VO0wxanFvBL7GkM6dTHlgX+jhBApRetaWpnDabOeTcnA==", + "dev": true, + "bin": { + "jsesc": "bin/jsesc" + } + }, + "node_modules/require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/resolve": { + "version": "1.22.8", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.8.tgz", + "integrity": "sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw==", + "dev": true, + "dependencies": { + "is-core-module": "^2.13.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/resolve-cwd": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/resolve-cwd/-/resolve-cwd-3.0.0.tgz", + "integrity": "sha512-OrZaX2Mb+rJCpH/6CpSqt9xFVpN++x01XnN2ie9g6P5/3xelLAkXWVADpdz1IHD/KFfEXyE6V0U01OQ3UO2rEg==", + "dev": true, + "dependencies": { + "resolve-from": "^5.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/resolve-from": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", + "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/resolve-pkg-maps": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/resolve-pkg-maps/-/resolve-pkg-maps-1.0.0.tgz", + "integrity": "sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==", + "funding": { + "url": "https://github.com/privatenumber/resolve-pkg-maps?sponsor=1" + } + }, + "node_modules/resolve.exports": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/resolve.exports/-/resolve.exports-2.0.2.tgz", + "integrity": "sha512-X2UW6Nw3n/aMgDVy+0rSqgHlv39WZAlZrXCdnbyEiKm17DSqHX4MmQMaST3FbeWR5FTuRcUwYAziZajji0Y7mg==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/ripemd160": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/ripemd160/-/ripemd160-2.0.2.tgz", + "integrity": "sha512-ii4iagi25WusVoiC4B4lq7pbXfAp3D9v5CwfkY33vffw2+pkDjY1D8GaN7spsxvCSx8dkPqOZCEZyfxcmJG2IA==", + "dependencies": { + "hash-base": "^3.0.0", + "inherits": "^2.0.1" + } + }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/secp256k1": { + "version": "3.8.0", + "resolved": "https://registry.npmjs.org/secp256k1/-/secp256k1-3.8.0.tgz", + "integrity": "sha512-k5ke5avRZbtl9Tqx/SA7CbY3NF6Ro+Sj9cZxezFzuBlLDmyqPiL8hJJ+EmzD8Ig4LUDByHJ3/iPOVoRixs/hmw==", + "hasInstallScript": true, + "dependencies": { + "bindings": "^1.5.0", + "bip66": "^1.1.5", + "bn.js": "^4.11.8", + "create-hash": "^1.2.0", + "drbg.js": "^1.0.1", + "elliptic": "^6.5.2", + "nan": "^2.14.0", + "safe-buffer": "^5.1.2" + }, + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/secp256k1/node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" + }, + "node_modules/semver": { + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/sha.js": { + "version": "2.4.11", + "resolved": "https://registry.npmjs.org/sha.js/-/sha.js-2.4.11.tgz", + "integrity": "sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ==", + "dependencies": { + "inherits": "^2.0.1", + "safe-buffer": "^5.0.1" + }, + "bin": { + "sha.js": "bin.js" + } + }, + "node_modules/shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "dev": true, + "dependencies": { + "shebang-regex": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", + "dev": true + }, + "node_modules/sisteransi": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz", + "integrity": "sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==", + "dev": true + }, + "node_modules/slash": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", + "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/smart-buffer": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/smart-buffer/-/smart-buffer-4.2.0.tgz", + "integrity": "sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg==", + "engines": { + "node": ">= 6.0.0", + "npm": ">= 3.0.0" + } + }, + "node_modules/socks": { + "version": "2.8.3", + "resolved": "https://registry.npmjs.org/socks/-/socks-2.8.3.tgz", + "integrity": "sha512-l5x7VUUWbjVFbafGLxPWkYsHIhEvmF85tbIeFZWc8ZPtoMyybuEhL7Jye/ooC4/d48FgOjSJXgsF/AJPYCW8Zw==", + "dependencies": { + "ip-address": "^9.0.5", + "smart-buffer": "^4.2.0" + }, + "engines": { + "node": ">= 10.0.0", + "npm": ">= 3.0.0" + } + }, + "node_modules/source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/source-map-support": { + "version": "0.5.13", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.13.tgz", + "integrity": "sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w==", + "dev": true, + "dependencies": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, + "node_modules/sparse-bitfield": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/sparse-bitfield/-/sparse-bitfield-3.0.3.tgz", + "integrity": "sha512-kvzhi7vqKTfkh0PZU+2D2PIllw2ymqJKujUcyPMd9Y75Nv4nPbGJZXNhxsgdQab2BmlDct1YnfQCguEvHr7VsQ==", + "optional": true, + "dependencies": { + "memory-pager": "^1.0.2" + } + }, + "node_modules/sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", + "dev": true + }, + "node_modules/stack-utils": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-2.0.6.tgz", + "integrity": "sha512-XlkWvfIm6RmsWtNJx+uqtKLS8eqFbxUg0ZzLXqY0caEy9l7hruX8IpiDnjsLavoBgqCCR71TqWO8MaXYheJ3RQ==", + "dev": true, + "dependencies": { + "escape-string-regexp": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/stack-utils/node_modules/escape-string-regexp": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz", + "integrity": "sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "dependencies": { + "safe-buffer": "~5.2.0" + } + }, + "node_modules/string-length": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/string-length/-/string-length-4.0.2.tgz", + "integrity": "sha512-+l6rNN5fYHNhZZy41RXsYptCjA2Igmq4EG7kZAYFQI1E1VTXarr6ZPXBg6eq7Y6eK4FEhY6AJlyuFIb/v/S0VQ==", + "dev": true, + "dependencies": { + "char-regex": "^1.0.2", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/string-width": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-bom": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-4.0.0.tgz", + "integrity": "sha512-3xurFv5tEgii33Zi8Jtp55wEIILR9eh34FAW00PZf+JnSsTmV/ioewSgQl97JHvgjoRGwPShsWm+IdrxB35d0w==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-final-newline": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", + "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/strip-json-comments": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", + "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", + "dev": true, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/strnum": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/strnum/-/strnum-1.0.5.tgz", + "integrity": "sha512-J8bbNyKKXl5qYcR36TIO8W3mVGVHrmmxsd5PAItGkmyzwJvybiw2IVq5nqd0i4LSNSkB/sx9VHllbfFdr9k1JA==", + "optional": true + }, + "node_modules/substrate-ss58": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/substrate-ss58/-/substrate-ss58-1.0.3.tgz", + "integrity": "sha512-LLgHp67I5E7X1E27ixd/rH1IEYEuzVhyFZaps4nmMM/Map4kKvm7pq/CsOTcraR9krKZhicucRw3zEQpkh0nXg==", + "dependencies": { + "@polkadot/util": "^1.4.1", + "@polkadot/util-crypto": "^1.4.1" + } + }, + "node_modules/supports-color": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "dev": true, + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/test-exclude": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz", + "integrity": "sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w==", + "dev": true, + "dependencies": { + "@istanbuljs/schema": "^0.1.2", + "glob": "^7.1.4", + "minimatch": "^3.0.4" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/tmpl": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", + "integrity": "sha512-3f0uOEAQwIqGuWW2MVzYg8fV/QNnc/IpuJNG837rLuczAaLVHslWHZQj4IGiEl5Hs3kkbhwL9Ab7Hrsmuj+Smw==", + "dev": true + }, + "node_modules/to-fast-properties": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", + "integrity": "sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + }, + "node_modules/tr46": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-3.0.0.tgz", + "integrity": "sha512-l7FvfAHlcmulp8kr+flpQZmVwtu7nfRV7NZujtN0OqES8EL4O4e0qqzL0DC5gAvx/ZC/9lk6rhcUwYvkBnBnYA==", + "dependencies": { + "punycode": "^2.1.1" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/ts-md5": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/ts-md5/-/ts-md5-1.3.1.tgz", + "integrity": "sha512-DiwiXfwvcTeZ5wCE0z+2A9EseZsztaiZtGrtSaY5JOD7ekPnR/GoIVD5gXZAlK9Na9Kvpo9Waz5rW64WKAWApg==", + "engines": { + "node": ">=12" + } + }, + "node_modules/ts-node": { + "version": "10.9.2", + "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.2.tgz", + "integrity": "sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ==", + "dev": true, + "optional": true, + "peer": true, + "dependencies": { + "@cspotcode/source-map-support": "^0.8.0", + "@tsconfig/node10": "^1.0.7", + "@tsconfig/node12": "^1.0.7", + "@tsconfig/node14": "^1.0.0", + "@tsconfig/node16": "^1.0.2", + "acorn": "^8.4.1", + "acorn-walk": "^8.1.1", + "arg": "^4.1.0", + "create-require": "^1.1.0", + "diff": "^4.0.1", + "make-error": "^1.1.1", + "v8-compile-cache-lib": "^3.0.1", + "yn": "3.1.1" + }, + "bin": { + "ts-node": "dist/bin.js", + "ts-node-cwd": "dist/bin-cwd.js", + "ts-node-esm": "dist/bin-esm.js", + "ts-node-script": "dist/bin-script.js", + "ts-node-transpile-only": "dist/bin-transpile.js", + "ts-script": "dist/bin-script-deprecated.js" + }, + "peerDependencies": { + "@swc/core": ">=1.2.50", + "@swc/wasm": ">=1.2.50", + "@types/node": "*", + "typescript": ">=2.7" + }, + "peerDependenciesMeta": { + "@swc/core": { + "optional": true + }, + "@swc/wasm": { + "optional": true + } + } + }, + "node_modules/tslib": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.0.tgz", + "integrity": "sha512-d6xOpEDfsi2CZVlPQzGeux8XMwLT9hssAsaPYExaQMuYskwb+x1x7J371tWlbBdWHroy99KnVB6qIkUbs5X3UQ==" + }, + "node_modules/tsx": { + "version": "4.16.0", + "resolved": "https://registry.npmjs.org/tsx/-/tsx-4.16.0.tgz", + "integrity": "sha512-MPgN+CuY+4iKxGoJNPv+1pyo5YWZAQ5XfsyobUG+zoKG7IkvCPLZDEyoIb8yLS2FcWci1nlxAqmvPlFWD5AFiQ==", + "dependencies": { + "esbuild": "~0.21.5", + "get-tsconfig": "^4.7.5" + }, + "bin": { + "tsx": "dist/cli.mjs" + }, + "engines": { + "node": ">=18.0.0" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + } + }, + "node_modules/tweetnacl": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz", + "integrity": "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==" + }, + "node_modules/type-detect": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", + "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/type-fest": { + "version": "0.21.3", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", + "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/typescript": { + "version": "4.9.5", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.9.5.tgz", + "integrity": "sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==", + "dev": true, + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=4.2.0" + } + }, + "node_modules/undici-types": { + "version": "5.26.5", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-5.26.5.tgz", + "integrity": "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==" + }, + "node_modules/unicode-canonical-property-names-ecmascript": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-2.0.0.tgz", + "integrity": "sha512-yY5PpDlfVIU5+y/BSCxAJRBIS1Zc2dDG3Ujq+sR0U+JjUevW2JhocOF+soROYDSaAezOzOKuyyixhD6mBknSmQ==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/unicode-match-property-ecmascript": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-2.0.0.tgz", + "integrity": "sha512-5kaZCrbp5mmbz5ulBkDkbY0SsPOjKqVS35VpL9ulMPfSl0J0Xsm+9Evphv9CoIZFwre7aJoa94AY6seMKGVN5Q==", + "dev": true, + "dependencies": { + "unicode-canonical-property-names-ecmascript": "^2.0.0", + "unicode-property-aliases-ecmascript": "^2.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/unicode-match-property-value-ecmascript": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-2.1.0.tgz", + "integrity": "sha512-qxkjQt6qjg/mYscYMC0XKRn3Rh0wFPlfxB0xkt9CfyTvpX1Ra0+rAmdX2QyAobptSEvuy4RtpPRui6XkV+8wjA==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/unicode-property-aliases-ecmascript": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-2.1.0.tgz", + "integrity": "sha512-6t3foTQI9qne+OZoVQB/8x8rk2k1eVy1gRXhV3oFQ5T6R1dqQ1xtin3XqSlx3+ATBkliTaR/hHyJBm+LVPNM8w==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/unorm": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/unorm/-/unorm-1.6.0.tgz", + "integrity": "sha512-b2/KCUlYZUeA7JFUuRJZPUtr4gZvBh7tavtv4fvk4+KV9pfGiR6CQAQAWl49ZpR3ts2dk4FYkP7EIgDJoiOLDA==", + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/update-browserslist-db": { + "version": "1.0.16", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.16.tgz", + "integrity": "sha512-KVbTxlBYlckhF5wgfyZXTWnMn7MMZjMu9XG8bPlliUOP9ThaF4QnhP8qrjrH7DRzHfSk0oQv1wToW+iA5GajEQ==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "escalade": "^3.1.2", + "picocolors": "^1.0.1" + }, + "bin": { + "update-browserslist-db": "cli.js" + }, + "peerDependencies": { + "browserslist": ">= 4.21.0" + } + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + }, + "node_modules/uuid": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz", + "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==", + "funding": [ + "https://github.com/sponsors/broofa", + "https://github.com/sponsors/ctavan" + ], + "optional": true, + "bin": { + "uuid": "dist/bin/uuid" + } + }, + "node_modules/v8-compile-cache-lib": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz", + "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==", + "dev": true, + "optional": true, + "peer": true + }, + "node_modules/v8-to-istanbul": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/v8-to-istanbul/-/v8-to-istanbul-9.3.0.tgz", + "integrity": "sha512-kiGUalWN+rgBJ/1OHZsBtU4rXZOfj/7rKQxULKlIzwzQSvMJUUNgPwJEEh7gU6xEVxC0ahoOBvN2YI8GH6FNgA==", + "dev": true, + "dependencies": { + "@jridgewell/trace-mapping": "^0.3.12", + "@types/istanbul-lib-coverage": "^2.0.1", + "convert-source-map": "^2.0.0" + }, + "engines": { + "node": ">=10.12.0" + } + }, + "node_modules/walker": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", + "integrity": "sha512-ts/8E8l5b7kY0vlWLewOkDXMmPdLcVV4GmOQLyxuSswIJsweeFZtAsMF7k1Nszz+TYBQrlYRmzOnr398y1JemQ==", + "dev": true, + "dependencies": { + "makeerror": "1.0.12" + } + }, + "node_modules/web3subscriber": { + "version": "1.0.0", + "resolved": "git+ssh://git@github.com/DelphinusLab/delphinus-web3subscriber.git#b623f2174498bde8746d2acd43519680c968e466", + "license": "ISC", + "dependencies": { + "@types/bn.js": "^5.1.0", + "bn.js": "^5.2.0", + "ethers": "^6.8.1", + "mongodb": "^4.1.3", + "substrate-ss58": "^1.0.3" + } + }, + "node_modules/webidl-conversions": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", + "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", + "engines": { + "node": ">=12" + } + }, + "node_modules/whatwg-url": { + "version": "11.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-11.0.0.tgz", + "integrity": "sha512-RKT8HExMpoYx4igMiVMY83lN6UeITKJlBQ+vR/8ZJ8OCdSiN3RwCq+9gH0+Xzj0+5IrM6i4j/6LuvzbZIQgEcQ==", + "dependencies": { + "tr46": "^3.0.0", + "webidl-conversions": "^7.0.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/wrap-ansi": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", + "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" + } + }, + "node_modules/wrap-ansi/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/wrap-ansi/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/wrap-ansi/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", + "dev": true + }, + "node_modules/write-file-atomic": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-4.0.2.tgz", + "integrity": "sha512-7KxauUdBmSdWnmpaGFg+ppNjKF8uNLry8LyzjauQDOVONfFLNKrKvQOxZ/VuTIcS/gge/YNahf5RIIQWTSarlg==", + "dev": true, + "dependencies": { + "imurmurhash": "^0.1.4", + "signal-exit": "^3.0.7" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/ws": { + "version": "8.17.1", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.17.1.tgz", + "integrity": "sha512-6XQFvXTkbfUOZOKKILFG1PDK2NDQs4azKQl26T0YS5CxqWLgXajbPZ+h4gZekJyRqFU8pvnbAbbs/3TgRPy+GQ==", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": ">=5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/xxhashjs": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/xxhashjs/-/xxhashjs-0.2.2.tgz", + "integrity": "sha512-AkTuIuVTET12tpsVIQo+ZU6f/qDmKuRUcjaqR+OIvm+aCBsZ95i7UVY5WJ9TMsSaZ0DA2WxoZ4acu0sPH+OKAw==", + "dependencies": { + "cuint": "^0.2.2" + } + }, + "node_modules/y18n": { + "version": "5.0.8", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", + "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", + "engines": { + "node": ">=10" + } + }, + "node_modules/yallist": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", + "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==", + "dev": true + }, + "node_modules/yargs": { + "version": "17.7.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", + "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", + "dev": true, + "dependencies": { + "cliui": "^8.0.1", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.3", + "y18n": "^5.0.5", + "yargs-parser": "^21.1.1" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/yargs-parser": { + "version": "21.1.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", + "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", + "engines": { + "node": ">=12" + } + }, + "node_modules/yn": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", + "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", + "dev": true, + "optional": true, + "peer": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/yocto-queue": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", + "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/zkwasm-service-helper": { + "version": "1.0.0", + "resolved": "git+ssh://git@github.com/DelphinusLab/zkWasm-service-helper.git#928c63f1520ee2bfa958dab4a2005662336987e1", + "dependencies": { + "@types/bn.js": "^5.1.1", + "axios": "^1.2.1", + "bn.js": "^5.1.1", + "ethers": "^6.8.1", + "form-data": "^4.0.0", + "ts-md5": "^1.3.1", + "web3subscriber": "git+https://github.com/DelphinusLab/delphinus-web3subscriber.git", + "yargs": "17.6.2" + } + }, + "node_modules/zkwasm-service-helper/node_modules/yargs": { + "version": "17.6.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.6.2.tgz", + "integrity": "sha512-1/9UrdHjDZc0eOU0HxOHoS78C69UD3JRMvzlJ7S79S2nTaWRA/whGCTV8o9e/N/1Va9YIV7Q4sOxD8VV4pCWOw==", + "dependencies": { + "cliui": "^8.0.1", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.3", + "y18n": "^5.0.5", + "yargs-parser": "^21.1.1" + }, + "engines": { + "node": ">=12" + } + } + } +} diff --git a/examples/package.json b/examples/package.json new file mode 100644 index 00000000..e1eee838 --- /dev/null +++ b/examples/package.json @@ -0,0 +1,23 @@ +{ + "name": "zkwasm-service-helper-examples", + "version": "1.0.0", + "private": true, + "description": "Examples for zkwasm playground helper lib to communicate with zkwasm cloud service", + "dependencies": { + "tsx": "^4.16.0", + "zkwasm-service-helper": "https://github.com/DelphinusLab/zkWasm-service-helper#zkwas-289" + }, + "scripts": { + "build": "rm -fr dist/* && npx tsc -p tsconfig.json && npx tsc -p tsconfig-cjs.json && sh ./addhybridpackage.sh" + }, + "devDependencies": { + "@babel/core": "^7.23.9", + "@babel/preset-env": "^7.23.9", + "@babel/preset-typescript": "^7.23.3", + "@types/jest": "^29.5.12", + "@types/node": "^18.11.17", + "babel-jest": "^29.7.0", + "jest": "^29.7.0", + "typescript": "^4.3.4" + } +} diff --git a/examples/src/config.ts b/examples/src/config.ts new file mode 100644 index 00000000..22d10b36 --- /dev/null +++ b/examples/src/config.ts @@ -0,0 +1,19 @@ +import { ZkWasmServiceHelper } from "zkwasm-service-helper"; + +// Exporting a config object for example usage. +export const ServiceHelperConfig = { + serverUrl: "https://rpc.zkwasmhub.com:8090", + privateKey: "", + userAddress: "", +}; +export const ServiceHelper = new ZkWasmServiceHelper( + ServiceHelperConfig.serverUrl, + "", + "" +); + +// Example information required for verifying a proof. +export const Web3ChainConfig = { + providerUrl: "https://data-seed-prebsc-2-s1.bnbchain.org:8545", + chainId: 97, +}; diff --git a/examples/src/files/context.data b/examples/src/files/context.data new file mode 100644 index 0000000000000000000000000000000000000000..e0d84f457d2b5c802ecd286e7e576365d94af3b9 GIT binary patch literal 8 PcmZQzWMXDvWn%{b09*ha literal 0 HcmV?d00001 diff --git a/examples/src/files/image.wasm b/examples/src/files/image.wasm new file mode 100644 index 0000000000000000000000000000000000000000..cfccae5812d8deb432ff7cdb55c3cf4570fe2e16 GIT binary patch literal 129 zcmXAgK?=e!6hvo!YAP*A!JW7Wy-C*|!gi5Gltde?MHj}UH}RTA+{}ab7z`Ir09>h_ ziO)Rf!6ZhM4Yz8}eec3~x&l8@MmtU}T2KjPQIH~fnV;S3UDV}Tw732g?*jce`oRTA UwdIDAIyU&U_=CHKh6acF3;r${-v9sr literal 0 HcmV?d00001 diff --git a/examples/src/queries/autosubmit.ts b/examples/src/queries/autosubmit.ts new file mode 100644 index 00000000..79cce265 --- /dev/null +++ b/examples/src/queries/autosubmit.ts @@ -0,0 +1,80 @@ +import { + Round1BatchProof, + Round1BatchProofQuery, + PaginationResult, + PaginatedQuery, + Round2BatchProofQuery, + Round2BatchProof, + FinalBatchProof, + FinalBatchProofQuery, +} from "zkwasm-service-helper"; +import { ServiceHelper } from "../config"; + +// This will query the the queue of Round 1 proofs to be batched. +// Values returned are of the batch proof queue (Inputs to the proof from the original task) +// The Output of the Round 1 proof is stored in Round2BatchProof. + +// Query parameters are all optional, build your own based on your needs +// let round1QueueQuery: PaginatedQuery = { +// task_id, // Task id of the original task that the batch proof is associated with +// status: Round1BatchProofStatus.Batched, +// start: 0, +// total: 1, +// chain_id: 11155111, // Chain id of the auto submit network if required +// }; +export async function QueryRound1Queue( + queryParams: PaginatedQuery +): Promise> { + const response: PaginationResult = + await ServiceHelper.queryRound1BatchProofs(queryParams); + + // The response will contain items in the batch proof queue for Round 1 + const round1_input_data: Round1BatchProof = response.data[0]; + console.log("Proof details: "); + console.log(" ", round1_input_data); + + return response; +} + +// Query parameters are all optional, build your own based on your needs +// let round2QueueQuery: PaginatedQuery = { +// task_id, // Task id of the original task that the batch proof is associated with +// status: Round2BatchProofStatus.Batched, +// start: 0, +// total: 1, +// chain_id: 11155111, // Chain id of the auto submit network if required +// }; + +export async function QueryRound2Queue( + queryParams: PaginatedQuery +): Promise> { + const response: PaginationResult = + await ServiceHelper.queryRound2BatchProofs(queryParams); + + // The response will contain items in the batch proof queue for Round 2 + // Note that the items in the response contain the inputs to Round 2, which are also the outputs of Round 1. + const round2_input_data: Round2BatchProof = response.data[0]; + console.log("Proof details: "); + console.log(" ", round2_input_data); + + return response; +} + +export async function QueryFinalBatchProof( + queryParams: PaginatedQuery +): Promise> { + const task_id = ""; + + const response: PaginationResult = + await ServiceHelper.queryFinalBatchProofs(queryParams); + + // The response contains fully batched round 2 output information. + // Log it here for demonstration purposes. + + const proof: FinalBatchProof = response.data[0]; + console.log("Proof details: "); + console.log(" ", proof); + + // Return raw response for further processing + return response; +} diff --git a/examples/src/queries/task.ts b/examples/src/queries/task.ts new file mode 100644 index 00000000..2789bc2c --- /dev/null +++ b/examples/src/queries/task.ts @@ -0,0 +1,54 @@ +import { + ZkWasmServiceHelper, + ZkWasmUtil, + QueryParams, + PaginationResult, + Task, +} from "zkwasm-service-helper"; +import BN from "bn.js"; +import { ServiceHelper } from "../config"; + +// Provide the query parameters, all fields are optional +// const args: QueryParams = { +// id: taskid!, +// md5: null, +// user_address: null, +// tasktype: null, +// taskstatus: null, +// }; + +export async function QueryTasks(queryParams: QueryParams) { + const response: PaginationResult = await ServiceHelper.loadTasks( + queryParams + ); + const task: Task = response.data[0]; + + // convert the byte array to BN + let aggregate_proof = ZkWasmUtil.bytesToBN(task.proof); + let instances = ZkWasmUtil.bytesToBN(task.instances); + let batchInstances = ZkWasmUtil.bytesToBN(task.batch_instances); + let aux = ZkWasmUtil.bytesToBN(task.aux); + let fee = task.task_fee && ZkWasmUtil.convertAmount(task.task_fee); + + console.log("Task details: "); + console.log(" ", task); + console.log("proof:"); + aggregate_proof.map((proof: BN) => { + console.log("0x", proof.toString("hex")); + }); + console.log("batch_instacne:"); + batchInstances.map((ins: BN) => { + console.log("0x", ins.toString("hex")); + }); + console.log("instance:"); + instances.map((ins: BN) => { + console.log("0x", ins.toString("hex")); + }); + console.log(" aux:"); + aux.map((aux: BN) => { + console.log("0x", aux.toString("hex")); + }); + console.log("fee:", fee); + + return response; +} diff --git a/examples/src/tasks/addNewImage.ts b/examples/src/tasks/addNewImage.ts new file mode 100644 index 00000000..98bdfcb8 --- /dev/null +++ b/examples/src/tasks/addNewImage.ts @@ -0,0 +1,69 @@ +import { + AddImageParams, + WithSignature, + ZkWasmUtil, + ProvePaymentSrc, + WithInitialContext, +} from "zkwasm-service-helper"; + +import path from "node:path"; + +import fs from "node:fs"; +import { ServiceHelper, ServiceHelperConfig } from "../config"; + +export async function AddNewWasmImage() { + const __dirname = path.resolve(path.dirname("")); + const wasmFilePath = path.resolve(__dirname, "./src/files/image.wasm"); + const contextFilePath = path.resolve(__dirname, "./src/files/context.data"); + const fileSelected: Buffer = fs.readFileSync(wasmFilePath); + const md5 = ZkWasmUtil.convertToMd5(fileSelected as Uint8Array); + + let params: AddImageParams = { + name: "image.wasm", + image_md5: md5, + image: fileSelected, + user_address: ServiceHelperConfig.userAddress.toLowerCase(), + description_url: "", + avator_url: "", + circuit_size: 22, + // Determines whether the credits will be deducted from the user supplying proof requests (default) or the user who created the image + // Currently Enum values are Default and CreatorPay + prove_payment_src: ProvePaymentSrc.Default, + + // Networks which the auto submit service will batch and submit the proof to. + // Unsupported networks will be rejected. + // If empty array, Auto Submitted proofs will be rejected. + auto_submit_network_ids: [11155111], + }; + + // Optional Initial Context information + + // Upload a binary file first + let [contextFile, contextMd5] = await ZkWasmUtil.loadContexFileAsBytes( + contextFilePath + ); + + if (contextFile) { + let context_info: WithInitialContext = { + initial_context: contextFile, + initial_context_md5: contextMd5, + }; + params = { ...params, ...context_info }; + } + + let msg = ZkWasmUtil.createAddImageSignMessage(params); + let signature: string = await ZkWasmUtil.signMessage( + msg, + ServiceHelperConfig.privateKey + ); //Need user private key to sign the msg + let task: WithSignature = { + ...params, + signature, + }; + + let response = await ServiceHelper.addNewWasmImage(task); + + console.log("Add Image Response: ", response); +} + +AddNewWasmImage(); diff --git a/examples/src/tasks/submitProofTask.ts b/examples/src/tasks/submitProofTask.ts new file mode 100644 index 00000000..bd87e24c --- /dev/null +++ b/examples/src/tasks/submitProofTask.ts @@ -0,0 +1,94 @@ +import { + ProvingParams, + WithSignature, + ZkWasmUtil, + ProofSubmitMode, + InputContextType, + WithCustomInputContextType, +} from "zkwasm-service-helper"; + +import { ServiceHelper, ServiceHelperConfig } from "../config"; + +export async function AddNewProofTask() { + const image_md5 = ""; + const public_inputs = "0x22:i64 0x21:i64"; + const private_inputs = ""; + + const pb_inputs: Array = ZkWasmUtil.validateInputs(public_inputs); + const priv_inputs: Array = ZkWasmUtil.validateInputs(private_inputs); + + // Use the helper Enum type to determine the proof submit mode + const proofSubmitMode = ProofSubmitMode.Auto + ? ProofSubmitMode.Auto + : ProofSubmitMode.Manual; + + let provingParams: ProvingParams = { + user_address: ServiceHelperConfig.userAddress.toLowerCase(), + md5: image_md5, + public_inputs: pb_inputs, + private_inputs: priv_inputs, + // Whether the proof will be batched and verified through the auto submit service or manually submitted. + // If the field is not specified, the default value will be ProofSubmitMode.Manual and the proof will not be batched. + proof_submit_mode: proofSubmitMode, + }; + + // Context type for proof task. If none provided, will default to InputContextType.ImageCurrent in the server and use the image's current context + const selectedInputContextType = InputContextType.Custom; + + // For Custom Context, upload a binary file first containing the context. + if (selectedInputContextType === InputContextType.Custom) { + // Load bytes into Tempfile/Buffer type - Server side example with NodeJS + const contextBytes = new Uint8Array(64); + contextBytes.fill(1); + ZkWasmUtil.validateContextBytes(contextBytes); + let bytesFile = await ZkWasmUtil.bytesToTempFile(contextBytes); + + // // LOADING AS FILE DIRECTLY - Server side example with NodeJS + // let bytesFile = await ZkWasmUtil.loadContexFileAsBytes(""); + // // Convert uint8array to buffer + // const contextBytes: Buffer = Buffer.from(bytesFile); + + let context_info: WithCustomInputContextType = { + input_context: bytesFile, + input_context_md5: ZkWasmUtil.convertToMd5(contextBytes), + input_context_type: selectedInputContextType, + }; + + // // LOADING AS FILE DIRECTLY - Browser side example + // let contextFile = await ZkWasmUtil.loadContexFileAsBytes(""); + + // let context_info: WithCustomInputContextType = { + // input_context: contextFile, + // input_context_md5: ZkWasmUtil.convertToMd5(contextFile), + // input_context_type: selectedInputContextType, + // }; + provingParams = { ...provingParams, ...context_info }; + } else { + provingParams = { + ...provingParams, + input_context_type: selectedInputContextType, + }; + } + const msgString = ZkWasmUtil.createProvingSignMessage(provingParams); + + let signature: string; + try { + signature = await ZkWasmUtil.signMessage( + msgString, + ServiceHelperConfig.privateKey + ); + } catch (e: unknown) { + console.log("error signing message", e); + return; + } + + const fullParams: WithSignature = { + ...provingParams, + signature: signature, + }; + + const response = await ServiceHelper.addProvingTask(fullParams); + console.log(response); +} + +AddNewProofTask(); diff --git a/examples/src/verify/verifyAutoSubmitProof.ts b/examples/src/verify/verifyAutoSubmitProof.ts new file mode 100644 index 00000000..cc8b2e88 --- /dev/null +++ b/examples/src/verify/verifyAutoSubmitProof.ts @@ -0,0 +1,124 @@ +import { + ZkWasmUtil, + Task, + QueryParams, + AutoSubmitStatus, + Round2BatchProof, + Round2BatchProofStatus, + VerifyBatchProofParams, +} from "zkwasm-service-helper"; +import { withDelphinusWalletConnector } from "web3subscriber/src/client"; + +import { ServiceHelperConfig, Web3ChainConfig } from "../config"; +import { QueryTasks } from "../queries/task"; +import { QueryFinalBatchProof, QueryRound2Queue } from "../queries/autosubmit"; +import { + DelphinusBaseProvider, + GetBaseProvider, +} from "web3subscriber/src/provider"; + +const provider: DelphinusBaseProvider = GetBaseProvider( + Web3ChainConfig.providerUrl // web3 provider URL for the verifier chain +); + +export async function VerifyAutoSubmitProof() { + const queryParams: QueryParams = { + id: "", + tasktype: "Prove", + taskstatus: "Done", + user_address: null, + md5: null, + total: 1, + }; + + // Fetch a task from the playground service which contains the proof information + // See the example to build query function to fetch task details + const taskResponse = await QueryTasks(queryParams); + + // Handle missing tasks accordingly + // Assume task exists + const task: Task = taskResponse.data[0]; + + // Check if the base proof task has been registered with the BatchVerifier contract + // Note that this is a naive check as the Auto Submit service may have registered the proof only on one chain and not other ones. + const isRegistered = + task.auto_submit_status === AutoSubmitStatus.RegisteredProof; + + if (!isRegistered) { + console.log("Proof not registered on any batch verification contracts"); + return; + } + + const queryRound2QueueResponse = await QueryRound2Queue({ + task_id: task._id["$oid"], + chain_id: Web3ChainConfig.chainId, + status: Round2BatchProofStatus.Batched, + total: 1, + }); + + // Handle missing round 2 proofs accordingly + // Assume round 2 proof exists + // Since the response returned is the input to the round 2 proof, we will use this to verify the proof + const round_1_output: Round2BatchProof = queryRound2QueueResponse.data[0]; + + // Convert the Number[] into bytes/Uint8Array + const round_1_target_instances: Array = + round_1_output.target_instances.map((x) => { + return new Uint8Array(x); + }); + + // Convert the Number[] into bytes/Uint8Array + const round_1_shadow_instances: Uint8Array = new Uint8Array( + round_1_output.shadow_instances! + ); + + // Find the index of this proof in the round 1 output by comparing task_ids + // This will be used to verify that this proof was included in a particular batch. + // If it does not exist, the verification will fail + const index = round_1_output.task_ids.findIndex( + (id) => id === task._id["$oid"] + ); + + let proof_info: VerifyBatchProofParams = { + membership_proof_index: [BigInt(index)], + verify_instance: task.shadow_instances, + sibling_instances: round_1_target_instances, + round_1_shadow_instance: round_1_shadow_instances, + target_instances: [task.instances], + }; + + const finalBatchResponse = await QueryFinalBatchProof({ + task_id: task._id["$oid"], + chain_id: Web3ChainConfig.chainId, + }); + + // Handle missing final batch proofs accordingly + // Assume final batch proof exists + const finalBatchProof = finalBatchResponse.data[0]; + + // Use the Batch Verifier contract address to verify the proof + const contractAddress = finalBatchProof.verifier_contracts.batch_verifier; + + await withDelphinusWalletConnector( + async (connector) => { + let contract = await ZkWasmUtil.composeBatchVerifierContract( + connector, + contractAddress + ); + + let tx = await ZkWasmUtil.verifyBatchedProof( + contract.getEthersContract(), + proof_info + ); + // wait for tx to be mined, can add no. of confirmations as arg + const receipt = await tx.wait(); + + console.log("transaction:", tx.hash); + console.log("receipt:", receipt); + }, + provider, + ServiceHelperConfig.privateKey + ); +} + +VerifyAutoSubmitProof(); diff --git a/examples/src/verify/verifyProof.ts b/examples/src/verify/verifyProof.ts new file mode 100644 index 00000000..e718fd7a --- /dev/null +++ b/examples/src/verify/verifyProof.ts @@ -0,0 +1,92 @@ +import { + VerifyProofParams, + ZkWasmUtil, + Task, + QueryParams, +} from "zkwasm-service-helper"; +import { + withBrowserConnector, + withDelphinusWalletConnector, +} from "web3subscriber/src/client"; +import { + DelphinusBaseProvider, + DelphinusBrowserConnector, + GetBaseProvider, +} from "web3subscriber/src/provider"; +import { ServiceHelperConfig, Web3ChainConfig } from "../config"; +import { QueryTasks } from "../queries/task"; + +const provider: DelphinusBaseProvider = GetBaseProvider( + Web3ChainConfig.providerUrl // web3 provider URL for the verifier chain +); + +export async function VerifyProof() { + const queryParams: QueryParams = { + id: "", + tasktype: "Prove", + taskstatus: "Done", + user_address: null, + md5: null, + total: 1, + }; + + // Fetch a task from the playground service which contains the proof information + // See the example to build query function to fetch task details + const response = await QueryTasks(queryParams); + + // Handle missing tasks accordingly + // Assume task exists + const task: Task = response.data[0]; + + const verifierContractAddress = + task.task_verification_data.verifier_contracts.find( + (x) => x.chain_id === Web3ChainConfig.chainId + ); + + if (!verifierContractAddress) { + console.log( + "Verifier contract not found for chain id: ", + Web3ChainConfig.chainId + ); + return; + } + + await withDelphinusWalletConnector( + async (connector) => { + let contract = await ZkWasmUtil.composeVerifyContract( + connector, + task.task_verification_data.verifier_contracts[0].aggregator_verifier + ); + + // If the proof has no shadow instances, use the batch instances to try and verify instead. + // Mostly for legacy purposes. + // Proofs submitted with Auto Submit will not be verified using this method. + + let verify_instance = + task.shadow_instances.length === 0 + ? task.batch_instances + : task.shadow_instances; + + let verifyProofParams: VerifyProofParams = { + aggregate_proof: task.proof, + verify_instance: verify_instance, + aux: task.aux, + instances: [task.instances], // The target instances are wrapped in an array + }; + + let tx = await ZkWasmUtil.verifyProof( + contract.getEthersContract(), + verifyProofParams + ); + // wait for tx to be mined, can add no. of confirmations as arg + const receipt = await tx.wait(); + + console.log("transaction:", tx.hash); + console.log("receipt:", receipt); + }, + provider, + ServiceHelperConfig.privateKey + ); +} + +VerifyProof(); diff --git a/examples/tsconfig.json b/examples/tsconfig.json new file mode 100644 index 00000000..e18d1a2b --- /dev/null +++ b/examples/tsconfig.json @@ -0,0 +1,14 @@ +{ + "compilerOptions": { + "target": "ES2020", + "module": "ES2015", + "sourceMap": true, + "rootDir": "./src", + "noEmit": true, + "strict": true, + "moduleResolution": "node", + "esModuleInterop": true, + "skipLibCheck": true, + "forceConsistentCasingInFileNames": true + } +} diff --git a/src/helper/task.ts b/src/helper/task.ts index e1ce7e62..dbda64ec 100644 --- a/src/helper/task.ts +++ b/src/helper/task.ts @@ -385,7 +385,7 @@ export class ZkWasmServiceHelper { true ); if (this.endpoint.enable_logs) { - console.log("get addProvingTask response:", response.toString()); + console.log("get addProvingTask response:", response); } return response; } diff --git a/src/helper/util.ts b/src/helper/util.ts index b1ed5b0e..2ddcab04 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -18,7 +18,7 @@ import { DelphinusBrowserConnector, } from "web3subscriber/src/provider.js"; //import ERC20 from "../abi/ERC20"; -import { ERC20Lib } from "../abi/ERC20.js" +import { ERC20Lib } from "../abi/ERC20.js"; export class ZkWasmUtil { static contract_abi = { @@ -266,15 +266,15 @@ export class ZkWasmUtil { message += params.avator_url; message += params.circuit_size; - // Additional params afterwards - if (params.initial_context) { - message += params.initial_context_md5; - } - message += params.prove_payment_src; for (const chainId of params.auto_submit_network_ids) { message += chainId; } + + // Additional params afterwards + if (params.initial_context) { + message += params.initial_context_md5; + } return message; } @@ -513,9 +513,13 @@ export class ZkWasmUtil { ): Promise { if (typeof window === "undefined") { // We are in Node.js - const fs = require("fs"); - //const fs = await import("fs").then((module) => module.promises); - return fs.readFile(filePath, "utf8"); + const fs = await import("fs/promises"); + + const file = await fs.readFile(filePath, { + encoding: "utf-8", + }); + + return file; } else { // Browser environment throw new Error( @@ -525,12 +529,15 @@ export class ZkWasmUtil { } // For nodejs/server environments only - static async loadContexFileAsBytes(filePath: string): Promise { + static async loadContexFileAsBytes( + filePath: string + ): Promise<[Buffer, string]> { try { const fileContents = await this.loadContextFileFromPath(filePath); let bytes = new TextEncoder().encode(fileContents); this.validateContextBytes(bytes); - return bytes; + const md5 = this.convertToMd5(bytes); + return [Buffer.from(bytes), md5]; } catch (err) { throw err; } From d3d0ee42541bdab1bc704662b9ad15716bfdca80 Mon Sep 17 00:00:00 2001 From: Richard Hao Date: Tue, 2 Jul 2024 21:36:22 +1000 Subject: [PATCH 31/36] ZKWAS-289 (#82) * update type names * remove * naming updates * fix verify addr --- dist/cjs/helper/task.d.ts | 8 ++-- dist/cjs/helper/task.js | 6 +-- dist/cjs/index.d.ts | 6 +-- dist/cjs/index.js | 8 ++-- dist/cjs/interface/interface.d.ts | 35 +++++++------- dist/cjs/interface/interface.js | 36 +++++++-------- dist/mjs/helper/task.d.ts | 8 ++-- dist/mjs/helper/task.js | 6 +-- dist/mjs/index.d.ts | 6 +-- dist/mjs/index.js | 4 +- dist/mjs/interface/interface.d.ts | 35 +++++++------- dist/mjs/interface/interface.js | 34 +++++++------- examples/package-lock.json | 2 +- examples/src/queries/autosubmit.ts | 48 ++++++++++---------- examples/src/queries/task.ts | 3 +- examples/src/verify/verifyAutoSubmitProof.ts | 31 +++++-------- examples/src/verify/verifyProof.ts | 8 ++-- src/helper/task.ts | 30 ++++++------ src/index.ts | 36 +++++++-------- src/interface/interface.ts | 38 +++++++++------- 20 files changed, 195 insertions(+), 193 deletions(-) diff --git a/dist/cjs/helper/task.d.ts b/dist/cjs/helper/task.d.ts index 1ba6cae0..d10fce04 100644 --- a/dist/cjs/helper/task.d.ts +++ b/dist/cjs/helper/task.d.ts @@ -1,4 +1,4 @@ -import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, Round1BatchProofQuery, Round2BatchProofQuery, Round2BatchProof, Round1BatchProof, FinalBatchProofQuery, FinalBatchProof, ConciseTask, NodeStatistics, NodeStatisticsQueryParams } from "../interface/interface.js"; +import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, AutoSubmitProofQuery, Round1InfoQuery, Round1Info, Round2Info, Round2InfoQuery, AutoSubmitProof, ConciseTask, NodeStatistics, NodeStatisticsQueryParams } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; export declare class ZkWasmServiceHelper { endpoint: ZkWasmServiceEndpoint; @@ -14,9 +14,9 @@ export declare class ZkWasmServiceHelper { queryNodeStatistics(query: NodeStatisticsQueryParams): Promise; loadTasks(query: QueryParams): Promise>; loadTaskList(query: QueryParams): Promise>; - queryRound1BatchProofs(query: PaginatedQuery): Promise>; - queryRound2BatchProofs(query: PaginatedQuery): Promise>; - queryFinalBatchProofs(query: PaginatedQuery): Promise>; + queryAutoSubmitProofs(query: PaginatedQuery): Promise>; + queryRound1Info(query: PaginatedQuery): Promise>; + queryRound2Info(query: PaginatedQuery): Promise>; queryLogs(query: WithSignature): Promise; addPayment(payRequest: PaymentParams): Promise; addSubscription(subscription: SubscriptionRequest): Promise; diff --git a/dist/cjs/helper/task.js b/dist/cjs/helper/task.js index 9bddf343..5a4787a9 100644 --- a/dist/cjs/helper/task.js +++ b/dist/cjs/helper/task.js @@ -226,7 +226,7 @@ class ZkWasmServiceHelper { return tasks; }); } - queryRound1BatchProofs(query) { + queryAutoSubmitProofs(query) { return __awaiter(this, void 0, void 0, function* () { let proofData = yield this.endpoint.invokeRequest("GET", TaskEndpoint.ROUND_1_BATCH, JSON.parse(JSON.stringify(query))); if (this.endpoint.enable_logs) { @@ -235,7 +235,7 @@ class ZkWasmServiceHelper { return proofData; }); } - queryRound2BatchProofs(query) { + queryRound1Info(query) { return __awaiter(this, void 0, void 0, function* () { let proofData = yield this.endpoint.invokeRequest("GET", TaskEndpoint.ROUND_2_BATCH, JSON.parse(JSON.stringify(query))); if (this.endpoint.enable_logs) { @@ -244,7 +244,7 @@ class ZkWasmServiceHelper { return proofData; }); } - queryFinalBatchProofs(query) { + queryRound2Info(query) { return __awaiter(this, void 0, void 0, function* () { let proofData = yield this.endpoint.invokeRequest("GET", TaskEndpoint.FINAL_BATCH, JSON.parse(JSON.stringify(query))); if (this.endpoint.enable_logs) { diff --git a/dist/cjs/index.d.ts b/dist/cjs/index.d.ts index 81088a29..d8b90130 100644 --- a/dist/cjs/index.d.ts +++ b/dist/cjs/index.d.ts @@ -1,7 +1,7 @@ -import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams } from "./interface/interface.js"; +import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; import { ERC20Lib } from "./abi/ERC20.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; -export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, AutoSubmitProofStatus, Round1Status, Round2Status, ProofSubmitMode, ProvePaymentSrc, }; +export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, }; diff --git a/dist/cjs/index.js b/dist/cjs/index.js index 1286336b..7205f5e9 100644 --- a/dist/cjs/index.js +++ b/dist/cjs/index.js @@ -1,12 +1,12 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.ProvePaymentSrc = exports.ProofSubmitMode = exports.FinalProofStatus = exports.Round2BatchProofStatus = exports.Round1BatchProofStatus = exports.AutoSubmitStatus = exports.InputContextType = exports.ERC20Lib = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; +exports.ProvePaymentSrc = exports.ProofSubmitMode = exports.Round2Status = exports.Round1Status = exports.AutoSubmitProofStatus = exports.AutoSubmitStatus = exports.InputContextType = exports.ERC20Lib = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; const interface_js_1 = require("./interface/interface.js"); Object.defineProperty(exports, "InputContextType", { enumerable: true, get: function () { return interface_js_1.InputContextType; } }); -Object.defineProperty(exports, "Round1BatchProofStatus", { enumerable: true, get: function () { return interface_js_1.Round1BatchProofStatus; } }); -Object.defineProperty(exports, "Round2BatchProofStatus", { enumerable: true, get: function () { return interface_js_1.Round2BatchProofStatus; } }); +Object.defineProperty(exports, "AutoSubmitProofStatus", { enumerable: true, get: function () { return interface_js_1.AutoSubmitProofStatus; } }); +Object.defineProperty(exports, "Round1Status", { enumerable: true, get: function () { return interface_js_1.Round1Status; } }); +Object.defineProperty(exports, "Round2Status", { enumerable: true, get: function () { return interface_js_1.Round2Status; } }); Object.defineProperty(exports, "AutoSubmitStatus", { enumerable: true, get: function () { return interface_js_1.AutoSubmitStatus; } }); -Object.defineProperty(exports, "FinalProofStatus", { enumerable: true, get: function () { return interface_js_1.FinalProofStatus; } }); Object.defineProperty(exports, "ProofSubmitMode", { enumerable: true, get: function () { return interface_js_1.ProofSubmitMode; } }); Object.defineProperty(exports, "ProvePaymentSrc", { enumerable: true, get: function () { return interface_js_1.ProvePaymentSrc; } }); const util_js_1 = require("./helper/util.js"); diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index cde3caee..944979cd 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -45,7 +45,7 @@ export interface Task { input_context: Uint8Array; input_context_type?: InputContextType; output_context: Uint8Array; - _id: any; + _id: ObjectId; submit_time: string; process_started?: string; process_finished?: string; @@ -58,6 +58,9 @@ export interface Task { batch_proof_data?: BatchProofData; auto_submit_status?: AutoSubmitStatus; } +export type ObjectId = { + $oid: string; +}; export interface ConciseTask { _id: any; user_address: string; @@ -79,7 +82,7 @@ export interface BatchProofData { round_2_batch_ids?: AutoSubmitBatchMetadata[]; final_proof_batch_ids?: AutoSubmitBatchMetadata[]; } -export interface Round1BatchProof { +export interface AutoSubmitProof { _id?: any; task_id: string; base_proof_circuit_size: number; @@ -92,17 +95,17 @@ export interface Round1BatchProof { internal_message?: string; static_files_verification_data: StaticFileVerificationData; auto_submit_network_chain_id: number; - status: Round1BatchProofStatus; + status: AutoSubmitProofStatus; } export interface StaticFileVerificationData { static_file_checksum: Uint8Array; } -export declare enum Round1BatchProofStatus { +export declare enum AutoSubmitProofStatus { Pending = "Pending", Batched = "Batched", Failed = "Failed" } -export interface Round2BatchProof { +export interface Round1Info { _id?: any; round_1_ids: string[]; task_ids: string[]; @@ -117,14 +120,14 @@ export interface Round2BatchProof { auto_submit_network_chain_id: number; verifier_contracts: VerifierContracts; static_files_verification_data: StaticFileVerificationData; - status: Round2BatchProofStatus; + status: Round1Status; } -export declare enum Round2BatchProofStatus { +export declare enum Round1Status { Pending = "Pending", Batched = "Batched", Failed = "Failed" } -export interface FinalBatchProof { +export interface Round2Info { _id?: any; round_2_ids: string[]; task_ids: string[]; @@ -139,32 +142,32 @@ export interface FinalBatchProof { auto_submit_network_chain_id: number; verifier_contracts: VerifierContracts; registered_tx_hash: string | null; - status: FinalProofStatus; + status: Round2Status; } -export declare enum FinalProofStatus { +export declare enum Round2Status { ProofNotRegistered = "ProofNotRegistered", ProofRegistered = "ProofRegistered" } export type PaginatedQuery = T & PaginationQuery; -export interface Round1BatchProofQuery { +export interface AutoSubmitProofQuery { id?: string; task_id?: string; - status?: Round1BatchProofStatus; + status?: AutoSubmitProofStatus; circuit_size?: number; chain_id?: number; } -export interface Round2BatchProofQuery { +export interface Round1InfoQuery { id?: string; task_id?: string; - status?: Round2BatchProofStatus; + status?: Round1Status; circuit_size?: number; chain_id?: number; } -export interface FinalBatchProofQuery { +export interface Round2InfoQuery { id?: string; round_2_id?: string; task_id?: string; - status?: FinalProofStatus; + status?: Round2Status; chain_id?: number; } export interface PaginationQuery { diff --git a/dist/cjs/interface/interface.js b/dist/cjs/interface/interface.js index 196d61ed..99848958 100644 --- a/dist/cjs/interface/interface.js +++ b/dist/cjs/interface/interface.js @@ -1,29 +1,29 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.ProofSubmitMode = exports.ProvePaymentSrc = exports.AutoSubmitStatus = exports.FinalProofStatus = exports.Round2BatchProofStatus = exports.Round1BatchProofStatus = exports.InputContextType = void 0; +exports.ProofSubmitMode = exports.ProvePaymentSrc = exports.AutoSubmitStatus = exports.Round2Status = exports.Round1Status = exports.AutoSubmitProofStatus = exports.InputContextType = void 0; var InputContextType; (function (InputContextType) { InputContextType["Custom"] = "Custom"; InputContextType["ImageInitial"] = "ImageInitial"; InputContextType["ImageCurrent"] = "ImageCurrent"; })(InputContextType = exports.InputContextType || (exports.InputContextType = {})); -var Round1BatchProofStatus; -(function (Round1BatchProofStatus) { - Round1BatchProofStatus["Pending"] = "Pending"; - Round1BatchProofStatus["Batched"] = "Batched"; - Round1BatchProofStatus["Failed"] = "Failed"; -})(Round1BatchProofStatus = exports.Round1BatchProofStatus || (exports.Round1BatchProofStatus = {})); -var Round2BatchProofStatus; -(function (Round2BatchProofStatus) { - Round2BatchProofStatus["Pending"] = "Pending"; - Round2BatchProofStatus["Batched"] = "Batched"; - Round2BatchProofStatus["Failed"] = "Failed"; -})(Round2BatchProofStatus = exports.Round2BatchProofStatus || (exports.Round2BatchProofStatus = {})); -var FinalProofStatus; -(function (FinalProofStatus) { - FinalProofStatus["ProofNotRegistered"] = "ProofNotRegistered"; - FinalProofStatus["ProofRegistered"] = "ProofRegistered"; -})(FinalProofStatus = exports.FinalProofStatus || (exports.FinalProofStatus = {})); +var AutoSubmitProofStatus; +(function (AutoSubmitProofStatus) { + AutoSubmitProofStatus["Pending"] = "Pending"; + AutoSubmitProofStatus["Batched"] = "Batched"; + AutoSubmitProofStatus["Failed"] = "Failed"; +})(AutoSubmitProofStatus = exports.AutoSubmitProofStatus || (exports.AutoSubmitProofStatus = {})); +var Round1Status; +(function (Round1Status) { + Round1Status["Pending"] = "Pending"; + Round1Status["Batched"] = "Batched"; + Round1Status["Failed"] = "Failed"; +})(Round1Status = exports.Round1Status || (exports.Round1Status = {})); +var Round2Status; +(function (Round2Status) { + Round2Status["ProofNotRegistered"] = "ProofNotRegistered"; + Round2Status["ProofRegistered"] = "ProofRegistered"; +})(Round2Status = exports.Round2Status || (exports.Round2Status = {})); var AutoSubmitStatus; (function (AutoSubmitStatus) { AutoSubmitStatus["Round1"] = "Round1"; diff --git a/dist/mjs/helper/task.d.ts b/dist/mjs/helper/task.d.ts index 1ba6cae0..d10fce04 100644 --- a/dist/mjs/helper/task.d.ts +++ b/dist/mjs/helper/task.d.ts @@ -1,4 +1,4 @@ -import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, Round1BatchProofQuery, Round2BatchProofQuery, Round2BatchProof, Round1BatchProof, FinalBatchProofQuery, FinalBatchProof, ConciseTask, NodeStatistics, NodeStatisticsQueryParams } from "../interface/interface.js"; +import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, AutoSubmitProofQuery, Round1InfoQuery, Round1Info, Round2Info, Round2InfoQuery, AutoSubmitProof, ConciseTask, NodeStatistics, NodeStatisticsQueryParams } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; export declare class ZkWasmServiceHelper { endpoint: ZkWasmServiceEndpoint; @@ -14,9 +14,9 @@ export declare class ZkWasmServiceHelper { queryNodeStatistics(query: NodeStatisticsQueryParams): Promise; loadTasks(query: QueryParams): Promise>; loadTaskList(query: QueryParams): Promise>; - queryRound1BatchProofs(query: PaginatedQuery): Promise>; - queryRound2BatchProofs(query: PaginatedQuery): Promise>; - queryFinalBatchProofs(query: PaginatedQuery): Promise>; + queryAutoSubmitProofs(query: PaginatedQuery): Promise>; + queryRound1Info(query: PaginatedQuery): Promise>; + queryRound2Info(query: PaginatedQuery): Promise>; queryLogs(query: WithSignature): Promise; addPayment(payRequest: PaymentParams): Promise; addSubscription(subscription: SubscriptionRequest): Promise; diff --git a/dist/mjs/helper/task.js b/dist/mjs/helper/task.js index 4a319f6e..c7cc6f40 100644 --- a/dist/mjs/helper/task.js +++ b/dist/mjs/helper/task.js @@ -179,21 +179,21 @@ export class ZkWasmServiceHelper { } return tasks; } - async queryRound1BatchProofs(query) { + async queryAutoSubmitProofs(query) { let proofData = await this.endpoint.invokeRequest("GET", TaskEndpoint.ROUND_1_BATCH, JSON.parse(JSON.stringify(query))); if (this.endpoint.enable_logs) { console.log("loading proof data!"); } return proofData; } - async queryRound2BatchProofs(query) { + async queryRound1Info(query) { let proofData = await this.endpoint.invokeRequest("GET", TaskEndpoint.ROUND_2_BATCH, JSON.parse(JSON.stringify(query))); if (this.endpoint.enable_logs) { console.log("loading proof data!"); } return proofData; } - async queryFinalBatchProofs(query) { + async queryRound2Info(query) { let proofData = await this.endpoint.invokeRequest("GET", TaskEndpoint.FINAL_BATCH, JSON.parse(JSON.stringify(query))); if (this.endpoint.enable_logs) { console.log("loading proof data!"); diff --git a/dist/mjs/index.d.ts b/dist/mjs/index.d.ts index 81088a29..d8b90130 100644 --- a/dist/mjs/index.d.ts +++ b/dist/mjs/index.d.ts @@ -1,7 +1,7 @@ -import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofStatus, Round2BatchProofStatus, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams } from "./interface/interface.js"; +import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; import { ERC20Lib } from "./abi/ERC20.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; -export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, Round1BatchProof, Round2BatchProof, FinalBatchProof, Round1BatchProofQuery, Round2BatchProofQuery, FinalBatchProofQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, AutoSubmitProofStatus, Round1Status, Round2Status, ProofSubmitMode, ProvePaymentSrc, }; +export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, }; diff --git a/dist/mjs/index.js b/dist/mjs/index.js index 231024d0..dd7ba510 100644 --- a/dist/mjs/index.js +++ b/dist/mjs/index.js @@ -1,6 +1,6 @@ -import { InputContextType, Round1BatchProofStatus, Round2BatchProofStatus, AutoSubmitStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, } from "./interface/interface.js"; +import { InputContextType, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitStatus, ProofSubmitMode, ProvePaymentSrc, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; import { ERC20Lib } from "./abi/ERC20.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, Round1BatchProofStatus, Round2BatchProofStatus, FinalProofStatus, ProofSubmitMode, ProvePaymentSrc, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, AutoSubmitProofStatus, Round1Status, Round2Status, ProofSubmitMode, ProvePaymentSrc, }; diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index cde3caee..944979cd 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -45,7 +45,7 @@ export interface Task { input_context: Uint8Array; input_context_type?: InputContextType; output_context: Uint8Array; - _id: any; + _id: ObjectId; submit_time: string; process_started?: string; process_finished?: string; @@ -58,6 +58,9 @@ export interface Task { batch_proof_data?: BatchProofData; auto_submit_status?: AutoSubmitStatus; } +export type ObjectId = { + $oid: string; +}; export interface ConciseTask { _id: any; user_address: string; @@ -79,7 +82,7 @@ export interface BatchProofData { round_2_batch_ids?: AutoSubmitBatchMetadata[]; final_proof_batch_ids?: AutoSubmitBatchMetadata[]; } -export interface Round1BatchProof { +export interface AutoSubmitProof { _id?: any; task_id: string; base_proof_circuit_size: number; @@ -92,17 +95,17 @@ export interface Round1BatchProof { internal_message?: string; static_files_verification_data: StaticFileVerificationData; auto_submit_network_chain_id: number; - status: Round1BatchProofStatus; + status: AutoSubmitProofStatus; } export interface StaticFileVerificationData { static_file_checksum: Uint8Array; } -export declare enum Round1BatchProofStatus { +export declare enum AutoSubmitProofStatus { Pending = "Pending", Batched = "Batched", Failed = "Failed" } -export interface Round2BatchProof { +export interface Round1Info { _id?: any; round_1_ids: string[]; task_ids: string[]; @@ -117,14 +120,14 @@ export interface Round2BatchProof { auto_submit_network_chain_id: number; verifier_contracts: VerifierContracts; static_files_verification_data: StaticFileVerificationData; - status: Round2BatchProofStatus; + status: Round1Status; } -export declare enum Round2BatchProofStatus { +export declare enum Round1Status { Pending = "Pending", Batched = "Batched", Failed = "Failed" } -export interface FinalBatchProof { +export interface Round2Info { _id?: any; round_2_ids: string[]; task_ids: string[]; @@ -139,32 +142,32 @@ export interface FinalBatchProof { auto_submit_network_chain_id: number; verifier_contracts: VerifierContracts; registered_tx_hash: string | null; - status: FinalProofStatus; + status: Round2Status; } -export declare enum FinalProofStatus { +export declare enum Round2Status { ProofNotRegistered = "ProofNotRegistered", ProofRegistered = "ProofRegistered" } export type PaginatedQuery = T & PaginationQuery; -export interface Round1BatchProofQuery { +export interface AutoSubmitProofQuery { id?: string; task_id?: string; - status?: Round1BatchProofStatus; + status?: AutoSubmitProofStatus; circuit_size?: number; chain_id?: number; } -export interface Round2BatchProofQuery { +export interface Round1InfoQuery { id?: string; task_id?: string; - status?: Round2BatchProofStatus; + status?: Round1Status; circuit_size?: number; chain_id?: number; } -export interface FinalBatchProofQuery { +export interface Round2InfoQuery { id?: string; round_2_id?: string; task_id?: string; - status?: FinalProofStatus; + status?: Round2Status; chain_id?: number; } export interface PaginationQuery { diff --git a/dist/mjs/interface/interface.js b/dist/mjs/interface/interface.js index 3b813b8b..7344a7ff 100644 --- a/dist/mjs/interface/interface.js +++ b/dist/mjs/interface/interface.js @@ -4,23 +4,23 @@ export var InputContextType; InputContextType["ImageInitial"] = "ImageInitial"; InputContextType["ImageCurrent"] = "ImageCurrent"; })(InputContextType || (InputContextType = {})); -export var Round1BatchProofStatus; -(function (Round1BatchProofStatus) { - Round1BatchProofStatus["Pending"] = "Pending"; - Round1BatchProofStatus["Batched"] = "Batched"; - Round1BatchProofStatus["Failed"] = "Failed"; -})(Round1BatchProofStatus || (Round1BatchProofStatus = {})); -export var Round2BatchProofStatus; -(function (Round2BatchProofStatus) { - Round2BatchProofStatus["Pending"] = "Pending"; - Round2BatchProofStatus["Batched"] = "Batched"; - Round2BatchProofStatus["Failed"] = "Failed"; -})(Round2BatchProofStatus || (Round2BatchProofStatus = {})); -export var FinalProofStatus; -(function (FinalProofStatus) { - FinalProofStatus["ProofNotRegistered"] = "ProofNotRegistered"; - FinalProofStatus["ProofRegistered"] = "ProofRegistered"; -})(FinalProofStatus || (FinalProofStatus = {})); +export var AutoSubmitProofStatus; +(function (AutoSubmitProofStatus) { + AutoSubmitProofStatus["Pending"] = "Pending"; + AutoSubmitProofStatus["Batched"] = "Batched"; + AutoSubmitProofStatus["Failed"] = "Failed"; +})(AutoSubmitProofStatus || (AutoSubmitProofStatus = {})); +export var Round1Status; +(function (Round1Status) { + Round1Status["Pending"] = "Pending"; + Round1Status["Batched"] = "Batched"; + Round1Status["Failed"] = "Failed"; +})(Round1Status || (Round1Status = {})); +export var Round2Status; +(function (Round2Status) { + Round2Status["ProofNotRegistered"] = "ProofNotRegistered"; + Round2Status["ProofRegistered"] = "ProofRegistered"; +})(Round2Status || (Round2Status = {})); export var AutoSubmitStatus; (function (AutoSubmitStatus) { AutoSubmitStatus["Round1"] = "Round1"; diff --git a/examples/package-lock.json b/examples/package-lock.json index 10ef807d..9901a3dc 100644 --- a/examples/package-lock.json +++ b/examples/package-lock.json @@ -9702,7 +9702,7 @@ }, "node_modules/zkwasm-service-helper": { "version": "1.0.0", - "resolved": "git+ssh://git@github.com/DelphinusLab/zkWasm-service-helper.git#928c63f1520ee2bfa958dab4a2005662336987e1", + "resolved": "git+ssh://git@github.com/DelphinusLab/zkWasm-service-helper.git#6327b99f78e0d89e78f0d5b4d92feb2c72e53bb9", "dependencies": { "@types/bn.js": "^5.1.1", "axios": "^1.2.1", diff --git a/examples/src/queries/autosubmit.ts b/examples/src/queries/autosubmit.ts index 79cce265..ea6fce00 100644 --- a/examples/src/queries/autosubmit.ts +++ b/examples/src/queries/autosubmit.ts @@ -1,12 +1,12 @@ import { - Round1BatchProof, - Round1BatchProofQuery, PaginationResult, PaginatedQuery, - Round2BatchProofQuery, - Round2BatchProof, - FinalBatchProof, - FinalBatchProofQuery, + AutoSubmitProofQuery, + AutoSubmitProof, + Round1InfoQuery, + Round1Info, + Round2InfoQuery, + Round2Info, } from "zkwasm-service-helper"; import { ServiceHelper } from "../config"; @@ -22,14 +22,14 @@ import { ServiceHelper } from "../config"; // total: 1, // chain_id: 11155111, // Chain id of the auto submit network if required // }; -export async function QueryRound1Queue( - queryParams: PaginatedQuery -): Promise> { - const response: PaginationResult = - await ServiceHelper.queryRound1BatchProofs(queryParams); +export async function queryAutoSubmitProofs( + queryParams: PaginatedQuery +): Promise> { + const response: PaginationResult = + await ServiceHelper.queryAutoSubmitProofs(queryParams); // The response will contain items in the batch proof queue for Round 1 - const round1_input_data: Round1BatchProof = response.data[0]; + const round1_input_data: AutoSubmitProof = response.data[0]; console.log("Proof details: "); console.log(" ", round1_input_data); @@ -45,33 +45,33 @@ export async function QueryRound1Queue( // chain_id: 11155111, // Chain id of the auto submit network if required // }; -export async function QueryRound2Queue( - queryParams: PaginatedQuery -): Promise> { - const response: PaginationResult = - await ServiceHelper.queryRound2BatchProofs(queryParams); +export async function queryRound1ProofInfo( + queryParams: PaginatedQuery +): Promise> { + const response: PaginationResult = + await ServiceHelper.queryRound1Info(queryParams); // The response will contain items in the batch proof queue for Round 2 // Note that the items in the response contain the inputs to Round 2, which are also the outputs of Round 1. - const round2_input_data: Round2BatchProof = response.data[0]; + const round2_input_data: Round1Info = response.data[0]; console.log("Proof details: "); console.log(" ", round2_input_data); return response; } -export async function QueryFinalBatchProof( - queryParams: PaginatedQuery -): Promise> { +export async function queryRound2ProofInfo( + queryParams: PaginatedQuery +): Promise> { const task_id = ""; - const response: PaginationResult = - await ServiceHelper.queryFinalBatchProofs(queryParams); + const response: PaginationResult = + await ServiceHelper.queryRound2Info(queryParams); // The response contains fully batched round 2 output information. // Log it here for demonstration purposes. - const proof: FinalBatchProof = response.data[0]; + const proof: Round2Info = response.data[0]; console.log("Proof details: "); console.log(" ", proof); diff --git a/examples/src/queries/task.ts b/examples/src/queries/task.ts index 2789bc2c..d6280b6d 100644 --- a/examples/src/queries/task.ts +++ b/examples/src/queries/task.ts @@ -1,5 +1,4 @@ import { - ZkWasmServiceHelper, ZkWasmUtil, QueryParams, PaginationResult, @@ -17,7 +16,7 @@ import { ServiceHelper } from "../config"; // taskstatus: null, // }; -export async function QueryTasks(queryParams: QueryParams) { +export async function queryTasks(queryParams: QueryParams) { const response: PaginationResult = await ServiceHelper.loadTasks( queryParams ); diff --git a/examples/src/verify/verifyAutoSubmitProof.ts b/examples/src/verify/verifyAutoSubmitProof.ts index cc8b2e88..7c2e50de 100644 --- a/examples/src/verify/verifyAutoSubmitProof.ts +++ b/examples/src/verify/verifyAutoSubmitProof.ts @@ -3,15 +3,15 @@ import { Task, QueryParams, AutoSubmitStatus, - Round2BatchProof, - Round2BatchProofStatus, VerifyBatchProofParams, + Round1Status, + Round1Info, } from "zkwasm-service-helper"; import { withDelphinusWalletConnector } from "web3subscriber/src/client"; import { ServiceHelperConfig, Web3ChainConfig } from "../config"; -import { QueryTasks } from "../queries/task"; -import { QueryFinalBatchProof, QueryRound2Queue } from "../queries/autosubmit"; +import { queryTasks } from "../queries/task"; +import { queryRound1ProofInfo } from "../queries/autosubmit"; import { DelphinusBaseProvider, GetBaseProvider, @@ -33,7 +33,7 @@ export async function VerifyAutoSubmitProof() { // Fetch a task from the playground service which contains the proof information // See the example to build query function to fetch task details - const taskResponse = await QueryTasks(queryParams); + const taskResponse = await queryTasks(queryParams); // Handle missing tasks accordingly // Assume task exists @@ -49,17 +49,17 @@ export async function VerifyAutoSubmitProof() { return; } - const queryRound2QueueResponse = await QueryRound2Queue({ - task_id: task._id["$oid"], + const round_1_info_response = await queryRound1ProofInfo({ + task_id: task._id.$oid, chain_id: Web3ChainConfig.chainId, - status: Round2BatchProofStatus.Batched, + status: Round1Status.Batched, total: 1, }); // Handle missing round 2 proofs accordingly // Assume round 2 proof exists // Since the response returned is the input to the round 2 proof, we will use this to verify the proof - const round_1_output: Round2BatchProof = queryRound2QueueResponse.data[0]; + const round_1_output: Round1Info = round_1_info_response.data[0]; // Convert the Number[] into bytes/Uint8Array const round_1_target_instances: Array = @@ -87,17 +87,10 @@ export async function VerifyAutoSubmitProof() { target_instances: [task.instances], }; - const finalBatchResponse = await QueryFinalBatchProof({ - task_id: task._id["$oid"], - chain_id: Web3ChainConfig.chainId, - }); - - // Handle missing final batch proofs accordingly - // Assume final batch proof exists - const finalBatchProof = finalBatchResponse.data[0]; - // Use the Batch Verifier contract address to verify the proof - const contractAddress = finalBatchProof.verifier_contracts.batch_verifier; + const contractAddress = task.task_verification_data.verifier_contracts.find( + (x) => x.chain_id === Web3ChainConfig.chainId + )?.batch_verifier!; await withDelphinusWalletConnector( async (connector) => { diff --git a/examples/src/verify/verifyProof.ts b/examples/src/verify/verifyProof.ts index e718fd7a..f258ae8b 100644 --- a/examples/src/verify/verifyProof.ts +++ b/examples/src/verify/verifyProof.ts @@ -14,7 +14,7 @@ import { GetBaseProvider, } from "web3subscriber/src/provider"; import { ServiceHelperConfig, Web3ChainConfig } from "../config"; -import { QueryTasks } from "../queries/task"; +import { queryTasks } from "../queries/task"; const provider: DelphinusBaseProvider = GetBaseProvider( Web3ChainConfig.providerUrl // web3 provider URL for the verifier chain @@ -32,7 +32,7 @@ export async function VerifyProof() { // Fetch a task from the playground service which contains the proof information // See the example to build query function to fetch task details - const response = await QueryTasks(queryParams); + const response = await queryTasks(queryParams); // Handle missing tasks accordingly // Assume task exists @@ -41,7 +41,7 @@ export async function VerifyProof() { const verifierContractAddress = task.task_verification_data.verifier_contracts.find( (x) => x.chain_id === Web3ChainConfig.chainId - ); + )?.aggregator_verifier; if (!verifierContractAddress) { console.log( @@ -55,7 +55,7 @@ export async function VerifyProof() { async (connector) => { let contract = await ZkWasmUtil.composeVerifyContract( connector, - task.task_verification_data.verifier_contracts[0].aggregator_verifier + verifierContractAddress ); // If the proof has no shadow instances, use the batch instances to try and verify instead. diff --git a/src/helper/task.ts b/src/helper/task.ts index dbda64ec..b52e190f 100644 --- a/src/helper/task.ts +++ b/src/helper/task.ts @@ -24,12 +24,12 @@ import { User, Subscription, PaginatedQuery, - Round1BatchProofQuery, - Round2BatchProofQuery, - Round2BatchProof, - Round1BatchProof, - FinalBatchProofQuery, - FinalBatchProof, + AutoSubmitProofQuery, + Round1InfoQuery, + Round1Info, + Round2Info, + Round2InfoQuery, + AutoSubmitProof, ConciseTask, NodeStatistics, NodeStatisticsQueryParams, @@ -285,9 +285,9 @@ export class ZkWasmServiceHelper { return tasks; } - async queryRound1BatchProofs( - query: PaginatedQuery - ): Promise> { + async queryAutoSubmitProofs( + query: PaginatedQuery + ): Promise> { let proofData = await this.endpoint.invokeRequest( "GET", TaskEndpoint.ROUND_1_BATCH, @@ -299,9 +299,9 @@ export class ZkWasmServiceHelper { return proofData; } - async queryRound2BatchProofs( - query: PaginatedQuery - ): Promise> { + async queryRound1Info( + query: PaginatedQuery + ): Promise> { let proofData = await this.endpoint.invokeRequest( "GET", TaskEndpoint.ROUND_2_BATCH, @@ -313,9 +313,9 @@ export class ZkWasmServiceHelper { return proofData; } - async queryFinalBatchProofs( - query: PaginatedQuery - ): Promise> { + async queryRound2Info( + query: PaginatedQuery + ): Promise> { let proofData = await this.endpoint.invokeRequest( "GET", TaskEndpoint.FINAL_BATCH, diff --git a/src/index.ts b/src/index.ts index fc51d735..8d68963a 100644 --- a/src/index.ts +++ b/src/index.ts @@ -38,19 +38,19 @@ import { WithoutInitialContext, WithoutInputContextType, WithoutResetContext, - Round1BatchProof, - Round2BatchProof, - FinalBatchProof, - Round1BatchProofStatus, - Round2BatchProofStatus, - Round1BatchProofQuery, - Round2BatchProofQuery, - FinalBatchProofQuery, + AutoSubmitProofStatus, + Round1Status, + Round2Status, + AutoSubmitProof, + Round1Info, + Round2Info, + AutoSubmitProofQuery, + Round1InfoQuery, + Round2InfoQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, - FinalProofStatus, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, @@ -70,9 +70,9 @@ export { ERC20Lib, InputContextType, AutoSubmitStatus, - Round1BatchProofStatus, - Round2BatchProofStatus, - FinalProofStatus, + AutoSubmitProofStatus, + Round1Status, + Round2Status, ProofSubmitMode, ProvePaymentSrc, }; @@ -116,12 +116,12 @@ export type { WithoutInitialContext, WithoutInputContextType, WithoutResetContext, - Round1BatchProof, - Round2BatchProof, - FinalBatchProof, - Round1BatchProofQuery, - Round2BatchProofQuery, - FinalBatchProofQuery, + AutoSubmitProof, + Round1Info, + Round2Info, + AutoSubmitProofQuery, + Round1InfoQuery, + Round2InfoQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, diff --git a/src/interface/interface.ts b/src/interface/interface.ts index 97cab012..a5aba16a 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -50,7 +50,7 @@ export interface Task { input_context: Uint8Array; input_context_type?: InputContextType; // The type of context for the task output_context: Uint8Array; // The context output from the task which should go to the image - _id: any; + _id: ObjectId; submit_time: string; process_started?: string; process_finished?: string; @@ -64,6 +64,10 @@ export interface Task { auto_submit_status?: AutoSubmitStatus; } +export type ObjectId = { + $oid: string; +}; + export interface ConciseTask { _id: any; user_address: string; @@ -88,7 +92,7 @@ export interface BatchProofData { final_proof_batch_ids?: AutoSubmitBatchMetadata[]; } -export interface Round1BatchProof { +export interface AutoSubmitProof { _id?: any; // The task id of the original aggregate proof task task_id: string; @@ -103,21 +107,21 @@ export interface Round1BatchProof { internal_message?: string; static_files_verification_data: StaticFileVerificationData; auto_submit_network_chain_id: number; - status: Round1BatchProofStatus; + status: AutoSubmitProofStatus; } export interface StaticFileVerificationData { static_file_checksum: Uint8Array; } -export enum Round1BatchProofStatus { +export enum AutoSubmitProofStatus { Pending = "Pending", Batched = "Batched", Failed = "Failed", } -// Round2BatchProof is the task for the second round of aggregation -export interface Round2BatchProof { +// Round1Info contains input to Round2 and output of Round1 +export interface Round1Info { _id?: any; // _ids of round 1 batch proofs which will be/are aggregated in this round 2 batch proof round_1_ids: string[]; @@ -141,16 +145,16 @@ export interface Round2BatchProof { auto_submit_network_chain_id: number; verifier_contracts: VerifierContracts; static_files_verification_data: StaticFileVerificationData; - status: Round2BatchProofStatus; + status: Round1Status; } -export enum Round2BatchProofStatus { +export enum Round1Status { Pending = "Pending", Batched = "Batched", Failed = "Failed", } -export interface FinalBatchProof { +export interface Round2Info { _id?: any; // _ids of round 2 id which is aggregated in this final batch proof round_2_ids: string[]; @@ -170,37 +174,37 @@ export interface FinalBatchProof { auto_submit_network_chain_id: number; verifier_contracts: VerifierContracts; registered_tx_hash: string | null; - status: FinalProofStatus; + status: Round2Status; } -export enum FinalProofStatus { +export enum Round2Status { ProofNotRegistered = "ProofNotRegistered", ProofRegistered = "ProofRegistered", } export type PaginatedQuery = T & PaginationQuery; -export interface Round1BatchProofQuery { +export interface AutoSubmitProofQuery { id?: string; task_id?: string; - status?: Round1BatchProofStatus; + status?: AutoSubmitProofStatus; circuit_size?: number; chain_id?: number; } -export interface Round2BatchProofQuery { +export interface Round1InfoQuery { id?: string; task_id?: string; - status?: Round2BatchProofStatus; + status?: Round1Status; circuit_size?: number; chain_id?: number; } -export interface FinalBatchProofQuery { +export interface Round2InfoQuery { id?: string; round_2_id?: string; task_id?: string; - status?: FinalProofStatus; + status?: Round2Status; chain_id?: number; } From 8873e35cc5bc9c5b49112ab3df0b87d6c6b7e1b0 Mon Sep 17 00:00:00 2001 From: Oscar Downing Date: Wed, 17 Jul 2024 11:07:22 +0530 Subject: [PATCH 32/36] ZKWAS-301 & ZKWAS-304: Update inteface for node list improvements (#84) --- dist/cjs/interface/interface.d.ts | 8 ++++++-- dist/mjs/interface/interface.d.ts | 8 ++++++-- src/interface/interface.ts | 9 +++++++-- 3 files changed, 19 insertions(+), 6 deletions(-) diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index 944979cd..22a4a1b0 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -4,6 +4,10 @@ export interface Statistics { totalTasks: number; totalDeployed: number; } +export interface TimingStatistics { + latest_time_taken_secs: number; + latest_timestamp: string; +} export interface NodeStatistics { address: string; statistics: { @@ -12,8 +16,8 @@ export interface NodeStatistics { total_tasks: number; timed_out_count: number; last_timed_out: string; - last_successful_proof_task_time: string; - last_successful_proof_processing_time: number; + setup_timing_stats?: TimingStatistics; + proof_timing_stats?: TimingStatistics; }; } export interface NodeStatisticsQueryParams { diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index 944979cd..22a4a1b0 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -4,6 +4,10 @@ export interface Statistics { totalTasks: number; totalDeployed: number; } +export interface TimingStatistics { + latest_time_taken_secs: number; + latest_timestamp: string; +} export interface NodeStatistics { address: string; statistics: { @@ -12,8 +16,8 @@ export interface NodeStatistics { total_tasks: number; timed_out_count: number; last_timed_out: string; - last_successful_proof_task_time: string; - last_successful_proof_processing_time: number; + setup_timing_stats?: TimingStatistics; + proof_timing_stats?: TimingStatistics; }; } export interface NodeStatisticsQueryParams { diff --git a/src/interface/interface.ts b/src/interface/interface.ts index a5aba16a..dff29201 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -5,6 +5,11 @@ export interface Statistics { totalDeployed: number; } +export interface TimingStatistics { + latest_time_taken_secs: number; + latest_timestamp: string; +} + export interface NodeStatistics { address: string; statistics: { @@ -13,8 +18,8 @@ export interface NodeStatistics { total_tasks: number; timed_out_count: number; last_timed_out: string; - last_successful_proof_task_time: string; - last_successful_proof_processing_time: number; + setup_timing_stats?: TimingStatistics; + proof_timing_stats?: TimingStatistics; }; } From 78e35d85b4f3607cd2e762336d0547533fdf8065 Mon Sep 17 00:00:00 2001 From: Oscar Downing Date: Wed, 17 Jul 2024 11:10:53 +0530 Subject: [PATCH 33/36] Revert "ZKWAS-301 & ZKWAS-304: Update inteface for node list improvements (#84)" (#85) This reverts commit 8873e35cc5bc9c5b49112ab3df0b87d6c6b7e1b0. --- dist/cjs/interface/interface.d.ts | 8 ++------ dist/mjs/interface/interface.d.ts | 8 ++------ src/interface/interface.ts | 9 ++------- 3 files changed, 6 insertions(+), 19 deletions(-) diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index 22a4a1b0..944979cd 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -4,10 +4,6 @@ export interface Statistics { totalTasks: number; totalDeployed: number; } -export interface TimingStatistics { - latest_time_taken_secs: number; - latest_timestamp: string; -} export interface NodeStatistics { address: string; statistics: { @@ -16,8 +12,8 @@ export interface NodeStatistics { total_tasks: number; timed_out_count: number; last_timed_out: string; - setup_timing_stats?: TimingStatistics; - proof_timing_stats?: TimingStatistics; + last_successful_proof_task_time: string; + last_successful_proof_processing_time: number; }; } export interface NodeStatisticsQueryParams { diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index 22a4a1b0..944979cd 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -4,10 +4,6 @@ export interface Statistics { totalTasks: number; totalDeployed: number; } -export interface TimingStatistics { - latest_time_taken_secs: number; - latest_timestamp: string; -} export interface NodeStatistics { address: string; statistics: { @@ -16,8 +12,8 @@ export interface NodeStatistics { total_tasks: number; timed_out_count: number; last_timed_out: string; - setup_timing_stats?: TimingStatistics; - proof_timing_stats?: TimingStatistics; + last_successful_proof_task_time: string; + last_successful_proof_processing_time: number; }; } export interface NodeStatisticsQueryParams { diff --git a/src/interface/interface.ts b/src/interface/interface.ts index dff29201..a5aba16a 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -5,11 +5,6 @@ export interface Statistics { totalDeployed: number; } -export interface TimingStatistics { - latest_time_taken_secs: number; - latest_timestamp: string; -} - export interface NodeStatistics { address: string; statistics: { @@ -18,8 +13,8 @@ export interface NodeStatistics { total_tasks: number; timed_out_count: number; last_timed_out: string; - setup_timing_stats?: TimingStatistics; - proof_timing_stats?: TimingStatistics; + last_successful_proof_task_time: string; + last_successful_proof_processing_time: number; }; } From a8eec55ad57914d848309210a301dd7725c4f6b1 Mon Sep 17 00:00:00 2001 From: yymone Date: Wed, 31 Jul 2024 10:14:45 +1000 Subject: [PATCH 34/36] Feature/july refine (#89) * ZKWAS-301 & ZKWAS-304: Update inteface for node list improvements (#86) * ZKWAS-318: added endpoint for setting rest server maintenance mode (#88) --------- Co-authored-by: Oscar Downing --- dist/cjs/helper/task.d.ts | 4 +++- dist/cjs/helper/task.js | 10 ++++++++++ dist/cjs/helper/util.d.ts | 3 ++- dist/cjs/helper/util.js | 8 ++++++++ dist/cjs/index.d.ts | 6 +++--- dist/cjs/index.js | 4 +++- dist/cjs/interface/interface.d.ts | 22 ++++++++++++++++++++-- dist/cjs/interface/interface.js | 12 +++++++++++- dist/mjs/helper/task.d.ts | 4 +++- dist/mjs/helper/task.js | 8 ++++++++ dist/mjs/helper/util.d.ts | 3 ++- dist/mjs/helper/util.js | 8 ++++++++ dist/mjs/index.d.ts | 6 +++--- dist/mjs/index.js | 4 ++-- dist/mjs/interface/interface.d.ts | 22 ++++++++++++++++++++-- dist/mjs/interface/interface.js | 10 ++++++++++ src/helper/task.ts | 15 +++++++++++++++ src/helper/util.ts | 10 ++++++++++ src/index.ts | 6 ++++++ src/interface/interface.ts | 26 ++++++++++++++++++++++++-- 20 files changed, 171 insertions(+), 20 deletions(-) diff --git a/dist/cjs/helper/task.d.ts b/dist/cjs/helper/task.d.ts index d10fce04..4120c333 100644 --- a/dist/cjs/helper/task.d.ts +++ b/dist/cjs/helper/task.d.ts @@ -1,4 +1,4 @@ -import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, AutoSubmitProofQuery, Round1InfoQuery, Round1Info, Round2Info, Round2InfoQuery, AutoSubmitProof, ConciseTask, NodeStatistics, NodeStatisticsQueryParams } from "../interface/interface.js"; +import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, AutoSubmitProofQuery, Round1InfoQuery, Round1Info, Round2Info, Round2InfoQuery, AutoSubmitProof, ConciseTask, NodeStatistics, NodeStatisticsQueryParams, SetMaintenanceModeParams } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; export declare class ZkWasmServiceHelper { endpoint: ZkWasmServiceEndpoint; @@ -25,6 +25,7 @@ export declare class ZkWasmServiceHelper { addDeployTask(task: WithSignature): Promise; addResetTask(task: WithSignature): Promise; modifyImage(data: WithSignature): Promise; + setMaintenanceMode(req: WithSignature): Promise; sendRequestWithSignature(method: "GET" | "POST", path: TaskEndpoint, task: WithSignature, isFormData?: boolean): Promise; createHeaders(task: WithSignature): Record; omitSignature(task: WithSignature): OmitSignature; @@ -37,6 +38,7 @@ export declare enum TaskEndpoint { RESET = "/reset", MODIFY = "/modify", PAY = "/pay", + SET_MAINTENANCE_MODE = "/admin/set_maintenance_mode", SUBSCRIBE = "/subscribe", LOGS = "/logs", ROUND_1_BATCH = "/round1_batch_proofs", diff --git a/dist/cjs/helper/task.js b/dist/cjs/helper/task.js index 5a4787a9..fffc82f6 100644 --- a/dist/cjs/helper/task.js +++ b/dist/cjs/helper/task.js @@ -325,6 +325,15 @@ class ZkWasmServiceHelper { return response; }); } + setMaintenanceMode(req) { + return __awaiter(this, void 0, void 0, function* () { + let response = yield this.sendRequestWithSignature("POST", TaskEndpoint.SET_MAINTENANCE_MODE, req, true); + if (this.endpoint.enable_logs) { + console.log("setMaintenanceMode response:", response.toString()); + } + return response; + }); + } sendRequestWithSignature(method, path, task, isFormData = false) { return __awaiter(this, void 0, void 0, function* () { // TODO: create return types for tasks using this method @@ -376,6 +385,7 @@ var TaskEndpoint; TaskEndpoint["RESET"] = "/reset"; TaskEndpoint["MODIFY"] = "/modify"; TaskEndpoint["PAY"] = "/pay"; + TaskEndpoint["SET_MAINTENANCE_MODE"] = "/admin/set_maintenance_mode"; TaskEndpoint["SUBSCRIBE"] = "/subscribe"; TaskEndpoint["LOGS"] = "/logs"; TaskEndpoint["ROUND_1_BATCH"] = "/round1_batch_proofs"; diff --git a/dist/cjs/helper/util.d.ts b/dist/cjs/helper/util.d.ts index 86ffb70f..19ce633a 100644 --- a/dist/cjs/helper/util.d.ts +++ b/dist/cjs/helper/util.d.ts @@ -1,6 +1,6 @@ /// import BN from "bn.js"; -import { AddImageParams, ProvingParams, DeployParams, ResetImageParams, ModifyImageParams, VerifyProofParams, LogQuery, ContextHexString, VerifyBatchProofParams } from "../interface/interface.js"; +import { AddImageParams, ProvingParams, DeployParams, ResetImageParams, ModifyImageParams, VerifyProofParams, SetMaintenanceModeParams, LogQuery, ContextHexString, VerifyBatchProofParams } from "../interface/interface.js"; import { Contract, Signer } from "ethers"; import { DelphinusWalletConnector, DelphinusBrowserConnector } from "web3subscriber/src/provider.js"; export declare class ZkWasmUtil { @@ -78,6 +78,7 @@ export declare class ZkWasmUtil { static convertAmount(balance: Uint8Array): string; static createLogsMesssage(params: LogQuery): string; static createAddImageSignMessage(params: AddImageParams): string; + static createSetMaintenanceModeSignMessage(params: SetMaintenanceModeParams): string; static createProvingSignMessage(params: ProvingParams): string; static createDeploySignMessage(params: DeployParams): string; static createResetImageMessage(params: ResetImageParams): string; diff --git a/dist/cjs/helper/util.js b/dist/cjs/helper/util.js index 23a6635a..05b20571 100644 --- a/dist/cjs/helper/util.js +++ b/dist/cjs/helper/util.js @@ -160,6 +160,14 @@ class ZkWasmUtil { } return message; } + static createSetMaintenanceModeSignMessage(params) { + let message = ""; + message += params.mode; + message += params.nonce; + message += params.request_type; + message += params.user_address; + return message; + } static createProvingSignMessage(params) { // No need to sign the file itself, just the md5 let message = ""; diff --git a/dist/cjs/index.d.ts b/dist/cjs/index.d.ts index d8b90130..72be6a7a 100644 --- a/dist/cjs/index.d.ts +++ b/dist/cjs/index.d.ts @@ -1,7 +1,7 @@ -import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams } from "./interface/interface.js"; +import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams, MaintenanceModeType, SetMaintenanceModeParams, AdminRequestType } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; import { ERC20Lib } from "./abi/ERC20.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, AutoSubmitProofStatus, Round1Status, Round2Status, ProofSubmitMode, ProvePaymentSrc, }; -export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, AutoSubmitProofStatus, Round1Status, Round2Status, ProofSubmitMode, ProvePaymentSrc, MaintenanceModeType, AdminRequestType, }; +export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, SetMaintenanceModeParams, }; diff --git a/dist/cjs/index.js b/dist/cjs/index.js index 7205f5e9..bcc0d5d6 100644 --- a/dist/cjs/index.js +++ b/dist/cjs/index.js @@ -1,6 +1,6 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.ProvePaymentSrc = exports.ProofSubmitMode = exports.Round2Status = exports.Round1Status = exports.AutoSubmitProofStatus = exports.AutoSubmitStatus = exports.InputContextType = exports.ERC20Lib = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; +exports.AdminRequestType = exports.MaintenanceModeType = exports.ProvePaymentSrc = exports.ProofSubmitMode = exports.Round2Status = exports.Round1Status = exports.AutoSubmitProofStatus = exports.AutoSubmitStatus = exports.InputContextType = exports.ERC20Lib = exports.ZkWasmUtil = exports.ZkWasmServiceHelper = exports.ZkWasmServiceEndpoint = void 0; const interface_js_1 = require("./interface/interface.js"); Object.defineProperty(exports, "InputContextType", { enumerable: true, get: function () { return interface_js_1.InputContextType; } }); Object.defineProperty(exports, "AutoSubmitProofStatus", { enumerable: true, get: function () { return interface_js_1.AutoSubmitProofStatus; } }); @@ -9,6 +9,8 @@ Object.defineProperty(exports, "Round2Status", { enumerable: true, get: function Object.defineProperty(exports, "AutoSubmitStatus", { enumerable: true, get: function () { return interface_js_1.AutoSubmitStatus; } }); Object.defineProperty(exports, "ProofSubmitMode", { enumerable: true, get: function () { return interface_js_1.ProofSubmitMode; } }); Object.defineProperty(exports, "ProvePaymentSrc", { enumerable: true, get: function () { return interface_js_1.ProvePaymentSrc; } }); +Object.defineProperty(exports, "MaintenanceModeType", { enumerable: true, get: function () { return interface_js_1.MaintenanceModeType; } }); +Object.defineProperty(exports, "AdminRequestType", { enumerable: true, get: function () { return interface_js_1.AdminRequestType; } }); const util_js_1 = require("./helper/util.js"); Object.defineProperty(exports, "ZkWasmUtil", { enumerable: true, get: function () { return util_js_1.ZkWasmUtil; } }); const endpoint_js_1 = require("./helper/endpoint.js"); diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index 944979cd..19e46d81 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -4,6 +4,10 @@ export interface Statistics { totalTasks: number; totalDeployed: number; } +export interface TimingStatistics { + latest_time_taken_secs: number; + latest_timestamp: string; +} export interface NodeStatistics { address: string; statistics: { @@ -12,8 +16,8 @@ export interface NodeStatistics { total_tasks: number; timed_out_count: number; last_timed_out: string; - last_successful_proof_task_time: string; - last_successful_proof_processing_time: number; + setup_timing_stats?: TimingStatistics; + proof_timing_stats?: TimingStatistics; }; } export interface NodeStatisticsQueryParams { @@ -463,3 +467,17 @@ export interface TransactionInfo { user_address: string; receiver_address: string; } +export declare enum MaintenanceModeType { + Disabled = "Disabled", + Enabled = "Enabled" +} +export declare enum AdminRequestType { + Default = "Default", + MaintenanceMode = "MaintenanceMode" +} +export interface SetMaintenanceModeParams { + mode: MaintenanceModeType; + nonce: number; + request_type: AdminRequestType; + user_address: string; +} diff --git a/dist/cjs/interface/interface.js b/dist/cjs/interface/interface.js index 99848958..f97a0a08 100644 --- a/dist/cjs/interface/interface.js +++ b/dist/cjs/interface/interface.js @@ -1,6 +1,6 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.ProofSubmitMode = exports.ProvePaymentSrc = exports.AutoSubmitStatus = exports.Round2Status = exports.Round1Status = exports.AutoSubmitProofStatus = exports.InputContextType = void 0; +exports.AdminRequestType = exports.MaintenanceModeType = exports.ProofSubmitMode = exports.ProvePaymentSrc = exports.AutoSubmitStatus = exports.Round2Status = exports.Round1Status = exports.AutoSubmitProofStatus = exports.InputContextType = void 0; var InputContextType; (function (InputContextType) { InputContextType["Custom"] = "Custom"; @@ -42,3 +42,13 @@ var ProofSubmitMode; ProofSubmitMode["Manual"] = "Manual"; ProofSubmitMode["Auto"] = "Auto"; })(ProofSubmitMode = exports.ProofSubmitMode || (exports.ProofSubmitMode = {})); +var MaintenanceModeType; +(function (MaintenanceModeType) { + MaintenanceModeType["Disabled"] = "Disabled"; + MaintenanceModeType["Enabled"] = "Enabled"; +})(MaintenanceModeType = exports.MaintenanceModeType || (exports.MaintenanceModeType = {})); +var AdminRequestType; +(function (AdminRequestType) { + AdminRequestType["Default"] = "Default"; + AdminRequestType["MaintenanceMode"] = "MaintenanceMode"; +})(AdminRequestType = exports.AdminRequestType || (exports.AdminRequestType = {})); diff --git a/dist/mjs/helper/task.d.ts b/dist/mjs/helper/task.d.ts index d10fce04..4120c333 100644 --- a/dist/mjs/helper/task.d.ts +++ b/dist/mjs/helper/task.d.ts @@ -1,4 +1,4 @@ -import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, AutoSubmitProofQuery, Round1InfoQuery, Round1Info, Round2Info, Round2InfoQuery, AutoSubmitProof, ConciseTask, NodeStatistics, NodeStatisticsQueryParams } from "../interface/interface.js"; +import { QueryParams, ProvingParams, DeployParams, Statistics, AddImageParams, WithSignature, UserQueryParams, PaymentParams, TxHistoryQueryParams, LogQuery, ResetImageParams, PaginationResult, Task, Image, TransactionInfo, AppConfig, OmitSignature, ModifyImageParams, SubscriptionRequest, ERC20DepositInfo, User, Subscription, PaginatedQuery, AutoSubmitProofQuery, Round1InfoQuery, Round1Info, Round2Info, Round2InfoQuery, AutoSubmitProof, ConciseTask, NodeStatistics, NodeStatisticsQueryParams, SetMaintenanceModeParams } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; export declare class ZkWasmServiceHelper { endpoint: ZkWasmServiceEndpoint; @@ -25,6 +25,7 @@ export declare class ZkWasmServiceHelper { addDeployTask(task: WithSignature): Promise; addResetTask(task: WithSignature): Promise; modifyImage(data: WithSignature): Promise; + setMaintenanceMode(req: WithSignature): Promise; sendRequestWithSignature(method: "GET" | "POST", path: TaskEndpoint, task: WithSignature, isFormData?: boolean): Promise; createHeaders(task: WithSignature): Record; omitSignature(task: WithSignature): OmitSignature; @@ -37,6 +38,7 @@ export declare enum TaskEndpoint { RESET = "/reset", MODIFY = "/modify", PAY = "/pay", + SET_MAINTENANCE_MODE = "/admin/set_maintenance_mode", SUBSCRIBE = "/subscribe", LOGS = "/logs", ROUND_1_BATCH = "/round1_batch_proofs", diff --git a/dist/mjs/helper/task.js b/dist/mjs/helper/task.js index c7cc6f40..154f2a8e 100644 --- a/dist/mjs/helper/task.js +++ b/dist/mjs/helper/task.js @@ -256,6 +256,13 @@ export class ZkWasmServiceHelper { } return response; } + async setMaintenanceMode(req) { + let response = await this.sendRequestWithSignature("POST", TaskEndpoint.SET_MAINTENANCE_MODE, req, true); + if (this.endpoint.enable_logs) { + console.log("setMaintenanceMode response:", response.toString()); + } + return response; + } async sendRequestWithSignature(method, path, task, isFormData = false) { // TODO: create return types for tasks using this method let headers = this.createHeaders(task); @@ -304,6 +311,7 @@ export var TaskEndpoint; TaskEndpoint["RESET"] = "/reset"; TaskEndpoint["MODIFY"] = "/modify"; TaskEndpoint["PAY"] = "/pay"; + TaskEndpoint["SET_MAINTENANCE_MODE"] = "/admin/set_maintenance_mode"; TaskEndpoint["SUBSCRIBE"] = "/subscribe"; TaskEndpoint["LOGS"] = "/logs"; TaskEndpoint["ROUND_1_BATCH"] = "/round1_batch_proofs"; diff --git a/dist/mjs/helper/util.d.ts b/dist/mjs/helper/util.d.ts index 86ffb70f..19ce633a 100644 --- a/dist/mjs/helper/util.d.ts +++ b/dist/mjs/helper/util.d.ts @@ -1,6 +1,6 @@ /// import BN from "bn.js"; -import { AddImageParams, ProvingParams, DeployParams, ResetImageParams, ModifyImageParams, VerifyProofParams, LogQuery, ContextHexString, VerifyBatchProofParams } from "../interface/interface.js"; +import { AddImageParams, ProvingParams, DeployParams, ResetImageParams, ModifyImageParams, VerifyProofParams, SetMaintenanceModeParams, LogQuery, ContextHexString, VerifyBatchProofParams } from "../interface/interface.js"; import { Contract, Signer } from "ethers"; import { DelphinusWalletConnector, DelphinusBrowserConnector } from "web3subscriber/src/provider.js"; export declare class ZkWasmUtil { @@ -78,6 +78,7 @@ export declare class ZkWasmUtil { static convertAmount(balance: Uint8Array): string; static createLogsMesssage(params: LogQuery): string; static createAddImageSignMessage(params: AddImageParams): string; + static createSetMaintenanceModeSignMessage(params: SetMaintenanceModeParams): string; static createProvingSignMessage(params: ProvingParams): string; static createDeploySignMessage(params: DeployParams): string; static createResetImageMessage(params: ResetImageParams): string; diff --git a/dist/mjs/helper/util.js b/dist/mjs/helper/util.js index 8af23ff5..e20fba89 100644 --- a/dist/mjs/helper/util.js +++ b/dist/mjs/helper/util.js @@ -243,6 +243,14 @@ export class ZkWasmUtil { } return message; } + static createSetMaintenanceModeSignMessage(params) { + let message = ""; + message += params.mode; + message += params.nonce; + message += params.request_type; + message += params.user_address; + return message; + } static createProvingSignMessage(params) { // No need to sign the file itself, just the md5 let message = ""; diff --git a/dist/mjs/index.d.ts b/dist/mjs/index.d.ts index d8b90130..72be6a7a 100644 --- a/dist/mjs/index.d.ts +++ b/dist/mjs/index.d.ts @@ -1,7 +1,7 @@ -import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams } from "./interface/interface.js"; +import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams, MaintenanceModeType, SetMaintenanceModeParams, AdminRequestType } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; import { ERC20Lib } from "./abi/ERC20.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, AutoSubmitProofStatus, Round1Status, Round2Status, ProofSubmitMode, ProvePaymentSrc, }; -export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, AutoSubmitProofStatus, Round1Status, Round2Status, ProofSubmitMode, ProvePaymentSrc, MaintenanceModeType, AdminRequestType, }; +export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, SetMaintenanceModeParams, }; diff --git a/dist/mjs/index.js b/dist/mjs/index.js index dd7ba510..159dcf4e 100644 --- a/dist/mjs/index.js +++ b/dist/mjs/index.js @@ -1,6 +1,6 @@ -import { InputContextType, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitStatus, ProofSubmitMode, ProvePaymentSrc, } from "./interface/interface.js"; +import { InputContextType, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitStatus, ProofSubmitMode, ProvePaymentSrc, MaintenanceModeType, AdminRequestType, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; import { ERC20Lib } from "./abi/ERC20.js"; -export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, AutoSubmitProofStatus, Round1Status, Round2Status, ProofSubmitMode, ProvePaymentSrc, }; +export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, AutoSubmitProofStatus, Round1Status, Round2Status, ProofSubmitMode, ProvePaymentSrc, MaintenanceModeType, AdminRequestType, }; diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index 944979cd..19e46d81 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -4,6 +4,10 @@ export interface Statistics { totalTasks: number; totalDeployed: number; } +export interface TimingStatistics { + latest_time_taken_secs: number; + latest_timestamp: string; +} export interface NodeStatistics { address: string; statistics: { @@ -12,8 +16,8 @@ export interface NodeStatistics { total_tasks: number; timed_out_count: number; last_timed_out: string; - last_successful_proof_task_time: string; - last_successful_proof_processing_time: number; + setup_timing_stats?: TimingStatistics; + proof_timing_stats?: TimingStatistics; }; } export interface NodeStatisticsQueryParams { @@ -463,3 +467,17 @@ export interface TransactionInfo { user_address: string; receiver_address: string; } +export declare enum MaintenanceModeType { + Disabled = "Disabled", + Enabled = "Enabled" +} +export declare enum AdminRequestType { + Default = "Default", + MaintenanceMode = "MaintenanceMode" +} +export interface SetMaintenanceModeParams { + mode: MaintenanceModeType; + nonce: number; + request_type: AdminRequestType; + user_address: string; +} diff --git a/dist/mjs/interface/interface.js b/dist/mjs/interface/interface.js index 7344a7ff..3dc08efe 100644 --- a/dist/mjs/interface/interface.js +++ b/dist/mjs/interface/interface.js @@ -39,3 +39,13 @@ export var ProofSubmitMode; ProofSubmitMode["Manual"] = "Manual"; ProofSubmitMode["Auto"] = "Auto"; })(ProofSubmitMode || (ProofSubmitMode = {})); +export var MaintenanceModeType; +(function (MaintenanceModeType) { + MaintenanceModeType["Disabled"] = "Disabled"; + MaintenanceModeType["Enabled"] = "Enabled"; +})(MaintenanceModeType || (MaintenanceModeType = {})); +export var AdminRequestType; +(function (AdminRequestType) { + AdminRequestType["Default"] = "Default"; + AdminRequestType["MaintenanceMode"] = "MaintenanceMode"; +})(AdminRequestType || (AdminRequestType = {})); diff --git a/src/helper/task.ts b/src/helper/task.ts index b52e190f..8ad40d99 100644 --- a/src/helper/task.ts +++ b/src/helper/task.ts @@ -33,6 +33,7 @@ import { ConciseTask, NodeStatistics, NodeStatisticsQueryParams, + SetMaintenanceModeParams, } from "../interface/interface.js"; import { ZkWasmServiceEndpoint } from "./endpoint.js"; import { ethers } from "ethers"; @@ -429,6 +430,19 @@ export class ZkWasmServiceHelper { return response; } + async setMaintenanceMode(req: WithSignature) { + let response = await this.sendRequestWithSignature( + "POST", + TaskEndpoint.SET_MAINTENANCE_MODE, + req, + true, + ); + if (this.endpoint.enable_logs) { + console.log("setMaintenanceMode response:", response.toString()); + } + return response; + } + async sendRequestWithSignature( method: "GET" | "POST", path: TaskEndpoint, @@ -491,6 +505,7 @@ export enum TaskEndpoint { RESET = "/reset", MODIFY = "/modify", PAY = "/pay", + SET_MAINTENANCE_MODE = "/admin/set_maintenance_mode", SUBSCRIBE = "/subscribe", LOGS = "/logs", ROUND_1_BATCH = "/round1_batch_proofs", diff --git a/src/helper/util.ts b/src/helper/util.ts index 2ddcab04..48875d01 100644 --- a/src/helper/util.ts +++ b/src/helper/util.ts @@ -7,6 +7,7 @@ import { ResetImageParams, ModifyImageParams, VerifyProofParams, + SetMaintenanceModeParams, LogQuery, ContextHexString, InputContextType, @@ -278,6 +279,15 @@ export class ZkWasmUtil { return message; } + static createSetMaintenanceModeSignMessage(params: SetMaintenanceModeParams): string { + let message = ""; + message += params.mode; + message += params.nonce; + message += params.request_type; + message += params.user_address; + return message; + } + static createProvingSignMessage(params: ProvingParams): string { // No need to sign the file itself, just the md5 let message = ""; diff --git a/src/index.ts b/src/index.ts index 8d68963a..6dab34e3 100644 --- a/src/index.ts +++ b/src/index.ts @@ -56,6 +56,9 @@ import { ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams, + MaintenanceModeType, + SetMaintenanceModeParams, + AdminRequestType, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; @@ -75,6 +78,8 @@ export { Round2Status, ProofSubmitMode, ProvePaymentSrc, + MaintenanceModeType, + AdminRequestType, }; export type { @@ -128,4 +133,5 @@ export type { AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, + SetMaintenanceModeParams, }; diff --git a/src/interface/interface.ts b/src/interface/interface.ts index a5aba16a..79d59e1e 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -5,6 +5,11 @@ export interface Statistics { totalDeployed: number; } +export interface TimingStatistics { + latest_time_taken_secs: number; + latest_timestamp: string; +} + export interface NodeStatistics { address: string; statistics: { @@ -13,8 +18,8 @@ export interface NodeStatistics { total_tasks: number; timed_out_count: number; last_timed_out: string; - last_successful_proof_task_time: string; - last_successful_proof_processing_time: number; + setup_timing_stats?: TimingStatistics; + proof_timing_stats?: TimingStatistics; }; } @@ -563,3 +568,20 @@ export interface TransactionInfo { user_address: string; receiver_address: string; } + +export enum MaintenanceModeType { + Disabled = "Disabled", + Enabled = "Enabled", +} + +export enum AdminRequestType { + Default = "Default", + MaintenanceMode = "MaintenanceMode", +} + +export interface SetMaintenanceModeParams { + mode: MaintenanceModeType, + nonce : number, + request_type: AdminRequestType, + user_address: string, +} From 5a97270202e3d3937c985ed072d3464a1af94f3b Mon Sep 17 00:00:00 2001 From: Richard Hao Date: Fri, 30 Aug 2024 09:22:29 +0800 Subject: [PATCH 35/36] feature/August (#95) * ZKWAS-327: Node version information (#90) * version for nodes * optional field * server version info * rename * paginated node stats (#92) * guest static in task type (#94) * update package (#96) --- dist/cjs/helper/task.d.ts | 2 +- dist/cjs/index.d.ts | 4 ++-- dist/cjs/interface/interface.d.ts | 9 +++++++++ dist/mjs/helper/task.d.ts | 2 +- dist/mjs/index.d.ts | 4 ++-- dist/mjs/interface/interface.d.ts | 9 +++++++++ examples/package-lock.json | 4 ++-- examples/package.json | 2 +- examples/src/tasks/submitProofTask.ts | 3 ++- src/helper/task.ts | 17 +++++++++-------- src/index.ts | 2 ++ src/interface/interface.ts | 18 ++++++++++++++---- 12 files changed, 54 insertions(+), 22 deletions(-) diff --git a/dist/cjs/helper/task.d.ts b/dist/cjs/helper/task.d.ts index 4120c333..9f839f1f 100644 --- a/dist/cjs/helper/task.d.ts +++ b/dist/cjs/helper/task.d.ts @@ -11,7 +11,7 @@ export declare class ZkWasmServiceHelper { queryDepositHistory(history_query: TxHistoryQueryParams): Promise>; queryConfig(): Promise; loadStatistics(): Promise; - queryNodeStatistics(query: NodeStatisticsQueryParams): Promise; + queryNodeStatistics(query: NodeStatisticsQueryParams): Promise>; loadTasks(query: QueryParams): Promise>; loadTaskList(query: QueryParams): Promise>; queryAutoSubmitProofs(query: PaginatedQuery): Promise>; diff --git a/dist/cjs/index.d.ts b/dist/cjs/index.d.ts index 72be6a7a..9c046396 100644 --- a/dist/cjs/index.d.ts +++ b/dist/cjs/index.d.ts @@ -1,7 +1,7 @@ -import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams, MaintenanceModeType, SetMaintenanceModeParams, AdminRequestType } from "./interface/interface.js"; +import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams, MaintenanceModeType, SetMaintenanceModeParams, AdminRequestType, ServerVersionInfo } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; import { ERC20Lib } from "./abi/ERC20.js"; export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, AutoSubmitProofStatus, Round1Status, Round2Status, ProofSubmitMode, ProvePaymentSrc, MaintenanceModeType, AdminRequestType, }; -export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, SetMaintenanceModeParams, }; +export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, SetMaintenanceModeParams, ServerVersionInfo, }; diff --git a/dist/cjs/interface/interface.d.ts b/dist/cjs/interface/interface.d.ts index 19e46d81..75c486bc 100644 --- a/dist/cjs/interface/interface.d.ts +++ b/dist/cjs/interface/interface.d.ts @@ -19,6 +19,9 @@ export interface NodeStatistics { setup_timing_stats?: TimingStatistics; proof_timing_stats?: TimingStatistics; }; + version_info?: { + version: string; + }; } export interface NodeStatisticsQueryParams { address?: string; @@ -56,6 +59,7 @@ export interface Task { task_fee?: Uint8Array; status_message?: string; internal_message?: string; + guest_statics?: number; task_verification_data: TaskVerificationData; debug_logs?: string; proof_submit_mode?: ProofSubmitMode; @@ -344,6 +348,11 @@ export interface AppConfig { deployments: ContractDeployments[]; subscription_plans: SubscriptionParams[]; supported_auto_submit_network_ids: number[]; + server_version_info: ServerVersionInfo; +} +export interface ServerVersionInfo { + current_version: string; + minimum_supported_node_version: string; } export interface ContractDeployments { chain_id: number; diff --git a/dist/mjs/helper/task.d.ts b/dist/mjs/helper/task.d.ts index 4120c333..9f839f1f 100644 --- a/dist/mjs/helper/task.d.ts +++ b/dist/mjs/helper/task.d.ts @@ -11,7 +11,7 @@ export declare class ZkWasmServiceHelper { queryDepositHistory(history_query: TxHistoryQueryParams): Promise>; queryConfig(): Promise; loadStatistics(): Promise; - queryNodeStatistics(query: NodeStatisticsQueryParams): Promise; + queryNodeStatistics(query: NodeStatisticsQueryParams): Promise>; loadTasks(query: QueryParams): Promise>; loadTaskList(query: QueryParams): Promise>; queryAutoSubmitProofs(query: PaginatedQuery): Promise>; diff --git a/dist/mjs/index.d.ts b/dist/mjs/index.d.ts index 72be6a7a..9c046396 100644 --- a/dist/mjs/index.d.ts +++ b/dist/mjs/index.d.ts @@ -1,7 +1,7 @@ -import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams, MaintenanceModeType, SetMaintenanceModeParams, AdminRequestType } from "./interface/interface.js"; +import { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, WithSignature, User, UserQueryParams, PaymentParams, SubscriptionParams, Subscription, SubscriptionType, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, TaskStatus, TaskType, AppConfig, PaginationResult, ResetImageParams, LogQuery, ModifyImageParams, ChainDetails, InputContextType, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProofStatus, Round1Status, Round2Status, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, AutoSubmitStatus, VerifyBatchProofParams, AutoSubmitBatchMetadata, ProofSubmitMode, ProvePaymentSrc, NodeStatistics, NodeStatisticsQueryParams, MaintenanceModeType, SetMaintenanceModeParams, AdminRequestType, ServerVersionInfo } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; import { ZkWasmServiceEndpoint } from "./helper/endpoint.js"; import { ZkWasmServiceHelper } from "./helper/task.js"; import { ERC20Lib } from "./abi/ERC20.js"; export { ZkWasmServiceEndpoint, ZkWasmServiceHelper, ZkWasmUtil, ERC20Lib, InputContextType, AutoSubmitStatus, AutoSubmitProofStatus, Round1Status, Round2Status, ProofSubmitMode, ProvePaymentSrc, MaintenanceModeType, AdminRequestType, }; -export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, SetMaintenanceModeParams, }; +export type { Task, ConciseTask, ProvingParams, DeployParams, QueryParams, VerifyProofParams, VerifyData, StatusState, DeploymentInfo, Image, Statistics, AddImageParams, TaskStatus, TaskType, WithSignature, User, UserQueryParams, Subscription, SubscriptionType, PaymentParams, SubscriptionParams, SubscriptionRequest, TxHistoryQueryParams, TransactionInfo, ResetImageParams, AppConfig, PaginationResult, LogQuery, ModifyImageParams, ChainDetails, ContextHexString, WithCustomInputContextType, WithInitialContext, WithNonCustomInputContextType, WithResetContext, WithoutInitialContext, WithoutInputContextType, WithoutResetContext, AutoSubmitProof, Round1Info, Round2Info, AutoSubmitProofQuery, Round1InfoQuery, Round2InfoQuery, PaginatedQuery, PaginationQuery, VerifyBatchProofParams, AutoSubmitBatchMetadata, NodeStatistics, NodeStatisticsQueryParams, SetMaintenanceModeParams, ServerVersionInfo, }; diff --git a/dist/mjs/interface/interface.d.ts b/dist/mjs/interface/interface.d.ts index 19e46d81..75c486bc 100644 --- a/dist/mjs/interface/interface.d.ts +++ b/dist/mjs/interface/interface.d.ts @@ -19,6 +19,9 @@ export interface NodeStatistics { setup_timing_stats?: TimingStatistics; proof_timing_stats?: TimingStatistics; }; + version_info?: { + version: string; + }; } export interface NodeStatisticsQueryParams { address?: string; @@ -56,6 +59,7 @@ export interface Task { task_fee?: Uint8Array; status_message?: string; internal_message?: string; + guest_statics?: number; task_verification_data: TaskVerificationData; debug_logs?: string; proof_submit_mode?: ProofSubmitMode; @@ -344,6 +348,11 @@ export interface AppConfig { deployments: ContractDeployments[]; subscription_plans: SubscriptionParams[]; supported_auto_submit_network_ids: number[]; + server_version_info: ServerVersionInfo; +} +export interface ServerVersionInfo { + current_version: string; + minimum_supported_node_version: string; } export interface ContractDeployments { chain_id: number; diff --git a/examples/package-lock.json b/examples/package-lock.json index 9901a3dc..ce1ddb33 100644 --- a/examples/package-lock.json +++ b/examples/package-lock.json @@ -9,7 +9,7 @@ "version": "1.0.0", "dependencies": { "tsx": "^4.16.0", - "zkwasm-service-helper": "https://github.com/DelphinusLab/zkWasm-service-helper#zkwas-289" + "zkwasm-service-helper": "git+https://github.com/DelphinusLab/zkWasm-service-helper.git#feature/August" }, "devDependencies": { "@babel/core": "^7.23.9", @@ -9702,7 +9702,7 @@ }, "node_modules/zkwasm-service-helper": { "version": "1.0.0", - "resolved": "git+ssh://git@github.com/DelphinusLab/zkWasm-service-helper.git#6327b99f78e0d89e78f0d5b4d92feb2c72e53bb9", + "resolved": "git+ssh://git@github.com/DelphinusLab/zkWasm-service-helper.git#db4dafce2a440015d70dca5f48f3900df3c0940d", "dependencies": { "@types/bn.js": "^5.1.1", "axios": "^1.2.1", diff --git a/examples/package.json b/examples/package.json index e1eee838..a08019c6 100644 --- a/examples/package.json +++ b/examples/package.json @@ -5,7 +5,7 @@ "description": "Examples for zkwasm playground helper lib to communicate with zkwasm cloud service", "dependencies": { "tsx": "^4.16.0", - "zkwasm-service-helper": "https://github.com/DelphinusLab/zkWasm-service-helper#zkwas-289" + "zkwasm-service-helper": "git+https://github.com/DelphinusLab/zkWasm-service-helper.git#feature/August" }, "scripts": { "build": "rm -fr dist/* && npx tsc -p tsconfig.json && npx tsc -p tsconfig-cjs.json && sh ./addhybridpackage.sh" diff --git a/examples/src/tasks/submitProofTask.ts b/examples/src/tasks/submitProofTask.ts index bd87e24c..22ce5aa8 100644 --- a/examples/src/tasks/submitProofTask.ts +++ b/examples/src/tasks/submitProofTask.ts @@ -33,7 +33,8 @@ export async function AddNewProofTask() { }; // Context type for proof task. If none provided, will default to InputContextType.ImageCurrent in the server and use the image's current context - const selectedInputContextType = InputContextType.Custom; + const selectedInputContextType = + InputContextType.ImageCurrent as InputContextType; // (as InputContextType) for compiler to allow comparison below since just hardcoded here. // For Custom Context, upload a binary file first containing the context. if (selectedInputContextType === InputContextType.Custom) { diff --git a/src/helper/task.ts b/src/helper/task.ts index 8ad40d99..d53d8e9e 100644 --- a/src/helper/task.ts +++ b/src/helper/task.ts @@ -162,7 +162,7 @@ export class ZkWasmServiceHelper { async queryNodeStatistics( query: NodeStatisticsQueryParams - ): Promise { + ): Promise> { let headers = { "Content-Type": "application/json" }; let queryJson = JSON.parse(JSON.stringify(query)); @@ -175,7 +175,7 @@ export class ZkWasmServiceHelper { console.log("loading node statistics"); } - return res as NodeStatistics[]; + return res as PaginationResult; } async loadTasks(query: QueryParams): Promise> { @@ -431,12 +431,13 @@ export class ZkWasmServiceHelper { } async setMaintenanceMode(req: WithSignature) { - let response = await this.sendRequestWithSignature( - "POST", - TaskEndpoint.SET_MAINTENANCE_MODE, - req, - true, - ); + let response = + await this.sendRequestWithSignature( + "POST", + TaskEndpoint.SET_MAINTENANCE_MODE, + req, + true + ); if (this.endpoint.enable_logs) { console.log("setMaintenanceMode response:", response.toString()); } diff --git a/src/index.ts b/src/index.ts index 6dab34e3..0244fd0a 100644 --- a/src/index.ts +++ b/src/index.ts @@ -59,6 +59,7 @@ import { MaintenanceModeType, SetMaintenanceModeParams, AdminRequestType, + ServerVersionInfo, } from "./interface/interface.js"; import { ZkWasmUtil } from "./helper/util.js"; @@ -134,4 +135,5 @@ export type { NodeStatistics, NodeStatisticsQueryParams, SetMaintenanceModeParams, + ServerVersionInfo, }; diff --git a/src/interface/interface.ts b/src/interface/interface.ts index 79d59e1e..648f4e3b 100644 --- a/src/interface/interface.ts +++ b/src/interface/interface.ts @@ -21,6 +21,9 @@ export interface NodeStatistics { setup_timing_stats?: TimingStatistics; proof_timing_stats?: TimingStatistics; }; + version_info?: { + version: string; + }; } export interface NodeStatisticsQueryParams { @@ -62,6 +65,7 @@ export interface Task { task_fee?: Uint8Array; status_message?: string; internal_message?: string; + guest_statics?: number; task_verification_data: TaskVerificationData; debug_logs?: string; proof_submit_mode?: ProofSubmitMode; @@ -428,6 +432,12 @@ export interface AppConfig { deployments: ContractDeployments[]; subscription_plans: SubscriptionParams[]; supported_auto_submit_network_ids: number[]; + server_version_info: ServerVersionInfo; +} + +export interface ServerVersionInfo { + current_version: string; + minimum_supported_node_version: string; } export interface ContractDeployments { @@ -580,8 +590,8 @@ export enum AdminRequestType { } export interface SetMaintenanceModeParams { - mode: MaintenanceModeType, - nonce : number, - request_type: AdminRequestType, - user_address: string, + mode: MaintenanceModeType; + nonce: number; + request_type: AdminRequestType; + user_address: string; } From 0f82ce6614734f7bbd5d18da5db0c5cc2c64baab Mon Sep 17 00:00:00 2001 From: rhaoio Date: Fri, 30 Aug 2024 11:43:20 +1000 Subject: [PATCH 36/36] example package --- examples/package-lock.json | 4 ++-- examples/package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/package-lock.json b/examples/package-lock.json index ce1ddb33..165341aa 100644 --- a/examples/package-lock.json +++ b/examples/package-lock.json @@ -9,7 +9,7 @@ "version": "1.0.0", "dependencies": { "tsx": "^4.16.0", - "zkwasm-service-helper": "git+https://github.com/DelphinusLab/zkWasm-service-helper.git#feature/August" + "zkwasm-service-helper": "git+https://github.com/DelphinusLab/zkWasm-service-helper.git" }, "devDependencies": { "@babel/core": "^7.23.9", @@ -9702,7 +9702,7 @@ }, "node_modules/zkwasm-service-helper": { "version": "1.0.0", - "resolved": "git+ssh://git@github.com/DelphinusLab/zkWasm-service-helper.git#db4dafce2a440015d70dca5f48f3900df3c0940d", + "resolved": "git+ssh://git@github.com/DelphinusLab/zkWasm-service-helper.git#5a97270202e3d3937c985ed072d3464a1af94f3b", "dependencies": { "@types/bn.js": "^5.1.1", "axios": "^1.2.1", diff --git a/examples/package.json b/examples/package.json index a08019c6..2aef614f 100644 --- a/examples/package.json +++ b/examples/package.json @@ -5,7 +5,7 @@ "description": "Examples for zkwasm playground helper lib to communicate with zkwasm cloud service", "dependencies": { "tsx": "^4.16.0", - "zkwasm-service-helper": "git+https://github.com/DelphinusLab/zkWasm-service-helper.git#feature/August" + "zkwasm-service-helper": "git+https://github.com/DelphinusLab/zkWasm-service-helper.git" }, "scripts": { "build": "rm -fr dist/* && npx tsc -p tsconfig.json && npx tsc -p tsconfig-cjs.json && sh ./addhybridpackage.sh"