Rohan Protocol MCP

v0.8.3
io.github.rohan-protocol/mcp Checked 1 hour ago Published 7 days ago

Stateless zero-knowledge trust gateway and WebMCP shield for AI agents on Midnight.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

rohan_execute_handshake

Executes or locally previews a confidential handshake commitment on Midnight. Usage guidelines: - Use for a user-authorized settlement; set dryRun: true only when the user asks to preview, test, or inspect a commitment without on-chain settlement (default false). - Do not use for reads, history, status, or audit; use rohan_get_ledger_state, rohan_get_transaction_history, rohan_get_agent_status, or rohan_verify_commitment instead. - Keep sensitive values in confidentialPayload, actionSummary generic, and private keys out of tool arguments. Follow recoveryAction on errors; after replay check tra…

ParameterTypeDescription
actionSummary *stringRequired public high-level action label.
agentIdstringOptional Sovereign Agent DID. Defaults to the local signer's DID and must match it when provided.
confidentialPayloadobjectOptional confidential parameters, canonicalized and hashed locally.
counterpartyIdstringOptional counterparty agent identifier.
dryRunbooleanOnly set true when the user asks to preview, test, or inspect the commitment without settling on-chain. Defaults to false.
intentstringDeprecated alias. actionSummary remains required.

rohan_get_ledger_state

Reads the current anchored Rohan Protocol contract state on Midnight. Usage guidelines: - Use for the latest state root, block height, or last transaction hash; do not use for transaction lists (use rohan_get_transaction_history) or identity/relayer health (use rohan_get_agent_status). - This is a read-only network lookup; do not include confidential payloads. If unavailable, check rohan_get_agent_status before retrying.

rohan_get_transaction_history

Lists historical Rohan Protocol settlement transactions and receipts on Midnight. Usage guidelines: - Use to find or inspect prior settlements, especially after REPLAY_DETECTED; do not use for the latest state root (use rohan_get_ledger_state) or identity/health (use rohan_get_agent_status). - This read-only lookup accepts no confidential payload. If it fails, check rohan_get_agent_status and follow the returned error guidance.

ParameterTypeDescription
limitintegerMaximum number of historical transactions to return (default: 10, max: 50).

rohan_verify_commitment

Cryptographically audits a plaintext payload and/or a portable RohanAuditBundle offline in local memory (0 gas). Usage guidelines: - Use to verify a payload digest or audit bundle; do not use to submit a handshake (use rohan_execute_handshake). - For expectedDigest mode provide the exact original JSON payload and the inner payloadDigest; never pass the outer timestamp-salted intentHash. For auditBundle mode, provide the complete bundle and optionally the original payload. - Verification is local and does not send plaintext to the relayer. Treat valid: false as a cryptographic mismatch, not a t…

ParameterTypeDescription
auditBundleobjectOptional portable RohanAuditBundle (schema: rohan-audit-bundle/v1) returned by rohan_execute_handshake. Verifies Ed25519 signature, intentHash binding, and payloadDigest.
expectedDigeststringExpected inner SHA-256 digest of the canonicalized payload (from actionSummary digest: sha256:<hash> or auditBundle.payloadDigest). Accepts raw hex, 0x, or sha256: prefixes.
payloadobjectPlaintext contract, agreement, or confidential data object to verify.

rohan_get_agent_status

Returns the active Sovereign Agent identity (W3C did:key), signing mode, configured network, and relayer reachability (gracefully degrades if offline). Usage guidelines: - Use to inspect local identity or diagnose connectivity and signature errors; do not use for transaction details (use rohan_get_transaction_history) or full ledger state (use rohan_get_ledger_state). - Never exposes private keys. Do not send secrets as arguments; if offline, inspect configuration and retry only after recovery.