- Is flosch/stripe-bundle a Laravel package I can install with composer require?
- No. flosch/stripe-bundle is a Symfony bundle: it has no Laravel service provider, no facade, no publishable config file, and no package auto-discovery. Its only job is registering the official stripe/stripe-php client in Symfony's dependency injection container and exposing a pre-configured client. On a Laravel application it is a category mismatch, and Composer will typically fail to resolve it because Laravel ships Symfony components but not symfony/framework-bundle. Treat it as a Symfony tool, not a Laravel dependency.
- How do I install and configure flosch/stripe-bundle in a Symfony app?
- Install it with Composer and enable the bundle in your kernel or bundles.php, then add your Stripe public and secret keys plus any client options under the bundle's configuration key in config/packages. Once the credentials are set, the configured Stripe client becomes available as a container service you can inject anywhere. Keep the secret key in environment variables rather than committing it to configuration files.
- What Laravel package should I use instead for Stripe payments?
- There is no reason to look for a wrapper at all: bind stripe/stripe-php as a singleton in a first-party service provider and mirror the config surface the bundle offers (public key, secret key, API version, optional client options). This is roughly half a day to one day of work and removes a third-party dependency from revenue-adjacent code. You also get to add the pieces the bundle does not supply, such as webhook signature verification and idempotency keys.
- Does flosch/stripe-bundle support Laravel autowiring or dependency injection?
- It supports autowiring only within Symfony's container, where the Stripe client is registered as a service and can be type-hinted in controllers and services. Laravel's container will not see that registration because there is no Laravel service provider in the package. Laravel's own container autowiring works fine with the Stripe SDK directly once you bind it yourself.
- Which PHP and Symfony versions does flosch/stripe-bundle support?
- The bundle targets Symfony 3 and later, which implies long end-of-life constraints that rarely resolve cleanly against modern PHP versions. Before writing any code, check the composer.json require block for exact php, symfony/framework-bundle, and stripe/stripe-php constraints, and confirm nothing in the chain is out of security support. If you are on a currently supported Symfony release, verify the resolution works without --ignore-platform-reqs, which is unacceptable for a payments dependency.
- Does flosch/stripe-bundle verify Stripe webhook signatures?
- No. The bundle only injects an API-key-configured Stripe client; webhook signature verification, idempotency handling, and retry or backoff logic are all left to you. You must call Stripe\Webhook::constructEvent with the raw request body, the Stripe-Signature header, and your signing secret. Do this in a route that bypasses CSRF and any middleware that would rewrite or parse the payload.
- How do I use the Stripe PHP SDK in Laravel without this bundle?
- Require stripe/stripe-php directly, add your keys to config/services.php and .env, and register a singleton in a service provider that constructs StripeClient with an explicit API version. Inject that client, or a thin wrapper around it, into your controllers and jobs. Pinning the API version explicitly protects you from Stripe's rolling deprecations changing response and webhook shapes silently.
- Is flosch/stripe-bundle safe and maintained enough for production payments?
- It has very low adoption (roughly 29 stars, no dependents) and no visible CI, test suite, security policy, or documented release cadence, with a bus factor of one. For revenue-adjacent code that combination reads as supply-chain risk rather than convenience. The MIT license leaves a fork path open, but forking turns a dependency into an internal maintenance obligation you must staff and own.
- How do I migrate an existing Symfony app off flosch/stripe-bundle?
- Define the Stripe client explicitly in config/services.yaml, keep the same service id so call sites do not change, then remove the bundle from Composer and your kernel. Preserve behavior by copying the bundle's configuration values, especially the API version, into the new service definition. If the app was vendor-patched, replace the patch behind the same internal interface first, then delete it.
- What are the alternatives to flosch/stripe-bundle for Stripe in PHP?
- The most reliable alternative is the official stripe/stripe-php SDK wired directly through your framework's container, which is what most maintained Symfony and Laravel integrations effectively do. You can also treat the bundle as a reference implementation: copy its wiring pattern, keep the SDK as the real dependency, and skip the package. If you want a maintained Symfony integration, check release activity, supported Symfony versions, and test coverage before adopting.