mysociety / popit-api

DEPRECATED - Development on PopIt has stopped and it is no longer being maintained
https://goo.gl/Vvej4Q
Other
17 stars 3 forks source link

Add bulk delete endpoints to the API #128

Closed chrismytton closed 9 years ago

chrismytton commented 9 years ago

This allows you to remove all the people, organizations, memberships and posts from an instance in one go. Alternatively you can just remove the records from an individual collection.

Fixes https://github.com/mysociety/popit/issues/464

struan commented 9 years ago

One thing this doesn't do is remove the elastic search indexes so if you delete a collection and then do /search/persons it will still return things.

The deleting from mongo side looks fine though.

chrismytton commented 9 years ago

Oooh, good point. Shouldn't be too tricky to just drop the whole index for a given instance I don't suppose.