Get list of all contacts with status 'DoNotMail' for an account
I am generating a report that gets the list of contacts that have the status 'DoNotMail' for accounts.
Currently I am using the C# api to get list of all contacts for an account and checking each contact if thier status is "DoNotMail". Considering accounts that have large number of contacts this is a time consuming task.
Is the any way to get the list of such contacts('DoNotDisturb') with a single API call?
You will get the first 50 contacts, and be provided with a "next" link to the next 50 contacts in do not mail, until there are no more. We can only provide 50 contacts at a time with the GET request. Otherwise you could bulk export your Do Not Mail contacts as a CSV or XLS.