LaravelFCM\Sender\FCMSender::sendToGroup PHP Method

sendToGroup() public method

Send a message to a group of devices identified with them notification key
public sendToGroup ( $notificationKey, Options $options = null, PayloadNotification $notification = null, PayloadData $data = null ) : GroupResponse
$notificationKey
$options LaravelFCM\Message\Options
$notification LaravelFCM\Message\PayloadNotification
$data LaravelFCM\Message\PayloadData
return LaravelFCM\Response\GroupResponse
    public function sendToGroup($notificationKey, Options $options = null, PayloadNotification $notification = null, PayloadData $data = null)
    {
        $request = new Request($notificationKey, $options, $notification, $data);
        $responseGuzzle = $this->post($request);
        return new GroupResponse($responseGuzzle, $notificationKey);
    }