2👍
✅
Instead of passing the username and password as part of the header send it as data in the body instead. Here’s an example of doing this with jQuery: http://jpadilla.com/post/73791304724/auth-with-json-web-tokens
Taking from the example the data you pass in the body should look like this:
{ username: "admin", password: "abc123"}
Source:stackexchange.com