Internal API call refactors
Merge branch 'master' of git://github.com/phrest/api