feat: add xProof certification skills#1
Open
jasonxkensei wants to merge 6 commits intomultiversx:masterfrom
Open
feat: add xProof certification skills#1jasonxkensei wants to merge 6 commits intomultiversx:masterfrom
jasonxkensei wants to merge 6 commits intomultiversx:masterfrom
Conversation
Off-chain certification for agent outputs via xProof API. Adds certifyFile, certifyHash, certifyBatch, verifyProof, and certifyAndSubmitProof (composite xProof + MX-8004 flow). Ref: #679
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add xProof certification skills
Summary
Adds
xproof_skills.ts-- off-chain certification for agent outputs via the xProof API, with a composite flow that chains xProof certification with MX-8004 Validation Registrysubmit_proof.Ref: multiversx/mx-openclaw-skills#1, issue #679
What it does
certifyFile(params)certifyHash(params)certifyBatch(params)verifyProof(certId)certifyAndSubmitProof(params)submit_proofin one callIntegration architecture
Auth modes
Authorization: Bearer pm_...(set viaXPROOF_API_KEYenv var)useX402: true+x402Paymentheader value.x402 payment challenge
When calling without an API key and without a valid
x402Payment, the xProof API returns HTTP 402 with a JSON body:{ "x402Version": 1, "accepts": [{ "scheme": "exact", "price": "50000", "network": "base", "payTo": "0x..." }] }The skill throws
XProofPaymentRequiredwith the full payment details. The caller is responsible for completing the x402 payment and retrying with thex402Paymentparameter (base64-encoded payment receipt).Files changed
src/skills/xproof_skills.ts-- new skill modulesrc/skills/index.ts-- barrel export updatedsrc/config.ts-- addedCONFIG.XPROOFblock (BASE_URL,API_KEY).env.example-- addedXPROOF_API_KEY,XPROOF_BASE_URLCode conventions
Logger,CONFIG, JSDoc headers, exported typesCONFIG.XPROOF(not rawprocess.env)submitProoffromvalidation_skills.tsfor the composite flowcryptoand nativefetch