Forum Discussion
Peter1
Dec 23, 2021Copper Contributor
Bulk Delete via Rest invoke in Poweshell
Hi All,
I am using the below rest method from PowerShell to delete the ID (123) and it is working ,now i have 100 + ids ,how can delete all the 100+ ID 's one by one automatically one after other.Kindly suggest
Invoke-RestMethod -Uri 'http://127.0.0.1/api/data(123)' -Method Delete -ContentType "application/xml" -Credential username
- farismalaebSteel ContributorPlace them in a loop using For loop
https://adamtheautomator.com/powershell-for-loop/