Preview DNS records from a nameserver

POST /api/v2/dns-zones/{id}/smartcopy-scan

Scan one public nameserver for a domain and compare the discovered records with the selected HostUp DNS zone.

Get {id} from GET /api/v2/dns-zones data[].id. sourceDomain is optional and defaults to the selected zone's domain.

This operation only builds a preview; it does not change the zone.

Review each record's annotation before importing records into the zone.

Validation failures use errors[] with /nameserver or /sourceDomain pointers and stable field codes.

Domains & DNS DNS

Authentication

Required API scope: write:dns

Authenticate with an API key in the Authorization: Bearer <token> header.

Context

Path Parameters

id string required Example: zone_01hxa3b4c5d6e7f8g9h0j1k2m3

Public DNS zone ID from GET /api/v2/dns-zones. Do not invent this value; use the exact ID returned by the referenced API response.

Headers

Authorization Bearer <token>
Accept application/json
Content-Type application/json

Body

required
application/json
nameserver string required · Example: ns1.example.net

Public nameserver hostname or IP address to query directly.

sourceDomain string · Example: example.com

Domain to query at the source nameserver. Omit to use the destination zone's domain.

Responses

200 SmartCopy comparison preview.
records array<object> required
records[].type string · enum required · Example: A
A
AAAA
CNAME
ALIAS
MX
TXT
CAA
SRV
NS
TLSA
records[].name string required · Example: www

Record name relative to the destination zone. @ is the zone root.

records[].value string required · Example: 192.0.2.10
records[].ttl number · Example: 3600
records[].priority number · Example: 10
records[].weight number · Example: 5
records[].port number · Example: 5060
records[].isCloudflare boolean · Example: false

True when the source record has proxy-specific behavior that needs review.

records[].cloudflareWarning string

Customer-facing warning about source proxy behavior, when applicable.

records[].recordSubtype string · enum · Example: SPF
SPF
DMARC
DKIM
DOMAINKEY
MS365
records[].annotation string · enum required · Example: new

How the discovered record compares with the destination zone.

new
duplicate
conflict
records[].conflictingValue string

Existing destination value when annotation is conflict.

domain string · nullable required · Example: example.com

nameserver string · nullable required · Example: ns1.example.net

existingCount integer · min: 0 required · Example: 8
400 Invalid request or source lookup. Inspect errors[0].code: missing_nameserver, invalid_nameserver, nameserver_not_public, nameserver_unreachable, dns_scan_failed, or invalid_source_domain.
type string · Example: https://developer.hostup.se/errors/invalid_request
title string · Example: Validation failed
status integer · Example: 400
detail string · Example: The request body failed validation.
code string · Example: invalid_request

Stable machine-readable code. Branch on this field, not on detail.

instance string · Example: /api/v2/orders
requestId string · Example: req_01hxa3b4c5d6e7f8g9h0j1k2m3
timestamp string · Example: 2026-04-27T12:34:56.000Z
errors array<object>

Field-level validation errors when code is invalid_request.

errors[].pointer string required · Example: /items/0/eppCode
errors[].detail string required · Example: `eppCode` is required for this transfer.
errors[].code string required · Example: missing_required
extensions object
401 Unauthorized. Authentication is required.
type string · Example: https://developer.hostup.se/errors/invalid_request
title string · Example: Validation failed
status integer · Example: 400
detail string · Example: The request body failed validation.
code string · Example: invalid_request

Stable machine-readable code. Branch on this field, not on detail.

instance string · Example: /api/v2/orders
requestId string · Example: req_01hxa3b4c5d6e7f8g9h0j1k2m3
timestamp string · Example: 2026-04-27T12:34:56.000Z
errors array<object>

Field-level validation errors when code is invalid_request.

errors[].pointer string required · Example: /items/0/eppCode
errors[].detail string required · Example: `eppCode` is required for this transfer.
errors[].code string required · Example: missing_required
extensions object
403 Forbidden. The caller lacks a required scope or does not own the resource.
type string · Example: https://developer.hostup.se/errors/invalid_request
title string · Example: Validation failed
status integer · Example: 400
detail string · Example: The request body failed validation.
code string · Example: invalid_request

Stable machine-readable code. Branch on this field, not on detail.

instance string · Example: /api/v2/orders
requestId string · Example: req_01hxa3b4c5d6e7f8g9h0j1k2m3
timestamp string · Example: 2026-04-27T12:34:56.000Z
errors array<object>

Field-level validation errors when code is invalid_request.

errors[].pointer string required · Example: /items/0/eppCode
errors[].detail string required · Example: `eppCode` is required for this transfer.
errors[].code string required · Example: missing_required
extensions object
404 The selected DNS zone does not exist or is not accessible to the caller.
type string · Example: https://developer.hostup.se/errors/invalid_request
title string · Example: Validation failed
status integer · Example: 400
detail string · Example: The request body failed validation.
code string · Example: invalid_request

Stable machine-readable code. Branch on this field, not on detail.

instance string · Example: /api/v2/orders
requestId string · Example: req_01hxa3b4c5d6e7f8g9h0j1k2m3
timestamp string · Example: 2026-04-27T12:34:56.000Z
errors array<object>

Field-level validation errors when code is invalid_request.

errors[].pointer string required · Example: /items/0/eppCode
errors[].detail string required · Example: `eppCode` is required for this transfer.
errors[].code string required · Example: missing_required
extensions object
429 Rate limited. Retry after the limit resets. 429 responses include Retry-After seconds plus X-RateLimit-* headers.
type string · Example: https://developer.hostup.se/errors/invalid_request
title string · Example: Validation failed
status integer · Example: 400
detail string · Example: The request body failed validation.
code string · Example: invalid_request

Stable machine-readable code. Branch on this field, not on detail.

instance string · Example: /api/v2/orders
requestId string · Example: req_01hxa3b4c5d6e7f8g9h0j1k2m3
timestamp string · Example: 2026-04-27T12:34:56.000Z
errors array<object>

Field-level validation errors when code is invalid_request.

errors[].pointer string required · Example: /items/0/eppCode
errors[].detail string required · Example: `eppCode` is required for this transfer.
errors[].code string required · Example: missing_required
extensions object
500 Internal error. Retry later or contact support if the issue persists.
type string · Example: https://developer.hostup.se/errors/invalid_request
title string · Example: Validation failed
status integer · Example: 400
detail string · Example: The request body failed validation.
code string · Example: invalid_request

Stable machine-readable code. Branch on this field, not on detail.

instance string · Example: /api/v2/orders
requestId string · Example: req_01hxa3b4c5d6e7f8g9h0j1k2m3
timestamp string · Example: 2026-04-27T12:34:56.000Z
errors array<object>

Field-level validation errors when code is invalid_request.

errors[].pointer string required · Example: /items/0/eppCode
errors[].detail string required · Example: `eppCode` is required for this transfer.
errors[].code string required · Example: missing_required
extensions object
POST https://cloud.hostup.se/api/v2/dns-zones/{id}/smartcopy-scan
For AI assistants
View as Markdown
cURL
curl -X POST "https://cloud.hostup.se/api/v2/dns-zones/zone_01hxa3b4c5d6e7f8g9h0j1k2m3/smartcopy-scan" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{
    "nameserver": "ns1.example.net",
    "sourceDomain": "example.com"
  }'
Response
{
  "records": [
    {
      "type": "A",
      "name": "www",
      "value": "192.0.2.10",
      "ttl": 3600,
      "annotation": "new"
    },
    {
      "type": "MX",
      "name": "@",
      "value": "mail.example.com",
      "priority": 10,
      "annotation": "conflict",
      "conflictingValue": "old-mail.example.com"
    }
  ],
  "domain": "example.com",
  "nameserver": "ns1.example.net",
  "existingCount": 8
}
Request Body Scan a source nameserver
{
  "nameserver": "ns1.example.net",
  "sourceDomain": "example.com"
}