> For the complete documentation index, see [llms.txt](https://windows.help.formit.autodesk.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://windows.help.formit.autodesk.com/plugins/how-to-develop-plugins/advanced-development/versioning.md).

# Versioning

As you develop and update your plugin, at some point, you may need to version the code.

For example, FormIt's APIs may change between releases, and while you may want the new version of your plugin to use new FormIt or WSM APIs, you'd also like to keep the plugin working in older clients.

Starting with FormIt **v18.0**, you can implement versioning for your plugin in 3 simple steps:

* Add a *versions.json* file to the root of your plugin directory
* Specify each compatible FormIt version, and the directory containing those plugin files, in *versions.json*
* Use the FormIt internal version number, or "Build Number", found in FormIt under Info > About.

### How to organize versioning for your plugin

Organize your plugin files and directories to match *versions.json*

Your *versions.json* should look like this:

```
        [
            {
                "version":{
                    "major":18,
                    "minor":0
                },
                "path":"v18_0"
            },
            {
                "version":{
                    "major":19,
                    "minor":1
                },
                "path":"v19_0"
            }
        ]
        
```

The above paths *v18\_0* and *v19\_0* must be valid subpaths from the root of your directory/repository.

![](/files/K0fTJfKAm0F1L72DPuIF)

![](/files/hOBaq5bdnIqVVpVhRTKX)

![](/files/0JczOzbPdEltMGBMYB1o)

A great way to handle this is to move your plugin code into subdirectories. Using the above *versions.json*, a directory structure would look like this:

* **versions.json** (file)
* **v18\_0** (directory)
  * **manifest.json** (file)
  * **plugin.html** (file)
  * **plugin.js** (file)
* **v19\_0** (directory)
  * **manifest.json** (file)
  * **plugin.html** (file)
  * **plugin.js** (file)

Optional properties on version are "exactVersion" and "lastVersion". "exactVersion" indicates the version has to match FormIt's version exactly. "lastVersion" indicates the last version allowed to run in FormIt.\\

```
[
    {
      "version":{
        "major":18,
        "minor":0,
        "exactVersion":true
        },
        "path":"v18_0"
    },
    {
        "version":{
            "major":19,
            "minor":1,
            "lastVersion":true
       },
        "path":"v19_0"
    }
 ]
```

It's also possible to use git branches/tags/commits for your paths.

If you're working with a pre-release or beta build of FormIt, and would like to test changes to a plugin that only works with the pre-release version:

* Follow the steps above, except using the filename *versions\_prerelease.json*
* If you commit *versions\_prerelease* to your repo, you'll want to remove it when that pre-release version of FormIt is released
  * Otherwise, future pre-release FormIt versions will be loading the plugin from a location that could be stale or intended for an older version


---

# 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://windows.help.formit.autodesk.com/plugins/how-to-develop-plugins/advanced-development/versioning.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.
