Skip to content

DNC (Do Not Call) API

Do-not-call list management and queries.

Overview

The DNC API allows you to manage Do-Not-Call lists. These are lists of phone numbers that should not be contacted. DNC lists can be campaign-specific (limiting restrictions to a single campaign) or global (restricting all campaigns from contacting).

Endpoints

Update DNC—API

Update a DNC record.

Endpoint: POST /dnc/update

Authentication: Required (auth_token)

Parameters

NameTypeRequiredDescription
auth_tokenstringYesAuthentication token
idstringYesDNC ID to update
phone_numberstringNoPhone number
phone_codestringNoCountry/region phone code
campaign_idstringNoCampaign ID (0 for global)
reasonstringNoReason for DNC listing (leave blank to clear)
purposestringNoPurpose of DNC entry

Request Example

POST https://api.convoso.com/v1/dnc/update
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&id=5083&phone_number=5551234567&reason=Customer%20Request

Response Example

json
{
  "success": true,
  "id": 5083
}

Response Fields

FieldTypeDescription
successbooleanSuccess status of update
idintegerUpdated DNC ID

Error Codes

CodeDescription
6004Invalid phone number format
6008Phone number already in DNC
6026Invalid campaign ID
6056DNC ID not found
6057Invalid reason code
6058Invalid purpose value
6059Update operation failed

Insert DNC—API

Insert phone number into DNC list.

Endpoint: POST /dnc/insert

Authentication: Required (auth_token)

Parameters

NameTypeRequiredDescription
auth_tokenstringYesAuthentication token
phone_numberstringYesPhone number to add to DNC
phone_codestringYesCountry/region phone code
campaign_idstringYesCampaign ID (0 for global)
reasonstringNoReason for DNC listing
purposestringNoPurpose of DNC entry

Phone Code Reference

CountryCode
USA/Canada1
UK44
Australia61
Germany49
France33
Spain34
India91
China86
Mexico52
Brazil55

Request Examples

POST https://api.convoso.com/v1/dnc/insert
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&phone_number=5551234567&phone_code=1&campaign_id=0&reason=Customer%20Request
POST https://api.convoso.com/v1/dnc/insert
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&phone_number=5551234567&phone_code=1&campaign_id=111

Response Example

json
{
  "success": true,
  "id": 1
}

Response Fields

FieldTypeDescription
successbooleanSuccess status
idintegerID of newly created DNC entry

Error Codes

CodeDescription
6006Invalid phone number
6007Duplicate entry
6008Phone already in DNC
6026Invalid campaign ID
6056Insert operation failed
6057Invalid reason
6058Invalid purpose

Campaign ID Values

ValueMeaning
-1Purpose type DNC
0Global DNC (all campaigns)
Specific IDCampaign-specific DNC

Use Cases

  1. Global DNC: Prevent contact across all campaigns
  2. Campaign-Specific: Block within single campaign
  3. Regulatory Compliance: Add opt-out requests
  4. Customer Requests: Honor do-not-call requests
  5. Dead Numbers: Prevent dialing invalid numbers

Search DNC—API

Search DNC list.

Endpoint: POST /dnc/search

Authentication: Required (auth_token)

Parameters

NameTypeRequiredDescription
auth_tokenstringYesAuthentication token
idstringNoFilter by DNC ID
campaign_idstringNoFilter by campaign ID
phone_numberstringNoFilter by phone number
phone_codestringNoFilter by phone code
insert_datestringNoFilter by insert date (YYYY-MM-DD hh:mm:ss)
offsetintegerNoPagination offset (default 0, max 100000)
limitintegerNoResults per page (default 100, max 1000)
reasonstringNoFilter by reason: -BLANK- or -NOTBLANK-
purposestringNoFilter by purpose

Request Examples

POST https://api.convoso.com/v1/dnc/search
Content-Type: application/x-www-form-urlencoded

auth_token=abc123
POST https://api.convoso.com/v1/dnc/search
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&phone_number=5551234567
POST https://api.convoso.com/v1/dnc/search
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&campaign_id=111&limit=500
POST https://api.convoso.com/v1/dnc/search
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&insert_date=2026-03-03 10:30:00&offset=0&limit=100

Response Example

json
{
  "data": {
    "offset": 0,
    "limit": 100,
    "total": 350,
    "entries": [
      {
        "id": "5083",
        "phone_number": "5551234567",
        "campaign_id": "0",
        "insert_date": "2026-03-03",
        "phone_code": "1",
        "campaign_uid": "0",
        "campaign_name": "Global DNC"
      },
      {
        "id": "5084",
        "phone_number": "5551234568",
        "campaign_id": "111",
        "insert_date": "2026-03-03",
        "phone_code": "1",
        "campaign_uid": "111",
        "campaign_name": "Sales Campaign"
      }
    ]
  }
}

Response Fields

Root Level:

FieldTypeDescription
dataobjectData wrapper object

Data Object:

FieldTypeDescription
offsetintegerPagination offset
limitintegerResults per page
totalintegerTotal matching entries
entriesarrayArray of DNC records

DNC Entry:

FieldTypeDescription
idstringDNC entry ID
phone_numberstringPhone number on DNC list
campaign_idstringCampaign ID (0 for global)
insert_datestringDate added to DNC
phone_codestringPhone code
campaign_uidstringCampaign unique ID
campaign_namestringCampaign name

Filtering Examples

Find specific number:

POST https://api.convoso.com/v1/dnc/search
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&phone_number=5551234567

Campaign-specific DNC:

POST https://api.convoso.com/v1/dnc/search
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&campaign_id=111

Global DNC only:

POST https://api.convoso.com/v1/dnc/search
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&campaign_id=0

Purpose type DNC:

POST https://api.convoso.com/v1/dnc/search
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&campaign_id=-1

Entries without reason:

POST https://api.convoso.com/v1/dnc/search
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&reason=-BLANK-

Entries with reason:

POST https://api.convoso.com/v1/dnc/search
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&reason=-NOTBLANK-

Entries added on specific date:

POST https://api.convoso.com/v1/dnc/search
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&insert_date=2026-03-03 14:30:00

Error Codes

CodeDescription
6006Invalid phone format
6008Invalid parameter
6026Invalid campaign ID
6057Invalid reason filter
6058Invalid purpose filter

DNC Delete—API

Remove entries from DNC lists.

Endpoint: POST /dnc/delete

Authentication: Required (auth_token)

Parameters

NameTypeRequiredDescription
auth_tokenstringYesAuthentication token
phone_numberstringYesPhone number to remove from DNC
phone_codestringYesCountry/region phone code
campaign_idstringYesCampaign ID (0 for global)
update_lead_statusbooleanNoUpdate associated lead status
lead_statusstringNoStatus to set on associated leads

Request Examples

POST https://api.convoso.com/v1/dnc/delete
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&phone_number=5551234567&phone_code=1&campaign_id=0
POST https://api.convoso.com/v1/dnc/delete
Content-Type: application/x-www-form-urlencoded

auth_token=abc123&phone_number=5551234567&phone_code=1&campaign_id=111&update_lead_status=true&lead_status=ACTIVE

Response Example

json
{
  "success": true
}

Response Fields

FieldTypeDescription
successbooleanSuccess status of deletion

Error Codes

CodeDescription
6000Invalid phone number
6001Phone not found in DNC
6002Invalid campaign ID
6003Invalid phone code
6004Delete operation failed
6005Invalid lead status

Update Lead Status Option

When update_lead_status=true, you can optionally set all associated leads' status:

  • Useful when removing from DNC to restore leads to callable state
  • Leave blank to not change lead statuses
  • Use valid status codes from your system

Common DNC Workflows

Adding a Global DNC Entry

POST /dnc/insert
- phone_number: 5551234567
- phone_code: 1
- campaign_id: 0
- reason: Customer Request

Result: Number blocked across all campaigns

Adding Campaign-Specific DNC

POST /dnc/insert
- phone_number: 5551234567
- phone_code: 1
- campaign_id: 111

Result: Number blocked only for campaign 111

Checking if Number is DNC

POST /dnc/search
- phone_number: 5551234567

Result: Returns all DNC entries for that number

Removing from DNC

POST /dnc/delete
- phone_number: 5551234567
- phone_code: 1
- campaign_id: 0

Result: Number can be dialed again

Batch DNC Addition (Python)

python
dnc_numbers = [
    ('5551234567', '1', '0'),  # phone, code, campaign
    ('5551234568', '1', '0'),
    ('5551234569', '1', '0'),
]

for phone, code, campaign in dnc_numbers:
    requests.post(
        'https://api.convoso.com/v1/dnc/insert',
        data={
            'auth_token': token,
            'phone_number': phone,
            'phone_code': code,
            'campaign_id': campaign,
            'reason': 'Batch Import'
        }
    )

Best Practices

  1. Use campaign_id=0 for most opt-outs (global scope)
  2. Always include phone_code for international numbers
  3. Document reasons for audit trail
  4. Verify before deleting to avoid unwanted dialing
  5. Batch import large DNC files outside peak hours
  6. Regular audits of DNC list for accuracy
  7. Coordinate with compliance for regulatory DNC lists

Regulatory Considerations

Different jurisdictions have DNC regulations:

  • USA: FTC Do-Not-Call Registry compliance required
  • UK: ICO Privacy Shield requirements
  • GDPR: EU right to be forgotten
  • CCPA: California consumer privacy rights

Consult legal team for your jurisdiction's requirements.



Last Updated: 2026-03-03

Community project — not affiliated with or endorsed by Convoso.