Skip to content

非公式 / UnofficialCloudflare, Inc. 非提携。アカウント情報は入力しないでください。Not affiliated with Cloudflare, Inc. Do not enter Cloudflare credentials here.Official docsこのサイトについてプライバシー

すべてのエージェント
GitHub

GitHub Copilot + Cloudflare

エディター拡張と CLI です。Agent モード、ワークスペースのコンテキスト、ネイティブな PR 連携があります。GitHub 製です。

TerminalCloudExtension

クイックスタート

  1. GitHub Copilot をインストールする

    Visual Studio Marketplace ↗ から、VS Code に GitHub Copilot 拡張機能をインストールします。JetBrains IDE、Visual Studio、Xcode については、Copilot 拡張機能をインストールする ↗ ガイドを参照してください。

  2. Cloudflare Skills をインストールする

    npx skills add https://github.com/cloudflare/skills
  3. Cloudflare MCP サーバーを設定する

    VS Code では .vscode/mcp.json に追加します。Copilot CLI では、ユーザー単位の設定は ~/.copilot/mcp-config.json、プロジェクト単位の設定は .mcp.json または .github/mcp.json に追加します。ドメイン別の MCP サーバーは mcp-server-cloudflare ↗ を参照してください。Cloudflare API 全体向けの MCP サーバー(Code Mode)は cloudflare/mcp ↗ を参照してください。

    {
      "mcpServers": {
        "cloudflare": { "url": "https://mcp.cloudflare.com/mcp" },
        "cloudflare-docs": { "url": "https://docs.mcp.cloudflare.com/mcp" },
        "cloudflare-bindings": { "url": "https://bindings.mcp.cloudflare.com/mcp" },
        "cloudflare-builds": { "url": "https://builds.mcp.cloudflare.com/mcp" },
        "cloudflare-observability": { "url": "https://observability.mcp.cloudflare.com/mcp" }
      }
    }
  4. プロンプトを試す

    Copilot Chat(Ctrl+Shift+I)を開き、エージェントモード(agent mode)に切り替えて、次のようなプロンプトを試します。

    Hyperdrive でコネクションプーリングし、既存の Postgres データベースに Worker をつないでください。

Cloudflare プラットフォームへのアクセス

各セクションを開くと、詳しく読めます。

Cloudflare Skills

Cloudflare の仕組みをエージェントに教える、持続するプラットフォームコンテキストです。

Skills は、エージェントが必要なときに読み込む手順です。 cloudflare/skills バンドルはプラットフォームの各層をカバーします。そのため、毎回説明しなくても、エージェントはあなたの作法を把握します。

  • agents-sdkBuild, debug, or review Cloudflare Agents SDK applications using the agents package.
  • basinBuild and troubleshoot Cloudflare Basin analytics workflows with Basin Pipelines, Basin Catalog, and Basin SQL. Use for streaming data into R2 Iceberg tables, managing catalogs, or querying those tables; also use for requests using the former Data Platform, Pipelines, R2 Data Catalog, or R2 SQL names.
  • cf-cliCloudflare's official cf CLI (beta) for the public Cloudflare API and Workers projects. Use for finding and running Cloudflare commands from the terminal — sign-in and profiles, cf cli search, cf schema, cf deploy/dev/build, resource commands for DNS, zones, D1, KV, and R2 — and for choosing between cf and Wrangler in a project.
  • cloudflareDiscover and choose Cloudflare products for apps, APIs, AI agents, storage, networking, and security. Use for architecture and product selection, including when the user describes a need without naming a Cloudflare product; then find the relevant skill or documentation. Also use when a Cloudflare-proxied site shows a Cloudflare error page, a `52x` status, a 1xxx error code, or a Cloudflare `403`, to decide whether to fix Cloudflare configuration or the origin.
  • cloudflare-app-bootstrapGet a Cloudflare Workers app to a working local request by connecting its bindings, secrets, and initial data, then verifying real application behavior. Use for app setup or onboarding after the project exists; use frameworks-on-cloudflare or cf-cli to create or configure the project, and wrangler or cf-cli for isolated commands.
  • cloudflare-email-serviceImplement or troubleshoot Cloudflare Email Sending and Email Routing integrations and their delivery configuration.
  • cloudflare-oneDesign, configure, troubleshoot, or review Cloudflare One Zero Trust and SASE deployments. Use cloudflare-one-migrations for migration planning from other vendors. Also use when an agent, script, crawler, or other non-browser client needs to reach a webpage or API protected by Cloudflare Access.
  • cloudflare-one-migrationsAssess and plan migrations from existing VPN, SWG, or SASE platforms to Cloudflare One, including policy mapping, parity gaps, and rollout.
  • durable-objectsBuild, debug, or review Cloudflare Durable Objects code for persistent state and coordination.
  • frameworks-on-cloudflareBuild, migrate, and deploy web-framework applications on Cloudflare Workers. Use when a framework project such as Astro, SvelteKit, React Router, TanStack Start, Nuxt, Hono, or a React or Vue SPA targets Cloudflare, or when a framework repository contains Workers deployment configuration.
  • gateway-workersBuild, debug, or review Cloudflare Workers invoked by the Forward action in Gateway HTTP policies, including the GatewayMiddleware entrypoint, Gateway types, context, and continuation.
  • k2Build and troubleshoot Cloudflare K2 or K2 Streams durable logs. Use for stream setup, producing from Workers or HTTP, configuring retention and inputs, and consuming through subscriptions.
  • nextjs-on-cloudflareBuild, migrate, and deploy Next.js apps on Cloudflare Workers with vinext. Use when starting a Next.js project on Cloudflare, moving an existing app to Workers, choosing between vinext and OpenNext, or setting up vinext for Workers. For setup, migration, or deployment, install vinext's upstream skills with `npx skills add cloudflare/vinext` if missing, then read and follow the applicable skill and docs.
  • sandbox-migrate-to-nextMigrate Cloudflare Sandbox apps from stable @cloudflare/sandbox to @cloudflare/sandbox@next (SDK 1.0 preview). Use sandbox-next for apps already on the preview.
  • sandbox-nextBuild or maintain Cloudflare Sandbox apps on @cloudflare/sandbox@next (SDK 1.0 preview). Use sandbox-migrate-to-next when porting a stable app.
  • sandbox-stableBuild or maintain Cloudflare Sandbox apps on the stable @cloudflare/sandbox package. Use sandbox-next for preview apps and sandbox-migrate-to-next for stable-to-preview migrations.
  • turnstile-spinSet up, repair, or migrate to Cloudflare Turnstile bot verification in an existing frontend and backend, including server-side Siteverify.
  • web-perfAudit, diagnose, or optimize website loading and interaction performance, Core Web Vitals, and Lighthouse performance scores.
  • workers-best-practicesCloudflare Workers best practices for production applications. Use when writing, reviewing, or configuring Workers.
  • workers-developmentRun, inspect, and debug Cloudflare Workers during local development with cf dev, wrangler dev, or the Cloudflare Vite plugin, using Local Explorer to read and seed binding data and query local traces and logs. Also routes production debugging to Workers observability. Use for debugging requests whether or not the project uses Wrangler.
  • workers-profilingProfile or debug CPU usage and memory allocation in deployed Cloudflare Workers and Durable Objects. Then use this information to optimize your code.
  • wranglerRun or troubleshoot Wrangler CLI commands in projects that have a wrangler.jsonc, wrangler.json, or wrangler.toml file, including local development, Previews, deployment, and resource management. For new projects and projects without a Wrangler configuration file, use the cf CLI instead.
MCP サーバー

Cloudflare API、ドキュメント、可観測性へのライブアクセスです。

MCP サーバーは、実行時に Cloudflare を呼ぶ型付きツールを提供します。 選択肢は 2 つです。Code Mode — Cloudflare API 全体をカバーする 1 台のサーバー(約 1,000 トークンで 2,500 以上のエンドポイント)— か、 cloudflare/mcp-server-cloudflare リポジトリでホストされる、領域に特化したサーバー群です。カタログ全体は Cloudflare 向け MCP サーバー のドキュメントにもあります。

  • Cloudflare API MCP Servercode modeBest when you want broad access across Cloudflare's APIs through code executionhttps://mcp.cloudflare.com/mcp
  • Code mode APIcode modeBroad access to the full Cloudflare API via code execution, with minimal token overheadhttps://mcp.cloudflare.com/mcp
  • Browser Run serverFetch web pages, convert them to markdown and take screenshotshttps://browser.mcp.cloudflare.com/mcp
  • Cloudflare Blog serverSearch and read posts from the Cloudflare Bloghttps://blog.mcp.cloudflare.com/mcp
  • Cloudflare One CASB serverQuickly identify any security misconfigurations for SaaS applications to safeguard users & datahttps://casb.mcp.cloudflare.com/mcp
  • Container serverSpin up a sandbox development environmenthttps://containers.mcp.cloudflare.com/mcp
  • Demo Day serverDemonstrate a minimal Cloudflare MCP serverhttps://demo-day.mcp.cloudflare.com/mcp
  • Digital Experience Monitoring serverGet quick insight on critical applications for your organizationhttps://dex.mcp.cloudflare.com/mcp
  • Documentation serverGet up-to-date reference information on Cloudflarehttps://docs.mcp.cloudflare.com/mcp
Wrangler CLI

ローカル開発、デプロイ、Workers 向けコマンドです。

ローカル開発、デプロイ、製品固有のコマンド(wrangler d1 migrations apply や wrangler tail など)には Wrangler を使います。 同梱の wrangler Skill が、いつそれを使うかをエージェントに教えます。

エージェント向けドキュメント

エージェント向けに最適化した、トークン効率のよいリファレンスです。

任意の Cloudflare ドキュメント URL に /index.md を付けると、きれいな Markdown 版になります。 各トップレベル製品セクションには、1 つのコンテキストウィンドウに収まるページ索引の llms.txt もあります。よく使うものは次のとおりです。

これらのドキュメントがエージェント向けにどう構成されているかの全体像は、エージェント向けドキュメント ガイドを参照してください。

プロンプトの例

Hyperdrive でコネクションプーリングし、既存の Postgres データベースに Worker をつないでください。
この Worker を Cloudflare のステージングと本番にデプロイする GitHub Actions を設定してください。
API エンドポイントを守るために、mTLS 認証とスキーマ検証を追加してください。
Durable Objects の WebSocket hibernation を使い、アプリにリアルタイム共同編集を追加してください。
公開 API への不正利用を止めるために、レート制限と WAF ルールを設定してください。

ヒント

  • Cloudflare API MCP サーバーは Code Mode を使います。Copilot は型付き API に対して JavaScript を書き、約 1,000 トークンで 2,500 以上のエンドポイントのいずれにも到達できます。
  • 構築やデプロイを依頼する前に、Copilot Chat で @workspace を使い、Workers プロジェクトの全体コンテキストをエージェントに渡します。
  • リポジトリ全体の慣習を書いた .github/copilot-instructions.md をコミットします。Copilot は毎回のやり取りで自動的に読み込みます。オンデマンドで読み込まれる Skills を補完します。

よくある質問

Copilot は Cloudflare Skills に対応していますか?

対応しています。GitHub Copilot は、VS Code の agent mode、Copilot CLI、cloud agent で Agent Skills に対応しました。npx skills add https://github.com/cloudflare/skills を実行してインストールします。Copilot が Skills を探す場所の詳細は、About agent skills ↗ ガイドを参照してください。

Skills、MCP サーバー、Wrangler CLI は、どれを使うべきですか?

3 つとも使います。Skills は、agent mode のセッションごとに Cloudflare の知見を読み込みます。Cloudflare API MCP サーバーは、プラットフォーム操作(DNS、WAF、Zero Trust、R2 バケット)を扱います。Wrangler は VS Code ターミナルでローカル開発とデプロイを実行します。同梱の wrangler Skill が、どれをいつ使うかを Copilot に教えます。

.github/copilot-instructions.md はまだ必要ですか?

補完関係です。ほぼすべての作業に当てはまる、リポジトリ全体の簡単な慣習(コーディング規約、優先するライブラリ)にはカスタム指示を使います。状況に応じた詳しい案内で、関連するときだけ Copilot に読み込ませたい内容には Skills を使います。

Copilot は Cloudflare に直接デプロイできますか?

できます。VS Code ターミナルの Wrangler 経由か、Copilot が生成できる GitHub Actions ワークフロー経由です。

トラブルシューティング

Copilot で Skills が読み込まれない

Skills が使えるのは、VS Code の agent mode、Copilot CLI、cloud agent だけです。インライン補完や通常のチャットでは使えません。Copilot Chat を agent mode に切り替えます。それでも Skills が見つからない場合は、Copilot が確認するパスについて About agent skills ↗ を参照してください。

VS Code で MCP サーバーが使えない

MCP をネイティブにサポートする VS Code 1.99 以降を使っていることを確認します。サーバー設定は .vscode/mcp.json に追加します。

Cloudflare 製品の情報が古い

Cloudflare docs MCP サーバー を有効にすると、エージェントは実行時に最新のドキュメントを取得できます。MCP サーバーを使いたくない場合は、developers.cloudflare.com/llms.txt を直接指定して全製品の一覧を渡すか、developers.cloudflare.com/<product>/llms.txt で製品別の索引を渡します。

Cloudflare 上でエージェントを構築する

その他のエージェント

Anthropic

Claude Code

ターミナルで動くコーディングエージェントです。コードベースを理解し、コマンドを実行し、ファイルを編集し、git を扱います。Anthropic 製です。

ガイドを見る
OpenAI

Codex

OpenAI のコーディングエージェントです。ターミナル CLI とデスクトップアプリがあります。サンドボックス内でファイルの読み書き、コマンド実行、Web 閲覧ができます。

ガイドを見る
Cursor

Cursor

VS Code を土台にした、AI を第一級にした IDE です。複数ファイルの Composer 編集とバックグラウンドエージェントがあります。Cursor 製です。

ガイドを見る
Anomaly

OpenCode

オープンソースのターミナルエージェントです。充実した TUI があり、75 以上の LLM に対応します。Anomaly 製です。

ガイドを見る
Cognition

Windsurf

エージェント型 IDE です。Cascade コンテキストと、複数ステップ作業向けの Flows があります。Cognition 製です。

ガイドを見る
Microsoft

Visual Studio Code

無料のオープンソースコードエディターです。ネイティブの Model Context Protocol(MCP)クライアントと Copilot Chat 連携があります。Microsoft 製です。

ガイドを見る
Command Code

Command Code

Command Code は、オープンモデル向けでよく使われるコーディングエージェントのひとつです。コーディングの好みを自動で学び、作業するほど改善します。

ガイドを見る
LM Studio

Bionic

コーディングと作業向けの強力なエージェントです。基本はローカルで動き、クラウド上のオープンモデルも使えます。LM Studio 製です。

ガイドを見る

役に立ちましたか?