Loading...
Loading...
Use DNSHE to register, manage, and automate free subdomains (us.ci, cc.cd, de5.net, ccwu.cc) with Anycast DNS via dashboard or REST API.
npx skill4agent add aradotso/trending-skills dnshe-freedomainsSkill by ara.so — Daily 2026 Skills collection.
us.cicc.cdde5.netccwu.ccmyproject| Suffix | Use Case |
|---|---|
| CI/CD pipelines, API endpoints, SaaS |
| Portfolios, creative projects |
| Tech blogs, dev environments, docs |
| Personal pages, community projects |
AuthorizationAuthorization: Bearer $DNSHE_API_TOKENexport DNSHE_API_TOKEN="your_token_here"
export DNSHE_BASE_URL="https://www.dnshe.com/api/v1"curl -s -X GET "$DNSHE_BASE_URL/domains" \
-H "Authorization: Bearer $DNSHE_API_TOKEN" \
-H "Content-Type: application/json"curl -s -X POST "$DNSHE_BASE_URL/domains" \
-H "Authorization: Bearer $DNSHE_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"subdomain": "myproject",
"suffix": "us.ci"
}'curl -s -X POST "$DNSHE_BASE_URL/domains/myproject.us.ci/records" \
-H "Authorization: Bearer $DNSHE_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"type": "A",
"name": "@",
"value": "203.0.113.42",
"ttl": 300
}'curl -s -X PUT "$DNSHE_BASE_URL/domains/myproject.us.ci/records/{record_id}" \
-H "Authorization: Bearer $DNSHE_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"type": "A",
"name": "@",
"value": "203.0.113.99",
"ttl": 300
}'curl -s -X DELETE "$DNSHE_BASE_URL/domains/myproject.us.ci/records/{record_id}" \
-H "Authorization: Bearer $DNSHE_API_TOKEN"curl -s -X POST "$DNSHE_BASE_URL/domains/myproject.us.ci/renew" \
-H "Authorization: Bearer $DNSHE_API_TOKEN"import os
import requests
API_TOKEN = os.environ["DNSHE_API_TOKEN"]
BASE_URL = "https://www.dnshe.com/api/v1"
HEADERS = {
"Authorization": f"Bearer {API_TOKEN}",
"Content-Type": "application/json",
}
def register_subdomain(subdomain: str, suffix: str) -> dict:
resp = requests.post(
f"{BASE_URL}/domains",
headers=HEADERS,
json={"subdomain": subdomain, "suffix": suffix},
)
resp.raise_for_status()
return resp.json()
def add_record(domain: str, record_type: str, name: str, value: str, ttl: int = 300) -> dict:
resp = requests.post(
f"{BASE_URL}/domains/{domain}/records",
headers=HEADERS,
json={"type": record_type, "name": name, "value": value, "ttl": ttl},
)
resp.raise_for_status()
return resp.json()
def renew_domain(domain: str) -> dict:
resp = requests.post(
f"{BASE_URL}/domains/{domain}/renew",
headers=HEADERS,
)
resp.raise_for_status()
return resp.json()
def list_domains() -> list:
resp = requests.get(f"{BASE_URL}/domains", headers=HEADERS)
resp.raise_for_status()
return resp.json()
if __name__ == "__main__":
# Register subdomain
result = register_subdomain("myproject", "us.ci")
print("Registered:", result)
# Point it to a server
record = add_record("myproject.us.ci", "A", "@", "203.0.113.42")
print("Record added:", record)
# Add a www CNAME
cname = add_record("myproject.us.ci", "CNAME", "www", "myproject.us.ci")
print("CNAME added:", cname)import os
import requests
from datetime import datetime, timedelta
API_TOKEN = os.environ["DNSHE_API_TOKEN"]
BASE_URL = "https://www.dnshe.com/api/v1"
HEADERS = {"Authorization": f"Bearer {API_TOKEN}"}
def renew_expiring_domains(days_threshold: int = 30):
"""Renew any domain expiring within `days_threshold` days."""
resp = requests.get(f"{BASE_URL}/domains", headers=HEADERS)
resp.raise_for_status()
domains = resp.json()
now = datetime.utcnow()
threshold = now + timedelta(days=days_threshold)
for domain in domains:
# Adjust field name to match actual API response
expires_at = datetime.fromisoformat(domain.get("expires_at", "").replace("Z", ""))
if expires_at <= threshold:
name = domain["domain"]
renew_resp = requests.post(f"{BASE_URL}/domains/{name}/renew", headers=HEADERS)
if renew_resp.ok:
print(f"✅ Renewed: {name}")
else:
print(f"❌ Failed to renew {name}: {renew_resp.text}")
if __name__ == "__main__":
renew_expiring_domains(days_threshold=30)const fetch = require('node-fetch'); // or use built-in fetch in Node 18+
const API_TOKEN = process.env.DNSHE_API_TOKEN;
const BASE_URL = 'https://www.dnshe.com/api/v1';
const headers = {
'Authorization': `Bearer ${API_TOKEN}`,
'Content-Type': 'application/json',
};
async function registerSubdomain(subdomain, suffix) {
const res = await fetch(`${BASE_URL}/domains`, {
method: 'POST',
headers,
body: JSON.stringify({ subdomain, suffix }),
});
if (!res.ok) throw new Error(`Register failed: ${await res.text()}`);
return res.json();
}
async function addRecord(domain, type, name, value, ttl = 300) {
const res = await fetch(`${BASE_URL}/domains/${domain}/records`, {
method: 'POST',
headers,
body: JSON.stringify({ type, name, value, ttl }),
});
if (!res.ok) throw new Error(`Add record failed: ${await res.text()}`);
return res.json();
}
async function listDomains() {
const res = await fetch(`${BASE_URL}/domains`, { headers });
if (!res.ok) throw new Error(`List failed: ${await res.text()}`);
return res.json();
}
async function renewDomain(domain) {
const res = await fetch(`${BASE_URL}/domains/${domain}/renew`, {
method: 'POST',
headers,
});
if (!res.ok) throw new Error(`Renew failed: ${await res.text()}`);
return res.json();
}
// Example usage
(async () => {
const domain = await registerSubdomain('myapp', 'cc.cd');
console.log('Registered:', domain);
const record = await addRecord('myapp.cc.cd', 'A', '@', '203.0.113.42');
console.log('A record added:', record);
// Add TXT for domain verification / Let's Encrypt
const txt = await addRecord('myapp.cc.cd', 'TXT', '_acme-challenge', 'your-challenge-value');
console.log('TXT record added:', txt);
})();# .github/workflows/dnshe-renew.yml
name: DNSHE Domain Auto-Renewal
on:
schedule:
- cron: '0 9 * * 1' # Every Monday at 9am UTC
workflow_dispatch:
jobs:
renew:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install dependencies
run: pip install requests
- name: Run renewal script
env:
DNSHE_API_TOKEN: ${{ secrets.DNSHE_API_TOKEN }}
run: python scripts/renew_domains.py#!/bin/bash
# update-dns.sh — Update A record to current public IP
DOMAIN="${DNSHE_DOMAIN:-myproject.us.ci}"
RECORD_ID="${DNSHE_RECORD_ID}" # Get from dashboard or API list
PUBLIC_IP=$(curl -s https://api.ipify.org)
echo "Updating $DOMAIN to $PUBLIC_IP"
curl -s -X PUT "https://www.dnshe.com/api/v1/domains/${DOMAIN}/records/${RECORD_ID}" \
-H "Authorization: Bearer $DNSHE_API_TOKEN" \
-H "Content-Type: application/json" \
-d "{\"type\": \"A\", \"name\": \"@\", \"value\": \"${PUBLIC_IP}\", \"ttl\": 60}"{ "type": "A", "name": "@", "value": "YOUR_SERVER_IP", "ttl": 300 }{ "type": "CNAME", "name": "www", "value": "myproject.us.ci", "ttl": 300 }{ "type": "MX", "name": "@", "value": "mail.example.com", "ttl": 300, "priority": 10 }{ "type": "TXT", "name": "_acme-challenge", "value": "ACME_CHALLENGE_TOKEN", "ttl": 60 }{ "type": "AAAA", "name": "@", "value": "2001:db8::1", "ttl": 300 }{ "type": "SRV", "name": "_http._tcp", "value": "10 20 80 myproject.us.ci", "ttl": 300 }| Type | Purpose |
|---|---|
| IPv4 address |
| IPv6 address |
| Canonical name alias |
| Mail exchange |
| Text (SPF, DKIM, ACME) |
| Name server delegation |
| Service locator |
| Certificate authority authorization |
/renewGET /domains/{domain}/recordsdig myproject.us.cinslookup myproject.us.ciDNSHE_API_TOKEN| Resource | URL |
|---|---|
| Dashboard | dnshe.com |
| Support Email | support@dnshe.com |
| ToS | dnshe.com/tos.html |
| Abuse Reports | dnshe.com/domainabuse/ |