---
title: "Get DNC by phone"
method: GET
path: "/{sub_domain}/api/dnc/phone/{phone}/{country_iso}"
tags: ["DNCs"]
---

# Get DNC by phone

`GET /{sub_domain}/api/dnc/phone/{phone}/{country_iso}`

## Request

- Base URL: `https://api.commpeak.com/dialer`
- URL: `https://api.commpeak.com/dialer/{sub_domain}/api/dnc/phone/{phone}/{country_iso}`
- Auth: API key in header `Authorization`

Retrieve a Do Not Call (DNC) entry by phone number.

**When to use.** Check whether a specific number is on your DNC list when you do not have its ID. To look up by ID instead, use `GET /dnc/{id}`.

**Parameters.** `phone` (path): the phone number to look up. `country_iso` (path): the two-letter country code (ISO 3166-1 alpha-2, for example `US`) used to normalize the number before matching.

**Returns.** `{ "dnc": [ <entry> ] }`. Returns an error if no matching entry is found.

**Example.** `GET /api/dnc/phone/12125551234/US`

## Path parameters

- `phone` string, required: Phone number.
- `country_iso` string, required: Country ISO2 code, used to normalize the phone number.
- `sub_domain` string, required: Dialer Name (subdomain)

## Response `200`

Successful Response

- DNCResponse
  - `dnc` DNCItem[], required
    - `id` integer, nullable: DNC ID.
    - `phone` string, nullable: DNC phone number.
    - `lead_id` integer, nullable: Lead ID that the DNC was created from.
    - `campaign_lead_id` integer, nullable: Campaign Lead ID that the DNC was created from, can be null.
    - `approved` integer, nullable: Whether the DNC is approved: 0 = unapproved, 1 = approved.
    - `approved_by_user_id` integer, nullable: ID of the user who approved the DNC.
    - `permanent` integer, nullable: Whether the DNC is permanent: 0 = no, 1 = yes.
    - `first_name` string, nullable: Lead's first name.
    - `last_name` string, nullable: Lead's last name.
    - `username` string, nullable: Username of the user who approved the DNC.
    - `phone_normalized` string, nullable: Lead's phone number normalized.

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/commpeak/apis/commpeak-dialer-api.md) - [All operations](https://skmtc.dev/commpeak/apis/commpeak-dialer-api/llms.txt) - [OpenAPI document](https://skmtc.dev/commpeak/apis/commpeak-dialer-api/revisions/18c5edc07544?raw)
