The old libary didn't support OAuth version 2.0, which fosoauthserver bundles uses. Replacing the OAuth libs with a different one.
Fixed the oauth libs. Everything works now for logging in and saving the data.