---
title: DNS Lookup
slug: dns-lookup
url: https://apyverse.com/apyhub/service/dns-lookup
provider: ApyHub
categories: [Data Validation, Developer Tools, Geolocation]
tags: [dns, dns-lookup, domain-resolution, mx-records, txt-records, reverse-dns]
auth: api_key
---

# DNS Lookup

Query A, AAAA, MX, NS, TXT, CNAME, or PTR records for a host. Get structured answers with status, addresses, names, TXT, MX, or reverse DNS targets.

## Endpoints

| Method | Path | Description | Atoms |
| --- | --- | --- | --- |
| GET | `` | What it does Looks up DNS records for the specified host and returns a JSON object containing the D… | 10 |

## About

## What it does
DNS Lookup lets you query a hostname or IP address and get the resolver’s answer back as structured DNS data. Send a `host` and, optionally, a record `type` of `A`, `AAAA`, `MX`, `NS`, `TXT`, `CNAME`, or `PTR`.

The response includes a `data` object with the queried `host`, requested `type`, and a `status` value of `OK`, `NXDOMAIN`, `NODATA`, or `ERROR`. Depending on the record type, the payload also returns `addresses` for `A` and `AAAA` records, `mx` entries with `preference` and `exchange`, `names` for `NS` or `CNAME`, `txt` strings for TXT records, and `ptr` target names for reverse lookups.

Use DNS Lookup when you need to verify that a domain resolves, inspect mail routing, check TXT records for SPF or verification setups, or confirm reverse DNS for an IP address. It’s a straightforward way to add DNS inspection to onboarding flows, diagnostics, monitoring, or support tooling without parsing raw resolver output.

The response keeps the record-type-specific fields separated, so you only read the data that applies to the query you made.

## Usage

Authenticate with an ApyHub API key in the `apy-token` header.
Full docs and a live playground: https://apyverse.com/apyhub/service/dns-lookup
