Validate DNS records
Validate DNS records prior to update for the selected domain.
Validate DNS records prior to update for the selected domain.
If the validation is successful, the response will contain 200 Success code.
If there is validation error, the response will fail with 422 Validation error code.
Use this endpoint to verify DNS record validity before applying changes.
Authorizations
AuthorizationstringRequired
API Token authentication
Path parameters
domainstringRequiredExample:
Domain name
mydomain.tldBody
overwritebooleanOptionalDefault:
If true, resource records (RRs) matching name and type will be deleted and new RRs will be created,
otherwise resource records' ttl's are updated and new records are appended.
If no matching RRs are found, they are created.
trueExample: trueResponses
200
Success response
application/json
messagestringOptionalExample:
Request accepted401
Unauthenticated response
application/json
422
Validation error response
application/json
500
Error response
application/json
post/api/dns/v1/zones/{domain}/validate
POST /api/dns/v1/zones/{domain}/validate HTTP/1.1
Host: developers.hostinger.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 105
{
"overwrite": true,
"zone": [
{
"name": "www",
"records": [
{
"content": "mydomain.tld."
}
],
"ttl": 14400,
"type": "A"
}
]
}{
"message": "Request accepted"
}Last updated
Was this helpful?