Define & Validate APIsAPIMatic for VS Code

Build an API Workspace

Check that your API definition is ready for APIMatic SDKs, portals, and transformation with the build step in APIMatic for VS Code.

Build checks that your API definition is valid for and compatible with APIMatic. It converts the API definition into an intermediate format supported by APIMatic and runs additional checks on it, including checks that matter for code generation, such as naming conventions. You don't have to build in the extension before you generate SDKs or developer portals, but a successful build shows that your definition is ready for them. Transform runs the build for you. If the build fails, update your API definition to resolve the reported issues.

Prerequisites

In order to build your API workspace in the VS Code extension, it is required that your workspace has passed through the validation layer and that did not result in any validation errors (blocking or otherwise). If it did, you may see an error like below:

Build Error

Note, that validation warnings or any linting errors are allowed and will not prevent the build from proceeding.

Build the API workspace

To build your API workspace, you need to select the tools (🛠️) icon from the left side of the status bar:

Build Workspace

The build process will start in the background after verifying that the validation process has occurred and didn't find any validation errors. While the build is running, you should see a Building... message in the status bar:

Build Running

Depending on whether the build passes or not, you will see a Build Success or a Build Failed message in the status bar:

Build Success

The validation views will be populated with additional messages from the build process with codes beginning with APIMATIC. If the build fails, the messages will include errors as well.

Build Messages

You will need to re-trigger the build process each time the validation information changes for the API workspace.

On this page