DRY: use _API_ROOT directly in _get_endpoint
move host part of the URL to the Api class
add default scopes and personas to api
we need the _api member in classmethods as well, so saving it in __init__ is no good
style: use the _api class member instead of the closure variable
bugfix

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
DRY: refactor out the Authorization header

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
offline_access is giving trouble

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
fix the Token.read method

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
keep CRUD methods public

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
add a Token.save method just to be coherent with the Client API

though I don't think it's going to be used

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
convert Token.accessTokenExpiresAt to datetime object

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
Merge pull request #2 from Lacrymology/IDCubed/pr1

Fixes from @maurycyp and work from there
utility method to wrap HTTPErrors with MitreIdExceptions

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
Refs #806.
don't lose the original exceptions when raising a MitreIdException

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
Refs #806.
make sure the created client is deleted even if a test fails

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
Refs #806.
until tokens stop expiring, I cannot be sure I'll know the default token's
properties

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
Refs #806.
new token

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
Refs #806.
Token.read() doesn't have default values anymore

Signed-off-by: Tomas Neme <lacrymology@gmail.com>
Refs #806.
Merge pull request #1 from Lacrymology/master

Thanks @lacrymology!