parseWorkflowName
Workflow names are stored as machine-readable identifiers like workflow//./src/workflows/order//processOrder. This function parses them into components suitable for display in a user interface, for example when listing runs from the World SDK, where run.workflowName holds the machine-readable form.
API signature
Parameters
| Parameter | Type | Description |
|---|---|---|
name | string | The machine-readable workflow name (e.g. from run.workflowName) |
Returns
{ shortName: string; moduleSpecifier: string; functionName: string } | null
| Property | Description |
|---|---|
shortName | The display name. For default exports, falls back to the module's short name (e.g. "order" for ./src/workflows/order). |
moduleSpecifier | The module the workflow is defined in: a relative path (./src/workflows/order) or a package specifier (@myorg/flows@1.0.0). |
functionName | The full exported function name. |
Returns null when the input is not a valid workflow name.