improved performance and added some new features

Improved performance by various database optimisations.
Implemented the option to select what fields to search in.
Implemented the option to select what part of the activity data the api should return
Please don't use `+` for string concatenation in python. Use `.join()` syntax or  string formatting. http://legacy.python.org/dev/peps/pep-0008/#programming-recommendations