New permissions api
Add test cases for permissions API
Also changed response to return only permissions (not username)
Merge pull request #725 from openspending/687-authorization-api

687 authorization api