dns.zones.import-transferCopy the zone from its current primary by AXFR (a one-time move), replacing sets with the same name and type
The primary must allow a transfer to the addresses in importFrom (zone-transfer get). SOA and apex NS are skipped, as are DNSSEC records and types not served here (listed in skipped). Use dryRun first to see what would be written.
Request syntax
POST /dns/api/zones/{id}/import-transfer
{
"primary": "string",
"port": "number",
"tsig": "object",
"dryRun": "boolean"
}Path parameters
idRequiredstring
Constraints: uuid
Request body
primaryRequiredstring
The primary to transfer from: an IP address or a host name. Only public addresses are dialled; a name with any private address is refused
Constraints: 1-253 chars
portOptionalnumber
TCP port, 1 to 65535. Absent: 53
Constraints: integer, 1-65535
tsigOptionalobject
Sign the request and verify every signed answer with this key. Absent: unsigned
Constraints: JSON
dryRunOptionalboolean
Transfer and parse, write nothing: the answer lists what would be imported
Response
200 with { imported, wouldImport, skipped, transfer: { serial, records, messages, bytes, signed } }, plus records (each { name, type, ttl, values }) on a dry run. 502 "Transfer from … failed: …" when the primary refused, did not answer within 30 s, or its TSIG did not verify; 400 "Nothing imported: …" for records that do not validate; 409 past 10,000 record sets. Nothing is written on a refusal.
A JSON response is wrapped as { "success": true, "data": … }; the CLI prints the whole body with --json.
Errors
- 400The request does not pass the schema above. The body is { "error": …, "issues": […] }, one issue per field.
- 401No credentials, or an access key that is unknown, revoked or expired.
- 403The caller's policies do not allow dns:ImportZone on this resource. The body names the action and the resource, and the refusal is recorded in the audit log.
- 404The resource does not exist in your organization.
Examples
The required parameters only, with example values. Replace id and the other placeholders with your own.
dcloud dns zones import-transfer id --primary examplecurl -X POST "https://console.platform.deutschecloud.app/dns/api/zones/id/import-transfer" \
-H "Authorization: EWS-ACCESS-KEY $ACCESS_KEY" \
-H "Content-Type: application/json" \
-d '{"primary":"example"}'import { DcloudClient } from '@dcloud/sdk';
const client = new DcloudClient();
const result = await client.dns.zones.importTransfer({ id: "id", primary: "example" });from dcloud import Client
client = Client()
result = client.dns.zones.import_transfer(id="id", primary="example")Generated from the API description, the same one the API checks requests against and the CLI is built from. MCP tool: dcloud_dns_zones_import-transfer.