This lib is to help communicate with zkwasm service
This lib main provide a ZkWasmServiceHelper class to help user to communicate to zkwasm service backend. It mainly provide API to add tasks and get informations to zkwasm service backend.
like:
- async queryImage(md5: string);
- async loadTasks(query: QueryParams);
- async addNewWasmImage(task: WithSignature);
- async addProvingTask(task: WithSignature);
There are several examples of how to use this lib in the examples
folder.
cd examples
npm install
-
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. -
Within each script you want to run, you will also need to update values for querying and submitting tasks such as task ids.
Currently only the scripts under src/tasks
and src/verify
are runnable. The queries
are merely examples which are used in these executable scripts.
npx tsx src/tasks/addNewImage.ts