# Reset a DNS zone to the server defaults

This function resets a domain's DNS
zone to the server's default zone template.

Important:

- This action destroys every custom record in the zone. Records that
  the zone template does not recreate, for example MX, TXT and
  CNAME records added by hand, are lost.
- The reset outcome is reported in the data field rather than in the
  status field. A call can succeed at the API level while the zone
  rebuild itself fails, so check the result.status field in the
  returned data.

When you disable the DNS role,
the system disables this function.

Endpoint: GET /ZoneEdit/resetzone
Version: 11.138.0.10
Security: BasicAuth

## Query parameters:

  - `domain` (string, required)
    The domain whose DNS zone to reset.
    Example: "example.com"

## Response 200 fields (application/json):

  - `data` (array)
    A single entry holding the zone rebuild's own reply. The rebuild outcome is reported here rather than in the response's status field.

  - `data.result` (object)
    The reply from the zone rebuild.

  - `data.result.checkmx` (object,null)
    The outcome of the mail exchanger check that the system runs after it rebuilds the zone. The system omits this field when the rebuild fails.

  - `data.result.status` (integer)
    Whether the system rebuilt the zone.
* 1 - The system rebuilt the zone.
* 0 - The rebuild failed. Check the statusmsg field for more details.
    Enum: 0, 1

  - `data.result.statusmsg` (string)
    A message that describes the rebuild's outcome.
    Example: "Zone Reset"

  - `errors` (array,null)

  - `messages` (array,null)

  - `metadata` (object)

  - `metadata.transformed` (integer)

  - `status` (integer)
    * 1 — Success.
* 0 — Failed. Check the errors field for more details.
    Enum: 0, 1

  - `warnings` (array,null)


