---
title: "Add DNS Zone"
method: POST
path: "/dnszone"
tags: ["DNS Zone"]
---

# Add DNS Zone

`POST /dnszone`

## Request body

- DnsZoneAddModel
  - `Domain` string, required — The domain that will be added.
  - `Records` AddDnsRecordModel[], nullable — Optional array of DNS records to add when creating the zone.
    - `Type` 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 — 0 = A 1 = AAAA 2 = CNAME 3 = TXT 4 = MX 5 = Redirect 6 = Flatten 7 = PullZone 8 = SRV 9 = CAA 10 = PTR 11 = Script 12 = NS 13 = SVCB 14 = HTTPS 15 = TLSA
    - `Ttl` integer, nullable
    - `Value` string, nullable
    - `Name` string, nullable
    - `Weight` integer, nullable
    - `Priority` integer, nullable
    - `Flags` integer, nullable
    - `Tag` string, nullable
    - `Port` integer, nullable
    - `PullZoneId` integer, nullable
    - `ScriptId` integer, nullable
    - `Accelerated` boolean, nullable
    - `MonitorType` 0 | 1 | 2 | 3 — 0 = None 1 = Ping 2 = Http 3 = Monitor
    - `GeolocationLatitude` number, double, nullable
    - `GeolocationLongitude` number, double, nullable
    - `LatencyZone` string, nullable
    - `SmartRoutingType` 0 | 1 | 2 — 0 = None 1 = Latency 2 = Geolocation
    - `Disabled` boolean, nullable
    - `EnviromentalVariables` DnsRecordEnviromentalVariableModel[], nullable
      - `Name` string, nullable
      - `Value` string, nullable
    - `Comment` string, nullable
    - `AutoSslIssuance` boolean, nullable

## Response `201`

The DNS Zone was successfuly added

## Other responses

- `400` — Failed adding the DNS Zone. Model validation failed
- `401` — The request authorization failed
- `500` — Internal Server Error

---

[API](https://skmtc.net/bunny/apis/bunny-net-cdn-logging.md) · [All operations](https://skmtc.net/bunny/apis/bunny-net-cdn-logging/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/bunny/bunny-net-cdn-logging/versions/9e622620664b/schema)
