After you create a workflow for a Data Agent database, you can run that workflow from the Fabricate API.
For example, if you created a workflow that adds a set of records to the database, you can use the API to incorporate that workflow into your automation.
Getting the parameter names for a workflow
When you run a workflow, you must provide any parameter values that the workflow requires.
On the workflow details panel, to get the parameter names, hover over each field label.
Tooltip with the workflow parameter name The script view also lists the parameters.
Parameters list on script view for a workflow Starting the workflow
To run a workflow from a Data Agent workspace, call:
The body of the request provides any parameter values that the workflow needs.
For example:
The request returns a task identifier and a status. For example:
Checking the status of the workflow processing
To check the status of a workflow, call:
The status information includes:
The identifier of the task and the workflow.
When the workflow processing began.
The status of the workflow processing. The available status values are:
in_progress - Workflow is currently executing
completed - Workflow finished successfully
failed - Workflow encountered an error
canceled - Workflow was canceled by user
For completed workflows:
When the workflow completed.
The results of the workflow.
Any files generated by the workflow.
For failed workflows, the error that caused the failure.
Response for a workflow in progress
Here is an example of a response for a workflow in progress:
Response for a completed workflow
Here is an example of a response for a completed workflow.
Response for a failed workflow
Here is an example of a response for a failed workflow:
Downloading files that a workflow generated
If the workflow generated files, then to download those files, call: