{
  "markdown": "<p align=\"center\">\n  <img src=\"https://img.shields.io/badge/GARL_Protocol-v1.4.0-00ff88?style=for-the-badge&labelColor=0a0a0a\" alt=\"Version\" />\n  <img src=\"https://img.shields.io/badge/License-Apache_2.0-blue?style=for-the-badge&labelColor=0a0a0a\" alt=\"License\" />\n  <img src=\"https://img.shields.io/badge/GitHub_Action-Live-00ff88?style=for-the-badge&labelColor=0a0a0a\" alt=\"GitHub Action\" />\n  <img src=\"https://img.shields.io/badge/A2A_v1.0-Compliant-00ff88?style=for-the-badge&labelColor=0a0a0a\" alt=\"A2A v1.0\" />\n  <img src=\"https://img.shields.io/badge/MCP-29_Tools-00ff88?style=for-the-badge&labelColor=0a0a0a\" alt=\"MCP\" />\n  <br/>\n  <a href=\"https://github.com/Garl-Protocol/garl/actions/workflows/ci.yml\"><img src=\"https://github.com/Garl-Protocol/garl/actions/workflows/ci.yml/badge.svg\" alt=\"CI\" /></a>\n</p>\n\n<h1 align=\"center\">GARL Protocol</h1>\n<p align=\"center\"><strong>Prove what your AI agent was authorized to do — and what it actually did.</strong></p>\n\n<p align=\"center\">\n<em>Capability tokens set hard limits on an agent — spend caps, merchant allowlists, side-effect class, expiry — and a delegated token can only narrow its parent, never widen it.<br/>Every action becomes an ECDSA-secp256k1-signed Action Receipt bound to the token that authorized it, Merkle-anchored on Base mainnet, and verifiable offline without trusting GARL.</em>\n</p>\n\n<p align=\"center\">\n  <a href=\"https://garl.ai/connect\">Add your agent</a> ·\n  <a href=\"https://garl.ai/anchors\">Anchor chain</a> ·\n  <a href=\"https://garl.ai\">Website</a> ·\n  <a href=\"https://garl.ai/docs\">Docs</a> ·\n  <a href=\"https://garl.ai/r/6ff83db8\">Live receipt</a> ·\n  <a href=\"#try-it-now\">Try It</a>\n</p>\n\n---\n\n<!-- HERO IMAGE -->\n<p align=\"center\">\n  <img src=\".github/assets/hero.png\" alt=\"GARL Protocol Dashboard\" width=\"720\" />\n</p>\n\n---\n\n## Try it now\n\n### Path A — For Agents (SDK / MCP)\n\n### With Claude Desktop or Cursor (MCP)\n\nAdd to your Claude Desktop config (`claude_desktop_config.json`) or Cursor MCP settings:\n\n```json\n{\n  \"mcpServers\": {\n    \"garl\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"@garl-protocol/mcp-server\"]\n    }\n  }\n}\n```\n\nThat's it — 29 named tools (including batch variants like `garl_verify_batch`) are now available in your AI assistant: receipts, Trust Vector lookups, capability tokens (issue/verify/revoke), Capability Gate pre-flight, UETA §10(b) undo, and more.\n\n### With curl (zero install)\n\n```bash\n# Check an agent's trust score\ncurl -s \"https://api.garl.ai/api/v1/trust/verify?agent_id=5872ce17-5718-4980-ade3-e51c9556fb53\" | python3 -m json.tool\n\n# Find the most trusted coding agent\ncurl -s \"https://api.garl.ai/api/v1/trust/route?category=coding&min_tier=silver\" | python3 -m json.tool\n\n# See the live leaderboard\ncurl -s \"https://api.garl.ai/api/v1/leaderboard?limit=5\" | python3 -m json.tool\n```\n\n### With Python\n\n```bash\npip install garl-protocol\n```\n\n```python\nimport garl\n\ngarl.init(\"your_api_key\", \"your_agent_uuid\")\ngarl.log_action(\"Analyzed dataset\", \"success\", category=\"data\")\n\nresult = garl.is_trusted(\"target_agent_uuid\", min_score=60)\nif result[\"trusted\"]:\n    print(f\"Safe to delegate — score: {result['score']}/100\")\n```\n\n### With JavaScript\n\n```bash\nnpm install @garl-protocol/sdk\n```\n\n```javascript\nimport { init, logAction, isTrusted } from \"@garl-protocol/sdk\";\n\ninit(\"your_api_key\", \"your_agent_uuid\", \"https://api.garl.ai/api/v1\");\nawait logAction(\"Generated REST API\", \"success\", { category: \"coding\" });\n\nconst result = await isTrusted(\"target_agent_uuid\", { minScore: 60 });\nif (result.trusted) {\n  console.log(`Safe to delegate — score: ${result.score}/100`);\n}\n```\n\n### Capability tokens — authorization with hard limits\n\n```bash\n# Issue a scoped token for your agent (owner API key required)\ncurl -s -X POST https://api.garl.ai/api/v1/capability/issue \\\n  -H \"x-api-key: $GARL_API_KEY\" -H \"Content-Type: application/json\" \\\n  -d '{\n    \"agent_id\": \"your-agent-uuid\",\n    \"scope\": \"payment:stripe.com\",\n    \"side_effect_class\": \"reversible\",\n    \"spend_limit_usd\": 50,\n    \"merchant_allowlist\": [\"stripe.com\"],\n    \"expires_in_seconds\": 3600\n  }' | python3 -m json.tool\n\n# Anyone can verify a token — no auth, no account\ncurl -s -X POST https://api.garl.ai/api/v1/capability/verify \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\"token\": \"<the JWT-form token>\"}' | python3 -m json.tool\n```\n\nA delegated child token can only *narrow* its parent (lower spend limit,\nsubset allowlist, equal-or-narrower scope, same-or-earlier expiry) — enforced\nat issue time and re-checked link-by-link at verification. Full wire format:\n[`protocol/spec/capability-token-v0.1.md`](./protocol/spec/capability-token-v0.1.md).\n\n### Path B — For Code (GitHub Action, 5 lines of YAML)\n\nSign every AI-authored commit in your pull requests.\n\n```yaml\n# .github/workflows/garl-receipt.yml\nname: GARL Receipt\non:\n  pull_request:\n    types: [opened, synchronize, reopened]\njobs:\n  sign:\n    runs-on: ubuntu-latest\n    permissions: { contents: read, pull-requests: write, checks: write }\n    steps:\n      - uses: actions/checkout@v4\n        with: { fetch-depth: 0 }\n      - uses: Garl-Protocol/garl-receipt-action@v1.1.0\n        with:\n          garl-api-key: ${{ secrets.GARL_API_KEY }}\n          garl-agent-id: ${{ secrets.GARL_AGENT_ID }}\n```\n\nEvery PR gets a rolling GARL Receipt comment + informational check:\n\n```\n🔐 GARL Verified AI Code\n├── Model: claude-opus-4-6\n├── Tool: Claude Code\n├── Files touched: 12\n├── Duration: 4m 12s\n├── Signed: ECDSA-secp256k1 ✓\n└── Receipt: https://garl.ai/r/a8f3c2d1\n```\n\nSetup guide: [`Garl-Protocol/garl-receipt-action`](https://github.com/Garl-Protocol/garl-receipt-action) ·\nLive landing page: [garl.ai/for-code](https://garl.ai/for-code).\n\n---\n\n## Receipts — a paste-ready proof for every trace\n\nEvery submitted trace gets a public shareable **Receipt URL** at\n`https://garl.ai/r/{short}` — a cryptographic proof card (agent, tier, task,\nduration, SHA-256 hash, ECDSA signature) with an Open Graph image that\npreviews richly in Slack, Twitter/X, GitHub PRs, and LinkedIn.\n\n```bash\ncurl -s https://api.garl.ai/api/v1/verify/6ff83db8 | python3 -m json.tool\n#  → receipt_url: https://garl.ai/r/6ff83db8\n```\n\nSDKs expose `receipt_url` / `receiptUrl` on every `log_action` / `verify`\nreturn and a `client.receipt(hash)` shortcut. The MCP tool `garl_receipt`\nresolves any short or full hash to a paste-ready URL.\n\n## GitHub Action — sign every AI-authored commit\n\nAdd `Garl-Protocol/garl/integrations/github-action-receipt` to your PR\nworkflow. It detects Claude Code, Cursor, GitHub Copilot, Aider, and Codex\nco-author trailers, submits a signed trace per qualifying commit, and posts\na rolling PR comment + informational check with receipt URLs:\n\n```yaml\n- uses: Garl-Protocol/garl/integrations/github-action-receipt@main\n  with:\n    garl-api-key: ${{ secrets.GARL_API_KEY }}\n    garl-agent-id: ${{ secrets.GARL_AGENT_ID }}\n```\n\nFull setup in [`integrations/github-action-receipt`](./integrations/github-action-receipt/README.md).\nOnly metadata is uploaded — never diffs or source.\n\n## Why GARL?\n\n| Problem | GARL's Answer |\n|---------|---------------|\n| \"What was this agent *allowed* to do?\" | Capability tokens: `spend_limit_usd`, `merchant_allowlist`, `side_effect_class`, expiry — with Biscuit-style attenuation (delegation can only narrow, re-checked link-by-link at verify) |\n| \"Did it stay inside those limits?\" | Every Action Receipt binds `capability_request.token_hash` + `policy_decision` into the signed envelope; the Capability Gate escalates low-trust irreversible actions to a human |\n| \"Is this agent reliable?\" | 5-dimensional trust scoring with Exponential Moving Average |\n| \"Which agent should I pick?\" | Smart routing by category + minimum certification tier |\n| \"Can I verify its track record?\" | Immutable ledger with ECDSA-signed execution traces + shareable Receipt URLs |\n| \"Does it work with my stack?\" | MCP Server · A2A Protocol · REST API · Python & JS SDKs · GitHub Action |\n| \"Prove this AI commit is real\" | GitHub Action posts a signed receipt per AI-authored commit |\n| \"What about on-chain agents?\" | ERC-8004 format compatible (off-chain). Receipt-batch Merkle roots are anchored on Base mainnet (`MerkleAnchor` at `0xBeD7EdeFbEb02be9682bCdeC5fb5D7DA28b1b6F2`). |\n\n---\n\n## Works with\n\n<p align=\"center\">\n  <strong>Claude Desktop</strong> · <strong>Cursor</strong> · <strong>Any MCP Client</strong> · <strong>Google A2A</strong> · <strong>ERC-8004</strong> · <strong>REST API</strong> · <strong>Python</strong> · <strong>JavaScript</strong> · <strong>LangChain</strong> · <strong>CrewAI</strong> · <strong>AutoGen</strong> · <strong>LlamaIndex</strong> · <strong>Semantic Kernel</strong> · <strong>GitHub Actions</strong>\n</p>\n\n---\n\n## How it works\n\nEvery agent action is hashed, signed, scored across five dimensions, and made queryable — creating a verifiable trust record.\n\n```\nAgent executes task → SHA-256 hash + ECDSA signature → 5D EMA scoring → Tier assigned → Queryable via API/MCP/A2A\n```\n\n```\n┌─────────────────────────────────────────────────────────────────┐\n│                        GARL Protocol                            │\n├─────────────────────────────────────────────────────────────────┤\n│                                                                 │\n│  ┌──────────┐   ┌──────────┐   ┌──────────┐   ┌──────────┐    │\n│  │  Python   │   │   JS     │   │   MCP    │   │   A2A    │    │\n│  │   SDK     │   │   SDK    │   │  Server  │   │ JSON-RPC │    │\n│  └────┬─────┘   └────┬─────┘   └────┬─────┘   └────┬─────┘    │\n│       │              │              │              │            │\n│       └──────────────┴──────────────┴──────────────┘            │\n│                          │                                      │\n│                    ┌─────▼─────┐                                │\n│                    │  FastAPI  │  REST + A2A + MCP              │\n│                    │  Backend  │  Rate Limited + CORS            │\n│                    └─────┬─────┘                                │\n│                          │                                      │\n│          ┌───────────────┼───────────────┐                      │\n│          │               │               │                      │\n│    ┌─────▼─────┐  ┌─────▼─────┐  ┌─────▼─────┐               │\n│    │ Reputation│  │  Signing  │  │  Webhook  │               │\n│    │  Engine   │  │  Engine   │  │  Engine   │               │\n│    │ • 5D EMA  │  │ • SHA-256 │  │ • HMAC    │               │\n│    │ • Tiers   │  │ • ECDSA   │  │ • Retry   │               │\n│    └───────────┘  └───────────┘  └───────────┘               │\n│                          │                                      │\n│                    ┌─────▼─────┐                                │\n│                    │ Supabase  │  PostgreSQL + RLS              │\n│                    │           │  Immutable Triggers            │\n│                    └───────────┘                                │\n│                                                                 │\n└─────────────────────────────────────────────────────────────────┘\n```\n\n---\n\n## ERC-8004 Compatibility\n\nGARL Protocol serves agent metadata in [ERC-8004](https://eips.ethereum.org/EIPS/eip-8004) format (off-chain). Separately, the Merkle roots of batched Action Receipts are anchored on Base mainnet (`MerkleAnchor` contract `0xBeD7EdeFbEb02be9682bCdeC5fb5D7DA28b1b6F2`, chain 8453). Individual receipts are not written on-chain; anyone can verify a receipt's inclusion against an anchored root via `verifyProof`.\n\n```bash\n# Get ERC-8004 compatible metadata for any agent\ncurl -s \"https://api.garl.ai/api/v1/agents/{agent_id}/erc8004\" | python3 -m json.tool\n\n# Get trust scores in ERC-8004 Reputation Registry feedback format\ncurl -s \"https://api.garl.ai/api/v1/agents/{agent_id}/erc8004/feedback\" | python3 -m json.tool\n```\n\nGARL uses the same cryptographic curve as Ethereum (ECDSA-secp256k1), making trust attestations natively verifiable by on-chain systems.\n\n---\n\n## Documentation\n\n| Topic | Link |\n|-------|------|\n| Capability Token wire format (spec) | [protocol/spec/capability-token-v0.1.md](./protocol/spec/capability-token-v0.1.md) |\n| Action Receipt wire format (spec) | [protocol/spec/action-receipt-v0.1.md](./protocol/spec/action-receipt-v0.1.md) |\n| Anchoring runbook (weekly Merkle anchor on Base) | [docs/runbooks/anchoring.md](./docs/runbooks/anchoring.md) |\n| Full API Reference (60+ REST endpoints + A2A + MCP) | [docs/api-reference.md](./docs/api-reference.md) |\n| MCP Server (29 named tools, including batch variants) | [garl.ai/docs#mcp-server](https://garl.ai/docs#mcp-server) |\n| A2A Protocol Integration | [garl.ai/docs#a2a](https://garl.ai/docs#a2a) |\n| ERC-8004 Compatibility | [garl.ai/docs#erc-8004](https://garl.ai/docs#erc-8004) |\n| Python & JS SDKs | [garl.ai/docs#sdks](https://garl.ai/docs#sdks) |\n| Architecture & Tech Stack | [docs/architecture.md](./docs/architecture.md) |\n| Deployment & Self-hosting | [docs/deployment.md](./docs/deployment.md) |\n| Security | [docs/security.md](./docs/security.md) |\n\nInteractive API explorer: [api.garl.ai/docs](https://api.garl.ai/docs) (Swagger) · [api.garl.ai/redoc](https://api.garl.ai/redoc)\n\n---\n\n## Live now\n\n- **[garl.ai](https://garl.ai)** — Live dashboard & real-time trust feed\n- **[Add your agent](https://garl.ai/connect)** — Connect any agent (REST, SDK, MCP, GitHub Action) in three steps\n- **[My Agents](https://garl.ai/account)** — sign in (Clerk) and claim the agents you've connected by API key to track their activity from one place\n- **[Registry](https://garl.ai/registry)** — Browse connected agents and their signed, verifiable activity\n- **[Verify](https://garl.ai/verify)** — Public cryptographic trace verification\n- **[Playground](https://garl.ai/playground)** — Interactive API explorer\n- **[Simulator](https://garl.ai/simulator)** — 5D trust score calculator with what-if analysis\n- **[Compare](https://garl.ai/compare)** — Side-by-side agent comparison with radar overlay\n- **[Swagger](https://api.garl.ai/docs)** — Full OpenAPI documentation\n- **[Anchors](https://garl.ai/anchors)** — every Merkle batch with its root, receipt count, and Base tx (`GET /api/v1/anchors`)\n- **[MerkleAnchor on Base](https://basescan.org/address/0xBeD7EdeFbEb02be9682bCdeC5fb5D7DA28b1b6F2)** — Receipt-batch Merkle roots anchored on Base mainnet (chain 8453)\n- **[MCP Registry](https://registry.modelcontextprotocol.io/)** — Listed as `io.github.Garl-Protocol/agent-trust`\n\n---\n\n## Contributing\n\nGARL Protocol is open source under the Apache 2.0 License. Contributions are welcome — see [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines and [CODE_OF_CONDUCT.md](CODE_OF_CONDUCT.md) for community standards. Every commit must be DCO-signed (`git commit -s`).\n\n**Requirements:** **Python 3.10+** for the backend (PEP 604 union syntax),\n**Node 18+** for the frontend. macOS users: the system `python3` is 3.9\nand will fail backend tests — install 3.10+ via `pyenv` / `brew install python@3.12`\nand invoke explicitly (`python3.12 -m pytest tests/`).\n\n1. Fork the repository\n2. Create your feature branch (`git checkout -b feature/amazing-feature`)\n3. Run tests (`python3.12 -m pytest` for backend, `npx next build` for frontend)\n4. Commit your changes with DCO sign-off (`git commit -s -m 'Add amazing feature'`)\n5. Open a Pull Request\n\n---\n\n## Canonical registry, self-hosting, and marks\n\n- **Canonical registry**: `https://api.garl.ai` — the single deployment whose public key anchors the `GARL Verified` status. Public keys are published at [`/.well-known/garl-keys.json`](https://api.garl.ai/.well-known/garl-keys.json).\n- **Self-hosting is supported** and documented in [`docs/self-host.md`](docs/self-host.md). Self-hosted deployments are first-class participants but are not the canonical registry; see [GOVERNANCE.md](GOVERNANCE.md).\n- **Trademark policy**: [TRADEMARK.md](TRADEMARK.md). The source code is Apache 2.0; the GARL name and logo are project marks and subject to the policy.\n\nProject decision-making, breaking-change process, and the boundary between repository features (Apache 2.0 forever) and potential future Cloud-only services on the canonical registry are documented in [GOVERNANCE.md](GOVERNANCE.md).\n\n---\n\n## License\n\nApache License 2.0 — see [LICENSE](LICENSE) for details.\n",
  "bytes": 16311,
  "sha": "567c397ab4e2fd4b16ef587f972c9feb5474ce7457a6907f02371f7058af55ca",
  "repo_slug": "garl-protocol/garl",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_garl_protocol_agent_trust_1dccc0da/readme"
}