Dvarapala
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Dvarapalaverify the audit log's hash chain and show any tampered entries"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Dvarapala
Permission gates + tamper-evident audit logs for AI agents and MCP servers. 3 lines to add.
Agents execute tools, run commands, move money. When something goes wrong you need to answer two questions: should that have been allowed? and exactly where did the run go wrong? Dvarapala answers both — before (gating) and after (audit) — with zero dependencies.
import dvarapala
gate = dvarapala.Gate(policy="policy.json", audit="audit.jsonl")
@gate(risk="critical")
def refund(customer_id: str, amount_cents: int):
... # nothing runs unless policy + consent approve; every decision is hash-chainedWhy
Gate (before): declarative policy (
allow/warn/confirm/deny), heuristic risk scoring, consent ladder (once / session / always), kill switch, rate limiter.Audit (during → after): append-only JSONL with a SHA-256 chain per record. Editing or deleting history breaks verification:
dvarapala verify audit.jsonl.Causal fields from day one: every record carries
run_id,step,parent_step,context_refs,alternatives_considered,state_delta— so "why did the agent do that?" attribution can be built on top without re-instrumenting anything.
30-second tour
gate = dvarapala.Gate(
policy={
"rules": [
{"id": "reads-free", "match": {"tool": "read_*"}, "effect": "allow"},
{"id": "refunds-human","match": {"tool": "refund"}, "effect": "confirm"},
{"id": "no-drop", "match": {"keywords": ["drop table"]}, "effect": "deny"},
]
},
audit=".dvara/audit.jsonl",
)Annotate where a call happens in your agent loop:
with dvarapala.step(run_id="r1", step_no=17,
alternatives_considered=["cancel_order"]):
refund("c1", 5000) # audited with step=17, alternatives recordedDenied calls raise dvarapala.Denied (a PermissionError) — catch it and let
the model retry something else.
Surfaces
Surface | Import |
Decorator for any sync/async function |
|
ASGI middleware for HTTP tool endpoints |
|
MCP server tool handlers |
|
CLI |
|
Design rules
Stdlib-only core. No dependencies; YAML policies are an optional extra.
Deny-safe defaults. Non-interactive sessions deny instead of prompting; unknown shell commands assess as MEDIUM; destructive tokens as CRITICAL.
The log is evidence. Chain verification is one command, no server needed.
Status
v0.1.0 (alpha). The gate and audit core are stable; adapters and the
failure-attribution layer (why did step 24 fail because of step 6?) are on
the roadmap. MIT licensed. Contributions welcome.
Install
pip install dvarapala # core, stdlib-only
pip install dvarapala[yaml] # + YAML policy support
pip install dvarapala[dev] # + pytest/ruffLicense
MIT — see LICENSE.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Runtime permission, approval, and audit layer for AI agent tool execution.
See, price, and control every tool call your AI agents make: policy checks, cost, and audit tools.
Bitcoin-anchored, tamper-evident audit log for AI agents — record, disclose and verify actions.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/demolished-lab/dvarapala'
If you have feedback or need assistance with the MCP directory API, please join our Discord server