DonorDrive/PublicAPI

Feature Request: Simple endpoint values to sort results

timmixell opened this issue · 1 comments

We currently require users to have an understanding of SQL knowledge to filter and sort the results of various endpoints. It maybe be beneficial to have /top, /newest (alias for our current default), /oldest as additional values in the endpoint path, that would allow users to grab relevant information without having to get into the muck of SQL:

/api/participants/newest - would retrieve the newest participants
/api/participants/1234/donations/top - would retrieve single-donations in descending order of amount
/api/events/500/teams/top - would retrieve the top fundraising teams for a given event (id: 500)

we lose flexibility supporting this request.