Menu

## SendPushNotification

SendPushNotification.php : 12

### Table of Contents

#### Methods

sendNotification() : DownstreamResponse|null
  Send a push notification to a user via FCM.
sendTeacherNotification() : DownstreamResponse|null
  Send a teacher-specific push notification via FCM.

### Methods

#### sendNotification()

SendPushNotification.php : 22

Send a push notification to a user via FCM.

`public sendNotification(array<string|int, mixed> $array, array<string|int, mixed>|string $usertoken) : DownstreamResponse|null`

##### Parameters

$array : array<string|int, mixed>

  Payload containing at least 'type' and 'message'

$usertoken : array<string|int, mixed>|string

  Single token or array of device tokens

##### Return values

DownstreamResponse|null —

Response object or null on failure

#### sendTeacherNotification()

SendPushNotification.php : 69

Send a teacher-specific push notification via FCM.

`public sendTeacherNotification(array<string|int, mixed> $array, array<string|int, mixed>|string $usertoken) : DownstreamResponse|null`

##### Parameters

$array : array<string|int, mixed>

  Payload containing at least 'type' and 'message'

$usertoken : array<string|int, mixed>|string

  Single token or array of device tokens

##### Return values

DownstreamResponse|null —

Response object or null on failure

## Search results