Export OpenAPI Definitions
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.
From the Workflow Pane, click the download button on the right-hand side, then Download OpenAPI Definition
.
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.
Additionally, the REST Request supports these definitions.
Tips for creating rich definitions
Follow these tips to ensure that the generated definitions are as rich as possible.
Provide 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 ofText
- 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
andFgResponseBody
, ensure they contain sample values especially if JSON or XML - If you're using header Properties
FgRequestHeaders
andFgResponseHeaders
, ensure they contain sample values