Skip to content

Basic class to send push notifications using google firebase.

License

Notifications You must be signed in to change notification settings

legomolina/fcm-push-notifications

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FCM Push Notifications

Basic class to send push notifications using google firebase.

Installation

Be careful! This library needs curl module for php to work.

FMC Push Notifications is hosted in packagist so you can get it from Composer

composer require legomolina/fcm-push-notification

Usage

Require the Composer autoload in your index:

<?php
    require 'vendor/autoload.php';

Set your Firebase API key

FCMPushNotifications::API_KEY = "my_api_key";

Create a notification object:

$notification = new FCMNotification("Title", "Message");

And send notifications

FCMPushNotifications::send("mobile_token_or_topic", $notification, [ "custom" => "data" ]);

License

FMC Push Notifications is licensed under the GPL v3 license. See License File for more information.

About

Basic class to send push notifications using google firebase.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages