From 90966633bb359adfa478b1a292f010bf320ae2cf Mon Sep 17 00:00:00 2001 From: Shahed Nasser Date: Thu, 23 Oct 2025 16:03:00 +0300 Subject: [PATCH] chore: update description of emitEventStep (#13838) --- packages/core/core-flows/src/common/steps/emit-event.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/core/core-flows/src/common/steps/emit-event.ts b/packages/core/core-flows/src/common/steps/emit-event.ts index a049aeb137..3f3856bba0 100644 --- a/packages/core/core-flows/src/common/steps/emit-event.ts +++ b/packages/core/core-flows/src/common/steps/emit-event.ts @@ -39,7 +39,11 @@ type Input = { export const emitEventStepId = "emit-event-step" /** - * Emit an event. + * This step emits an event, which you can listen to in a [subscriber](https://docs.medusajs.com/learn/fundamentals/events-and-subscribers). You can pass data to the + * subscriber by including it in the `data` property. + * + * The event is only emitted after the workflow has finished successfully. So, even if it's executed in the middle of the workflow, it won't actually emit the event until the workflow has completed successfully. + * If the workflow fails, it won't emit the event at all. * * @example * emitEventStep({