DNCs

Mass approve or unapprove DNC

Approve or unapprove many Do Not Call (DNC) entries in a single request, and optionally create any that do not exist yet.

When to use. Update the approval status of many numbers at once. For a single number, use POST /dnc to add one, or the {id}/approve and {id}/unapprove endpoints to change one entry.

Request body.

  • dnc (array, required): the entries to process. Each item has:
    • phone (string, required): the phone number.
    • approved (integer, required): target approval status, 0 for unapproved or 1 for approved.
    • country_iso (string): the two-letter country code (for example US) used to normalize the number.
    • permanent (integer): whether the entry is permanent, 0 for no or 1 for yes.
  • create_missing (boolean): set to true to create entries that are not found. A number is created only when it can be normalized.

Returns. { "dnc": [ ... ] } with one processed entry per input item. Returns an error if the dnc list is empty, or an item is missing its approved value.

Example. { "create_missing": true, "dnc": [ { "phone": "12125551234", "country_iso": "US", "approved": 1 } ] }

post/{sub_domain}/api/dnc/mass

Request

  • Base URL
    https://api.commpeak.com/dialer
  • URL
    https://api.commpeak.com/dialer/{sub_domain}/api/dnc/mass
  • Auth
    API key in header Authorization

Path parameters

sub_domainstring required

Dialer Name (subdomain)

Request body

create_missingboolean nullable

Set to true to create DNC entries that do not yet exist.

Response

Successful Response

Example response

{
  "dnc": [
    {
      "approved": 255,
      "approved_by_user_id": 42751242,
      "campaign_lead_id": 17957443,
      "id": 86591947,
      "lead_id": 0,
      "permanent": 0,
      "phone": "397606698848"
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.