cloudflare-manager

Manage Cloudflare DNS records, Tunnels (cloudflared), and Zero Trust policies. Use for pointing domains, exposing local services via tunnels, and updating ingress rules.

3,891 stars
Complexity: medium

About this skill

The Cloudflare Manager skill provides a standardized way for AI agents to interact with and manage Cloudflare infrastructure. It automates common tasks such as adding, listing, or deleting DNS records, configuring Zero Trust policies, and updating local Cloudflare Tunnel (cloudflared) ingress rules. This capability allows an agent to directly control aspects of domain resolution and secure service exposure. This skill is particularly useful for agents needing to perform routine network configuration, quickly set up new services accessible via Cloudflare Tunnels, or dynamically adjust access policies. By abstracting the command-line interactions, it enables intelligent agents to respond to deployment events or user requests by modifying Cloudflare settings without manual intervention. Users can leverage this skill to automate the pointing of domains to new IPs, expose locally running development services securely through Cloudflare, or update ingress rules for their Zero Trust network, all through high-level agent prompts.

Best use case

The primary use case is automating Cloudflare infrastructure management tasks, particularly for DNS and secure tunnel configurations. This benefits developers, DevOps engineers, and system administrators who want to programmatically control their Cloudflare resources via an AI agent, streamlining deployment workflows and ensuring consistent configuration.

Manage Cloudflare DNS records, Tunnels (cloudflared), and Zero Trust policies. Use for pointing domains, exposing local services via tunnels, and updating ingress rules.

Users should expect successful creation, modification, or listing of Cloudflare DNS records, or updated Cloudflare Tunnel ingress configurations on their host machine.

Practical example

Example input

Please add an A record for `dev.example.com` pointing to `192.0.2.1` in Cloudflare using the `cloudflare-manager` skill.

Example output

Successfully added DNS A record for dev.example.com pointing to 192.0.2.1. Record ID: xxxxxxxxxx.

When to use this skill

  • When an AI agent needs to programmatically add, list, or delete DNS records on Cloudflare.
  • To automate the exposure of local services securely through Cloudflare Tunnels by updating ingress rules.
  • For dynamically adjusting Cloudflare Zero Trust policies based on specific conditions or deployment events.
  • To integrate Cloudflare resource management into automated deployment or incident response workflows.

When not to use this skill

  • For complex Cloudflare configurations best managed through a full Infrastructure-as-Code (IaC) solution like Terraform.
  • If direct, interactive control via the Cloudflare UI or `cloudflared` CLI is preferred for one-off tasks.
  • When granular control or advanced features beyond DNS, Tunnels, and basic Zero Trust policies are required.
  • On systems where `sudo` access for `cloudflared` service management is not permissible or securely configurable.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/cloudflare-manager/SKILL.md --create-dirs "https://raw.githubusercontent.com/openclaw/skills/main/skills/1999azzar/cloudflare-manager/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/cloudflare-manager/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How cloudflare-manager Compares

Feature / Agentcloudflare-managerStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexitymediumN/A

Frequently Asked Questions

What does this skill do?

Manage Cloudflare DNS records, Tunnels (cloudflared), and Zero Trust policies. Use for pointing domains, exposing local services via tunnels, and updating ingress rules.

How difficult is it to install?

The installation complexity is rated as medium. You can find the installation instructions above.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

# Cloudflare Manager

Standardized system for managing Cloudflare infrastructure and local tunnel ingress.

## Prerequisites
- **Binary**: `python3` and `cloudflared` must be installed.
- **Credentials**: `CLOUDFLARE_API_TOKEN` (minimal Zone permissions) and `CLOUDFLARE_ZONE_ID`.

## Setup
1. Define credentials in the environment or a local `.env` file.
2. Initialize the local environment: `bash scripts/install.sh`.

## Core Workflows

### 1. DNS Management
Add, list, or delete DNS records via Cloudflare API.
- **List**: `python3 $WORKSPACE/skills/cloudflare-manager/scripts/cf_manager.py list-dns`
- **Add**: `python3 $WORKSPACE/skills/cloudflare-manager/scripts/cf_manager.py add-dns --type A --name <subdomain> --content <ip>`

### 2. Tunnel Ingress (Local)
Update `/etc/cloudflared/config.yml` and restart the tunnel service.
- **Update**: `python3 $WORKSPACE/skills/cloudflare-manager/scripts/cf_manager.py update-ingress --hostname <host> --service <url>`
- **Safety**: Use `--dry-run` to preview configuration changes before application.

## Security & Permissions
- **Sudo Usage**: The `update-ingress` command requires `sudo` to write to system directories and restart the `cloudflared` service.
- **Least Privilege**: Configure restricted sudo access using the pattern in `references/sudoers.example`.
- **Token Isolation**: Ensure API tokens are scoped narrowly to specific zones and permissions.

## Reference
- **Sudoers Pattern**: See [references/sudoers.example](references/sudoers.example).
- **Tunnel Logic**: See [references/tunnel-guide.md](references/tunnel-guide.md).

Related Skills

node-red-manager

3891
from openclaw/skills

Manage Node-RED instances via Admin API or CLI. Automate flow deployment, install nodes, and troubleshoot issues. Use when user wants to "build automation", "connect devices", or "fix node-red".

DevOps & Infrastructure

botlearn-healthcheck

3891
from openclaw/skills

botlearn-healthcheck — BotLearn autonomous health inspector for OpenClaw instances across 5 domains (hardware, config, security, skills, autonomy); triggers on system check, health report, diagnostics, or scheduled heartbeat inspection.

DevOps & Infrastructure

Incident Postmortem Generator

3891
from openclaw/skills

Generate blameless incident postmortems from raw notes, Slack threads, or bullet points.

DevOps & Infrastructure

Post-Mortem & Incident Review Framework

3891
from openclaw/skills

Run structured post-mortems that actually prevent repeat failures. Blameless analysis, root cause identification, and action tracking.

DevOps & Infrastructure

afrexai-performance-engineering

3891
from openclaw/skills

Complete performance engineering system — profiling, optimization, load testing, capacity planning, and performance culture. Use when diagnosing slow applications, optimizing code/queries/infrastructure, load testing before launch, planning capacity, or building performance into CI/CD. Covers Node.js, Python, Go, Java, databases, APIs, and frontend.

DevOps & Infrastructure

OpenClaw Mastery — The Complete Agent Engineering & Operations System

3891
from openclaw/skills

> Built by AfrexAI — the team that runs 9+ production agents 24/7 on OpenClaw.

DevOps & Infrastructure

Legacy System Modernization Engine

3891
from openclaw/skills

Complete methodology for assessing, planning, and executing legacy system modernization — from monolith decomposition to cloud migration. Works for any tech stack, any scale.

DevOps & Infrastructure

Incident Response Playbook

3891
from openclaw/skills

Structured incident response for business and IT teams. Guides you through detection, triage, containment, resolution, and post-mortem — with auto-generated timelines and action items.

DevOps & Infrastructure

Git Engineering & Repository Strategy

3891
from openclaw/skills

You are a Git Engineering expert. You help teams design branching strategies, implement code review workflows, manage monorepos, automate releases, and maintain healthy repository practices at scale.

DevOps & Infrastructure

Django Production Engineering

3891
from openclaw/skills

Complete methodology for building, scaling, and operating production Django applications. From project structure to deployment, security to performance — every decision framework a Django team needs.

DevOps & Infrastructure

IT Disaster Recovery Plan Generator

3891
from openclaw/skills

Build production-ready disaster recovery plans that actually get followed when things break.

DevOps & Infrastructure

afrexai-api-architect

3891
from openclaw/skills

Design, build, test, document, and secure production-grade APIs. Covers the full lifecycle from schema design through deployment, monitoring, and versioning. Use when designing new APIs, reviewing existing ones, generating OpenAPI specs, building test suites, or debugging production issues.

DevOps & Infrastructure