Raw Update#
- class pywa.types.base_update.RawUpdate#
The raw update dict from WhatsApp.
This class is a subclass of
dictand is immutable (you canβt change its content).
Example
>>> from pywa import WhatsApp >>> from pywa.types import RawUpdate
>>> wa = WhatsApp(...)
>>> @wa.on_raw_update ... def callback(_: WhatsApp, update: RawUpdate): ... print(update["entry"]) # the raw dict ... print(update.id, update.field, update.value) # shortcut properties ... print(update.raw) # the raw bytes of the update