When attempting to re-scaffold an API in Anypoint Studio after modifying its RAML specification, you may encounter the following error:
An Apikit configuration is mandatory.
This occurs even if an APIkit configuration was previously present and the project was scaffolded successfully.
This issue occurs when the APIKit configuration is placed in an xml file which is not stored in the src/main/mule folder, but in a subfolder instead.
This usually happens when configurations are placed in a global.xml configuration file and you save this file in a subfolder like a "commons" folder. The APIkit scaffolding process expects the configuration file to be in the root src/main/mule folder to scaffold and update the APIkit configuration. This is a known limitation in Anypoint Studio.
To resolve this issue, relocate your global.xml file (the file where you stored the APIKit configuration) to the root `src/main/mule` directory.
1. Locate global.xml: In your Anypoint Studio project, navigate to the `src/main/mule` folder. If your `global.xml` file is inside a subfolder (e.g., `src/main/mule/common/global.xml`), proceed to the next step.
2. Move global.xml: Drag and drop or cut and paste the `global.xml` file from its current subfolder directly into the `src/main/mule` folder. Ensure it resides alongside other main configuration files (e.g., `your-api-main.xml`, `your-api-implementation.xml`).
3. Re-scaffold API: After moving the file, attempt to re-scaffold your API in Anypoint Studio. The scaffolding process should now complete successfully.
005460320

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.