alexziskind1 / nativescript-oauth

Other
35 stars 53 forks source link

Any plans to support non-interactive login #69

Open mykone opened 6 years ago

mykone commented 6 years ago

Hello, are there any plans to support non-interactive login, sending login and password automatically?

  const credentials = {
      email: '<email>',
      password: '<password>'
  };

  tnsOAuthModule.login(credentials)
       .then(()=>{
         callback('logged in');
       })
       .catch((er)=>{
         callback('Error Loggin in');
       });

I am trying to build an app which consumes Microsoft Office365 Calendar API, and I want the app to start automatically, login in the background, and list the calendar events.

If not possible, are there any alternatives. I tried simple-oauth2, but it doesn't seem supported by Nativescript.

Thanks

lumayara commented 6 years ago

I have a similar scenario where I want the user to login only once and not anymore but I still need a token to access the user's stuff in office 365... I have been looking for a solution but have not found so far.. I am using refresh tokens but still is not the ideal scenario. Any insights? Thank you!