# Return whether domains use recognized nameservers

This function indicates whether the account's domains' nameservers resolve to an IP address that this server recognizes as its own. It predicts the outcome of the create-time nameserver validation that runs when a domain is added to the account, without performing any privileged action.

Endpoint: GET /DNS/ensure_domains_use_recognized_nameservers
Version: 11.138.0.10
Security: BasicAuth

## Query parameters:

  - `domain` (string, required)
    The domain to check.

Note:

To check multiple domains, duplicate or increment the parameter name. For example, to check three domains, you could:
* Use the domain parameter multiple times.
* Use the domain, domain-1, and domain-2 parameters.
    Example: "example1.com"

## Response 200 fields (application/json):

  - `apiversion` (integer)
    The version of the API.
    Example: 3

  - `func` (string)
    The name of the method called.
    Example: "ensure_domains_use_recognized_nameservers"

  - `module` (string)
    The name of the module called.
    Example: "DNS"

  - `result` (object)

  - `result.data` (array,null)
    The results from each domain parameter's nameserver check.
* null - The domain would pass the create-time nameserver validation.
* An object describing why it would not, with a type field set to one of:
  * domain_not_registered - The domain has no resolvable nameserver IP addresses.
  * unrecognized_nameservers - The domain's nameservers do not resolve to an IP address this server recognizes as its own.

Note:

 The function returns the results from the domains in the same order that you called them.

 The entire call fails, rather than returning a per-domain result, when the check cannot be reliably determined from the calling user's process — for example, on a cPanel Cloud controller, or when the validator fails for a reason other than the two outcomes above. Treat a failed call as "unable to determine" rather than as every domain failing.
    Example: [{"message":"The system cannot use the domain \"example.com\" because its registered nameservers are not associated with this server.","type":"unrecognized_nameservers"}]

  - `result.data.message` (string)
    The validator's own localized message.
    Example: "The system cannot use the domain \"example.com\" because its registered nameservers are not associated with this server."

  - `result.data.type` (string)
    A short machine-readable reason code.
    Enum: "domain_not_registered", "unrecognized_nameservers"

  - `result.errors` (array,null)
    List of errors if the API failed.

  - `result.messages` (array,null)
    List of messages generated by the API.

  - `result.metadata` (object)

  - `result.metadata.transformed` (integer)
    Post-processing may have transformed the data.
    Enum: 1

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

  - `result.warnings` (array,null)
    List of warnings generated by the API. Warnings describe non-critical failures or other problematic conditions noted while running a API.


