Change Nameservers

Updating Authoritative Nameservers: Allows you to change the nameservers for your domain to point it to your web host or custom DNS service. At least two valid strings are strictly required (ns1 and ns2) for a successful update at the registry level. This immediately executes a synchronous upstream command to Dynadot.

Endpoint: POST /{id}/nameservers

Parameters:

  • id (required, URL parameter): The local ID of the domain
  • ns1 (required, string): Primary nameserver (e.g. ns1.hosting.com)
  • ns2 (required, string): Secondary nameserver (e.g. ns2.hosting.com)
  • ns3 (optional, string): Tertiary nameserver
  • ns4 (optional, string): Quaternary nameserver

Example Request:

curl -X POST "https://umva.net/api/domain/123/nameservers" 
  -H "X-API-Key: your_api_key_here" 
  -H "Content-Type: application/json" 
  -d '{"ns1": "ns1.hosting.com", "ns2": "ns2.hosting.com"}'

Success Response Example (HTTP 200):

{
  "success": true,
  "message": "Nameservers updated successfully!",
  "data": {
    "domain": "example.com",
    "nameservers": {
      "ns1": "ns1.hosting.com",
      "ns2": "ns2.hosting.com",
      "ns3": null,
      "ns4": null
    }
  }
}

Error Response Example (HTTP 500):

{
  "success": false,
  "message": "Failed to update nameservers: Invalid nameserver format."
}