{
  "schemaVersion": "1.0",
  "item": {
    "slug": "astro",
    "name": "Astro",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/bezkom/astro",
    "canonicalUrl": "https://clawhub.ai/bezkom/astro",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/astro",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=astro",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "SKILL.md",
      "_meta.json",
      "scripts/astro-i18n-check.py",
      "scripts/astro-new-post.py"
    ],
    "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-23T16:43:11.935Z",
      "expiresAt": "2026-04-30T16:43:11.935Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=4claw-imageboard",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=4claw-imageboard",
        "contentDisposition": "attachment; filename=\"4claw-imageboard-1.0.1.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/astro"
    },
    "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/astro",
    "agentPageUrl": "https://openagent3.xyz/skills/astro/agent",
    "manifestUrl": "https://openagent3.xyz/skills/astro/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/astro/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": "Astro Static Site Generator",
        "body": "Deploy multilingual static websites for free on Cloudflare using Astro framework."
      },
      {
        "title": "Prerequisites",
        "body": "Node.js 20+ installed\nCloudflare account (free)\nGit repository (GitHub, GitLab, or Bitbucket)"
      },
      {
        "title": "1. Create Project",
        "body": "npm create astro@latest my-site -- --template minimal\ncd my-site\nnpm install"
      },
      {
        "title": "2. Configure for Cloudflare",
        "body": "Static Sites (Recommended for most use cases)\n\nNo adapter needed. Use default static output:\n\n// astro.config.mjs\nimport { defineConfig } from 'astro/config';\n\nexport default defineConfig({\n  site: 'https://your-site.pages.dev',\n});\n\nSSR/Edge Functions (Optional)\n\nIf you need server-side rendering or edge functions:\n\nnpm install @astrojs/cloudflare\n\n// astro.config.mjs\nimport { defineConfig } from 'astro/config';\nimport cloudflare from '@astrojs/cloudflare';\n\nexport default defineConfig({\n  output: 'server',\n  adapter: cloudflare(),\n  site: 'https://your-site.pages.dev',\n});"
      },
      {
        "title": "3. Deploy to Cloudflare",
        "body": "Git Integration (Recommended)\n\nPush to GitHub/GitLab\nCloudflare Dashboard → Pages → Create project → Connect to Git\nConfigure:\n\nBuild command: npm run build\nBuild output: dist\n\nDirect Upload\n\n# Deploy (authenticate via Cloudflare dashboard or wrangler)\nnpx wrangler pages deploy dist"
      },
      {
        "title": "Astro Config",
        "body": "// astro.config.mjs\nexport default defineConfig({\n  i18n: {\n    defaultLocale: 'en',\n    locales: ['en', 'es', 'fr', 'de'],\n    routing: {\n      prefixDefaultLocale: false,  // /about instead of /en/about\n    },\n  },\n});\n\nRouting Modes:\n\nSettingURL StructureBest ForprefixDefaultLocale: false/about, /es/aboutDefault locale at rootprefixDefaultLocale: true/en/about, /es/aboutAll locales prefixed"
      },
      {
        "title": "Content Structure",
        "body": "src/content/\n├── config.ts          # Content collection schema\n└── docs/\n    ├── en/\n    │   ├── index.md\n    │   └── guide.md\n    ├── es/\n    │   ├── index.md\n    │   └── guide.md\n    └── fr/\n        ├── index.md\n        └── guide.md"
      },
      {
        "title": "Content Collection Schema",
        "body": "// src/content/config.ts\nimport { defineCollection, z } from 'astro:content';\n\nconst docs = defineCollection({\n  type: 'content',\n  schema: z.object({\n    title: z.string(),\n    description: z.string(),\n    lang: z.enum(['en', 'es', 'fr', 'de']),\n  }),\n});\n\nexport const collections = { docs };\n\nNote: Run npx astro sync after adding content collections to generate types."
      },
      {
        "title": "Language Switcher Component",
        "body": "---\n// src/components/LanguageSwitcher.astro\nconst languages = {\n  en: 'English',\n  es: 'Español',\n  fr: 'Français',\n  de: 'Deutsch',\n};\n\nconst currentPath = Astro.url.pathname;\nconst currentLang = Astro.currentLocale || 'en';\n---\n\n<select onchange=\"window.location = this.value\">\n  {Object.entries(languages).map(([code, name]) => (\n    <option \n      value={`/${code}${currentPath}`} \n      selected={code === currentLang}\n    >\n      {name}\n    </option>\n  ))}\n</select>"
      },
      {
        "title": "File Structure",
        "body": "my-site/\n├── astro.config.mjs      # Astro configuration\n├── package.json\n├── public/\n│   ├── favicon.svg\n│   └── _redirects        # Cloudflare redirects (optional)\n├── src/\n│   ├── components/\n│   │   └── LanguageSwitcher.astro\n│   ├── content/\n│   │   ├── config.ts\n│   │   └── blog/\n│   │       ├── en/\n│   │       └── es/\n│   ├── layouts/\n│   │   └── BaseLayout.astro\n│   └── pages/\n│       ├── index.astro\n│       ├── en/\n│       │   └── index.astro\n│       └── es/\n│           └── index.astro"
      },
      {
        "title": "Cloudflare Pages Settings",
        "body": "SettingValueBuild commandnpm run buildBuild outputdistNode version20EnvironmentNODE_VERSION=20"
      },
      {
        "title": "Custom Domain",
        "body": "Cloudflare Dashboard → Pages → your-site → Custom domains → Add domain"
      },
      {
        "title": "Redirects",
        "body": "Create public/_redirects:\n\n/  /en/  302\n/old-page  /new-page  301"
      },
      {
        "title": "Commands Reference",
        "body": "CommandDescriptionnpm run devStart dev servernpm run buildBuild for productionnpm run previewPreview production buildnpx astro syncGenerate content collection typesnpx wrangler loginAuthenticate with Cloudflarenpx wrangler pages deploy distDeploy to Cloudflare"
      },
      {
        "title": "Blog with Content Collections",
        "body": "---\n// src/pages/blog/[...slug].astro\nimport { getCollection } from 'astro:content';\n\nexport async function getStaticPaths() {\n  const posts = await getCollection('blog');\n  return posts.map(post => ({\n    params: { slug: post.slug },\n    props: { post },\n  }));\n}\n\nconst { post } = Astro.props;\nconst { Content } = await post.render();\n---\n\n<article>\n  <h1>{post.data.title}</h1>\n  <Content />\n</article>"
      },
      {
        "title": "Build Fails on Cloudflare",
        "body": "Set NODE_VERSION=20 in Cloudflare Pages environment variables."
      },
      {
        "title": "404 on Nested Routes",
        "body": "// astro.config.mjs\nexport default defineConfig({\n  trailingSlash: 'always',\n});"
      },
      {
        "title": "i18n Not Working",
        "body": "Ensure:\n\nLocales match folder names exactly\nContent files have correct lang frontmatter\nRun npx astro sync after creating content collections"
      },
      {
        "title": "Content Collection Type Errors",
        "body": "Run npx astro sync to generate TypeScript types."
      },
      {
        "title": "Resources",
        "body": "Astro Docs\nCloudflare Pages Docs\nAstro i18n Guide\nCloudflare Adapter"
      },
      {
        "title": "Scripts",
        "body": "ScriptDescriptionastro-new-post.pyCreate multilingual blog postsastro-i18n-check.pyValidate translation coverage"
      },
      {
        "title": "Script Usage",
        "body": "# Create a new post in multiple languages\npython scripts/astro-new-post.py --title \"My Post\" --langs en,es,fr\n\n# Create with author and tags\npython scripts/astro-new-post.py --title \"Tutorial\" --langs en,es --author \"John\" --tags tutorial,astro\n\n# Check translation coverage\npython scripts/astro-i18n-check.py --langs en,es,fr\n\n# Check specific content directory\npython scripts/astro-i18n-check.py --content-dir src/content/blog --langs en,es\n\n# Output as JSON\npython scripts/astro-i18n-check.py --langs en,es,fr --json\n\nAll scripts use only Python standard library (no dependencies)."
      }
    ],
    "body": "Astro Static Site Generator\n\nDeploy multilingual static websites for free on Cloudflare using Astro framework.\n\nPrerequisites\nNode.js 20+ installed\nCloudflare account (free)\nGit repository (GitHub, GitLab, or Bitbucket)\nQuick Start\n1. Create Project\nnpm create astro@latest my-site -- --template minimal\ncd my-site\nnpm install\n\n2. Configure for Cloudflare\n\nStatic Sites (Recommended for most use cases)\n\nNo adapter needed. Use default static output:\n\n// astro.config.mjs\nimport { defineConfig } from 'astro/config';\n\nexport default defineConfig({\n  site: 'https://your-site.pages.dev',\n});\n\n\nSSR/Edge Functions (Optional)\n\nIf you need server-side rendering or edge functions:\n\nnpm install @astrojs/cloudflare\n\n// astro.config.mjs\nimport { defineConfig } from 'astro/config';\nimport cloudflare from '@astrojs/cloudflare';\n\nexport default defineConfig({\n  output: 'server',\n  adapter: cloudflare(),\n  site: 'https://your-site.pages.dev',\n});\n\n3. Deploy to Cloudflare\n\nGit Integration (Recommended)\n\nPush to GitHub/GitLab\nCloudflare Dashboard → Pages → Create project → Connect to Git\nConfigure:\nBuild command: npm run build\nBuild output: dist\n\nDirect Upload\n\n# Deploy (authenticate via Cloudflare dashboard or wrangler)\nnpx wrangler pages deploy dist\n\nMultilingual Configuration\nAstro Config\n// astro.config.mjs\nexport default defineConfig({\n  i18n: {\n    defaultLocale: 'en',\n    locales: ['en', 'es', 'fr', 'de'],\n    routing: {\n      prefixDefaultLocale: false,  // /about instead of /en/about\n    },\n  },\n});\n\n\nRouting Modes:\n\nSetting\tURL Structure\tBest For\nprefixDefaultLocale: false\t/about, /es/about\tDefault locale at root\nprefixDefaultLocale: true\t/en/about, /es/about\tAll locales prefixed\nContent Structure\nsrc/content/\n├── config.ts          # Content collection schema\n└── docs/\n    ├── en/\n    │   ├── index.md\n    │   └── guide.md\n    ├── es/\n    │   ├── index.md\n    │   └── guide.md\n    └── fr/\n        ├── index.md\n        └── guide.md\n\nContent Collection Schema\n// src/content/config.ts\nimport { defineCollection, z } from 'astro:content';\n\nconst docs = defineCollection({\n  type: 'content',\n  schema: z.object({\n    title: z.string(),\n    description: z.string(),\n    lang: z.enum(['en', 'es', 'fr', 'de']),\n  }),\n});\n\nexport const collections = { docs };\n\n\nNote: Run npx astro sync after adding content collections to generate types.\n\nLanguage Switcher Component\n---\n// src/components/LanguageSwitcher.astro\nconst languages = {\n  en: 'English',\n  es: 'Español',\n  fr: 'Français',\n  de: 'Deutsch',\n};\n\nconst currentPath = Astro.url.pathname;\nconst currentLang = Astro.currentLocale || 'en';\n---\n\n<select onchange=\"window.location = this.value\">\n  {Object.entries(languages).map(([code, name]) => (\n    <option \n      value={`/${code}${currentPath}`} \n      selected={code === currentLang}\n    >\n      {name}\n    </option>\n  ))}\n</select>\n\nFile Structure\nmy-site/\n├── astro.config.mjs      # Astro configuration\n├── package.json\n├── public/\n│   ├── favicon.svg\n│   └── _redirects        # Cloudflare redirects (optional)\n├── src/\n│   ├── components/\n│   │   └── LanguageSwitcher.astro\n│   ├── content/\n│   │   ├── config.ts\n│   │   └── blog/\n│   │       ├── en/\n│   │       └── es/\n│   ├── layouts/\n│   │   └── BaseLayout.astro\n│   └── pages/\n│       ├── index.astro\n│       ├── en/\n│       │   └── index.astro\n│       └── es/\n│           └── index.astro\n\nCloudflare Pages Settings\nSetting\tValue\nBuild command\tnpm run build\nBuild output\tdist\nNode version\t20\nEnvironment\tNODE_VERSION=20\nCustom Domain\n\nCloudflare Dashboard → Pages → your-site → Custom domains → Add domain\n\nRedirects\n\nCreate public/_redirects:\n\n/  /en/  302\n/old-page  /new-page  301\n\nCommands Reference\nCommand\tDescription\nnpm run dev\tStart dev server\nnpm run build\tBuild for production\nnpm run preview\tPreview production build\nnpx astro sync\tGenerate content collection types\nnpx wrangler login\tAuthenticate with Cloudflare\nnpx wrangler pages deploy dist\tDeploy to Cloudflare\nBlog with Content Collections\n---\n// src/pages/blog/[...slug].astro\nimport { getCollection } from 'astro:content';\n\nexport async function getStaticPaths() {\n  const posts = await getCollection('blog');\n  return posts.map(post => ({\n    params: { slug: post.slug },\n    props: { post },\n  }));\n}\n\nconst { post } = Astro.props;\nconst { Content } = await post.render();\n---\n\n<article>\n  <h1>{post.data.title}</h1>\n  <Content />\n</article>\n\nTroubleshooting\nBuild Fails on Cloudflare\n\nSet NODE_VERSION=20 in Cloudflare Pages environment variables.\n\n404 on Nested Routes\n// astro.config.mjs\nexport default defineConfig({\n  trailingSlash: 'always',\n});\n\ni18n Not Working\n\nEnsure:\n\nLocales match folder names exactly\nContent files have correct lang frontmatter\nRun npx astro sync after creating content collections\nContent Collection Type Errors\n\nRun npx astro sync to generate TypeScript types.\n\nResources\nAstro Docs\nCloudflare Pages Docs\nAstro i18n Guide\nCloudflare Adapter\nScripts\nScript\tDescription\nastro-new-post.py\tCreate multilingual blog posts\nastro-i18n-check.py\tValidate translation coverage\nScript Usage\n# Create a new post in multiple languages\npython scripts/astro-new-post.py --title \"My Post\" --langs en,es,fr\n\n# Create with author and tags\npython scripts/astro-new-post.py --title \"Tutorial\" --langs en,es --author \"John\" --tags tutorial,astro\n\n# Check translation coverage\npython scripts/astro-i18n-check.py --langs en,es,fr\n\n# Check specific content directory\npython scripts/astro-i18n-check.py --content-dir src/content/blog --langs en,es\n\n# Output as JSON\npython scripts/astro-i18n-check.py --langs en,es,fr --json\n\n\nAll scripts use only Python standard library (no dependencies)."
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/bezkom/astro",
    "publisherUrl": "https://clawhub.ai/bezkom/astro",
    "owner": "bezkom",
    "version": "1.0.1",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/astro",
    "downloadUrl": "https://openagent3.xyz/downloads/astro",
    "agentUrl": "https://openagent3.xyz/skills/astro/agent",
    "manifestUrl": "https://openagent3.xyz/skills/astro/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/astro/agent.md"
  }
}