Add querying
add funnel example and test
reformat api.py and client.py for pep8