io.github.payclaw/badge

السجل الرسمي الذكاء الاصطناعي والوكلاء

Agents are not bots. Prove it. MCP-native identity declaration for authorized agents.

التثبيت

أضف هذا إلى إعدادات MCP في عميلك (Claude Desktop: claude_desktop_config.json، وCursor: ‏.cursor/mcp.json، ويستخدم VS Code وغيره الصيغة نفسها «mcpServers»).

NPM package @payclaw/badge
Claude Code
claude mcp add badge -e 'PAYCLAW_API_KEY=<your payclaw_api_key>' -e 'PAYCLAW_API_URL=<PAYCLAW_API_URL>' -- npx -y @payclaw/badge@0.4.0
إعداد JSON (Claude Desktop وCursor وVS Code)
{
    "mcpServers": {
        "badge": {
            "command": "npx",
            "args": [
                "-y",
                "@payclaw/badge@0.4.0"
            ],
            "env": {
                "PAYCLAW_API_KEY": "<your payclaw_api_key>",
                "PAYCLAW_API_URL": "<PAYCLAW_API_URL>"
            }
        }
    }
}

متغيرات البيئة

  • PAYCLAW_API_KEY إلزامي سري Your PayClaw API key (get one at payclaw.io)
  • PAYCLAW_API_URL PayClaw API URL (default: https://payclaw.io)

التوثيق

مأخوذ من ملف README للمشروع على GitHub ويُحدَّث أسبوعيًا. تفتح الروابط على GitHub.

المحتويات
  1. Badge by kya labs
  2. Badge SDK
  3. Badge MCP Server
  4. Links
  5. License

Badge by kya labs

Persistent identity for AI agents across merchant sites. Badge gives agents a credential they carry on every request — merchants verify it, trust accumulates across visits, and agents that build history earn better treatment over time.

Framework-agnostic. Transport-agnostic. Zero runtime dependencies.


Badge SDK

The SDK is the primary integration surface. Three methods cover the full lifecycle:

import { Badge } from "@kyalabs/badge-sdk";

const badge = await Badge.init();
const runId = badge.startRun();

await badge.declareVisit({
  merchant: "store.example.com",
  runId,
  url: "https://store.example.com/cart",
});

await badge.reportOutcome({
  merchant: "store.example.com",
  runId,
  outcome: "not_denied",
});

No signup. No API key. Badge.init() issues a guest pass on first run and caches it to disk. Identity survives process restarts.

npm install @kyalabs/badge-sdk

Full SDK documentation →

What the SDK covers
  • Identity model — three-tier ladder: guest pass (gp_v1_*) → badge token (kya_*) → authenticated identity
  • Lifecycle tracking — declare visits, report outcomes, correlate with run IDs
  • Offline resilience — never throws on network failure, deterministic fallback on every call
  • UCP integration — io.kyalabs.common.identity Credential Provider, published schemas, ES256-signed JWTs
  • Scoring — outcomes feed kyaScore (500–850), portable across merchants


Badge MCP Server

For MCP client users (Claude Desktop, Cursor, Windsurf), Badge also ships as an MCP tool server. The MCP server wraps the SDK — same identity model, same tokens, same scoring.

npx @kyalabs/badge

The SDK is the canonical integration path for platform builders and agent frameworks. The MCP server is a convenience wrapper for end users working within MCP clients.


License

MIT

الأسئلة الشائعة

ما هو io.github.payclaw/badge؟

Agents are not bots. Prove it. MCP-native identity declaration for authorized agents.

كيف أثبّت io.github.payclaw/badge؟

يعمل على جهازك. في Claude Code: claude mcp add badge -e 'PAYCLAW_API_KEY=<your payclaw_api_key>' -e 'PAYCLAW_API_URL=<PAYCLAW_API_URL>' -- npx -y @payclaw/badge@0.4.0. وفي العملاء الآخرين، الصق إعداد JSON من هذه الصفحة في إعدادات MCP الخاصة بهم.

هل يحتاج io.github.payclaw/badge إلى مفتاح API؟

نعم. يتطلب PAYCLAW_API_KEY، وتضبطها في إعداداته.

هل io.github.payclaw/badge مفتوح المصدر؟

نعم. شيفرته متاحة على GitHub بترخيص MIT.

من يصون io.github.payclaw/badge؟

ينشره payclaw. يدرجه AI.tn لكنه لا يصونه ولا يوصي به.

من سجل MCP الرسمي. الإدراج ليس توصية: راجع شيفرة الخادم وصلاحياته قبل منحه الوصول إلى بياناتك.