cloudflare-tunnel-api-setup

Automate Cloudflare Tunnel creation, credential retrieval, and DNS configuration via API.

Updated Apr 30, 2026
One-click install
npx skills add https://github.com/photonics-dhl/Hermes --skill cloudflare-tunnel-api-setup
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cloudflare-tunnel-api-setup
Source: https://github.com/photonics-dhl/Hermes/tree/main/hermes-home/skills/devops/cloudflare-tunnel-api-setup
Command: npx skills add https://github.com/photonics-dhl/Hermes --skill cloudflare-tunnel-api-setup

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Automates Cloudflare Tunnel API based setup to expose internal services securely by automating tunnel creation, credentials retrieval, DNS configuration, and startup, eliminating manual Dashboard steps.

Core Features & Use Cases

  • API-driven tunnel creation: Create and manage Cloudflare tunnels entirely through API calls.
  • Credentials retrieval & management: Fetch and store credentials.json for authenticated tunnel operation.
  • DNS automation: Configure and manage DNS records to point to the tunnel endpoint automatically.
  • Flexible deployment: Supports token-based run and config-driven deployment for varied environments.

Quick Start

Provide your Cloudflare account details and run the setup tool to create a tunnel, fetch credentials, and apply DNS configuration via API.

Frequently Asked Questions about cloudflare-tunnel-api-setup

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate Cloudflare Tunnel setup via API without using the dashboard?

You can automate Cloudflare Tunnel setup via API by creating the tunnel, fetching credentials.json, and configuring DNS records programmatically. This approach eliminates manual Dashboard steps, requiring only your Cloudflare account, domain, and a valid API token.

What Cloudflare API token scopes and prerequisites are needed to create a tunnel programmatically?

To create a tunnel programmatically, you need a Cloudflare account token with validated scopes, an active domain, and prerequisites like cert.pem. The setup process validates these token scopes and retrieves the necessary credentials for authenticated operation.

Can I use a config file instead of a token to run my Cloudflare Tunnel deployment?

Yes, Cloudflare Tunnel deployment supports both token-based runs and config-driven deployments. After retrieving credentials and configuring DNS automatically via API, you can generate a config file to run the tunnel in varied environments.

How does DNS automation work when exposing internal services with Cloudflare Tunnels?

DNS automation for Cloudflare Tunnels configures and manages DNS records to point directly to your tunnel endpoint automatically. This securely exposes your internal services with a custom domain without requiring manual DNS record creation.

What is the best way to manage credentials.json for an API-driven Cloudflare Tunnel?

The best way to manage credentials is to fetch and store credentials.json directly through API calls during tunnel creation. This automated retrieval ensures you have the necessary credentials for authenticated tunnel operation without manual extraction.