Skip to main content
The workflow service drives interactive customer flows (retention prompts, dunning, onboarding). It speaks to a backend execution engine via a request/response API and exposes the running flow as reactive state — current step, available responses, completion outcome.

Setup

For local development, swap the adapter:

Shape (key surface)

WorkflowStepInfo carries the current step’s actionType, actionConfig, and the list of availableResponses the customer can pick from.

Execution model

Workflows are deterministic request/response — no websockets, no in-memory timers. Each customer action becomes a respond() call; the backend advances the state machine and returns the next step. Timeouts are orchestrator-driven (the backend schedules them).

Example: workflow action block

A typical action block reads the current step config and offers a response button per available choice:

Starting a flow

The host page typically starts a flow in response to a customer action — such as canceling a subscription or initiating a retention offer.
flowType is a stable client identifier. The backend selects the published workflow definition that matches the flow type for the trigger source.