laravel-notification-channels/gcm
Laravel notification channel for sending push notifications through Google Cloud Messaging (GCM). It integrates GCM with Laravel’s notification system, letting you deliver mobile push messages through a dedicated channel.
Architecture fit. The package is a thin adapter, not a platform: one notification channel class (GcmChannel) implementing Laravel's send() contract, one message DTO (GcmMessage) for payload construction, a config file holding a single legacy server API key, and a service provider. It slots into the framework's via() pattern exactly like first-party channels, so architecturally it is a low-ceremony, single-responsibility component with almost no surface area. That is the extent of the good news — the design is idiomatic, but it is idiomatic for a transport that no longer exists.
Integration feasibility. Effectively zero for any greenfield or maintained application. The package targets Google's legacy GCM HTTP endpoint (android.googleapis.com/gcm/send) authenticated by a legacy server key. Google shut down GCM on April 10, 2019 and replaced it with Firebase Cloud Messaging; the legacy server key model was retired alongside it. Even before shutdown, the Composer constraints pin it to the Laravel 5.4–5.6 / PHP 5.6–7.0 era, so it will not resolve against Laravel 9/10/11 without a fork. Nothing in this package can be made to deliver a push notification today without rewriting the transport layer — at which point you have written an FCM client and are only reusing the class names.
Technical risk: critical. Four compounding factors:
The MIT license is the only clean dimension — forking is legally unencumbered, but a fork inherits 100% of the maintenance burden for a component that must be functionally rewritten anyway.
Key questions.
Recommendation: do not adopt. Treat it as a historical reference for Laravel notification channel structure only.
Stack fit. The only scenario where this package is even syntactically appropriate is a legacy Laravel 5.4–5.6 service whose Android client still ships a GCM SDK and which has an existing legacy server key — a combination that has been non-functional since 2019. For any current stack, the fit is negative: it forces a framework downgrade to gain a transport that returns errors.
Migration path. The correct target is FCM via laravel-notification-channels/fcm (HTTP v1 API, service-account credentials) or kreait/laravel-firebase. The translation is mechanical because the message shapes are near-identical:
| GCM package concept | FCM equivalent |
|---|---|
GcmMessage::create()->to($token) |
FcmMessage::create()->to($token) |
->data([...]) |
->data([...]) |
->notification($title, $body) |
->notification(...) |
collapse_key, time_to_live |
Android config block (ttl, collapse_key) |
| Legacy server key in config | Service account JSON / OAuth2 bearer |
via('gcm') |
via('fcm') or FcmChannel::class |
The channel name and config key change, so notification classes need a one-line edit each; payload construction is largely a find-and-replace.
Compatibility. Two distinct compatibility problems, and the second is the expensive one:
Notification contract has been stable across major versions, so the channel mechanics port cleanly to a maintained FCM package.Sequencing.
If step 1 shows no live traffic, collapse steps 3–6 into a single ticket and delete rather than migrate.
Maintenance. The defining operational characteristic is that maintenance cost is recurring and unbounded while value is zero. Every PHP minor, every Laravel major, and every Composer security advisory requires hand-patching a fork with no upstream to rebase onto. Because the package is archived, there is no "wait for a fix" option — internal ownership is mandatory, and it competes with product work in perpetuity.
Support. No vendor, no active maintainer, no community forum. Internal engineers become the sole escalation path for a component they did not write and cannot meaningfully improve. Knowledge concentration risk is high for a component that will attract attention only when it breaks.
Scaling. Not a meaningful axis here, but worth naming: the channel sends one message per notification dispatch, so throughput is bounded by queue workers rather than any provider-specific limit. The legacy GCM multicast ceiling (1,000 tokens per request) was never exercised by this implementation, so fan-out to large audiences requires N dispatches. FCM's topic messaging removes that constraint entirely — a genuine capability gain, not just a dependency swap.
Failure modes. These are the operational argument in miniature:
Ramp-up. Trivial. The codebase is a few hundred lines and any Laravel developer will read it in under an hour. That is precisely why it is not worth keeping: the implementation is cheap to reproduce, while the transport knowledge that matters — FCM HTTP v1 credentials, token lifecycle, topic design, delivery diagnostics — lives entirely outside this package. Adopting it teaches the team nothing transferable.
Bottom line for planning. Do not budget for integration; budget for a half-day audit and, at most, a one-sprint replacement to a maintained FCM package. If the audit finds live GCM-dependent clients, escalate to a mobile-platform workstream — the server-side package is the smallest part of that problem.
How can I help you explore Laravel packages today?