---
schema_version: "1"
id: 6a9bd7c75d5809d42e65525059aa684e9bac1b8a737119c0a038e4cfc070d6fb
title: Troubleshooting AI Features in Anypoint Code Builder
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/anypoint-code-builder/troubleshoot-generative-ai.md
canonical_url: https://docs.mulesoft.com/anypoint-code-builder/troubleshoot-generative-ai
source_site: docs.mulesoft.com
content_type: documentation
content_hash: b74a54faaaf56b78b28b5df7ae3cc5db238e553008cc87c1c6a33e4377ce1c84
description: MuleSoft Documentation Site
latest: true
---
---
product: Anypoint Code Builder
version: master
---

# Troubleshooting AI Features in Anypoint Code Builder

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

The following errors can occur when you use MuleSoft Vibes in Anypoint Code Builder.

## Required Permissions for MuleSoft Vibes

MuleSoft Vibes always uses the permissions of the logged-in Anypoint Platform user. MuleSoft Vibes
can’t perform any action that the user doesn’t already have permission to perform.

Here are the permissions required across capabilities in the MuleSoft MCP Server:

Required Permissions

**Anypoint Monitoring** \* Monitoring Viewer

**API Manager** \* Manage APIs Configuration \* Manage Policies \* View APIs Configuration \* View
Policies

**Exchange** \* Exchange Administrator \* Exchange Contributor \* Exchange Creator \* Exchange
Viewer

**General** \* View Organization \* View Connected Applications

**Runtime Manager** \* Read Applications \* Create Applications \* Read Runtime Fabrics \* CloudHub
Network Viewer

**Usage** \* Usage Viewer

To configure MuleSoft Vibes with a different set of permissions, you must:

1.  Remove or disable the out-of-the-box MuleSoft MCP Server.

2.  Follow the steps in the
    [MuleSoft MCP Server documentation](https://docs.mulesoft.com/mulesoft-mcp-server/getting-started#set-up-authentication)
    to set up a connected app with the desired permissions.

## AI Features Not Enabled for Your Organization

If you see the message `AI features are not enabled for your organization`, your Anypoint Platform
organization is not linked to a Salesforce organization with an active generative AI license, or
Einstein is not enabled.

To resolve this error, verify:

- Your Anypoint Platform organization is connected to a Salesforce organization with generative AI
  enabled. For setup instructions, see
  [Connecting a Trusted Salesforce Organization to Anypoint Platform](https://docs.mulesoft.com/access-management/connecting-salesforce-orgs)
  and
  [Salesforce Organization Connections in Anypoint Platform](https://docs.mulesoft.com/access-management/trusted-salesforce-org).

- Einstein is enabled in Access Management. See
  [Enabling or Disabling Generative AI for Anypoint Platform](https://docs.mulesoft.com/access-management/enabling-generative-ai).

  > [!NOTE] If you are a MuleSoft customer without an existing Salesforce organization, contact your
  > MuleSoft account team to provision an Einstein-enabled Salesforce organization.

> [!NOTE] If the **MuleSoft > Anypoint Platform Setup** option is not visible in Salesforce or you
> encounter a "Page not found" error, the **Enable Flow API Actions** permission may not be enabled
> for your Salesforce organization. Contact MuleSoft Support with your Salesforce Org ID to request
> this permission. For setup instructions, see
> [Connecting a Trusted Salesforce Organization to Anypoint Platform](https://docs.mulesoft.com/access-management/connecting-salesforce-orgs).

## Unexpected Results When Using Mulesoft Vibes

If the generated flow doesn’t return accurate or useful results for your message, try rewriting your
message and follow the guidelines to
[write an effective message](https://docs.mulesoft.com/anypoint-code-builder/vibes-create-integrations#craft-ai-prompt).

If results are still inconsistent, verify that your project context and Mulesoft Vibes settings are
correctly configured.

## HTTP 409 Conflict Error

If you receive an HTTP 409 Conflict error when initializing or prompting MuleSoft Vibes, the error
indicates a configuration mismatch between Anypoint Platform and Salesforce.

To resolve this error, verify:

- Your Anypoint Platform organization is linked to a Salesforce organization. See
  [Connecting a Trusted Salesforce Organization to Anypoint Platform](https://docs.mulesoft.com/access-management/connecting-salesforce-orgs)
  and
  [Salesforce Organization Connections in Anypoint Platform](https://docs.mulesoft.com/access-management/trusted-salesforce-org).

- Einstein is enabled in Access Management. See
  [Enabling or Disabling Generative AI for Anypoint Platform](https://docs.mulesoft.com/access-management/enabling-generative-ai).

- You have the **Mule Developer Generative AI User** permission. See
  [Anypoint Code Builder Permissions](https://docs.mulesoft.com/anypoint-code-builder/start-configure-permissions#permissions).

## Vibes Features are Unresponsive or Fail to Load

If MuleSoft Vibes features aren’t working as expected, verify that your system points to the JDK
used by Anypoint Code Builder.

### Configure JAVA\_HOME on macOS

1.  Identify the path where Anypoint Code Builder has installed the JDK. It typically follows this
    pattern:

    /Users/<your\_username>/AnypointCodeBuilder/java/<jdk\_version>/Contents/Home

2.  Open your shell profile (usually `~/.zshrc` for Zsh or `~/.bash_profile` for Bash) in a text
    editor:

    ```bash
    nano ~/.zshrc
    ```

3.  Add these lines, replacing `<path_to_jdk>` with the path identified in the previous step:

    ```bash
    export JAVA_HOME="<path_to_jdk>"
    export PATH="$JAVA_HOME/bin:$PATH"
    ```

4.  Save the file and reload the profile:

    ```bash
    source ~/.zshrc
    ```

5.  Verify the configuration by running `echo $JAVA_HOME` and `java -version`.

### Configure JAVA\_HOME on Windows

1.  Identify the path where Anypoint Code Builder has installed the JDK. It typically follows this
    pattern:

    C:\\Users\\<your\_username>\\AnypointCodeBuilder\\java\\<jdk\_version>

2.  Open Windows Search, enter `Edit the system environment variables`, and then select
    **Environment Variables**.

3.  In **User variables** or **System variables**, create or update `JAVA_HOME` with your JDK path.

4.  Update the `Path` variable and add this line:

    %JAVA\_HOME%\\bin

5.  Open a new Command Prompt and verify the configuration:

    ```bash
    echo %JAVA_HOME%
    java -version
    ```

## Token and Quota Errors

### Prompt Size Exceeds the Token Limit

If you see the error `Prompt size exceeds the token limit when PII is enabled`, the Einstein Trust
Layer’s PII detection and masking is active and is expanding the size of your prompt beyond the
model’s token limit.

To resolve this error, you must:

- Start a new chat session to clear the conversation history.

- Remove large project folders or files from the attached context.

- Break your request into smaller, more focused prompts.

### Salesforce Connection Error

If MuleSoft Vibes returns a `[SALESFORCE] Connection error`, the Salesforce AI model has reached its
daily request or token limit for your session.

To resolve this error, you must:

- Start a new chat session to reset your token usage.

- Wait for the daily limit to reset, then retry.

- Contact your Anypoint Platform organization administrator if the error persists.

## Java 17 Connector Compatibility Errors

If MuleSoft Vibes generates a flow and you then see an `Unsupported class file version` build error,
the generated `pom.xml` may reference connector versions that are not compatible with Mule runtime
4.6 and later, and Java 17.

To resolve this error, update the connector version in your `pom.xml` to a version that supports
Java 17, and rebuild the project.

## See Also

- [Log in to Anypoint Platform](https://docs.mulesoft.com/anypoint-code-builder/start-acb#log-in-to-anypoint-platform-from-the-ide)

- [Anypoint Code Builder Permissions](https://docs.mulesoft.com/anypoint-code-builder/start-configure-permissions#permissions)

- [Creating Integrations with MuleSoft Vibes](https://docs.mulesoft.com/anypoint-code-builder/vibes-create-integrations)

- [Known Issues](https://help.salesforce.com/s/issues)
