morcen/passage
Morcen Passage is a lightweight Laravel package that provides a clean, expressive API for defining and managing state transitions and workflows on your Eloquent models. Keep complex business logic organized, track changes with ease, and integrate seamlessly into any Laravel application.
Architecture fit. morcen/passage is a Laravel package for structuring outbound HTTP integrations as discrete, container-resolved "handlers" with a controller interface (PassageControllerInterface), a cache manager, an event subscriber for logging, and artisan tooling (passage:list, passage:controller). That is a strong architectural fit for Laravel estates that accumulate ad-hoc Http:: calls across services and need per-integration auth, caching, retries, and observability. v3.1.1 materially improves the fit: retry-enabled handler scaffolding (--with-retry), an HMAC controller stub, documented $when conditional-retry callbacks, and resilience in passage:list all target the operational gaps that typically block standardization.
Integration feasibility. Composer-installable, config-published, generator-driven — a low-ceremony onboarding path. The most consequential change is PR #81, which resolves security audit advisories by allowing Laravel 12. That removes a hard framework-version blocker for teams on Laravel 12 and is the single item that most affects go/no-go. The remaining changes are additive: new stubs, tests, docblocks, and CI dependency bumps with no runtime impact.
Technical risk.
feat: commits (HMAC stub, retry scaffolding). Semver-conservative consumers using ~3.1.0 will absorb new code generation behavior without a minor bump. Pin exactly and review generated output.passage:list tolerating broken handlers (PR #74) is good for DX but can mask misconfiguration in CI or dashboards. Pair with explicit health checks.Key questions.
$when receive both response and exception?Stack fit. Laravel applications already using the framework HTTP client, service container, and config publishing. The package sits alongside — not replaces — Guzzle/Http; handlers are the unit of integration, which maps cleanly to a "one handler per third-party service" ownership model.
Migration path. Greenfield: install and generate. Brownfield: inventory existing outbound calls, then migrate one handler at a time, starting with a read-only, idempotent integration. There is no data migration and no forced refactor; coexistence with existing Http:: usage is expected.
Compatibility. Confirm the resolved PHP and Laravel constraints in composer.json before adopting, specifically that your Laravel version and PHP minor are inside the newly widened range. The dependabot changes in this release are GitHub Actions and metadata tooling only — no runtime dependency risk. Verify your error-handling paths against the new structured-JSON invalid-base-URI response.
Sequencing.
^3.1.1 (or exact) in a non-production branch; run your application test suite.passage:controller; validate discovery and passage:list output.PassageEventSubscriber logging into your existing log/alert pipeline.--with-retry and a $when callback only for idempotent operations; review generated backoff values.Maintenance. Actively maintained: dependabot cadence, external contributions, documentation and test investment in this release. The patch-with-features pattern is the main process smell; expect to read changelogs rather than trust semver alone.
Support. Documentation improved meaningfully ($when semantics, @param/@return tags, interface usage example), but HMAC specifics and retry policy semantics remain underspecified relative to their production risk. Internal runbooks will be needed.
Scaling. Handler-per-integration scales well organizationally and keeps blast radius small. Centralized caching and retries reduce duplicate load on downstreams. Retry without jitter or a circuit breaker can amplify incidents during downstream degradation — treat retry configuration as a capacity decision, not a default.
Failure modes. Invalid base URI now fails with structured JSON — better, but confirm your monitoring parses it. Broken handlers are skipped by passage:list, so add a CI assertion that expected handlers are listed. Retries on non-idempotent calls, HMAC clock skew, cache stampede on cold keys, and swallowed handler-resolution errors are the four to instrument first.
Ramp-up. Low for Laravel-fluent engineers: generators and interface conventions cut boilerplate. Estimate one to two days for a developer to ship a first production handler with logging and retry, and roughly one sprint for a team to agree conventions, HMAC implementation, and observability. Adopt with a pinned version and a pilot integration; treat the retry and HMAC scaffolds as review-required starting points rather than finished patterns.
How can I help you explore Laravel packages today?