Skip to main content

Workflow API

Catalyst Workflows provides an easy way to express business processes and integrations as code, in a reliable, fault-tolerant way. See Workflow API Reference.

Workflows are stateful, allowing for writing durable, long-running applications with the ability to start, pause and stop executions and then pick back up without missing a step in the process.

Catalyst provides the workflow engine which takes care of the orchestration of the workflow, and your code only needs to contain the business logic steps.

Developing Catalyst Workflows

To develop using the Catalyst Workflow API, you are required to use the Dapr Workflow Authoring SDK in your application code.

On application start-up, the SDK instantiates a bi-directional gRPC stream with its associated Catalyst App ID. This connectivity is what enables the Catalyst workflow engine (powered by Dapr) to manage the execution of the app's workflow activities and tasks through the Workflow API. To learn more about the Dapr workflow engine hosted by Catalyst, read Dapr Workflow Architecture.

Using the Workflow API

To start, pause, stop and get information about your Catalyst Workflows, you can use the Workflow Management APIs. These APIs can be called directly, or used from an appliation to instantiate and monitor workflow instances.

Catalyst Workflows save their state incrementally by appending workflow state to a read-only history log. The workflow state store can be managed by Catalyst or you can use a state component to a transactional state store of your choice.

Only a single state component within a Catalyst project can be used as the workflow state store.

The Catalyst web console also provides a visualization on top of workflows, allowing for greater insights into the current status, parameters, history and output of each workflow execution.

In summary, to use the Workflow API:

  • Configure a workflow store: Enable Managed Workflow on your Catalyst project or set up an external store by creating a state component with the enableWorkflow metadata property set to true. If you are are using an external state component, read the current limitations.

  • Author your code using the Dapr Workflow SDK: Follow the instructions in Connect Dapr SDKs to Catalyst APIs to configure the workflow SDK in the language of your choice.

  • Manage the workflow: Start, pause and stop workflows using the Workflow Management APIs.

Try the Workflow API

Walk through the following quickstarts to see Pub/Sub in action:

Quickstart/tutorialDescription
Workflow API QuickstartExecute stateful workflows using managed workflow store