Post

2 followers Follow
0
Avatar

How to delete > 10.000 items?

I couldn't find any way to delete multiple items at once, so I decided to use the API. I want to truncate all my apps (total +/- 25.000 items). Due to the API limit (max. 250/hour for deleting items), I want to delete all the items from one app at once:

I've all the item_id's in an array (about 1400), using PHP:

$app = PodioItem::delete(implode(',', $delete));

This works for 500 items, but if I want to delete 1000 items, it doesn't work. Why not? Unfortunatly, I don't receive an error but a empty response. I think the maximum number of items I can delete at once is about 750.

How can I delete all items as easy as possible?

Stephan Vierkant Answered

Please sign in to leave a comment.

5 comments

0
Avatar

If you want to delete all items, it is much easier to first clone the app, and then delete the original app.

Christian Holm 0 votes
Comment actions Permalink
0
Avatar

That's not a solution, but a work around ;-)

The problem is that I'm using the API to sync all my data with another application (MailChimp). Deleting the original app would change the app_id, so I have to re-configure my other application.

Stephan Vierkant 0 votes
Comment actions Permalink
0
Avatar

It would still be a lot simpler I think. Deleting 25k items is a pretty big operation. 

There is no limit as such on the delete items call. We do queue up the deletion, so it will not happen all at once. They will be deleted on item per second as we want to spread out the load. However since the item_ids are part of the URL, I'm pretty sure you would hit the URL max length also.

Christian Holm 0 votes
Comment actions Permalink