NewWe open-sourced 50+ Laravel packages
Custom AI apps, agents and automation — Roundly ConsultingRoundly
All packages

All events are final readonly, dispatched after commit and never broadcast. Instance, step and escalation events carry the instance as $actor and the Actor DTO as $runAs:

EventPayload
InstanceStartedinstance
StepStartedinstance, stepRun
StepCompletedinstance, stepRun, outcome
StepFailedinstance, stepRun, code, willRetry
InstanceWaitinginstance, stepRun, waits
InstanceResumedinstance, stepRun, signal (SignalKind)
InstanceCompletedinstance
InstanceFailedinstance, code, message, node
InstanceCancelledinstance, reason
InstanceRetriedinstance, stepRun
EscalationTriggeredinstance, stepRun, level, actions
EscalationFailedinstance, stepRun, level, code
VersionPublisheddefinition, version, publisher
DraftSaveddefinition, version
DefinitionRetireddefinition
use RoundlyConsulting\Workflows\Events\InstanceFailed;

Event::listen(InstanceFailed::class, function (InstanceFailed $event): void {
    Log::warning('Workflow failed', [
        'instance' => $event->instance->ulid,
        'code' => $event->code,          // a FailureCode value or a host step's code
        'node' => $event->node,
    ]);
});

Show your open-source love

This package is free and MIT-licensed. If it saves you time, a one-off donation or a Patreon membership keeps it maintained, tested and documented.

More ways to support, including crypto

By donating, you agree to our donation terms.

Want this built into your product?

We integrate our packages into custom Laravel and AI builds. Tell us what you're working on and we'll reply within 48 hours.