Added
- If not already set, APNs configs are enriched with the necessary headers and fields to ensure the delivery of iOS background messages and alerts.
- The
apns-push-type
header is set tobackground
oralert
- The
content-available
field is set to1
in case of a background message
- The
- FCM Messages are now annotated for better PHPStan/Psalm resolution
- Added methods
\Kreait\Firebase\Messaging\AndroidConfig::withMinimalNotificationPriority()
\Kreait\Firebase\Messaging\AndroidConfig::withLowNotificationPriority()
\Kreait\Firebase\Messaging\AndroidConfig::withDefaultNotificationPriority()
\Kreait\Firebase\Messaging\AndroidConfig::withHighNotificationPriority()
\Kreait\Firebase\Messaging\AndroidConfig::withMaximalNotificationPriority()
\Kreait\Firebase\Messaging\AndroidConfig::withNotificationPriority()
\Kreait\Firebase\Messaging\AndroidConfig::withUnspecifiedNotificationPriority()
\Kreait\Firebase\Messaging\AndroidConfig::withPrivateNotificationVisibility()
\Kreait\Firebase\Messaging\AndroidConfig::withPublicNotificationVisibility()
\Kreait\Firebase\Messaging\AndroidConfig::withSecretNotificationVisibility()
\Kreait\Firebase\Messaging\AndroidConfig::withNotificationVisibility()
\Kreait\Firebase\Messaging\ApnsConfig::data()
\Kreait\Firebase\Messaging\ApnsConfig::hasHeader()
\Kreait\Firebase\Messaging\ApnsConfig::isAlert()
\Kreait\Firebase\Messaging\ApnsConfig::toArray()
\Kreait\Firebase\Messaging\ApnsConfig::withApsField()
\Kreait\Firebase\Messaging\ApnsConfig::withDataField()
\Kreait\Firebase\Messaging\ApnsConfig::withHeader()
Changed
- FCM notifications (
Kreait\Firebase\Messaging\Notification
) can now be created with null values. If a notification has only null values, the notification payload will be removed on serialization as if it wasn't provided at all. - Deprecations
\Kreait\Firebase\Messaging\AndroidConfig::withHighPriority()
, use\Kreait\Firebase\Messaging\AndroidConfig::withHighMessagePriority()
instead\Kreait\Firebase\Messaging\AndroidConfig::withNormalPriority()
, use\Kreait\Firebase\Messaging\AndroidConfig::withNormalMessagePriority()
instead\Kreait\Firebase\Messaging\AndroidConfig::withPriority()
, use\Kreait\Firebase\Messaging\AndroidConfig::withMessagePriority()
instead