Skip to content
Back to skills

Cloudflare

ASecurity

Deploy Cloudflare Workers/Pages. USE WHEN Cloudflare, worker, deploy, Pages, MCP server. SkillSearch('cloudflare') for docs.

  • 2 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added October 6, 2026
ai-agentsbashapi

Works with

  • api
  • mcp

Security analysis

A100/100

Pro scans all 3 files and shows the line behind each finding

Scanned October 6, 2026

npx -y skills add johansenmeister/Dual-PAI --skill Cloudflare --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Cloudflare?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Cloudflare
[![Security: A β€” Skills Directory](https://www.skillsdirectory.com/api/skills/johansenmeister-cloudflare/badge)](https://www.skillsdirectory.com/skills/johansenmeister-cloudflare)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: Cloudflare
description: Deploy Cloudflare Workers/Pages. USE WHEN Cloudflare, worker, deploy, Pages, MCP server. SkillSearch('cloudflare') for docs.
---

## Customization

**Before executing, check for user customizations at:**
`~/.opencode/PAI/USER/SKILLCUSTOMIZATIONS/Cloudflare/`

If this directory exists, load and apply any PREFERENCES.md, configurations, or resources found there. These override default behavior. If the directory does not exist, proceed with skill defaults.


## Notification


1. **Output text notification**:
   ```
   Running the **WorkflowName** workflow in the **Cloudflare** skill to ACTION...
   ```


# Cloudflare Skill

Deploy and manage Cloudflare Workers, MCP servers, and Pages.


## Workflow Routing

**When executing a workflow, output this notification directly:**

```
Running the **WorkflowName** workflow in the **Cloudflare** skill to ACTION...
```

  - **Create** MCP server or Worker β†’ `Workflows/Create.md`
  - **Troubleshoot** deployment issues β†’ `Workflows/Troubleshoot.md`

## Quick Reference

- **Account ID:** Set via `CF_ACCOUNT_ID` environment variable
- **Worker URL format:** `https://[worker-name].[your-subdomain].workers.dev`

## Deployment Commands

### Workers Deployment
```bash
# Unset tokens that interfere with wrangler login-based auth
(unset CF_API_TOKEN && unset CLOUDFLARE_API_TOKEN && wrangler deploy)
```

### Pages Deployment

**🚨 CRITICAL: ALL env tokens lack Pages permissions. MUST unset them to use OAuth:**

```bash
# ALWAYS unset tokens for Pages - OAuth login works, tokens don't
(unset CF_API_TOKEN && unset CLOUDFLARE_API_TOKEN && npx wrangler pages deploy dist --project-name=PROJECT_NAME --commit-dirty=true)
```

**Known Pages Projects:**
| Project | Directory | Deploy Command |
|---------|-----------|----------------|
| [project] | `~/Projects/[project]` | `(unset CF_API_TOKEN && unset CLOUDFLARE_API_TOKEN && npx wrangler pages deploy dist --project-name=[project] --commit-dirty=true)` |

## Critical Notes

- **Workers:** Unset `CF_API_TOKEN` and `CLOUDFLARE_API_TOKEN` before deploying - they interfere with wrangler login-based auth
- **Pages:** 🚨 **UNSET ALL TOKENS** - None of the API tokens have Pages permissions. OAuth-based wrangler login is the ONLY method that works.

## Examples

**Example 1: Deploy a Worker**
```
User: "deploy the MCP server to Cloudflare"
β†’ Invokes CREATE workflow
β†’ Unsets env tokens, runs wrangler deploy
β†’ "Deployed to https://mcp-server.[subdomain].workers.dev"
```

**Example 2: Deploy Pages site**
```
User: "deploy my-app to Cloudflare"
β†’ Builds dist/, unsets tokens
β†’ Runs wrangler pages deploy
β†’ "Deployed my-app to Cloudflare Pages"
```

**Example 3: Fix deployment error**
```
User: "Cloudflare deploy is failing with auth error"
β†’ Invokes TROUBLESHOOT workflow
β†’ Identifies token interference
β†’ "Fixed - tokens were overriding OAuth. Redeployed successfully."
```

Files in this skill

  • SKILL.md2.9 KB
  • Workflows/Create.md1.6 KB
  • Workflows/Troubleshoot.md16.5 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…