mijn.host API
  1. DNS templates
mijn.host API
  • Getting started
    • Introduction
    • Base url
    • Authentication
    • Response codes
  • Domains
    • Domains
      • List domains
      • Get domain
      • Update domain
      • Cancel domain
      • Get DNS records
      • Update DNS records
      • Update single DNS record
      • Get auth code
      • Cancel domain deletion
    • Contacts
      • List profiles
      • Create profile
      • Update profile
      • Get profile
    • Nameservers
      • List profiles
      • Create profile
      • Update profile
      • Get profile
    • DNS templates
      • List templates
        GET
      • Create template
        POST
      • Update template
        PUT
      • Get template
        GET
    • Availability
      • Check domain availability
    • Order
      • Order domain
  1. DNS templates

Update template

PUT
/domains/dns-templates/{id}
Update a DNS template.

Request

Authorization
Add parameter in header
API-key
Example:
API-key: ********************
Path Params

Header Params

Body Params application/json

Example
{
    "alias": "My DNS Template",
    "default": false,
    "records": [
        {
            "type": "A",
            "name": "",
            "value": "192.168.1.1",
            "ttl": 300
        },
        {
            "type": "CNAME",
            "name": "www",
            "value": "www.example.nl",
            "ttl": 300
        },
        {
            "type": "CNAME",
            "name": "mail",
            "value": "mail.example.nl",
            "ttl": 300
        },
        {
            "type": "MX",
            "name": "",
            "value": "mail.example.nl",
            "ttl": 300,
            "priority": 10
        },
        {
            "type": "TXT",
            "name": "",
            "value": "v=spf1 include:_spf.example.nl ~all",
            "ttl": 7200
        },
        {
            "type": "AAAA",
            "name": "",
            "value": "2001:41d0:302:1100:0:0:5:b92b",
            "ttl": 7200
        }
    ]
}

Request Code Samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request PUT 'https://mijn.host/api/v2/domains/dns-templates/1000' \
--header 'Accept;' \
--header 'User-Agent: my-application/1.0.0' \
--header 'API-key: <api-key>' \
--header 'Content-Type: application/json' \
--data-raw '{
    "alias": "My DNS Template",
    "default": false,
    "records": [
        {
            "type": "A",
            "name": "",
            "value": "192.168.1.1",
            "ttl": 300
        },
        {
            "type": "CNAME",
            "name": "www",
            "value": "www.example.nl",
            "ttl": 300
        },
        {
            "type": "CNAME",
            "name": "mail",
            "value": "mail.example.nl",
            "ttl": 300
        },
        {
            "type": "MX",
            "name": "",
            "value": "mail.example.nl",
            "ttl": 300,
            "priority": 10
        },
        {
            "type": "TXT",
            "name": "",
            "value": "v=spf1 include:_spf.example.nl ~all",
            "ttl": 7200
        },
        {
            "type": "AAAA",
            "name": "",
            "value": "2001:41d0:302:1100:0:0:5:b92b",
            "ttl": 7200
        }
    ]
}'

Responses

🟢200Success
application/json
Body

Example
{
    "status": 200,
    "status_description": "DNS template updated"
}
🟠400Invalid input
Modified at 2025-08-07 13:30:31
Previous
Create template
Next
Get template
Built with