{
  "schemaVersion": "1.0",
  "item": {
    "slug": "8004-skill-monad",
    "name": "8004 Harness For Monad",
    "source": "tencent",
    "type": "skill",
    "category": "其他",
    "sourceUrl": "https://clawhub.ai/fabriziogianni7/8004-skill-monad",
    "canonicalUrl": "https://clawhub.ai/fabriziogianni7/8004-skill-monad",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/8004-skill-monad",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=8004-skill-monad",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "SKILL.md",
      "assets/registration-template.json",
      "assets/AGENT_IDENTITY.template.md",
      "scripts/upload-pinata.mjs",
      "scripts/build-card.mjs",
      "scripts/full-register.mjs"
    ],
    "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",
      "slug": "8004-skill-monad",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-04-23T19:22:57.334Z",
      "expiresAt": "2026-04-30T19:22:57.334Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=8004-skill-monad",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=8004-skill-monad",
        "contentDisposition": "attachment; filename=\"8004-skill-monad-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null,
        "slug": "8004-skill-monad"
      },
      "scope": "item",
      "summary": "Item download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this item.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/8004-skill-monad"
    },
    "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/8004-skill-monad",
    "agentPageUrl": "https://openagent3.xyz/skills/8004-skill-monad/agent",
    "manifestUrl": "https://openagent3.xyz/skills/8004-skill-monad/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/8004-skill-monad/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": "ERC-8004 Identity Skill",
        "body": "Use this skill when the agent must register on the ERC-8004 Identity Registry to obtain an on-chain identity NFT. This identity is required to register as an agent in The CEO Protocol (CEOVault).\n\nReference: EIP-8004 Trustless Agents"
      },
      {
        "title": "Contract Address (Monad Mainnet)",
        "body": "ContractAddressERC-8004 Identity0x8004A169FB4a3325136EB29fA0ceB6D2e539a432"
      },
      {
        "title": "Interface Summary",
        "body": "The Identity Registry is ERC-721 based. Registering mints an NFT to msg.sender; the token ID is the agent ID."
      },
      {
        "title": "Write Functions",
        "body": "FunctionPurposeregister(string agentURI)Register with a URI; mints NFT, returns agentIdregister(string agentURI, MetadataEntry[] metadata)Register with URI and on-chain metadataregister()Register with no URI (set later via setAgentURI)setAgentURI(uint256 agentId, string newURI)Update the agent's URIsetMetadata(uint256 agentId, string metadataKey, bytes metadataValue)Set on-chain metadata"
      },
      {
        "title": "Read Functions (view)",
        "body": "FunctionReturnsUseownerOf(uint256 tokenId)addressCheck who owns an agent NFTtokenURI(uint256 tokenId)stringGet agent URI (same as agentURI)getAgentWallet(uint256 agentId)addressGet wallet linked to agentgetMetadata(uint256 agentId, string metadataKey)bytesGet on-chain metadata"
      },
      {
        "title": "Events",
        "body": "EventUseRegistered(uint256 indexed agentId, string agentURI, address indexed owner)Emitted on mintURIUpdated(uint256 indexed agentId, string newURI, address indexed updatedBy)Emitted on URI changeMetadataSet(uint256 indexed agentId, string indexed metadataKey, string metadataKey, bytes metadataValue)Emitted on metadata set"
      },
      {
        "title": "Registration Data Template",
        "body": "The agentURI must resolve to a JSON document conforming to EIP-8004 registration. Use this template and replace placeholders before hosting (IPFS or data URI):\n\n{\n  \"type\": \"https://eips.ethereum.org/EIPS/eip-8004#registration-v1\",\n  \"name\": \"AGENT_NAME\",\n  \"description\": \"AGENT_DESCRIPTION\",\n  \"image\": \"https://example.com/agent-image.png\",\n  \"services\": [\n    {\n      \"name\": \"A2A\",\n      \"endpoint\": \"https://YOUR_DOMAIN/.well-known/agent-card.json\",\n      \"version\": \"0.3.0\"\n    },\n    {\n      \"name\": \"MCP\",\n      \"endpoint\": \"https://YOUR_DOMAIN/mcp\",\n      \"version\": \"2025-06-18\"\n    }\n  ],\n  \"x402Support\": false,\n  \"active\": true,\n  \"registrations\": [],\n  \"supportedTrust\": [\n    \"reputation\"\n  ]\n}\n\nFieldReplace withAGENT_NAMEAgent display nameAGENT_DESCRIPTIONShort description of capabilitiesimageURL to agent avatar/imageYOUR_DOMAINYour domain for A2A/MCP endpoints (or omit services if not applicable)supportedTrustTrust models (e.g. [\"reputation\"] for CEO Protocol)\n\nFor a minimal CEO Protocol–only registration, you can omit services or set them to empty; supportedTrust: [\"reputation\"] is typical."
      },
      {
        "title": "Automated Scripts (preferred)",
        "body": "The Docker image includes production-ready scripts at:\n\n/opt/erc8004-scripts\n\nSource in workspace:\n\n/root/.openclaw/workspace/skills/8004-skill/scripts"
      },
      {
        "title": "Required env vars for script flow",
        "body": "MONAD_RPC_URL\nMONAD_CHAIN_ID=143 (or pass --chainId)\nAGENT_PRIVATE_KEY\nPINATA_JWT\nPINATA_GATEWAY (recommended for verification fetch)"
      },
      {
        "title": "Script commands",
        "body": "# 1) Register on-chain with empty URI -> returns agentId\nnode /opt/erc8004-scripts/register.mjs --network monad-mainnet\n\n# 2) Build card JSON with registrations[] embedded\nnode /opt/erc8004-scripts/build-card.mjs \\\n  --network monad-mainnet \\\n  --agentId 42 \\\n  --template /root/.openclaw/workspace/skills/8004-skill/assets/registration-template.json \\\n  --name \"CEO-1\" \\\n  --description \"Autonomous strategist for The CEO Protocol\" \\\n  --out /tmp/agent-42.json\n\n# 3) Upload to Pinata -> returns ipfs://CID\nnode /opt/erc8004-scripts/upload-pinata.mjs --file /tmp/agent-42.json\n\n# 4) Set token URI on-chain\nnode /opt/erc8004-scripts/set-agent-uri.mjs \\\n  --network monad-mainnet \\\n  --agentId 42 \\\n  --uri ipfs://CID\n\n# 5) Verify owner, tokenURI, wallet, and registrations[] match\nnode /opt/erc8004-scripts/verify.mjs --network monad-mainnet --agentId 42"
      },
      {
        "title": "One-shot command",
        "body": "node /opt/erc8004-scripts/full-register.mjs \\\n  --network monad-mainnet \\\n  --name \"CEO-1\" \\\n  --description \"Autonomous strategist for The CEO Protocol\" \\\n  --template /root/.openclaw/workspace/skills/8004-skill/assets/registration-template.json \\\n  --outCard /tmp/agent-card.json \\\n  --identityFile /root/.openclaw/workspace/AGENT_IDENTITY.md\n\nThis executes all 4 registration steps (register -> build card -> upload -> set URI) and writes identity state for later CEO Protocol onboarding."
      },
      {
        "title": "Registration Flow",
        "body": "Prerequisites\n\nWallet with MON for gas (use viem-local-signer address to confirm signer).\nagentURI: a URI pointing to your registration JSON (use the template above). Use IPFS (ipfs://...) or a data URI (data:application/json;base64,...).\n\n\n\nCall register(agentURI)\n\nEncode calldata with encodeFunctionData.\nSend via viem-local-signer send-contract.\nParse Registered event or return value for agentId.\n\n\n\nStore agentId\n\nThe returned agentId (token ID) is required for CEO Protocol registerAgent(metadataURI, ceoAmount, erc8004Id).\nPersist it in an identity file (see below)."
      },
      {
        "title": "Identity File Template",
        "body": "After registration, persist the on-chain identity so the agent can reference it for CEO Protocol and other flows. Use this template:\n\n# Agent Identity\n- **Address**: `<NOT SET>`\n- **Agent ID**: `<NOT SET>`\n- **Agent Registry**: `<NOT SET>`\n- **Chain ID**: `<NOT SET>`"
      },
      {
        "title": "How to fill it",
        "body": "FieldSourceExampleAddressviem-local-signer address (signer wallet)0xB4AF3708DA37a485E84b4F09c146eD0A8B7Df5c4Agent IDReturn value from register(agentURI)42Agent RegistryERC-8004 Identity contract (Monad: eip155:143:0x8004A169FB4a3325136EB29fA0ceB6D2e539a432)eip155:143:0x8004A169FB4a3325136EB29fA0ceB6D2e539a432Chain IDMonad mainnet143"
      },
      {
        "title": "How to use it",
        "body": "After registration: Write the identity file to workspace/IDENTITY.md or workspace/AGENT_IDENTITY.md so it is in the agent's context.\nBefore CEO Protocol registerAgent: Read Agent ID from the file — that is erc8004Id.\nConsistency check: Ensure Address matches viem-local-signer address and ownerOf(agentId) on the registry.\n\nExample filled identity:\n\n# Agent Identity\n- **Address**: `0xB4AF3708DA37a485E84b4F09c146eD0A8B7Df5c4`\n- **Agent ID**: `42`\n- **Agent Registry**: `eip155:143:0x8004A169FB4a3325136EB29fA0ceB6D2e539a432`\n- **Chain ID**: `143`"
      },
      {
        "title": "ABI (minimal)",
        "body": "[\n  {\n    \"type\": \"function\",\n    \"name\": \"register\",\n    \"stateMutability\": \"nonpayable\",\n    \"inputs\": [{ \"name\": \"agentURI\", \"type\": \"string\" }],\n    \"outputs\": [{ \"name\": \"agentId\", \"type\": \"uint256\" }]\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"register\",\n    \"stateMutability\": \"nonpayable\",\n    \"inputs\": [\n      { \"name\": \"agentURI\", \"type\": \"string\" },\n      {\n        \"name\": \"metadata\",\n        \"type\": \"tuple[]\",\n        \"components\": [\n          { \"name\": \"metadataKey\", \"type\": \"string\" },\n          { \"name\": \"metadataValue\", \"type\": \"bytes\" }\n        ]\n      }\n    ],\n    \"outputs\": [{ \"name\": \"agentId\", \"type\": \"uint256\" }]\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"register\",\n    \"stateMutability\": \"nonpayable\",\n    \"inputs\": [],\n    \"outputs\": [{ \"name\": \"agentId\", \"type\": \"uint256\" }]\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"setAgentURI\",\n    \"stateMutability\": \"nonpayable\",\n    \"inputs\": [\n      { \"name\": \"agentId\", \"type\": \"uint256\" },\n      { \"name\": \"newURI\", \"type\": \"string\" }\n    ],\n    \"outputs\": []\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"setMetadata\",\n    \"stateMutability\": \"nonpayable\",\n    \"inputs\": [\n      { \"name\": \"agentId\", \"type\": \"uint256\" },\n      { \"name\": \"metadataKey\", \"type\": \"string\" },\n      { \"name\": \"metadataValue\", \"type\": \"bytes\" }\n    ],\n    \"outputs\": []\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"ownerOf\",\n    \"stateMutability\": \"view\",\n    \"inputs\": [{ \"name\": \"tokenId\", \"type\": \"uint256\" }],\n    \"outputs\": [{ \"name\": \"\", \"type\": \"address\" }]\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"tokenURI\",\n    \"stateMutability\": \"view\",\n    \"inputs\": [{ \"name\": \"tokenId\", \"type\": \"uint256\" }],\n    \"outputs\": [{ \"name\": \"\", \"type\": \"string\" }]\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"getAgentWallet\",\n    \"stateMutability\": \"view\",\n    \"inputs\": [{ \"name\": \"agentId\", \"type\": \"uint256\" }],\n    \"outputs\": [{ \"name\": \"\", \"type\": \"address\" }]\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"getMetadata\",\n    \"stateMutability\": \"view\",\n    \"inputs\": [\n      { \"name\": \"agentId\", \"type\": \"uint256\" },\n      { \"name\": \"metadataKey\", \"type\": \"string\" }\n    ],\n    \"outputs\": [{ \"name\": \"\", \"type\": \"bytes\" }]\n  }\n]"
      },
      {
        "title": "Encoding and Sending",
        "body": "Use viem to encode, then viem-local-signer send-contract to broadcast. Example (Node/script):\n\nimport { encodeFunctionData } from \"viem\";\n\nconst ERC8004_IDENTITY = \"0x8004A169FB4a3325136EB29fA0ceB6D2e539a432\";\n\nconst abi = [\n  {\n    type: \"function\",\n    name: \"register\",\n    stateMutability: \"nonpayable\",\n    inputs: [{ name: \"agentURI\", type: \"string\" }],\n    outputs: [{ name: \"agentId\", type: \"uint256\" }],\n  },\n] as const;\n\nconst agentURI = \"ipfs://Qm...\"; // or data:application/json;base64,...\nconst data = encodeFunctionData({\n  abi,\n  functionName: \"register\",\n  args: [agentURI],\n});\n\n// Then run:\n// viem-local-signer send-contract --to 0x8004A169FB4a3325136EB29fA0ceB6D2e539a432 --data <hex> --value-wei 0 --wait"
      },
      {
        "title": "Agent Runbook",
        "body": "Confirm signer: viem-local-signer address\nEnsure wallet has MON for gas.\nPrepare agentURI (IPFS or data URI with registration JSON).\nEncode register(agentURI) with viem.\nPresent tx summary and ask for user confirmation.\nRun viem-local-signer send-contract --to 0x8004A169FB4a3325136EB29fA0ceB6D2e539a432 --data <calldata> --value-wei 0 --wait\nParse receipt/logs for agentId (or read from Registered event).\nWrite identity file (workspace/AGENT_IDENTITY.md or workspace/IDENTITY.md) using the template above with Address, Agent ID, Agent Registry, Chain ID."
      },
      {
        "title": "CEO Protocol Integration",
        "body": "CEOVault requires an ERC-8004 identity before registerAgent:\n\nCEOVault.registerAgent(metadataURI, ceoAmount, erc8004Id)\n\nerc8004Id = the token ID from ERC8004Identity.register(...).\nCaller must own that NFT (ownerOf(erc8004Id) == msg.sender)."
      },
      {
        "title": "Block Explorer",
        "body": "Monad: https://monadscan.com/\nTx link: https://monadscan.com/tx/<hash>\nContract: https://monadscan.com/address/0x8004A169FB4a3325136EB29fA0ceB6D2e539a432"
      }
    ],
    "body": "ERC-8004 Identity Skill\n\nUse this skill when the agent must register on the ERC-8004 Identity Registry to obtain an on-chain identity NFT. This identity is required to register as an agent in The CEO Protocol (CEOVault).\n\nReference: EIP-8004 Trustless Agents\n\nContract Address (Monad Mainnet)\nContract\tAddress\nERC-8004 Identity\t0x8004A169FB4a3325136EB29fA0ceB6D2e539a432\nInterface Summary\n\nThe Identity Registry is ERC-721 based. Registering mints an NFT to msg.sender; the token ID is the agent ID.\n\nWrite Functions\nFunction\tPurpose\nregister(string agentURI)\tRegister with a URI; mints NFT, returns agentId\nregister(string agentURI, MetadataEntry[] metadata)\tRegister with URI and on-chain metadata\nregister()\tRegister with no URI (set later via setAgentURI)\nsetAgentURI(uint256 agentId, string newURI)\tUpdate the agent's URI\nsetMetadata(uint256 agentId, string metadataKey, bytes metadataValue)\tSet on-chain metadata\nRead Functions (view)\nFunction\tReturns\tUse\nownerOf(uint256 tokenId)\taddress\tCheck who owns an agent NFT\ntokenURI(uint256 tokenId)\tstring\tGet agent URI (same as agentURI)\ngetAgentWallet(uint256 agentId)\taddress\tGet wallet linked to agent\ngetMetadata(uint256 agentId, string metadataKey)\tbytes\tGet on-chain metadata\nEvents\nEvent\tUse\nRegistered(uint256 indexed agentId, string agentURI, address indexed owner)\tEmitted on mint\nURIUpdated(uint256 indexed agentId, string newURI, address indexed updatedBy)\tEmitted on URI change\nMetadataSet(uint256 indexed agentId, string indexed metadataKey, string metadataKey, bytes metadataValue)\tEmitted on metadata set\nRegistration Data Template\n\nThe agentURI must resolve to a JSON document conforming to EIP-8004 registration. Use this template and replace placeholders before hosting (IPFS or data URI):\n\n{\n  \"type\": \"https://eips.ethereum.org/EIPS/eip-8004#registration-v1\",\n  \"name\": \"AGENT_NAME\",\n  \"description\": \"AGENT_DESCRIPTION\",\n  \"image\": \"https://example.com/agent-image.png\",\n  \"services\": [\n    {\n      \"name\": \"A2A\",\n      \"endpoint\": \"https://YOUR_DOMAIN/.well-known/agent-card.json\",\n      \"version\": \"0.3.0\"\n    },\n    {\n      \"name\": \"MCP\",\n      \"endpoint\": \"https://YOUR_DOMAIN/mcp\",\n      \"version\": \"2025-06-18\"\n    }\n  ],\n  \"x402Support\": false,\n  \"active\": true,\n  \"registrations\": [],\n  \"supportedTrust\": [\n    \"reputation\"\n  ]\n}\n\nField\tReplace with\nAGENT_NAME\tAgent display name\nAGENT_DESCRIPTION\tShort description of capabilities\nimage\tURL to agent avatar/image\nYOUR_DOMAIN\tYour domain for A2A/MCP endpoints (or omit services if not applicable)\nsupportedTrust\tTrust models (e.g. [\"reputation\"] for CEO Protocol)\n\nFor a minimal CEO Protocol–only registration, you can omit services or set them to empty; supportedTrust: [\"reputation\"] is typical.\n\nAutomated Scripts (preferred)\n\nThe Docker image includes production-ready scripts at:\n\n/opt/erc8004-scripts\n\nSource in workspace:\n\n/root/.openclaw/workspace/skills/8004-skill/scripts\n\nRequired env vars for script flow\nMONAD_RPC_URL\nMONAD_CHAIN_ID=143 (or pass --chainId)\nAGENT_PRIVATE_KEY\nPINATA_JWT\nPINATA_GATEWAY (recommended for verification fetch)\nScript commands\n# 1) Register on-chain with empty URI -> returns agentId\nnode /opt/erc8004-scripts/register.mjs --network monad-mainnet\n\n# 2) Build card JSON with registrations[] embedded\nnode /opt/erc8004-scripts/build-card.mjs \\\n  --network monad-mainnet \\\n  --agentId 42 \\\n  --template /root/.openclaw/workspace/skills/8004-skill/assets/registration-template.json \\\n  --name \"CEO-1\" \\\n  --description \"Autonomous strategist for The CEO Protocol\" \\\n  --out /tmp/agent-42.json\n\n# 3) Upload to Pinata -> returns ipfs://CID\nnode /opt/erc8004-scripts/upload-pinata.mjs --file /tmp/agent-42.json\n\n# 4) Set token URI on-chain\nnode /opt/erc8004-scripts/set-agent-uri.mjs \\\n  --network monad-mainnet \\\n  --agentId 42 \\\n  --uri ipfs://CID\n\n# 5) Verify owner, tokenURI, wallet, and registrations[] match\nnode /opt/erc8004-scripts/verify.mjs --network monad-mainnet --agentId 42\n\nOne-shot command\nnode /opt/erc8004-scripts/full-register.mjs \\\n  --network monad-mainnet \\\n  --name \"CEO-1\" \\\n  --description \"Autonomous strategist for The CEO Protocol\" \\\n  --template /root/.openclaw/workspace/skills/8004-skill/assets/registration-template.json \\\n  --outCard /tmp/agent-card.json \\\n  --identityFile /root/.openclaw/workspace/AGENT_IDENTITY.md\n\n\nThis executes all 4 registration steps (register -> build card -> upload -> set URI) and writes identity state for later CEO Protocol onboarding.\n\nRegistration Flow\n\nPrerequisites\n\nWallet with MON for gas (use viem-local-signer address to confirm signer).\nagentURI: a URI pointing to your registration JSON (use the template above). Use IPFS (ipfs://...) or a data URI (data:application/json;base64,...).\n\nCall register(agentURI)\n\nEncode calldata with encodeFunctionData.\nSend via viem-local-signer send-contract.\nParse Registered event or return value for agentId.\n\nStore agentId\n\nThe returned agentId (token ID) is required for CEO Protocol registerAgent(metadataURI, ceoAmount, erc8004Id).\nPersist it in an identity file (see below).\nIdentity File Template\n\nAfter registration, persist the on-chain identity so the agent can reference it for CEO Protocol and other flows. Use this template:\n\n# Agent Identity\n- **Address**: `<NOT SET>`\n- **Agent ID**: `<NOT SET>`\n- **Agent Registry**: `<NOT SET>`\n- **Chain ID**: `<NOT SET>`\n\nHow to fill it\nField\tSource\tExample\nAddress\tviem-local-signer address (signer wallet)\t0xB4AF3708DA37a485E84b4F09c146eD0A8B7Df5c4\nAgent ID\tReturn value from register(agentURI)\t42\nAgent Registry\tERC-8004 Identity contract (Monad: eip155:143:0x8004A169FB4a3325136EB29fA0ceB6D2e539a432)\teip155:143:0x8004A169FB4a3325136EB29fA0ceB6D2e539a432\nChain ID\tMonad mainnet\t143\nHow to use it\nAfter registration: Write the identity file to workspace/IDENTITY.md or workspace/AGENT_IDENTITY.md so it is in the agent's context.\nBefore CEO Protocol registerAgent: Read Agent ID from the file — that is erc8004Id.\nConsistency check: Ensure Address matches viem-local-signer address and ownerOf(agentId) on the registry.\n\nExample filled identity:\n\n# Agent Identity\n- **Address**: `0xB4AF3708DA37a485E84b4F09c146eD0A8B7Df5c4`\n- **Agent ID**: `42`\n- **Agent Registry**: `eip155:143:0x8004A169FB4a3325136EB29fA0ceB6D2e539a432`\n- **Chain ID**: `143`\n\nABI (minimal)\n[\n  {\n    \"type\": \"function\",\n    \"name\": \"register\",\n    \"stateMutability\": \"nonpayable\",\n    \"inputs\": [{ \"name\": \"agentURI\", \"type\": \"string\" }],\n    \"outputs\": [{ \"name\": \"agentId\", \"type\": \"uint256\" }]\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"register\",\n    \"stateMutability\": \"nonpayable\",\n    \"inputs\": [\n      { \"name\": \"agentURI\", \"type\": \"string\" },\n      {\n        \"name\": \"metadata\",\n        \"type\": \"tuple[]\",\n        \"components\": [\n          { \"name\": \"metadataKey\", \"type\": \"string\" },\n          { \"name\": \"metadataValue\", \"type\": \"bytes\" }\n        ]\n      }\n    ],\n    \"outputs\": [{ \"name\": \"agentId\", \"type\": \"uint256\" }]\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"register\",\n    \"stateMutability\": \"nonpayable\",\n    \"inputs\": [],\n    \"outputs\": [{ \"name\": \"agentId\", \"type\": \"uint256\" }]\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"setAgentURI\",\n    \"stateMutability\": \"nonpayable\",\n    \"inputs\": [\n      { \"name\": \"agentId\", \"type\": \"uint256\" },\n      { \"name\": \"newURI\", \"type\": \"string\" }\n    ],\n    \"outputs\": []\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"setMetadata\",\n    \"stateMutability\": \"nonpayable\",\n    \"inputs\": [\n      { \"name\": \"agentId\", \"type\": \"uint256\" },\n      { \"name\": \"metadataKey\", \"type\": \"string\" },\n      { \"name\": \"metadataValue\", \"type\": \"bytes\" }\n    ],\n    \"outputs\": []\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"ownerOf\",\n    \"stateMutability\": \"view\",\n    \"inputs\": [{ \"name\": \"tokenId\", \"type\": \"uint256\" }],\n    \"outputs\": [{ \"name\": \"\", \"type\": \"address\" }]\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"tokenURI\",\n    \"stateMutability\": \"view\",\n    \"inputs\": [{ \"name\": \"tokenId\", \"type\": \"uint256\" }],\n    \"outputs\": [{ \"name\": \"\", \"type\": \"string\" }]\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"getAgentWallet\",\n    \"stateMutability\": \"view\",\n    \"inputs\": [{ \"name\": \"agentId\", \"type\": \"uint256\" }],\n    \"outputs\": [{ \"name\": \"\", \"type\": \"address\" }]\n  },\n  {\n    \"type\": \"function\",\n    \"name\": \"getMetadata\",\n    \"stateMutability\": \"view\",\n    \"inputs\": [\n      { \"name\": \"agentId\", \"type\": \"uint256\" },\n      { \"name\": \"metadataKey\", \"type\": \"string\" }\n    ],\n    \"outputs\": [{ \"name\": \"\", \"type\": \"bytes\" }]\n  }\n]\n\nEncoding and Sending\n\nUse viem to encode, then viem-local-signer send-contract to broadcast. Example (Node/script):\n\nimport { encodeFunctionData } from \"viem\";\n\nconst ERC8004_IDENTITY = \"0x8004A169FB4a3325136EB29fA0ceB6D2e539a432\";\n\nconst abi = [\n  {\n    type: \"function\",\n    name: \"register\",\n    stateMutability: \"nonpayable\",\n    inputs: [{ name: \"agentURI\", type: \"string\" }],\n    outputs: [{ name: \"agentId\", type: \"uint256\" }],\n  },\n] as const;\n\nconst agentURI = \"ipfs://Qm...\"; // or data:application/json;base64,...\nconst data = encodeFunctionData({\n  abi,\n  functionName: \"register\",\n  args: [agentURI],\n});\n\n// Then run:\n// viem-local-signer send-contract --to 0x8004A169FB4a3325136EB29fA0ceB6D2e539a432 --data <hex> --value-wei 0 --wait\n\nAgent Runbook\nConfirm signer: viem-local-signer address\nEnsure wallet has MON for gas.\nPrepare agentURI (IPFS or data URI with registration JSON).\nEncode register(agentURI) with viem.\nPresent tx summary and ask for user confirmation.\nRun viem-local-signer send-contract --to 0x8004A169FB4a3325136EB29fA0ceB6D2e539a432 --data <calldata> --value-wei 0 --wait\nParse receipt/logs for agentId (or read from Registered event).\nWrite identity file (workspace/AGENT_IDENTITY.md or workspace/IDENTITY.md) using the template above with Address, Agent ID, Agent Registry, Chain ID.\nCEO Protocol Integration\n\nCEOVault requires an ERC-8004 identity before registerAgent:\n\nCEOVault.registerAgent(metadataURI, ceoAmount, erc8004Id)\n\nerc8004Id = the token ID from ERC8004Identity.register(...).\nCaller must own that NFT (ownerOf(erc8004Id) == msg.sender).\nBlock Explorer\nMonad: https://monadscan.com/\nTx link: https://monadscan.com/tx/<hash>\nContract: https://monadscan.com/address/0x8004A169FB4a3325136EB29fA0ceB6D2e539a432"
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/fabriziogianni7/8004-skill-monad",
    "publisherUrl": "https://clawhub.ai/fabriziogianni7/8004-skill-monad",
    "owner": "fabriziogianni7",
    "version": "1.0.0",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/8004-skill-monad",
    "downloadUrl": "https://openagent3.xyz/downloads/8004-skill-monad",
    "agentUrl": "https://openagent3.xyz/skills/8004-skill-monad/agent",
    "manifestUrl": "https://openagent3.xyz/skills/8004-skill-monad/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/8004-skill-monad/agent.md"
  }
}