tomatophp/filament-workflows
Filament Workflows brings visual workflow automation to Filament panels. Build triggers, conditions, approvals, and actions, connect Laravel models and notifications, and manage runs from a clean admin UI. Automate business processes without leaving your Filament app.
tomatophp/filament-icons ^5. Do not attempt this on a Laravel 11 / Filament 3 app — that code path lives on the v3 branch.composer require the package, then php artisan migrate. You get tables for workflows, triggers, actions and workflow logs. If you skip this, nothing errors (the trait is deliberately migration-safe) — it just silently does nothing.InteractsWithWorkflow trait to the model whose created / updated / deleted events should start a workflow.boot(), call FilamentWorkflows::action([SendWelcomeMail::class, AssignOwner::class]). Classes must extend Services\Abstracts\Action — anything else is ignored.Order created → trigger condition status is pending → action sends a notification → open the Workflow Log list and confirm one row per run. That loop (model event → condition → action → log) is 90% of day-to-day usage.Services\Abstracts\Action. Keep them idempotent: they can be re-run from a Workflow Log investigation, and multiple workflows may call the same one.FilamentWorkflows::action([...]) in a dedicated WorkflowServiceProvider (or a clearly commented block in AppServiceProvider) so reviewers can see every runnable action in one place. The array form registers all entries at once — use it rather than repeated single calls.where / is / value comparison. Use it to short-circuit obviously irrelevant events, and move anything richer (multi-field checks, related-model lookups, "only if not already processed") into the first action of the workflow.GET for pings and POST for payloads.FILAMENT_WORKFLOWS_WEBHOOK_TOKEN per environment, store it in your secret manager, and only then enable the endpoint — it is closed until the token is set. Because the token is kept out of logs, instrument the sender with a request ID if you need to trace calls.Workflow, Trigger, Action, WorkflowLog) inside RefreshDatabase tests: build a workflow, dispatch the model event, assert the side effect and the Workflow Log row. This is also the cheapest way to verify a condition filter behaves as you expect.Abstract\Action subclasses execute, treat the base class as an architectural contract. Code review should reject any class registered in FilamentWorkflows::action() that doesn't extend it.Services\Abstracts\Action simply doesn't run. There is no exception at registration time — you'll only notice via a Workflow Log run with no effect.InteractsWithWorkflow is safe on an unmigrated database — which is great for rolling deploys, but means "workflows aren't firing" is very often "the tables aren't there yet". Check php artisan migrate:status first.429s; make the sender retry with backoff and confirm the throttle limit is appropriate for your volume.where / is / value against a single record is not a query builder — no orWhere chains, no relation-based conditions. Complex branching belongs in actions.filament-icons to ^5 alongside Filament 5 to avoid panel boot failures.Abstract\Action base class, event triggers for custom domain signals, and the Filament resource/page layer for admin-facing customisation.How can I help you explore Laravel packages today?