Skip to main content
Using self-hosted Azure DevOps Server? Follow the Server review setup.

Before you begin

  • An Azure DevOps Services account with access to the repository you want reviewed and permission to create a personal access token (PAT).
  • An administrator who can install the CodeAnt AI extension in your organization. See Microsoft’s extension installation requirements.
  • View subscriptions and Edit subscriptions permissions for service hooks in the project. Project administrators have these by default. See Microsoft’s service hook permissions.
  • A repository where you can open a pull request.

Install the extension and create a token

1

Install CodeAnt AI

Open the CodeAnt AI extension and install it in the organization containing your project. If you cannot install extensions, ask your administrator to complete this step.
2

Create a personal access token

In Azure DevOps Services, open User settings → Personal access tokens and select + New Token.Name the token CodeAnt AI, select the intended organization or collection, and choose an expiry date permitted by your organization’s policy. Select these scopes:Code and Pull Request Threads are the scopes for scans and reviews. Add Build for DORA metrics and Work Items for work item data and Azure DevOps ticket creation.Select Create and copy the token before closing the page. You will use it in both service hook subscriptions below. See Microsoft’s PAT guide if token creation is restricted.
Review comments use the identity associated with the PAT. Use a dedicated service account if you want automated comments attributed to a bot user.

Create both service hook subscriptions

Service hooks send PR events and comments to CodeAnt. Configure both subscriptions for each project you want reviewed.
1

Send new pull requests to CodeAnt

In Azure DevOps, open the project and go to Project settings → Service hooks. Select Create a new subscription.Choose CodeAnt AI as the service and select Next. Choose the Pull request created trigger. Check that any repository filters include the repository you want reviewed, then select Next.Paste the PAT you created above into the access token field and select Finish.Azure DevOps service hook configured with the CodeAnt AI service
2

Send pull request comments to CodeAnt

Create another subscription to CodeAnt AI in the same project. Choose Pull request comment created, check the repository filters, and use the same PAT. Select Finish.This subscription delivers review commands and questions posted on PRs.
Confirm that both subscriptions appear in Project settings → Service hooks. Creating the extension installation alone does not configure these project subscriptions.

Get your first review

Open a new pull request in a repository covered by the subscriptions. CodeAnt AI posts review feedback directly on the PR. When it finds an issue, its comment explains the problem, severity, and suggested fix. See how to read a review comment. To review an existing PR or rerun a review, post:
The Pull request comment created subscription must be configured for this command to reach CodeAnt.

Troubleshooting

Confirm that the CodeAnt AI extension is installed in the organization containing this project. Ask the administrator who installed it to check the installation, then reopen the service hook wizard.
Ask a project administrator to create the subscriptions or grant you View subscriptions and Edit subscriptions permissions. Repository access alone does not grant permission to manage service hooks.
Check that both subscriptions exist in the PR’s project and that their repository filters include the repository. Check the subscription’s notification history for failed deliveries. Confirm that the PAT is valid and its owner can access the repository, then post @codeant-ai: review. If feedback still does not appear, contact CodeAnt support with the project, PR URL, and delivery error. Do not include the PAT.
Check the Pull request comment created subscription, including its repository filter and token. The subscription for new PRs does not deliver PR comments.
Create a replacement PAT with the same scopes and repository access. Update the access token in both CodeAnt service hook subscriptions. If you also saved the PAT in CodeAnt’s organization connection, update that credential too. Request a review to verify the replacement before revoking an old token that is still valid.

Next steps

Customize your reviews

Add review rules for your team’s coding standards.

Connect repository scans

Connect your organization to browse repositories and configure analysis.