| name | workflow-validate |
| description | Review Notion Worker Workflows for trigger typing and retry safety. |
| user-invocable | true |
| disable-model-invocation | true |
Workflow validation
Review every file in src/workflows/ and any modules it calls. Report each
finding with its file, line, impact, and fix.
Treat these as errors:
- A Workflow is not a direct file or does not default-export
createWorkflow.
- Trigger-specific event fields are used without type narrowing.
- Non-deterministic work occurs outside an awaited step.
- Step order or names can change between retries.
- A step result is not JSON-serializable or later code needs an in-memory mutation.
- A retry-sensitive write lacks an idempotency key or duplicate guard.
- External failures are ignored, or credentials are hard-coded or logged.
Run npm run check and npm run build when dependencies are installed.