{
  "schemaVersion": "1.0",
  "item": {
    "slug": "umami-setup",
    "name": "umami-setup",
    "source": "tencent",
    "type": "skill",
    "category": "数据分析",
    "sourceUrl": "https://clawhub.ai/superWorldSavior/umami-setup",
    "canonicalUrl": "https://clawhub.ai/superWorldSavior/umami-setup",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/umami-setup",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=umami-setup",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "SKILL.md"
    ],
    "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": "umami-setup",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-04-30T16:58:14.021Z",
      "expiresAt": "2026-05-07T16:58:14.021Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=umami-setup",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=umami-setup",
        "contentDisposition": "attachment; filename=\"umami-setup-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null,
        "slug": "umami-setup"
      },
      "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/umami-setup"
    },
    "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/umami-setup",
    "agentPageUrl": "https://openagent3.xyz/skills/umami-setup/agent",
    "manifestUrl": "https://openagent3.xyz/skills/umami-setup/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/umami-setup/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": "Overview",
        "body": "Self-hosted Umami analytics with a same-domain proxy to bypass adblockers. The script is served from the same domain as your site, so blockers see it as first-party."
      },
      {
        "title": "Prerequisites",
        "body": "A running Umami instance (self-hosted, e.g. analytics.casys.ai)\nAdmin credentials for Umami\nAccess to the website's codebase for proxy configuration"
      },
      {
        "title": "Step 1: Create the website in Umami",
        "body": "# Login\nTOKEN=$(curl -s -X POST \"https://<UMAMI_HOST>/api/auth/login\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\"username\":\"admin\",\"password\":\"<PASSWORD>\"}' \\\n  | python3 -c \"import json,sys; print(json.load(sys.stdin)['token'])\")\n\n# Create website\ncurl -s -X POST \"https://<UMAMI_HOST>/api/websites\" \\\n  -H \"Authorization: Bearer $TOKEN\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\"name\":\"<SITE_NAME>\",\"domain\":\"<DOMAIN>\"}' | python3 -m json.tool\n\nSave the id from the response — that's your data-website-id."
      },
      {
        "title": "Step 2: Set up the proxy",
        "body": "The proxy serves the Umami script and send endpoint from your own domain. Adblockers can't distinguish it from your own assets.\n\nPick the method matching your stack:"
      },
      {
        "title": "Next.js (rewrites in next.config.ts)",
        "body": "// next.config.ts\nconst nextConfig: NextConfig = {\n  async rewrites() {\n    return [\n      {\n        source: \"/u/script.js\",\n        destination: \"https://<UMAMI_HOST>/script.js\",\n      },\n      {\n        source: \"/u/api/send\",\n        destination: \"https://<UMAMI_HOST>/api/send\",\n      },\n    ];\n  },\n};\n\nThen add to your layout:\n\n<script defer src=\"/u/script.js\" data-website-id=\"<WEBSITE_ID>\"></script>"
      },
      {
        "title": "Astro + Vercel (rewrites in vercel.json)",
        "body": "{\n  \"rewrites\": [\n    {\n      \"source\": \"/u/script.js\",\n      \"destination\": \"https://<UMAMI_HOST>/script.js\"\n    },\n    {\n      \"source\": \"/u/api/send\",\n      \"destination\": \"https://<UMAMI_HOST>/api/send\"\n    }\n  ]\n}\n\nThen add before </head> in your layout(s):\n\n<script defer src=\"/u/script.js\" data-website-id=\"<WEBSITE_ID>\"></script>"
      },
      {
        "title": "Caddy (reverse proxy)",
        "body": "example.com {\n    handle /u/script.js {\n        rewrite * /script.js\n        reverse_proxy https://<UMAMI_HOST> {\n            header_up Host <UMAMI_HOST>\n        }\n    }\n    handle /u/api/send {\n        rewrite * /api/send\n        reverse_proxy https://<UMAMI_HOST> {\n            header_up Host <UMAMI_HOST>\n        }\n    }\n}"
      },
      {
        "title": "Nginx",
        "body": "location /u/script.js {\n    proxy_pass https://<UMAMI_HOST>/script.js;\n    proxy_set_header Host <UMAMI_HOST>;\n}\nlocation /u/api/send {\n    proxy_pass https://<UMAMI_HOST>/api/send;\n    proxy_set_header Host <UMAMI_HOST>;\n}"
      },
      {
        "title": "Step 3: Verify",
        "body": "Deploy the proxy config\nVisit your site in a browser\nCheck Umami dashboard — you should see a pageview within seconds\nTest with adblocker enabled — visit again with uBlock Origin on; the pageview should still appear\nVerify the proxy works: curl -sI https://<YOUR_DOMAIN>/u/script.js should return 200"
      },
      {
        "title": "Proxy path convention",
        "body": "Use /u/ as the proxy prefix. It's short, non-obvious to blockers, and consistent across projects:\n\nProjectProxy pathUmami hostthenocodeguy.com/umami/script.jsanalytics.casys.aicasys.ai/u/script.jsanalytics.casys.ai"
      },
      {
        "title": "Umami API — quick reference",
        "body": "# Get all websites\ncurl -s -H \"Authorization: Bearer $TOKEN\" \"https://<UMAMI_HOST>/api/websites\"\n\n# Get stats for a website (last 24h)\nSTART=$(($(date +%s) * 1000 - 86400000))\nEND=$(($(date +%s) * 1000))\ncurl -s -H \"Authorization: Bearer $TOKEN\" \\\n  \"https://<UMAMI_HOST>/api/websites/<WEBSITE_ID>/stats?startAt=$START&endAt=$END\"\n\n# Get pageviews\ncurl -s -H \"Authorization: Bearer $TOKEN\" \\\n  \"https://<UMAMI_HOST>/api/websites/<WEBSITE_ID>/pageviews?startAt=$START&endAt=$END&unit=day\""
      },
      {
        "title": "Notes",
        "body": "The Umami instance should be behind a reverse proxy with HTTPS (e.g. Cloudflare → Caddy → localhost:3002)\nDocker bind on 127.0.0.1 only — never expose Umami directly to the internet\nThe /u/ prefix can be anything — /stats/, /t/, etc. — as long as it doesn't conflict with existing routes"
      }
    ],
    "body": "umami-setup — Add analytics to a new website\nOverview\n\nSelf-hosted Umami analytics with a same-domain proxy to bypass adblockers. The script is served from the same domain as your site, so blockers see it as first-party.\n\nPrerequisites\nA running Umami instance (self-hosted, e.g. analytics.casys.ai)\nAdmin credentials for Umami\nAccess to the website's codebase for proxy configuration\nStep 1: Create the website in Umami\n# Login\nTOKEN=$(curl -s -X POST \"https://<UMAMI_HOST>/api/auth/login\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\"username\":\"admin\",\"password\":\"<PASSWORD>\"}' \\\n  | python3 -c \"import json,sys; print(json.load(sys.stdin)['token'])\")\n\n# Create website\ncurl -s -X POST \"https://<UMAMI_HOST>/api/websites\" \\\n  -H \"Authorization: Bearer $TOKEN\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\"name\":\"<SITE_NAME>\",\"domain\":\"<DOMAIN>\"}' | python3 -m json.tool\n\n\nSave the id from the response — that's your data-website-id.\n\nStep 2: Set up the proxy\n\nThe proxy serves the Umami script and send endpoint from your own domain. Adblockers can't distinguish it from your own assets.\n\nPick the method matching your stack:\n\nNext.js (rewrites in next.config.ts)\n// next.config.ts\nconst nextConfig: NextConfig = {\n  async rewrites() {\n    return [\n      {\n        source: \"/u/script.js\",\n        destination: \"https://<UMAMI_HOST>/script.js\",\n      },\n      {\n        source: \"/u/api/send\",\n        destination: \"https://<UMAMI_HOST>/api/send\",\n      },\n    ];\n  },\n};\n\n\nThen add to your layout:\n\n<script defer src=\"/u/script.js\" data-website-id=\"<WEBSITE_ID>\"></script>\n\nAstro + Vercel (rewrites in vercel.json)\n{\n  \"rewrites\": [\n    {\n      \"source\": \"/u/script.js\",\n      \"destination\": \"https://<UMAMI_HOST>/script.js\"\n    },\n    {\n      \"source\": \"/u/api/send\",\n      \"destination\": \"https://<UMAMI_HOST>/api/send\"\n    }\n  ]\n}\n\n\nThen add before </head> in your layout(s):\n\n<script defer src=\"/u/script.js\" data-website-id=\"<WEBSITE_ID>\"></script>\n\nCaddy (reverse proxy)\nexample.com {\n    handle /u/script.js {\n        rewrite * /script.js\n        reverse_proxy https://<UMAMI_HOST> {\n            header_up Host <UMAMI_HOST>\n        }\n    }\n    handle /u/api/send {\n        rewrite * /api/send\n        reverse_proxy https://<UMAMI_HOST> {\n            header_up Host <UMAMI_HOST>\n        }\n    }\n}\n\nNginx\nlocation /u/script.js {\n    proxy_pass https://<UMAMI_HOST>/script.js;\n    proxy_set_header Host <UMAMI_HOST>;\n}\nlocation /u/api/send {\n    proxy_pass https://<UMAMI_HOST>/api/send;\n    proxy_set_header Host <UMAMI_HOST>;\n}\n\nStep 3: Verify\nDeploy the proxy config\nVisit your site in a browser\nCheck Umami dashboard — you should see a pageview within seconds\nTest with adblocker enabled — visit again with uBlock Origin on; the pageview should still appear\nVerify the proxy works: curl -sI https://<YOUR_DOMAIN>/u/script.js should return 200\nProxy path convention\n\nUse /u/ as the proxy prefix. It's short, non-obvious to blockers, and consistent across projects:\n\nProject\tProxy path\tUmami host\nthenocodeguy.com\t/umami/script.js\tanalytics.casys.ai\ncasys.ai\t/u/script.js\tanalytics.casys.ai\nUmami API — quick reference\n# Get all websites\ncurl -s -H \"Authorization: Bearer $TOKEN\" \"https://<UMAMI_HOST>/api/websites\"\n\n# Get stats for a website (last 24h)\nSTART=$(($(date +%s) * 1000 - 86400000))\nEND=$(($(date +%s) * 1000))\ncurl -s -H \"Authorization: Bearer $TOKEN\" \\\n  \"https://<UMAMI_HOST>/api/websites/<WEBSITE_ID>/stats?startAt=$START&endAt=$END\"\n\n# Get pageviews\ncurl -s -H \"Authorization: Bearer $TOKEN\" \\\n  \"https://<UMAMI_HOST>/api/websites/<WEBSITE_ID>/pageviews?startAt=$START&endAt=$END&unit=day\"\n\nNotes\nThe Umami instance should be behind a reverse proxy with HTTPS (e.g. Cloudflare → Caddy → localhost:3002)\nDocker bind on 127.0.0.1 only — never expose Umami directly to the internet\nThe /u/ prefix can be anything — /stats/, /t/, etc. — as long as it doesn't conflict with existing routes"
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/superWorldSavior/umami-setup",
    "publisherUrl": "https://clawhub.ai/superWorldSavior/umami-setup",
    "owner": "superWorldSavior",
    "version": "1.0.0",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/umami-setup",
    "downloadUrl": "https://openagent3.xyz/downloads/umami-setup",
    "agentUrl": "https://openagent3.xyz/skills/umami-setup/agent",
    "manifestUrl": "https://openagent3.xyz/skills/umami-setup/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/umami-setup/agent.md"
  }
}