Duncan_Stewart | 2018-08-13 19:28:28 UTC | #1
I'm building out a process to delete the contacts in a ContactList DELETE /api/v2/outbound/contactlists/{contactListId}/contacts and I don't see an example in JSON for how to format / provide the Contact.Ids that I want to delete.
tim.smith | 2018-08-13 19:37:38 UTC | #2
It's a query string array, so something like /api/v2/outbound/contactlists/f19465cf-5bc6-4871-b59f-5307575a3ddf/contacts?contactIds=1234,5678,9012
Duncan_Stewart | 2018-08-13 20:22:16 UTC | #3
In Postman I get '400 Bad Request' without any further details. I'm using the ContactList inin-outbound-id for the contactId.
tim.smith | 2018-08-13 20:25:20 UTC | #4
What's your request URL? Correlation ID?
Duncan_Stewart | 2018-08-13 20:39:57 UTC | #5
I'm not actually getting an error that I can see (Postman n00b) - the URL I'm trying is https://api.mypurecloud.com/api/v2/outbound/contactlists/e287404b-e731-4168-99fe-af1c152037fd/contacts?contactIds='e06e39685b4308c4a8c38a5ec46156a6'
tim.smith | 2018-08-13 20:40:29 UTC | #6
Don't use quotes in the URL.
Duncan_Stewart | 2018-08-13 20:46:10 UTC | #7
That, and not trying to debug too hard. That's going to be a serious URL if I have a couple hundred Contacts to delete..
(I can chunk my requests, I suppose..)
Thanks!
Duncan_Stewart | 2018-08-21 16:44:02 UTC | #8
I'm currently working with Salesforce support on an issue I'm having creating that URL, specifically appending the ContactList.Ids. Is there any movement towards having a DELETE method on ContactList/Contacts that would clear the list w/o deleting the list?
I'm hoping to resolve the URL construction problem soon, but even so, passing 10's of IDs in a URL string when the goal is just to dump all of them while retaining the list container is overkill. Since that container is critical for both the Campaign and the Outbound IVR it's associated to, I'd think that method would/could prove quite popular :D .
tim.smith | 2018-08-21 16:52:42 UTC | #9
I'm not aware of any pending work for that. You can request it here: https://purecloud.ideas.aha.io/ideas
Duncan_Stewart | 2018-08-23 13:37:53 UTC | #10
Having trouble accessing that; my forum credentials aren't the correct type.
tim.smith | 2018-08-23 14:09:29 UTC | #11
I think you sign in to that with your support credentials; it's definitely not the credentials for this forum. If you need further assistance, try posting on the community forum or opening a ticket with Care. I don't have access to administer that site.
system | 2018-09-23 14:17:29 UTC | #12
This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.
This post was migrated from the old Developer Forum.
ref: 3363