The idea is:
Add a workflow.afterPublish external hook that fires only when a user explicitly publishes a workflow, not on draft/auto-saves.
My use case:
I use external hooks (EXTERNAL_HOOK_FILES) to back up workflows to GitHub and sync them across multiple n8n instances. Currently workflow.afterUpdate fires on every save, including draft saves while editing. This triggers expensive operations (GitHub API calls, cross-instance sync) on every
auto-save, not just on intentional publishes.
There’s no way to distinguish a draft save from an explicit publish in the hook payload.
I think it would be beneficial to add this because:
Anyone using external hooks for backups, sync, or notifications is forced to run expensive operations on every save. A workflow.afterPublish hook would let consumers react only to intentional publishes, reducing unnecessary API calls and side effects.
Any resources to support this?
Are you willing to work on this?
Yes, but I don’t know how to implement it