If you're building Workflows that you're going to consume as API's, it's often useful to be able to export formal definitions of the Workflows.

The Export OpenAPI Definitions button in the Workflows Pane will generate a YAML OpenAPI document (formerly Swagger) containing these definitions.

You'll be able to use services like Swagger Hub to test API's as well as generate code stubs to consume these API's.

How to create rich definitions

Follow these tips to ensure that the generated definitions are as rich as possible.

Povide a description for each Workflow in the Workflow Design Settings Pane - this will be used as the service description.

Variable Bar Properties define the interface in to the Workflow. Apply these tips to each Property;

  • Set the data type (for example, if your Workflows requires a numeric value as input, set the Property type to Number rather than leaving it set to the default value of Text

  • Use Notes to describe Properties - Click the pen icon (while editing a Variable Bar Property Name) to add a descriptive note to the Property

  • If you're using the payload Properties FgRequestBody and FgResponseBody, ensure they contain sample values especially if JSON or XML

  • If you're using header Properties FgRequestHeaders and FgResponseHeaders, ensure they contain sample values

Did this answer your question?