botman/driver-web
Web driver for BotMan that connects PHP chatbots to websites, handling incoming browser messages and sending replies. Add interactive chatbot conversations to Laravel or PHP apps with a simple, framework-friendly integration.
Architecture fit
botman/driver-web is a channel driver for the BotMan conversational framework. It does not stand alone: it depends on botman/botman and contributes a WebDriver that exposes a JSON endpoint for a browser-based chat widget (or any custom front end acting as an API client). For a Laravel codebase this is a natural fit — the driver is a thin HTTP transport layered on BotMan's middleware/hearing pipeline, so intent matching, conversation state, and NLU calls remain in BotMan core. It is the right shape for FAQ bots, lead capture, and in-app support assistants where the front end is first-party.
Integration feasibility High for a proof of concept. Composer install plus a route registration and a widget embed is a sub-day effort for a Laravel developer. Feasibility drops for production hardening: the widget assets are dated, the endpoint is public and unauthenticated by default, and the package's release history ends in March 2018.
Technical risk
--ignore-platform-reqs or constraint overrides — both are unacceptable in a maintained application.Key questions
composer require resolve without overrides?Stack fit Laravel + BotMan core + this driver is a supported, documented combination for the BotMan 2.x era. It fits cleanly if the application is on PHP 7.4/8.0 with Laravel 6–8. On Laravel 10+ assume friction and budget a spike to confirm or reject.
Migration path
Treat the driver as an adapter, not a foundation. Define an internal ChatTransport interface (receive message → dispatch to conversation handler → return reply) and implement it once against this driver. If the package is later abandoned, swapping to a custom controller or a different channel is a one-class change rather than a rewrite. Isolate the widget behind a Blade component so the front end can be replaced independently of the backend.
Compatibility
Pin exact versions of botman/botman, botman/driver-web, and the transitive Symfony packages in composer.lock; add a Dependabot/renovate exclusion so automated bumps don't silently break the endpoint. Verify the widget's JS against the current browser matrix and any CSP — a 2018 Vue bundle will likely need CSP exceptions or re-bundling.
Sequencing
Maintenance Effectively zero upstream maintenance. Assume we own the code: fork it internally, vendor the pinned version, and record it in the dependency-risk register with a named owner and a review date. Budget a few days per year for PHP/Laravel upgrade compatibility, plus ad-hoc time if a transitive dependency CVE requires a patch we must author.
Support No vendor. Support is internal engineering plus GitHub issues with a years-old backlog. Any incident — widget not loading, endpoint 500s, conversation state lost — routes to our on-call, not to a supplier. Document the endpoint contract and known failure signatures so first-line support can triage.
Scaling The driver is request/response; each message boots BotMan and runs the middleware pipeline, so per-message latency is dominated by bootstrap and any external NLU call. Conversation state lives in session/cache — this is the binding constraint. For multi-node deployments, move session storage to Redis and ensure sticky or shared state; otherwise users lose context mid-conversation on every load-balancer hop. The endpoint is trivially cacheable-free and should sit behind a WAF/rate limiter. Plan capacity around concurrent open conversations, not page views.
Failure modes
Ramp-up Low for a Laravel developer — a half-day to first working bot using the docs, which are dated but adequate. The real ramp-up cost is institutional knowledge of the workarounds: pinned constraints, widget quirks, and the adapter seam. Capture that in an ADR at spike close, including the explicit decision to accept an unmaintained dependency for a bounded, low-risk use case — or to skip the package and write the endpoint directly.
How can I help you explore Laravel packages today?