# Response Format

A response is a JSON object: a `records` array plus paging, account, and status fields.

```json
{
  "records": [ ... ],
  "totalResults": 105,
  "moreResultsAvailable": 5,
  "next": "/nhi?token=YOUR_TOKEN&domain=example.com&next=CURSOR",
  "requestsLeft": 989,
  "domainStatus": "active"
}
```

## Root fields

| Field | Type | Description |
| --- | --- | --- |
| `records` | array | Matching records - see [Record Data Fields](nhi-data-fields). Up to 100 per page. |
| `totalResults` | integer | Total records matching the query. |
| `moreResultsAvailable` | integer | Records still available after this page. |
| `next` | string | Relative URL of the next page, or `null` when there is none. Append it to `https://api.webz.io` - see [Pagination](nhi-pagination). |
| `requestsLeft` | integer | Your remaining Non-Human Identities (NHI) API credit balance. |
| `domainStatus` | string | `pending` while the initial scan of a newly queried domain is running; `active` once it has completed. See below. |

## `domainStatus`

The first query for a domain starts monitoring it. While `pending`, results may be empty or partial - the request is still valid and still costs a credit. Once `active`, the initial scan is done; records continue to be added as new leaks are discovered, so re-query periodically.
