# Permissions for AI autodetect

To activate AI Code Autodetection, a SonarQube Server Instance Admin must first check that the feature is enabled.

Then, a DevOps platform administrator must set the correct permission level in your AI-powered web service. For specific instructions in your DevOps platform, please refer to the applicable section below.

## GitHub Copilot Business <a href="#github-copilot-business" id="github-copilot-business"></a>

When a SonarQube Server administrator activates [autodetect-ai-code](https://docs.sonarsource.com/sonarqube-server/2025.1/instance-administration/ai-features/autodetect-ai-code "mention") for a instance of SonarQube Server, GitHub Copilot Business app administrators must enable the GitHub integration. Check [#enable-in-github](https://docs.sonarsource.com/sonarqube-server/2025.1/instance-administration/autodetect-ai-code#enable-in-github "mention"), for the complete details. Once enabling the integration in GitHub, the GitHub Copilot Business app administrator will receive an will receive an email notification to confirm the SonarQube App’s permission request.

With access to your GitHub Copilot Business App, SonarQube Server can evaluate users’ GitHub Copilot usage and code contribution patterns to identify potential AI-generated code. If there is a match in user data, SonarQube Server will display the ![$ai-icon-sparkle](https://3560343708-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4FzELVjsPO4ijRo3jtBV%2Fuploads%2Fgit-blob-975a17de7ce8ae3b164dd9f9db9c791adb294bbb%2F4be9087a2b059c269f15df202838af7a74e71a96.svg?alt=media)**AI code detected** status on the project’s Overview and Project Information pages. The GitHub organization connected to Copilot should match the organization bound to SonarQube Server.

SonarQube Server does not retroactively check older code from previous commits. In addition, projects that have the ![$contains-ai-code](https://3560343708-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4FzELVjsPO4ijRo3jtBV%2Fuploads%2Fgit-blob-ca3b9de37a93a3d09c496b45878e418adab02c9f%2Fc151514ef7beca0f865ee429bc9fe0e33b05ceb4.svg?alt=media) applied by a quality standards admin will be excluded from automatic AI code detection. See the [#label-projects-with-ai-code](https://docs.sonarsource.com/sonarqube-server/2025.1/analysis-functions/ai-code-assurance/overview#label-projects-with-ai-code "mention") article for details.

{% hint style="warning" %}
If the GitHub Copilot Business and Enterprise account administrator chooses to ignore the request, Sonar’s AI Code Autodetection will be turned on, but not be activated.
{% endhint %}

## Related pages <a href="#related-pages" id="related-pages"></a>

* [overview](https://docs.sonarsource.com/sonarqube-server/2025.1/ai-capabilities/overview "mention") of AI capabilities
* Learn about [ai-standards](https://docs.sonarsource.com/sonarqube-server/2025.1/ai-capabilities/ai-standards "mention")
* See also [enable-ai-codefix](https://docs.sonarsource.com/sonarqube-server/2025.1/instance-administration/ai-features/enable-ai-codefix "mention") to get AI-generated fix suggestions
