Generate a complete Effect Cluster workflow with activities and schemas
Generates complete Effect Cluster workflows with activities, schemas, and tests.
/plugin marketplace add theinfinityguides/software-assembly-line/plugin install software-assembly-line@software-assembly-line<WorkflowName> [--activities <LIST>] [--durable] [--saga]Generate a complete Effect Cluster workflow with activities, schemas, and tests.
/sal:workflow <WorkflowName> [--activities <ACTIVITY_LIST>] [--durable] [--saga]
# Generate workflow with interactive activity prompts
/sal:workflow OrderProcessing
# Generate with specified activities
/sal:workflow OrderProcessing --activities "validateOrder,chargePayment,sendConfirmation"
# Generate durable workflow (survives restarts)
/sal:workflow OrderProcessing --durable
# Generate saga pattern (with compensation)
/sal:workflow OrderProcessing --saga
| Argument | Required | Description |
|---|---|---|
WorkflowName | Yes | PascalCase workflow name |
--activities | No | Comma-separated activity names |
--durable | No | Generate durable workflow with checkpoints |
--saga | No | Generate saga pattern with compensation activities |
packages/cluster)src/workflows/{WorkflowName}.tssrc/workflows/activities/{workflowName}.tssrc/workflows/schemas/{workflowName}.tssrc/workers/index.tstest/workflows/{workflowName}.test.tspackages/api)src/workflows/{workflowName}.client.tsSimple sequential execution:
export const OrderProcessing = Workflow.make({
name: "OrderProcessing",
execute: (input) => Effect.gen(function*() {
const validated = yield* Activities.validate(input)
const result = yield* Activities.process(validated)
yield* Activities.complete(result)
return { success: true, result }
}),
})
--durable)Checkpointed execution that survives restarts:
const validated = yield* Workflow.checkpoint(
"validate",
Activities.validate(input)
)
--saga)Compensating transactions pattern:
yield* Workflow.saga({
steps: [
{
execute: () => Activities.reserveInventory(input),
compensate: () => Activities.releaseInventory(input),
},
// ...
],
})
## Workflow Complete: OrderProcessing
### Files Created (6)
**Cluster (packages/cluster)**
- [x] src/workflows/schemas/orderProcessing.ts
- [x] src/workflows/activities/orderProcessing.ts
- [x] src/workflows/OrderProcessing.ts
- [x] src/workers/index.ts (updated)
- [x] test/workflows/orderProcessing.test.ts
**API (packages/api)**
- [x] src/workflows/orderProcessing.client.ts
### Activities Generated
1. `validateOrder` - Validates order data
2. `chargePayment` - Processes payment
3. `sendConfirmation` - Sends confirmation email
### Workflow Type
- [x] Standard workflow
- [ ] Durable (use --durable)
- [ ] Saga pattern (use --saga)
### Verification
- [x] Types check
- [x] Tests pass (6 new tests)
/workflowInteractive guide to the Jezweb Workflow: 5 commands for complete project lifecycle automation.