mcorley
mcorley

Reputation: 767

Long lived authentication with OAuth in Android App

How can a user grant an Android application permission to access a resource via OAuth until they decide to revoke it? For example, in order to read data from a users Google calendar, an app needs to get an authentication token. How can an app get a long lived authentication token to access calendar data when it needs it?

Upvotes: 0

Views: 565

Answers (1)

Nick Johnson
Nick Johnson

Reputation: 101139

Yes, they can - you'll want to look into OAuth. The user can grant your app limited permission to access their calendar, which is persistent - once you have the OAuth token, you can keep using it until they revoke it. In all likelihood, though, your app will need to send them to your site in the browser to get the OAuth authorization.

Upvotes: 1

Related Questions