[WIP] Make new authentication request more flexible and with Ajax request support

- [ ] Add specs