I have a use-case where I need to access all available objects rather than just the first page of results from the API. I've added a get_all function to the GraphAPI class to do so.
modified to submit access_token as a GET parameter on POST and DELETE…
merged from upstream
generator for loading all results when results are paged
added docstring to get_all
This is really cool, but I'd rather refactor _query and get to facilitate for this behavior than introduce get_all. What are your thoughts on implementing a page argument to get that defaults to False, but returns an interator instead of a dictionary if set to True?
refactored get_all into get function
updated unit tests for new interface
Good idea, I've refactored this as suggested.
I've merged this and bumped the version to 0.3. Thanks, @paulgb – this is an awesome feature.