self_test
Test the offline verification system by validating packaged sample receipts and bundles to confirm the verifier functions without network connectivity.
Instructions
Verify the packaged sample receipt and sample bundle to prove the verifier works offline.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- server.js:167-191 (handler)The 'self_test' tool is registered and implemented directly in the MCP server setup, invoking verifySingle and verifyBundle on pre-loaded artifacts.
server.tool( 'self_test', 'Verify the packaged sample receipt and sample bundle to prove the verifier works offline.', {}, async () => { try { const { receipt, bundle, publicKeyHex } = loadSelfTestArtifacts(); const receiptResult = verifySingle(receipt, publicKeyHex); const bundleResult = verifyBundle(bundle); return textResult({ ok: receiptResult.valid && bundleResult.valid, receipt: receiptResult, bundle: { valid: bundleResult.valid, total: bundleResult.total, passed: bundleResult.passed, failed: bundleResult.failed, }, note: 'No ScopeBlind servers were contacted.', }); } catch (error) { return textResult({ ok: false, error: error.message }); } } );