> For the complete documentation index, see [llms.txt](https://help.aikido.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.aikido.dev/ai-code-analysis/ai-code-audit-overview/create-an-ai-code-audit.md).

# Create a Code Security Audit

The create flow is two steps: pick the repositories you want analyzed, then confirm the credit cost and start.

## Prerequisites

Before you start, make sure:

* **You have the Manage Pentests and AI Code Analysis** [permission](/getting-started/automated-user-management/setting-roles-and-permissions.md). Without it, you can't create analyses or open existing ones.
* **At least one repository is connected.** [Self-scanned repositories](/code-scanning/local-code-scanning.md) aren't eligible and are excluded from the picker. You can pick up to **6** repositories per analysis.
* **Your wallet has enough credits** to cover the quoted cost. You can top up from inside the create flow if needed. See [Wallet & Credits](/miscellaneous-info/wallet-and-credits.md) for purchase details.

## Set up the analysis

To launch the wizard, click **AI** **Code Analysis** in the main navigation, then click **Create Audit** in the page header.

{% stepper %}
{% step %}
**Connect Repositories**

1. Open the **Repositories** picker and select up to 6 connected repositories.
2. To keep a monorepo audit focused, click **Exclude Paths** next to a selected repository and add the directories you don't want analyzed. For example, exclude unrelated applications or services that aren't part of this audit.
3. Click **Continue** to move to pricing.

<figure><img src="/files/joFFPIhGoVA3sarGqf7U" alt="Exclude Paths button next to a selected repository"><figcaption></figcaption></figure>

{% hint style="info" %}
Exclude unrelated applications or services, not documentation, READMEs, or other non-code assets. Aikido can use those files as architectural context to investigate security risks more accurately.
{% endhint %}

**Continue** stays disabled until at least one repository is selected. Clicking **Cancel** on this step takes you to your repositories list, which is useful if you still need to connect repos before continuing.
{% endstep %}

{% step %}
**Pricing**

Aikido calculates the credit cost for your selection. When the estimate is ready, the price shows next to **Full AI Code Analysis**, and your balance shows in the footer. If you're short on credits, click **Add Credits** to top up.

Click **Start Audit** to launch.
{% endstep %}
{% endstepper %}

After **Start Audit**, Aikido takes you to the assessment detail page, where you can follow progress and read findings as they land. See [Track Progress and Findings](/ai-code-analysis/ai-code-audit-overview/track-progress-and-findings.md).

## FAQ

### Why is there a 6-repo cap?

AI Code Analysis focuses agent attention on a coherent set of codebases. Beyond 6 repositories, the analysis tends to lose focus and quality drops. If you genuinely need more in a single analysis, contact support. The tooltip on the **Repositories** field links to the same path.

## Need help?

Open the **Intercom chat** in the bottom right corner if the credit estimate looks off or the picker doesn't show a repository you expect.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://help.aikido.dev/ai-code-analysis/ai-code-audit-overview/create-an-ai-code-audit.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
