Azure DevOps
Connect Azure DevOps so agents can read and update work items, code, pipelines and wikis for you. An admin registers an app in Microsoft Entra once, and then each person signs in with their own Microsoft account.
Azure DevOps can’t be added just by pasting its address, because Microsoft doesn’t allow that kind of sign-in. Use the Microsoft Entra sign-in below instead.
These steps follow Microsoft’s documentation and haven’t yet been tried end to end. Tell us if anything differs.
What Context provides
- The sign-in through Microsoft Entra, once you register an app for it.
- One connection per person, so agents act as that person and see and change only what they can in Azure DevOps.
- Tools for projects, work items, repos and pull requests, pipelines, wikis and test plans. Microsoft decides the exact list, and the connector’s Tools tab shows it.
What you will need
- Your Azure DevOps organization connected to your Microsoft Entra tenant (Organization settings → Microsoft Entra).
- Third-party application access via OAuth turned on (Organization settings → Policies).
- Someone who can register apps and grant admin consent in Microsoft Entra.
- Permission to add connectors (see Before you start).
1. Register the app in Entra
- Register the app, copy its IDs and create a client secret, as in Register the app in Microsoft Entra. That page has the redirect address to add.
- Under API permissions → Add a permission → APIs my organization uses, pick Azure DevOps
MCP and choose the delegated permissions agents need: read only, unless they must change
things. Also add Microsoft Graph →
offline_access, then click Grant admin consent.
If Azure DevOps MCP isn’t in that list, an admin adds it to your tenant once with these two commands (Cloud Shell in the Azure portal works), then picks it:
Code
Leave Allow public client flows off; it isn’t needed.
2. Add the connector
Start as in Set up the connector: click Install connector, keep MCP server,
and enter your organization’s address, using the name from dev.azure.com/<your-organization>:
Code
Under Sign-in, pick OAuth app, then Microsoft Entra, and fill in:
| Field | Value |
|---|---|
| Tenant ID or domain | The Directory (tenant) ID. The field also takes a domain, but Azure DevOps needs the ID. |
| Client ID | The Application (client) ID |
| Client secret | The secret’s Value |
| Scopes | https://mcp.dev.azure.com/.default |
Name it and click Install and sign in.
3. Sign in to finish setup
Click Sign in to <name> and sign in with your work account. This finishes setup and
connects your own account, so others can connect too.
4. Everyone connects
Each person clicks Connect on the connector and signs in with their own Microsoft account.
People stay signed in while they use the connector, until Microsoft ends their session (a password change, for example). They then click Reconnect. When the client secret expires, everyone is signed out, so paste a new secret in Edit config → Authentication before that date.
Troubleshooting
| What you see | Fix |
|---|---|
AADSTS50011 | Add the Web redirect URI exactly as in Register the app in Microsoft Entra. |
AADSTS65001 | Click Grant admin consent on the app registration. |
AADSTS700016, or Azure DevOps MCP isn’t in the list | Run the two commands in Register the app in Entra. |
| An issuer error at the end of the first sign-in | Use the tenant ID, not a domain. |
“token rejected by MCP server” or HTTP 401 | Use the scope https://mcp.dev.azure.com/.default, save, and reconnect. |
HTTP 403 | Turn on Third-party application access via OAuth, and check the person has access to the organization. |
More Microsoft codes are in Troubleshooting.
Optional: limit the tools with headers
Azure DevOps can offer fewer tools if the connector sends two
fixed headers. Open Tools, click
Edit as YAML, and add them under connector::
Code
X-MCP-Toolsets keeps only the groups you list (repos, wit for work items, pipelines,
wiki, work, testplan, advsec), and X-MCP-Readonly: "true" keeps only reading tools.
These narrow what the server offers; they never give anyone more access.
Who can connect
Accounts in your Microsoft Entra tenant, including guests, whose Azure DevOps organization is connected to it. Personal Microsoft accounts can’t. For a second Azure DevOps organization, add a second connector.
Don’t use the older Azure DevOps scope (499b84ac-…): this server refuses it. Microsoft’s
scope guidance
lists every permission.