Multiple website delete with API

i dont know what a error it was, but after trying to use SitesManager.addSite, in my dashboard were created about 1700 websites. Because of wrong API parameters are the urls not valid and contain code parts.
So i want to delete now all these websites, because do it manually in dashboard is not good solution. Is there the way how to delete it with help of API. I know SitesManager.deleteSite, but it deletes only 1 website by idSite.
Can someone tell me pls how to add array in API or maybe another solution for it?
Thank you!)


Honestly the easiest solution is to use your favourite scripting language and write a simple script that loops over the ids and does a API request for every one of them.
Even a simple for loop in bash with curl would work.

1 Like