fix token check
fix auth header, improve invalid token exception
Merge branch 'token-check'