Skip to content

Commit 71aaf18

Browse files
committed
Update README.md
1 parent 1891535 commit 71aaf18

File tree

1 file changed

+19
-16
lines changed

1 file changed

+19
-16
lines changed

README.md

Lines changed: 19 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
1-
This sample .NET MVC web app shows how to use the OAuth 2.0 capabilities in Visual Studio Online to prompt users to authorize your app and to acquire an access token and refresh token to access their Visual Studio Online resources.
1+
# Visual Studio Team Services .NET OAuth Sample
22

3-
To learn more about OAuth in Visual Studio Online, see [Authorize access with OAuth 2.0](http://www.visualstudio.com/integrate/get-started/get-started-auth-oauth2-vsi)
3+
This sample .NET MVC web app shows how to use the OAuth 2.0 capabilities in Visual Studio Team Services to prompt users to authorize your app and to acquire an access token and refresh token to access their Visual Studio Team Services resources.
44

5-
###Pre-requisities###
5+
To learn more about OAuth in Visual Studio Team Services, see [Authorize access with OAuth 2.0](http://www.visualstudio.com/integrate/get-started/get-started-auth-oauth2-vsi)
66

7-
These instructions assume you will be deploying this sample app to an Azure web site. To learn more and to get started, visit [Get started with Azure Web Sites and ASP.NET](http://azure.microsoft.com/en-us/documentation/articles/web-sites-dotnet-get-started).
7+
## How to setup
88

9-
###Setup###
10-
1. Register an OAuth client app on Visual Studio Online (https://app.vssps.visualstudio.com/app/register) (note: the callback URL should be https://yoursite.azurewebsites.net/oauth/callback, where "yoursite" is the name of your Azure web site)
9+
> These instructions assume you will be deploying this sample app to an Azure web site. To learn more and to get started, visit [Get started with Azure Web Sites and ASP.NET](http://azure.microsoft.com/en-us/documentation/articles/web-sites-dotnet-get-started).
10+
11+
1. Register an OAuth client app in Visual Studio Team Services (https://app.vssps.visualstudio.com/app/register)
12+
* The callback URL should be https://yoursite.azurewebsites.net/oauth/callback, where "yoursite" is the name of your Azure web site
1113
2. Clone this repository
1214
3. Open the solution (VSOClientOAuthSample.sln) in Visual Studio 2013 (or later)
1315
4. Update the following settings in web.config to match the values in the app you just registered:
@@ -16,20 +18,21 @@ These instructions assume you will be deploying this sample app to an Azure web
1618
* Scope (space separated)
1719
* Callback URL
1820
5. Build (this will trigger a NuGet package restore, which will pull in all dependencies of the project)
19-
6. Deploy the app.
21+
6. Deploy the app to Azure
22+
23+
### Run the sample
2024

21-
###Run###
22-
1. Navigate to the app (https://yoursite.azurewebsites.net)
23-
2. Confirm your App ID, scope, and callback URL are showing properly (lower left)
24-
3. Click the Start button
25-
4. Sign in to Visual Studio Online (if necessary)
25+
1. Navigate to the deployed app (https://yoursite.azurewebsites.net)
26+
2. Confirm your App ID, scope, and callback URL are displayed properly
27+
![app](appstart.png)
28+
3. Click **Start**
29+
4. Sign in to Visual Studio Team Services (if prompted)
2630
5. Review and accept the authorization request
2731

28-
If everything is setup properly, Visual Studio Online will generate an access token and refresh token and both values will be displayed. **As an app developer, you would always keep these values secret**. Also a new authorization will appear on [your profile page](https://app.vssps.visualstudio.com/Profile/View).
32+
If everything is setup properly, Visual Studio Team Services will issue an access token and refresh token and both values will be displayed. **You should keep these values secret**. Also a new authorization will appear in [your profile page](https://app.vssps.visualstudio.com/Profile/View).
2933

30-
With this access token, you can call [Visual Studio Online REST APIs](http://www.visualstudio.com/integrate/reference/reference-vso-overview-vsi) by passing the access token in the Authorization header. For example:
34+
With the access token you can invoke [Visual Studio Team Services REST APIs](http://www.visualstudio.com/integrate/reference/reference-vso-overview-vsi) by passing the access token in the Authorization header.FOr example:
3135

3236
```
33-
Authorization: Bearer {your access token}
37+
Authorization: Bearer {access token}
3438
```
35-

0 commit comments

Comments
 (0)