Cloudflare
/install cloudflare-toolkit
Cloudflare
Manage Cloudflare zones, DNS, SSL, tunnels, and settings via the bundled scripts/cf.sh bash script.
Prerequisites
curl,jq, andopensslmust be available on the system- Set
CLOUDFLARE_API_TOKENenvironment variable - Optionally set
CLOUDFLARE_ACCOUNT_IDfor tunnel operations
CLI: scripts/cf.sh
All operations go through the bundled scripts/cf.sh bash script (included in this skill). No external downloads needed.
# Run from skill directory
./scripts/cf.sh \x3Ccommand> [args...]
# Or reference by absolute path
/path/to/skills/cloudflare/scripts/cf.sh \x3Ccommand> [args...]
Commands
| Command | Args | Description |
|---|---|---|
help |
Show all commands | |
verify |
Verify API token is valid | |
zones |
[domain] |
List zones (optionally filter by domain name) |
zone-get |
\x3Czone_id> |
Get zone details |
zone-id |
\x3Cdomain> |
Get zone ID from domain name |
dns-list |
\x3Czone_id> [type] [name] |
List DNS records |
dns-create |
\x3Czone_id> \x3Ctype> \x3Cname> \x3Ccontent> [proxied] [ttl] |
Create DNS record |
dns-update |
\x3Czone_id> \x3Crecord_id> \x3Ctype> \x3Cname> \x3Ccontent> [proxied] [ttl] |
Update DNS record |
dns-delete |
\x3Czone_id> \x3Crecord_id> |
Delete DNS record |
dns-export |
\x3Czone_id> |
Export all records as JSON |
dns-import |
\x3Czone_id> \x3Cfile.json> |
Import records from JSON |
settings-list |
\x3Czone_id> |
List all zone settings |
setting-get |
\x3Czone_id> \x3Csetting> |
Get specific setting |
setting-set |
\x3Czone_id> \x3Csetting> \x3Cvalue> |
Update a setting |
ssl-get |
\x3Czone_id> |
Get current SSL mode |
ssl-set |
\x3Czone_id> \x3Cmode> |
Set SSL mode (off/flexible/full/strict) |
cache-purge |
\x3Czone_id> [url1 url2 ...] |
Purge specific URLs or everything |
pagerules-list |
\x3Czone_id> |
List page rules |
firewall-list |
\x3Czone_id> |
List firewall rules |
tunnels-list |
List Cloudflare Tunnels (needs ACCOUNT_ID) | |
tunnel-get |
\x3Ctunnel_id> |
Get tunnel details |
tunnel-create |
\x3Cname> |
Create a tunnel (needs ACCOUNT_ID) |
tunnel-delete |
\x3Ctunnel_id> |
Delete a tunnel (needs ACCOUNT_ID) |
analytics |
\x3Czone_id> [since_minutes] |
Zone analytics (default: last 24h) |
Proxied flag
true— orange cloud, traffic through Cloudflare (CDN, WAF, DDoS)false— grey cloud, DNS-only (use for MX, non-HTTP services)
TTL
1= automatic (Cloudflare-managed)- Set explicit seconds for DNS-only records (e.g.,
3600)
Typical workflows
Point domain to server
# Find zone ID
cf zones example.com
# Create A record (proxied)
cf dns-create \x3Czone_id> A example.com 1.2.3.4 true
# Create www CNAME
cf dns-create \x3Czone_id> CNAME www.example.com example.com true
Set up email (MX + SPF)
cf dns-create \x3Czone_id> MX example.com "mx.provider.com" false 1
cf dns-create \x3Czone_id> TXT example.com "v=spf1 include:provider.com ~all" false
Enable strict SSL
cf ssl-set \x3Czone_id> strict
Safety rules
Always confirm with the user before:
- Deleting DNS records (
dns-delete) - Changing SSL mode
- Modifying firewall rules
- Any destructive operation
Safe to do freely:
- Listing/reading zones, records, settings, analytics
- Verifying token
Reference
For DNS record types, SSL modes, and API details: see references/api-guide.md
- Make sure OpenClaw is installed (local or Docker)
- Run the install command in chat:
/install cloudflare-toolkit - After installation, invoke the skill by name or use
/cloudflare-toolkit - Provide required inputs per the skill's parameter spec and get structured output
What is Cloudflare?
Manage Cloudflare domains, DNS records, SSL settings, zone configuration, firewall rules, tunnels, and analytics via the Cloudflare API. Use when the user as... It is an AI Agent Skill for Claude Code / OpenClaw, with 1828 downloads so far.
How do I install Cloudflare?
Run "/install cloudflare-toolkit" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.
Is Cloudflare free?
Yes, Cloudflare is completely free (open-source). You can download, install and use it at no cost.
Which platforms does Cloudflare support?
Cloudflare is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).
Who created Cloudflare?
It is built and maintained by Shiwei Song (@insipidpoint); the current version is v1.5.0.