Workflows

A Workflow is an automation you build on the Catalytic platform. It is a template of the process you want to run each time your Workflow is started.

The Workflows client allows you to access your Workflows definitions. These can then be used to start Instances. It provides the following methods:

MethodDescription
getGets a specific Workflow by Id
findSearch for Workflows by Name or Owner
exportExport an existing Workflow
importWorkflowImport a Workflow

📘

Lean More About Workflows

In you're interested in learning more about what Workflows are or how they work on the Catalytic platform, see The Catalytic Help Docs Section on Workflows

🚧

Creating or Editing Workflows

Currently, the SDK does not support creating or editing Workflow definitions. Instead, you must create and edit your Workflows through the Catalytic Web App. Future versions of the SDK will support creating and editing Workflows.

Quickstart Example

/*
 * This example demonstrates getting Workflows by ID and by name
 */

import org.catalytic.sdk.CatalyticClient;
import org.catalytic.sdk.entities.Workflow;
import org.catalytic.sdk.entities.WorkflowsPage;

public class Program {
  
    public static void main(String[] args) throws Exception {

      	// Create and initialize the Catalytic SDK Client
        CatalyticClient catalytic = new CatalyticClient();
      
      	// Get a specific workflow by id
      	Workflow workflow = catalytic.workflows().get("c9f2beec-10c0-4f2f-b4e0-1d884c7e053c");
      
      	// Also find all Workflows with "SDK Example"
      	// in the name or description
      	Where where = new Where().text().matches("SDK Example");
        WorkflowsPage results = catalytic.workflows().find(where);
      	List<Workflow> workflows = new ArrayList<>();
        workflows.addAll(results.getWorkflows());
      
      	// Page through all the results and add the workflows to `workflows`
      	while (results.getNextPageToken() != null) {
          	results = catalytic.workflows().find(results.getNextPageToken());
          	workflows.addAll(results.getWorkflows());
        }
      
        System.out.println("Found " + workflows.size() + " Workflows by name and 1 by Id");
    }
}