DNSHE Free Domain Renewal and API Command Renewal Methods

This manual is intended to guide users on how to manually or automatically renew free domains that are about to expire through the DNSHE console or API.

I. Core Renewal Rules

  • Renewal window: Opens 180 days before the domain expiration date.

  • Web-based operation: Log in to the admin console and click the “Free Renewal” button that appears next to the domain. After a successful operation, the new expiration date will be displayed.

  • Cost: Completely free.

II. API-Based Automated Renewal Process

If you need to manage multiple domains, using the API is recommended.

Step 1: Obtain API Credentials

On the DNSHE domain page, go to [API Management] and create and save the following two key credentials:

  • X-API-Key

  • X-API-Secret

Step 2: Retrieve the Domain ID (subdomain_id)

Before performing a renewal, you must first obtain the internal ID of the target domain.

Query command:

 
 
curl -X GET "https://api005.dnshe.com/index.php?m=domain_hub&endpoint=dns_records&action=list" \ -H "X-API-Key: YourKey" \ -H "X-API-Secret: YourSecret"

Example response parsing:

The API will return a list of all domains. Locate the id field corresponding to the domain you want to renew.

 
 
{ "success": true, "subdomains": [ { "id": 1, "subdomain": "1.de5.net", "status": "active" } ] }

Step 3: Submit the Renewal Request

Replace the subdomain_id parameter in the command below with the id you obtained.

Renewal command:

 
 
curl -X GET "https://api005.dnshe.com/index.php?m=domain_hub&endpoint=dns_records&action=list&subdomain_id=1" \ -H "X-API-Key: YourKey" \ -H "X-API-Secret: YourSecret"

III. Renewal Result Verification

After executing the renewal command, check the returned JSON data.

Successful renewal example:

 
 
{ "success": true, "message": "Subdomain renewed successfully", "subdomain_id": 1, "previous_expires_at": "2026-01-05 00:00:00", "new_expires_at": "2027-01-05 00:00:00", "charged_amount": 0, "remaining_days": 365 }

Verification checklist:

  • success is true

  • new_expires_at has been updated to one year later

Status Field Reference

Field Description
previous_expires_at Expiration date before renewal
new_expires_at Expiration date after renewal
charged_amount Renewal fee (0 means free)
remaining_days Number of days remaining until the new expiration date

 
  • 免费域名, 免费域名api, 域名续期, 续费域名
  • 15 Users Found This Useful
Was this answer helpful?

Related Articles

Free Domain Name Service API User Manual

Welcome to the Free Domain API Service. This API is designed to provide developers with an...

DNSHE Free Domain API User Guide (V2.0)

DNSHE Free Domain API User Guide (V2.0) Basic Information API Endpoint:...