Api query branch pagination update

This should pretty much solve #85. Please do not merge yet, because we still have to figure out permissions for Submissions' index. Feedback/review would be appreciated.
? Is this incomplete?