{
  "schemaVersion": "1.0",
  "item": {
    "slug": "clawchain",
    "name": "Clawchain",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/bowen31337/clawchain",
    "canonicalUrl": "https://clawhub.ai/bowen31337/clawchain",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/clawchain",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=clawchain",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "SKILL.md",
      "clawchain-rpc-client/Cargo.toml",
      "clawchain-rpc-client/README.md",
      "clawchain-rpc-client/SKILL.md",
      "clawchain-rpc-client/src/client.rs",
      "clawchain-rpc-client/src/error.rs"
    ],
    "primaryDoc": "SKILL.md",
    "quickSetup": [
      "Download the package from Yavira.",
      "Extract the archive and review SKILL.md first.",
      "Import or place the package into your OpenClaw setup."
    ],
    "agentAssist": {
      "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
      "steps": [
        "Download the package from Yavira.",
        "Extract it into a folder your agent can access.",
        "Paste one of the prompts below and point your agent at the extracted folder."
      ],
      "prompts": [
        {
          "label": "New install",
          "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
        },
        {
          "label": "Upgrade existing",
          "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
        }
      ]
    },
    "sourceHealth": {
      "source": "tencent",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-04-30T16:55:25.780Z",
      "expiresAt": "2026-05-07T16:55:25.780Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=network",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=network",
        "contentDisposition": "attachment; filename=\"network-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null
      },
      "scope": "source",
      "summary": "Source download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this source.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/clawchain"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    },
    "downloadPageUrl": "https://openagent3.xyz/downloads/clawchain",
    "agentPageUrl": "https://openagent3.xyz/skills/clawchain/agent",
    "manifestUrl": "https://openagent3.xyz/skills/clawchain/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/clawchain/agent.md"
  },
  "agentAssist": {
    "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
    "steps": [
      "Download the package from Yavira.",
      "Extract it into a folder your agent can access.",
      "Paste one of the prompts below and point your agent at the extracted folder."
    ],
    "prompts": [
      {
        "label": "New install",
        "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
      },
      {
        "label": "Upgrade existing",
        "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
      }
    ]
  },
  "documentation": {
    "source": "clawhub",
    "primaryDoc": "SKILL.md",
    "sections": [
      {
        "title": "ClawChain RPC Client",
        "body": "Connect EvoClaw agents to the ClawChain blockchain for on-chain reputation tracking, token economics, and governance participation."
      },
      {
        "title": "Quick Start",
        "body": "use clawchain::ClawChainClient;\n\n#[tokio::main]\nasync fn main() -> anyhow::Result<()> {\n    // Connect to local node\n    let client = ClawChainClient::new(\"ws://127.0.0.1:9944\").await?;\n    \n    // Query agent reputation\n    let did = \"did:claw:1a2b3c4d...\";\n    let reputation = client.get_agent_reputation(did).await?;\n    println!(\"Reputation score: {}\", reputation);\n    \n    // Check token balance\n    let balance = client.get_token_balance(did).await?;\n    println!(\"CLAW tokens: {}\", balance);\n    \n    Ok(())\n}"
      },
      {
        "title": "Prerequisites",
        "body": "ClawChain node running:\nclawchain-node --dev --rpc-external --ws-external\n\n\n\nRust dependencies in Cargo.toml:\n[dependencies]\nclawchain = { path = \"/path/to/clawchain-skill\" }"
      },
      {
        "title": "Architecture",
        "body": "┌─────────────────────────────────────────────────┐\n│              EvoClaw Edge Agent                │\n├─────────────────────────────────────────────────┤\n│  ┌────────────────────────────────────────┐   │\n│  │  ClawChain Skill (this skill)         │   │\n│  │  └─ Substrate RPC client              │   │\n│  └────────────────────────────────────────┘   │\n└─────────────────────────────────────────────────┘\n          ↓ WebSocket\n┌─────────────────────────────────────────────────┐\n│         ClawChain Node (Substrate)             │\n│  ┌───────────────────────────────────────────┐  │\n│  │ AgentRegistry Pallet                      │  │\n│  │ ClawToken Pallet                           │  │\n│  │ Governance Pallet                           │  │\n│  └───────────────────────────────────────────┘  │\n└─────────────────────────────────────────────────┘"
      },
      {
        "title": "Agent DIDs",
        "body": "Agent identifiers follow the format:\n\ndid:claw:<hash>\n\nWhere <hash> is SHA-256(agent metadata + owner address)."
      },
      {
        "title": "Reputation Scores",
        "body": "Reputation is computed from:\n\nscore = (commits * 1000) + (pull_requests * 5000) + (docs * 2000)"
      },
      {
        "title": "Token Economics",
        "body": "Total Supply: 1 billion $CLAW\nDistribution: 40% airdrop, 30% validators, 20% treasury, 10% team\nInflation: 5% annual (floor 2%) for gas subsidies"
      },
      {
        "title": "Connection",
        "body": "let client = ClawChainClient::new(\"ws://localhost:9944\").await?;\n\nParameters:\n\nurl: WebSocket URL (ws:// or wss://)\nReturns: Connected client"
      },
      {
        "title": "Query Agent",
        "body": "let agent = client.get_agent(\"did:claw:...\").await?;\n\nReturns: AgentInfo struct with:\n\ndid: Agent DID\nowner: Owner address\nmetadata: IPFS hash\nreputation: Reputation score\nverifications: Number of attestations"
      },
      {
        "title": "Get Token Balance",
        "body": "let balance = client.get_token_balance(\"did:claw:...\").await?;\n\nReturns: Token balance (u128)"
      },
      {
        "title": "Register Agent",
        "body": "let did = client.register_agent(metadata_ipfs_hash).await?;\n\nReturns: Newly created DID"
      },
      {
        "title": "Vote on Proposal",
        "body": "client.vote(proposal_id, true).await?;\n\nParameters:\n\nproposal_id: Proposal identifier\napprove: true (approve) or false (reject)"
      },
      {
        "title": "Submit Transaction",
        "body": "let tx_hash = client.submit_extrinsic(call_data).await?;\n\nParameters:\n\ncall_data: Encoded extrinsic\nReturns: Transaction hash"
      },
      {
        "title": "Error Handling",
        "body": "use clawchain::ClawChainError;\n\nmatch client.get_agent(did).await {\n    Ok(agent) => println!(\"Agent: {:?}\", agent),\n    Err(ClawChainError::NotFound) => println!(\"Agent not found\"),\n    Err(e) => eprintln!(\"Error: {:?}\", e),\n}"
      },
      {
        "title": "Example: Full Agent Integration",
        "body": "use clawchain::ClawChainClient;\n\n#[tokio::main]\nasync fn main() -> anyhow::Result<()> {\n    let client = ClawChainClient::new(\"ws://127.0.0.1:9944\").await?;\n    \n    // 1. Register this agent\n    let metadata = b\"{\\\"name\\\":\\\"pi1-edge\\\",\\\"type\\\":\\\"edge\\\"}\";\n    let did = client.register_agent(metadata).await?;\n    println!(\"Registered: {}\", did);\n    \n    // 2. Check reputation\n    let rep = client.get_agent_reputation(&did).await?;\n    println!(\"Reputation: {}\", rep);\n    \n    // 3. Vote on governance proposal\n    if rep > 1000 {\n        client.vote(123, true).await?;\n        println!(\"Voted on proposal #123\");\n    }\n    \n    Ok(())\n}"
      },
      {
        "title": "Monitoring",
        "body": "Subscribe to chain events:\n\nclient.subscribe_events(|event| {\n    match event {\n        ChainEvent::Block(block) => println!(\"New block: {}\", block.number),\n        ChainEvent::AgentRegistered(did) => println!(\"Agent: {}\", did),\n        ChainEvent::ProposalPassed(id) => println!(\"Proposal {} passed\", id),\n    }\n}).await?;"
      },
      {
        "title": "Testing",
        "body": "Mock RPC server for testing:\n\nlet mock = MockServer::new().await?;\nlet client = mock.client().await?;"
      },
      {
        "title": "Security Notes",
        "body": "Never expose private keys in agent code\nUse programmatic signing for autonomous agents\nValidate all RPC responses\nImplement rate limiting for public RPC endpoints"
      },
      {
        "title": "References",
        "body": "ClawChain Architecture\nSubstrate RPC Docs\nAgent Registry Pallet"
      }
    ],
    "body": "ClawChain RPC Client\n\nConnect EvoClaw agents to the ClawChain blockchain for on-chain reputation tracking, token economics, and governance participation.\n\nQuick Start\nuse clawchain::ClawChainClient;\n\n#[tokio::main]\nasync fn main() -> anyhow::Result<()> {\n    // Connect to local node\n    let client = ClawChainClient::new(\"ws://127.0.0.1:9944\").await?;\n    \n    // Query agent reputation\n    let did = \"did:claw:1a2b3c4d...\";\n    let reputation = client.get_agent_reputation(did).await?;\n    println!(\"Reputation score: {}\", reputation);\n    \n    // Check token balance\n    let balance = client.get_token_balance(did).await?;\n    println!(\"CLAW tokens: {}\", balance);\n    \n    Ok(())\n}\n\nPrerequisites\n\nClawChain node running:\n\nclawchain-node --dev --rpc-external --ws-external\n\n\nRust dependencies in Cargo.toml:\n\n[dependencies]\nclawchain = { path = \"/path/to/clawchain-skill\" }\n\nArchitecture\n┌─────────────────────────────────────────────────┐\n│              EvoClaw Edge Agent                │\n├─────────────────────────────────────────────────┤\n│  ┌────────────────────────────────────────┐   │\n│  │  ClawChain Skill (this skill)         │   │\n│  │  └─ Substrate RPC client              │   │\n│  └────────────────────────────────────────┘   │\n└─────────────────────────────────────────────────┘\n          ↓ WebSocket\n┌─────────────────────────────────────────────────┐\n│         ClawChain Node (Substrate)             │\n│  ┌───────────────────────────────────────────┐  │\n│  │ AgentRegistry Pallet                      │  │\n│  │ ClawToken Pallet                           │  │\n│  │ Governance Pallet                           │  │\n│  └───────────────────────────────────────────┘  │\n└─────────────────────────────────────────────────┘\n\nKey Concepts\nAgent DIDs\n\nAgent identifiers follow the format:\n\ndid:claw:<hash>\n\n\nWhere <hash> is SHA-256(agent metadata + owner address).\n\nReputation Scores\n\nReputation is computed from:\n\nscore = (commits * 1000) + (pull_requests * 5000) + (docs * 2000)\n\nToken Economics\nTotal Supply: 1 billion $CLAW\nDistribution: 40% airdrop, 30% validators, 20% treasury, 10% team\nInflation: 5% annual (floor 2%) for gas subsidies\nAPI Reference\nConnection\nlet client = ClawChainClient::new(\"ws://localhost:9944\").await?;\n\n\nParameters:\n\nurl: WebSocket URL (ws:// or wss://)\nReturns: Connected client\nQuery Agent\nlet agent = client.get_agent(\"did:claw:...\").await?;\n\n\nReturns: AgentInfo struct with:\n\ndid: Agent DID\nowner: Owner address\nmetadata: IPFS hash\nreputation: Reputation score\nverifications: Number of attestations\nGet Token Balance\nlet balance = client.get_token_balance(\"did:claw:...\").await?;\n\n\nReturns: Token balance (u128)\n\nRegister Agent\nlet did = client.register_agent(metadata_ipfs_hash).await?;\n\n\nReturns: Newly created DID\n\nVote on Proposal\nclient.vote(proposal_id, true).await?;\n\n\nParameters:\n\nproposal_id: Proposal identifier\napprove: true (approve) or false (reject)\nSubmit Transaction\nlet tx_hash = client.submit_extrinsic(call_data).await?;\n\n\nParameters:\n\ncall_data: Encoded extrinsic\nReturns: Transaction hash\nError Handling\nuse clawchain::ClawChainError;\n\nmatch client.get_agent(did).await {\n    Ok(agent) => println!(\"Agent: {:?}\", agent),\n    Err(ClawChainError::NotFound) => println!(\"Agent not found\"),\n    Err(e) => eprintln!(\"Error: {:?}\", e),\n}\n\nExample: Full Agent Integration\nuse clawchain::ClawChainClient;\n\n#[tokio::main]\nasync fn main() -> anyhow::Result<()> {\n    let client = ClawChainClient::new(\"ws://127.0.0.1:9944\").await?;\n    \n    // 1. Register this agent\n    let metadata = b\"{\\\"name\\\":\\\"pi1-edge\\\",\\\"type\\\":\\\"edge\\\"}\";\n    let did = client.register_agent(metadata).await?;\n    println!(\"Registered: {}\", did);\n    \n    // 2. Check reputation\n    let rep = client.get_agent_reputation(&did).await?;\n    println!(\"Reputation: {}\", rep);\n    \n    // 3. Vote on governance proposal\n    if rep > 1000 {\n        client.vote(123, true).await?;\n        println!(\"Voted on proposal #123\");\n    }\n    \n    Ok(())\n}\n\nMonitoring\n\nSubscribe to chain events:\n\nclient.subscribe_events(|event| {\n    match event {\n        ChainEvent::Block(block) => println!(\"New block: {}\", block.number),\n        ChainEvent::AgentRegistered(did) => println!(\"Agent: {}\", did),\n        ChainEvent::ProposalPassed(id) => println!(\"Proposal {} passed\", id),\n    }\n}).await?;\n\nTesting\n\nMock RPC server for testing:\n\nlet mock = MockServer::new().await?;\nlet client = mock.client().await?;\n\nSecurity Notes\nNever expose private keys in agent code\nUse programmatic signing for autonomous agents\nValidate all RPC responses\nImplement rate limiting for public RPC endpoints\nReferences\nClawChain Architecture\nSubstrate RPC Docs\nAgent Registry Pallet"
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/bowen31337/clawchain",
    "publisherUrl": "https://clawhub.ai/bowen31337/clawchain",
    "owner": "bowen31337",
    "version": "1.0.1",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/clawchain",
    "downloadUrl": "https://openagent3.xyz/downloads/clawchain",
    "agentUrl": "https://openagent3.xyz/skills/clawchain/agent",
    "manifestUrl": "https://openagent3.xyz/skills/clawchain/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/clawchain/agent.md"
  }
}