ocilo / skype-http

Unofficial Skype API for Node.js via HTTP
https://ocilo.github.io/skype-http
MIT License
51 stars 24 forks source link

Strongly type Microsoft Account login errors #26

Closed demurgos closed 7 years ago

demurgos commented 7 years ago

This commit types most of the possible errors during a Skype login with the Microsoft Account workflow. One of the main features is that it detects invalid credentials. The errors are fully typed and you can use union types and discriminate on their name.

This MR also fixes an issue when the library thought that it had found the live token (#t) when it was in fact redirected to login page.

Closes #22

demurgos commented 7 years ago

I added the detection for the login limit and removed the ES5 build. The library can now use ES2015 objects. Since it is mainly targeted at a Node usage, it shouldn't cause any issues. If you still need to run it in an older browsers, a shim should be enough.