We are very excited to finally update our swagger modules to version 2:
swagger-sdk, cbSwagger. This major version has tons of new features and improvements when documenting ColdBox APIs. However, the biggest features are that we now support the latest Open API Spec => v3.0.2 and we can export your documentation in either JSON or YAML. Check out the release notes below to see all the great new improvements.
Swagger SDK v2.0
This module allows for software development using the Swagger/OpenAPI specification.
box install swagger-sdk
- Open API 3.02 support instead of swagger
- New template layout
- Engine removals: lucee4.5, ACF10, ACF11
- Upgraded jackson-core to latest v2.9.9
- Upgraded snakeyaml to latest v1.24
- Added more tests
- Added ability to chain methods on all methods that where void before.
document.asYAML()is not fully implemented so you can convert the document to yaml.
createLinkedHashMap()to use new ACF
structNew( "ordered" )instead.
This module automatically generates OpenAPI documenation from your configured application and module routes in either JSON or YAML by simply visiting
/cbSwagger in your URL. Focus on building your APIs and document them with ease by simply annotating your handlers.
box install cbSwagger
feature: Upgraded to swagger-sdk 2.0.0 to support OpenAPI 3.0.x. A great guide on migrating is here: https://blog.readme.io/an-example-filled-guide-to-swagger-3-2/
cbSwaggersettings to the
moduleSettingsstruct instead of top-level in the
config/ColdBox.cfc. Make sure you move your settings.
feature: You can now pass a
/cbSwaggerendpoint to either get the OpenAPI doc as
feature: You have two distinct routes for the json and yml formats:
You can choose your default output format via the module settings:
defaultFormatsetting. Valid options are
features: Support for ColdBox 5 event routing and response routing.
improvement: You can now tag your handlers with a
displayNamethat will be used for operation ID building
improvement: Improved the way operation Ids are reported so they can be unique when reusing handler actions.
structNew( "ordered" )
improvement: Removed lucee 4.5, acf11 support.