Allow 'page' parameter to be configurable.

Refactor and testing of @meowcakes's #407.

Signed-off-by: Ben Corlett <bencorlett@me.com>