add_internal_dnc tool manages your organization’s private Do Not Call list. Use it to add numbers when contacts request no further calls, or remove numbers when appropriate.
Parameters
Action to perform:
add- Add numbers to Internal DNC listremove- Remove numbers from Internal DNC list (requires an elevated role, see below)
remove requires an elevated role. The API key’s user must be a
Supervisor or Administrator, unless removal has been enabled for the Agent
role on your account. add is available to every role. An Agent key
attempting remove fails with API_ERROR.See Internal DNC List for the underlying
API.Response
The underlying API confirms an
add or remove without saying what each
number’s prior state was, so the tool reads the list immediately before
changing it and reports the difference. Each status therefore reflects a
snapshot taken just before the change; a concurrent edit to the same list can
make it stale. results is omitted entirely if that read does not return
JSON — success still tells you whether the change itself went through.Error Codes
Examples
- Add Request
- Add Response
- Remove Request
- Remove Response
Usage Notes
- Adding a number that already exists has no effect (idempotent);
resultsreports it asalready_exists - Removing a number that isn’t on the list has no effect;
resultsreports it asnot_found - Use
projIdto maintain separate Internal DNC lists per project or client - Phone numbers must be exactly 10 digits without formatting