Skip to content

Latest commit

 

History

History
153 lines (66 loc) · 3.15 KB

LaravelFCM-Sender-FCMSender.md

File metadata and controls

153 lines (66 loc) · 3.15 KB

LaravelFCM\Sender\FCMSender

Class FCMSender

Constants

MAX_TOKEN_PER_REQUEST

const MAX_TOKEN_PER_REQUEST = 1000

Properties

$client

protected \Illuminate\Foundation\Application $client

Guzzle Client

  • Visibility: protected

$config

protected array $config

configuration

  • Visibility: protected

$url

protected mixed $url

url

  • Visibility: protected

Methods

sendTo

\LaravelFCM\Response\DownstreamResponse|null LaravelFCM\Sender\FCMSender::sendTo(String|array $to, \LaravelFCM\Message\Options|null $options, \LaravelFCM\Message\PayloadNotification|null $notification, \LaravelFCM\Message\PayloadData|null $data)

send a downstream message to

  • a unique device with is registration Token
  • or to multiples devices with an array of registrationIds
  • Visibility: public

Arguments

sendToGroup

\LaravelFCM\Response\GroupResponse LaravelFCM\Sender\FCMSender::sendToGroup($notificationKey, \LaravelFCM\Message\Options|null $options, \LaravelFCM\Message\PayloadNotification|null $notification, \LaravelFCM\Message\PayloadData|null $data)

Send a message to a group of devices identified with them notification key

  • Visibility: public

Arguments

sendToTopic

\LaravelFCM\Response\TopicResponse LaravelFCM\Sender\FCMSender::sendToTopic(\LaravelFCM\Message\Topics $topics, \LaravelFCM\Message\Options|null $options, \LaravelFCM\Message\PayloadNotification|null $notification, \LaravelFCM\Message\PayloadData|null $data)

Send message devices registered at a or more topics

  • Visibility: public

Arguments

getUrl

string LaravelFCM\Sender\BaseSender::getUrl()

get the url

__construct

mixed LaravelFCM\Sender\BaseSender::__construct()

BaseSender constructor.