Home > Azure DevOps > Access VSO Work Items in Postman, by using Azure DevOps REST APIs, using PAT (Personal Access Token) authentication

Access VSO Work Items in Postman, by using Azure DevOps REST APIs, using PAT (Personal Access Token) authentication


 
Here in this post we will try to access VSO Work Items from Postman tool by using Azure DevOps REST APIs. To access and authenticate into Azure DevOps we will first create PAT (Personal Access Token) and then use it in the Postman tool.
 

Create Token in Azure DevOps portal:

 

1. Go to https://dev.azure.com/{YourOrg}/. On the top-right corner of the browser click on “User Settings” icon, and select “Personal access token” option from the drop down.


 

2. Now on the settings page click on the + icon to create a new Token, provide a new Name and Expiry Date of the Token, and scroll down.


 

3. At the bottom of the page you will see “Work Items” section, just select the “Read & write” check box, and click Create.


 

4. Now your Token is created, just copy it by clicking on the Copy button and save it somewhere securely. Otherwise you won’t be seeing it again on the portal for security reasons.


 

Using Postman to access VSO Work Items:

 

5. Download & Install Postman from here [link]
 

6. Open Postman tool, create a new Collection and add a new Request of type GET.

Populate following URL: https://dev.azure.com/{{YourOrg}}/{{YourProject}}/_apis/wit/workitems/
{{workitemId}}?api-version=6.0

Auth Tab:
  — Type = “Basic Auth”
    — UserName: {{PAT name}}
    — Password: {{Copied PAT secret from Azure DevOps portal}}


 

6. Now clicking on Send button will return you the Response with all the VSO Work Item attributes and details.


  1. SUDBAB
    April 14, 2021 at 6:57 pm

    The best guide about this! Thanks man, the docs on Microsoft’s website were quite confusing!

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: