- Can I install mrdanshur/awspushbundle directly in a Laravel application?
- No. It is a Symfony bundle, and Laravel does not process Symfony Bundle registration, Extension::load(), or the bundle's Configuration TreeBuilder. Installing it may also pull symfony/framework-bundle and dependency-injection into your app, so treat it as source material rather than a drop-in Laravel package.
- How do I use AWS SNS mobile push notifications in Laravel with this package?
- Use it as a reference implementation: copy the SNS client wrapper and payload-builder classes into app/Support/Push, put them behind a PushSender interface, and register that binding in AppServiceProvider. Keep credentials and platform application ARNs in config/services.php and environment variables. This is typically a one-to-two-day spike if the classes are not container-coupled.
- Does awspushbundle support FCM v1, or is it still using GCM?
- The 1.0.1 release is described as a GCM fix, not a migration to FCM v1 with OAuth2 and HTTP v1. Google has retired the legacy GCM and legacy FCM server-key APIs, so the Android path should be considered nonviable as shipped. Confirm whether any FCM v1 code exists before reusing the Android payload envelope; the APNS path may still be reusable.
- Which Laravel and PHP versions can use this package?
- The package is a Symfony bundle, so there is no official Laravel version support matrix. For a Laravel 10 or 11 extraction on PHP 8.1+, inspect its composer.json for aws/aws-sdk-php and symfony/* constraints before assuming compatibility. The bundle scaffolding is not intended to run in Laravel's container.
- How are AWS credentials and platform application ARNs configured?
- In Symfony, they are configured through the bundle's DI configuration tree and injected into the SNS client service. In Laravel, that configuration tree is never processed, so recreate the settings in config/services.php and bind your own SnsClient with env-based credentials. Store APNS and FCM platform application ARNs as config values, not hard-coded strings.
- Is mrdanshur/awspushbundle production-ready and actively maintained?
- It has 0 stars, 0 dependents, and a single maintainer, with roughly one patch in two years. Release 1.0.1 shows the maintainer is reachable, but it does not create downstream validation, a security-review process, or compatibility pressure on AWS SDK major bumps. For a production push path, vendor and own the small amount of code you need rather than depending on the bundle directly.
- Can I send push notifications to a single device endpoint or to a topic?
- The bundle advertises publishing to individual device endpoints and topics using SNS endpoint and topic ARNs. In a Laravel extraction, keep those publish calls in a thin service and verify the payload envelope for each platform. Direct endpoint ARNs are for one device; topic ARNs fan out to subscribers.
- Will this bundle conflict with Laravel's Symfony dependencies?
- Likely yes if installed as a normal Composer dependency. It brings symfony/framework-bundle and dependency-injection requirements that can collide with Laravel's pinned symfony/* versions. Run a Composer dry run and check why-not before installing; vendoring the portable classes avoids the dependency conflict entirely.
- How do I test SNS push notifications from Laravel without sending real pushes?
- Mock the SNS client behind your PushSender interface and assert the publish arguments, including target ARN and platform-specific payload. If the payload builders can be instantiated standalone, unit test them directly; if they require Symfony services, refactor them first. SNS mobile push has no true local sandbox, so a fake client is the practical test seam.
- What are the alternatives to using this bundle for Laravel push notifications?
- You can use aws/aws-sdk-php directly with a small SnsClient wrapper, or use Laravel notification channels for FCM and APNs. Managed providers are another option if you do not want to own token invalidation and delivery feedback. If you stay with SNS, evaluate token invalidation and endpoint-disabled feedback yourself, because this bundle appears fire-and-forget.