DDNS

DDNS Provider English Documentation

Overview

DNSPod is a DNS service provider under Tencent Cloud, widely used in mainland China. This DDNS project supports connecting to DNSPod via two authentication methods:

  1. API Token (Recommended)
  2. Email + Password (Legacy)

Authentication Methods

The API Token method is more secure and is the recommended way to integrate with DNSPod.

How to Obtain an API Token

  1. Login to DNSPod Console
  2. Go to API Key Management
  3. Create a New API Key
    • Click the “Create Key” button
    • Enter a descriptive name (e.g., “DDNS Host”)
    • Select appropriate permissions (domain management permission required)
    • Click “Confirm” to create
  4. Copy Key Information
    • ID: The key ID (numeric value)
    • Token: The actual key string (long alphanumeric string)
    • Important: Save both values immediately, as the key will only be shown once

Configuration Using API Token

{
  "dns": "dnspod",
  "id": "123456",
  "token": "abcdef1234567890abcdef1234567890"
}

Parameters:

Method 2: Email + Password (Legacy)

This method uses your DNSPod account email and password. It is still supported but less secure than API Token.

How to Use Email Authentication

  1. Ensure Account Availability
    • Make sure you can log in to DNSPod with your email and password
    • Verify your account has domain management permissions
  2. Email and Password Configuration
{
  "id": "your-email@example.com",
  "token": "your-account-password",
  "dns": "dnspod"
}

Parameters:

Complete Configuration Examples

{
  "id": "123456",
  "token": "abcdef1234567890abcdef1234567890abcdef12",
  "dns": "dnspod",
  "ipv6": ["home.example.com", "nas.example.com"]
}

Example 2: Email Authentication Configuration

{
  "id": "myemail@gmail.com",
  "token": "mypassword123",
  "dns": "dnspod",
  "ipv6": ["dynamic.mydomain.com"]
}

Example 3: Configuration with Line Settings

{
  "id": "123456",
  "token": "abcdef1234567890abcdef1234567890abcdef12",
  "dns": "dnspod",
  "ipv4": ["home.example.com"],
  "ttl": 600,
  "line": "电信"
}

Optional Configuration Parameters

TTL (Time To Live)

{
  "ttl": 600
}

Record Type

{
  "record_type": "A"
}

Line (ISP Route)

{
  "line": "默认"
}

Troubleshooting

Common Issues

“Authentication Failed” Error

“Domain Not Found” Error

“Record Creation Failed”

Debug Mode

Enable debug logging to troubleshoot issues:

ddns --debug

This will display detailed logs for troubleshooting.

Support and Resources

It is recommended to use the API Token method for better security and easier DDNS configuration management.