Adding JSON Web Token support

re-submitting to develop branch

addresses #140