2024-03-04
Welcome to this new major release of Mockoon. It adds a new exciting feature: support for environment variables. It also includes many bug fixes and improvements. Read on to learn more about this release.
Mockoon is proudly independent and open-source, maintained without external funding. We rely on both sponsorships and Mockoon Cloud subscriptions to keep improving the project and building new features. A big thank you to the companies below for supporting our work and helping us grow (and all the sponsors who helped this project over time!):
If you'd like to support Mockoon as well, you can become a sponsor or subscribe to Mockoon Cloud, every contribution helps keep the project alive and evolving. Thank you!
We introduced some breaking changes in this major release:
Mockoon now lets you access environment variables in your templates using the getEnvVar
helper. This allows you to avoid exposing your API keys and certificates in your mock server configuration:
{{getEnvVar 'MOCKOON_MY_VARIABLE'}}
Head over to the documentation to learn more about this feature.
(Issue #849)
We disabled the JSONPath "wrapping" feature causing every result to be wrapped in an array. This feature made it hard to use JSONPath in rules and templates and test for specific cases, like the absence of a property.
In practice, it means that fetching a single property with JSONPath may return undefined
or null internally instead of an empty array. This change may require you to update your rules and templates.
(Issue #1297)
--port
and --hostname
flags are now correctly applied when directly running OpenAPI specification files. (Issue #1308)We updated all the applications and libraries' dependencies to their latest versions. It also fixed some reported vulnerabilities. Updating the desktop application to Electron's latest version also remove support for macOS 10.13 and 10.14.
(Issue #1324)
A big thank you to the following people who helped to make Mockoon better: