zksync-era
zksync-era copied to clipboard
feat: Add `zks_getBatchPubdata` endpoint
Description
This PR adds an endpoint to the RPC that'll let a user like Validium's DA Manager get some batch's pubdata to store in some DA Layer.
How to test
- Run the hole stack (
zk && zk clean --all && zk init
) - Run the following
curl
curl http://localhost:3050 -X POST \
-H "Content-Type: application/json" \
--data '{"method":"zks_getBatchPubdata","params":[1],"id":1,"jsonrpc":"2.0"}'
@slowli, I solved both suggestions, let me know if there's anything else to do for this PR.
Not sure whether CI failure is expected, but AFAIU it's caused by the base branch; the changes in this PR look fine.
Thanks for all the feedback! I'll double-check, make a commit if necessary, and then merge.
@ilitteri let's keep this on hold until we merge validium mode abstraction. I want us to have a round of discussion on 3rd party DA first -- maybe we'll change the design.