# Insight Stats

GET /easm/assets/stats/insights: Groups assets of an asset_type by an attribute (insight_by: registrar, expiry date, registrant organization, IP, name server…

Source: https://docs.deepinfo.com/reference/easm/insight-stats/

Last updated: 2026-09-27

---
`GET https://api.deepinfo.com/v1/easm/assets/stats/insights`

Groups assets of an `asset_type` by an attribute (`insight_by`: registrar, expiry date, registrant organization, IP, name server, mail server, ASN, SSL certificate, SSL issuer, SSL subject organization or HTTP status) and counts them.

## Authentication

Send your API key in the `apikey` request header.

## Query Parameters

| Parameter | Required | Description | Example |
|---|---|---|---|
| `asset_type` | Required | One of: `domain`, `subdomain`, `ip`, `website`. | `domain` |
| `insight_by` | Required | One of: `whois_registrar`, `whois_expiry_date`, `whois_registrant_organization`, `dns_ip_address`, `dns_name_server`, `dns_mail_server`, `asn`, `ssl_certificate`, `ssl_issuer`, `ssl_subject_organization`, `http_status`. | `whois_registrar` |

## Response Fields

An array of objects:

| Field | Type |
|---|---|
| `name` | string |
| `count` | integer |

## Response Schema

_Inferred from examples._ Built from the saved 2xx example response: the fields it contains, with the types seen there. It is not a contract. The response body is an array; `[]` marks its elements.

| Field | Type |
|---|---|
| `[].name` | string |
| `[].count` | number |

## Examples

### 200 · OK

```bash
curl 'https://api.deepinfo.com/v1/easm/assets/stats/insights?asset_type=domain&insight_by=whois_registrar' \
  -H 'apikey: YOUR_API_KEY' \
  -H 'Accept: application/json'
```

`Content-Type: application/json` · `deepinfo-request-id: 00000000-0000-4000-8000-0000356d0001`

```json
[
  {
    "name": "Acme insight",
    "count": 29
  },
  {
    "name": "Acme insight 2",
    "count": 30
  }
]
```

### 400 · Invalid Parameter (invalid asset_type=invalid_value)

```bash
curl 'https://api.deepinfo.com/v1/easm/assets/stats/insights?asset_type=invalid_value&insight_by=whois_registrar' \
  -H 'apikey: YOUR_API_KEY' \
  -H 'Accept: application/json'
```

`Content-Type: application/json` · `deepinfo-request-id: 00000000-0000-4000-8000-0000356d0001`

```json
{
  "code": 10400,
  "parameters": [
    {
      "param": "asset_type",
      "details": [
        "Select a valid choice."
      ]
    }
  ],
  "solution": "https://docs.deepinfo.com/reference/"
}
```
