# Cloudflare

Deploys and manages Cloudflare Workers, Pages, KV, R2, D1, DNS, and Queues with the cf...

- Repository: https://github.com/danielmiessler/LifeOS (19669 stars)
- Category: AI and agents
- License: MIT
- Last updated: 2026-10-28
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add danielmiessler/LifeOS --skill Cloudflare -g -a claude-code -y`
Codex: `npx skills add danielmiessler/LifeOS --skill Cloudflare -g -a codex -y`
Cursor: `npx skills add danielmiessler/LifeOS --skill Cloudflare -g -a cursor -y`
Gemini CLI: `npx skills add danielmiessler/LifeOS --skill Cloudflare -g -a gemini-cli -y`

## Description

Deploys and manages Cloudflare Workers, Pages, KV, R2, D1, DNS, and Queues with the cf CLI, converts Wrangler projects to cf, and authors MCP servers as Workers; never call cf or wrangler raw for a write. USE WHEN deploy worker, deploy pages, ship worker, push to cloudflare, wrangler deploy, Cloudflare, Pages, DNS, KV, R2, D1, Queues, Workers AI, worker logs, build an MCP server, write an MCP server, expose this as MCP, MCP server structure, what shape should our MCP server be, MCP spec, server/discover, MCP stateless. NOT FOR non-Cloudflare deploys or MCP servers we only consume.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# Cloudflare Skill

**Contents:** Ideal State · Intent Routing · How It Works · Data & Config · Gotchas · Examples

Deploys and manages Cloudflare Workers, Pages, KV, R2, D1, DNS, and Queues with one tool, Cloudflare's `cf` CLI, run through `LIFEOS/TOOLS/CfEnv.ts` so the master token reaches the cf process and nothing else. A raw Cloudflare CLI call either runs on whatever token the calling shell exports (a shell profile that exports `.env` puts it in every interactive shell, the agent's Bash shell included), outside CfEnv's probes and review, or coasts on a stale OAuth login, which produces false "the token is dead, rotate it" diagnoses. This skill encodes one tool, one credential, one runner, and one set of verified probes so deploys and queries land the first time.

## Ideal State

- Every account-touching Cloudflare call runs through `LIFEOS/TOOLS/CfEnv.ts`, so the master token from `.env` reaches one cf process and nothing else: no raw cf or Wrangler write, no sourced `.env`, no OAuth fallback.
- Whatever is deployed or created answers only on its authoritative URL (custom domain with workers.dev and previews off, or workers.dev when no domain exists). The report proves it live with a version ID and a probe, and the code review, new-zone baseline and registration gates were passed rather than overridden.
- Reads and diagnoses come from live cf output in the same turn. An auth failure is traced through `auth whoami` and a scope-matching probe before any rotation is considered.
- An MCP server built here is a stateless Worker that meets `References/McpServerSpec.md`.

## Intent Routing

The rest: https://github.com/danielmiessler/LifeOS/blob/HEAD/LifeOS/install/skills/Cloudflare/SKILL.md
