Open
Description
class Aps:
"""Aps dictionary to be included in an APNS payload.
Args:
alert: A string or a ``messaging.ApsAlert`` instance (optional).
badge: A number representing the badge to be displayed with the message (optional).
sound: Name of the sound file to be played with the message or a
``messaging.CriticalSound`` instance (optional).
content_available: A boolean indicating whether to configure a background update
notification (optional).
category: String identifier representing the message type (optional).
thread_id: An app-specific string identifier for grouping messages (optional).
mutable_content: A boolean indicating whether to support mutating notifications at
the client using app extensions (optional).
custom_data: A dict of custom key-value pairs to be included in the Aps dictionary
(optional).
"""
def __init__(self, alert=None, badge=None, sound=None, content_available=None, category=None,
thread_id=None, mutable_content=None, custom_data=None):
self.alert = alert
self.badge = badge
self.sound = sound
self.content_available = content_available
self.category = category
self.thread_id = thread_id
self.mutable_content = mutable_content
self.custom_data = custom_data
in the doc strings Aps content_available states as boolean property, while in reality we need to send a number either 0 or 1.
Please fix the doc string, we where struggiling to understand why the custom data didn't receive in the message payload because of that incorrect stated doc string.
Than you