add support for collections

In reference to issue #28 

This hasn't been tested in all scenarios - only one project - but it works in production in that scenario.
`page_or_pose` should be `page_or_post`