Why integrate Devin with Azure DevOps?

Integrating Devin with your Azure DevOps organization allows Devin to clone repositories, create pull requests, and collaborate effectively with your team. This integration enables Devin to work seamlessly within your existing development workflow.

Setting up the Integration

  1. In your Devin account at app.devin.ai, go to Devin’s Workspace, and click the “Advanced Setup” button.

  1. Once on the Advanced Setup page, click the “Edit” -> “Set up in VSCode” button.

  1. Use the terminal within VSCode to add your Azure DevOps PAT token and then clone your repositories.

Before proceeding with the CLI setup, ensure you have:

  • Admin access to your Azure DevOps organization
  • A Personal Access Token (PAT) with appropriate permissions

Set up Azure CLI

  1. Install the Azure CLI for Ubuntu:
curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash
  1. Add the Azure DevOps Extension:
az extension add --name azure-devops
  1. Configure your Azure DevOps organization defaults:
az devops configure --defaults organization=https://dev.azure.com/{organization}
  1. Set up authentication using your Personal Access Token (PAT):
export AZURE_DEVOPS_EXT_PAT=${secret_name_in_env}
  1. Test your connection by listing repositories:
az repos list --project {project}

Cloning Repositories

  1. Create a directory for your repositories:
mkdir repos && cd ~/repos
  1. Clone your repository:
git clone https://{azure_devops_organization}:$AZURE_DEVOPS_EXT_PAT@dev.azure.com/<repo_path>
  1. Repeat step 2 for each repository you want to clone.

Clone all the repositories that you want to give Devin acces to. Once you finish with this machine setup, a machine snapshot will be saved. You can use this machine snapshot kickoff any new session with the same setup.

Required Permissions

When creating your Personal Access Token (PAT), ensure it has the following permissions:

  • Code
    • Read & Write
    • Status
    • Pull Request Contribute
    • Pull Request Management
  • Build
    • Read
    • Status
  • Project and Team
    • Read

We recommend setting up branch policies in Azure DevOps to ensure all changes go through proper review processes before being merged.

Security Considerations

  • Store your PAT securely and never commit it to source control
  • Use a dedicated service account for Devin’s integration if possible
  • Enable branch policies to enforce code review requirements
  • Regularly rotate your PAT for enhanced security

External Documentation

For more detailed information, refer to these official Microsoft docs:

Azure DevOps Integration FAQs