Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2068)

Unified Diff: chrome/common/extensions/api/identity.idl

Issue 305843003: Update chrome.identity API documentation to mention best practices. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: too much coffee obviously Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/api/identity.idl
diff --git a/chrome/common/extensions/api/identity.idl b/chrome/common/extensions/api/identity.idl
index a4893b25e826637ef624fb537f2cb99e53a00f02..18bd591fa3fd3de37b987609d6b411af9c0de299 100644
--- a/chrome/common/extensions/api/identity.idl
+++ b/chrome/common/extensions/api/identity.idl
@@ -62,9 +62,16 @@ namespace identity {
// section of manifest.json</a>.
//
// The Identity API caches access tokens in memory, so it's ok to
- // call <code>getAuthToken</code> any time a token is
+ // call <code>getAuthToken</code> non-interactively any time a token is
// required. The token cache automatically handles expiration.
//
+ // For a good user experience it is important interactive token requests are
+ // initiated by UI in your app explaining what the authorization is for.
+ // Failing to do this will cause your users to get authorization requests,
+ // or Chrome sign in screens if they are not signed in, with with no
+ // context. In particular, do not use <code>getAuthToken</code>
+ // interactively when your app is first launched.
+ //
// |details| : Token options.
// |callback| : Called with an OAuth2 access token as specified by the
// manifest, or undefined if there was an error.
@@ -96,9 +103,8 @@ namespace identity {
// For a good user experience it is important interactive auth flows are
// initiated by UI in your app explaining what the authorization is for.
// Failing to do this will cause your users to get authorization requests
- // - or even Chrome sign in screens if they are not signed in - with
- // no context. In particular, do not launch an interactive auth flow when
- // your app is first launched.
+ // with no context. In particular, do not launch an interactive auth flow
+ // when your app is first launched.
//
// |details| : WebAuth flow options.
// |callback| : Called with the URL redirected back to your application.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698