contributing

Sử dụng khi đóng góp cho kho lưu trữ Cloudflare Docs — viết hoặc chỉnh sửa các trang tài liệu, chọn loại nội dung hoặc thành phần, thêm changelog…

npx skills add https://github.com/cloudflare/cloudflare-docs --skill contributing

Contributing to Cloudflare Docs

This is the single skill to load for any change to the Cloudflare Docs repository. It does not contain the detail itself — it routes you to the right reference for the task in front of you. Read the reference that matches your task, then follow it.

Do not guess at conventions. The references below are the source of truth for how this repo expects content to be written, structured, and validated.

Canonical references override conflicting local patterns, especially for product section names, folders, and ordering.

Ground rules

These apply to every task below.

  • This is an open-source, public repository. Never put private Cloudflare information, secrets, credentials, internal URLs, or environment variable values into pages, code examples, commits, pull requests, comments, or anywhere else in this repository. If there is any doubt — even slight — about whether something is safe to publish, stop and ask the user.
  • Branch off the latest production. Before starting work, create your branch from an up-to-date production commit (git fetch origin then branch from origin/production), unless the user asks for a different base. This repo's default branch is production, not main.
  • Never commit or push automatically. Make the file changes, then ask the user whether they want to commit and push. Do not run git commit or git push unprompted.

Before you start: gather context

When the source material is thin or ambiguous, pause and ask the user before writing. You need enough to write something accurate, not just well-formatted. Ask for whatever is missing:

  • Source of truth — a PR, RFC, engineering spec, API schema, existing page, or product owner to verify behavior against. Do not invent technical claims.
  • Product and feature area — which Cloudflare product, and where in that product the change belongs.
  • Audience and intent — who reads this and what they are trying to do (get started, look something up, follow a procedure, understand a concept).
  • Availability — plan availability (Free/Pro/Business/Enterprise) and lifecycle status (GA, Beta, Alpha).
  • Scope — is this a new page, an edit, a restructure, or a changelog entry.

If the user already provided a clear spec or PR, proceed without interrogating them.

Task index

Find your task and read the listed reference(s). Paths are relative to this skill directory unless prefixed with .agents/.

Your taskRead
Write or edit a documentation pagereferences/writing-docs.md (the authoring workflow — start here)
Decide which pcx_content_type and page shapereferences/content-types.md
Decide how to present data / which componentreferences/choosing-components.md
Decide where a page belongs, redirects, reusereferences/information-architecture.md
Look up writing and formatting rules.agents/references/style-guide.md (canonical) and .agents/references/procedures.md for step-by-steps
Look up a component's props and examples.agents/references/components.md
Add or edit a changelog entryreferences/changelog.md
Review docs / post PR suggestionsreferences/reviewing-docs.md

The authoring workflow in references/writing-docs.md ties these together: gather context → locate where the page belongs → pick a content type → draft against the style guide → choose components for each piece of data → validate.

Validate before you finish

Run validation after any content change. Match the command set to your environment — a full build is local-only.

pnpm run check              # Type-check: validates frontmatter schemas + Astro types
pnpm run build              # Full build: validates MDX parsing, image paths, internal links — LOCAL ONLY (times out in CI)
pnpm run format             # Auto-fix Prettier formatting on edited files

In CI (CI=true), skip pnpm run build; run pnpm run check, pnpm run lint, and pnpm run format:core:check only.

If you modified public/__redirects, also run:

pnpm exec tsm bin/validate-redirects.ts

Always run pnpm run format on files you touched — CI fails on unformatted content.

Thêm skills từ cloudflare

dependabot-review
cloudflare
Phân tích một PR Dependabot để xác định những gì thực sự thay đổi trong từng gói được nâng cấp và liệu những thay đổi đó có ảnh hưởng đến repo này hay không. Báo cáo các API/phương thức đã thay đổi,…
module-registry
cloudflare
Tải khi làm việc với module registry trong workerd — đọc, sửa đổi, gỡ lỗi hoặc xem xét việc phân giải, biên dịch, đánh giá hoặc đăng ký module…
reproduce
cloudflare
Tái tạo một vấn đề GitHub của cloudflare/agents bằng cách tạo khung một dự án Agents/Worker tối thiểu và triển khai nó lên một tài khoản Cloudflare tạm thời, sau đó báo cáo…
local-explorer
cloudflare
Cách thêm sản phẩm/tài nguyên vào local explorer hoặc local API. Sử dụng khi triển khai các local API mới hoặc các route UI trong…
open-pr
cloudflare
Lấy một issue GitHub từ cloudflare/agents cùng với các phát hiện tái hiện lỗi và tạo một PR sửa lỗi một lần — tạo nhánh, thay đổi, kiểm thử, đẩy lên, và mở PR liên kết với issue đó.
write-endpoints
cloudflare
Hướng dẫn toàn diện để xây dựng các điểm cuối OpenAPI với chanfana - định nghĩa schema, xác thực yêu cầu, các thao tác CRUD, tích hợp cơ sở dữ liệu D1, và…
agents-sdk
cloudflare
Xây dựng AI agent trên Cloudflare Workers bằng Agents SDK. Tải khi tạo agent có trạng thái, quy trình làm việc bền vững, ứng dụng WebSocket thời gian thực, tác vụ theo lịch trình,…
changelog
cloudflare
Tạo, cập nhật và xem xét các mục nhật ký thay đổi sản phẩm cho trang tài liệu Cloudflare. Tải khi tạo tệp MDX nhật ký thay đổi, chỉnh sửa các tệp hiện có…