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

Side by Side Diff: chrome/common/extensions/docs/templates/articles/tut_oauth.html

Issue 19936002: Extension docs: Cleanup after there's only one version. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 7 years, 5 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 unified diff | Download patch
OLDNEW
1 <h1>Tutorial: OAuth</h1> 1 <h1>Tutorial: OAuth</h1>
2 2
3 3
4 <p> 4 <p>
5 <a href="http://oauth.net/">OAuth</a> is an open protocol that aims to standardi ze the way desktop and web applications access a user's private data. OAuth prov ides a mechanism for users to grant access to private data without sharing their private credentials (username/password). Many sites have started enabling APIs to use OAuth because of its security and standard set of libraries. 5 <a href="http://oauth.net/">OAuth</a> is an open protocol that aims to standardi ze the way desktop and web applications access a user's private data. OAuth prov ides a mechanism for users to grant access to private data without sharing their private credentials (username/password). Many sites have started enabling APIs to use OAuth because of its security and standard set of libraries.
6 </p> 6 </p>
7 <p> 7 <p>
8 This tutorial will walk you through the necessary steps for creating a Google Ch rome Extension that uses OAuth to access an API. It leverages a library that you can reuse in your extensions. 8 This tutorial will walk you through the necessary steps for creating a Google Ch rome Extension that uses OAuth to access an API. It leverages a library that you can reuse in your extensions.
9 </p> 9 </p>
10 <p> 10 <p>
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 'consumer_key': 'anonymous', 82 'consumer_key': 'anonymous',
83 'consumer_secret': 'anonymous', 83 'consumer_secret': 'anonymous',
84 'scope': 'https://docs.google.com/feeds/', 84 'scope': 'https://docs.google.com/feeds/',
85 'app_name': 'My Google Docs Extension' 85 'app_name': 'My Google Docs Extension'
86 }); 86 });
87 </pre> 87 </pre>
88 88
89 <p> 89 <p>
90 To use the OAuth library, 90 To use the OAuth library,
91 you must declare the "tabs" permision in the 91 you must declare the "tabs" permision in the
92 <a href="http://code.google.com/chrome/extensions/manifest.html">extension manif est</a>. 92 <a href="manifest.html">extension manifest</a>.
93 You must also declare the sites you are using 93 You must also declare the sites you are using
94 including the request URL, the authorize URL, access URL, 94 including the request URL, the authorize URL, access URL,
95 and, if necessary, the scope URL. 95 and, if necessary, the scope URL.
96 For example: 96 For example:
97 </p> 97 </p>
98 98
99 <pre> 99 <pre>
100 "permissions": [ "tabs", "https://docs.google.com/feeds/*", 100 "permissions": [ "tabs", "https://docs.google.com/feeds/*",
101 "https://www.google.com/accounts/OAuthGetRequestToken", 101 "https://www.google.com/accounts/OAuthGetRequestToken",
102 "https://www.google.com/accounts/OAuthAuthorizeToken", 102 "https://www.google.com/accounts/OAuthAuthorizeToken",
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
206 <h2 id="sample-code">Sample code</h2> 206 <h2 id="sample-code">Sample code</h2>
207 207
208 <p> 208 <p>
209 Sample extensions that use these techniques are available in the Chromium source tree: 209 Sample extensions that use these techniques are available in the Chromium source tree:
210 </p> 210 </p>
211 211
212 <ul> 212 <ul>
213 <li><a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/exten sions/docs/examples/extensions/gdocs/">.../examples/extensions/gdocs/</a></li> 213 <li><a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/exten sions/docs/examples/extensions/gdocs/">.../examples/extensions/gdocs/</a></li>
214 <li><a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/exten sions/docs/examples/extensions/oauth_contacts/">.../examples/extensions/oauth_co ntacts/</a></li> 214 <li><a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/exten sions/docs/examples/extensions/oauth_contacts/">.../examples/extensions/oauth_co ntacts/</a></li>
215 </ul> 215 </ul>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698