Expand description
chatPush support for RFC 8620 push subscriptions
(draft-atwood-jmap-chat-push-00).
The chatPush property lives in PushSubscription::extra as a map of
accountId to ChatPushConfig. A backend calls validate_chat_push on
every create and update, strip_unsupported_chat_push on every
subscription it returns from list_push_subscriptions, builds
notifications with chat_state_change_for, and builds the
ChatMessagePush for each new inbound message with
build_chat_message_push after should_push allows it.
Structs§
- Built
Push - A built
ChatMessagePushand the Web Push urgency to deliver it with. - Owner
Flags - The account owner’s standing in the Chat at delivery time, which decides the broadcast scopes that target them.
- Push
Item - The stored records one
ChatMessageEntryis built from.
Functions§
- build_
chat_ message_ push - Build the
ChatMessagePushfor one new inbound message under one subscription’sChatPushConfigforaccount_id. - chat_
state_ change_ for - The
StateChangeto push tosubfor the types inchanged, orNonewhen nothing is left to send. - should_
push - Whether a
ChatMessagePushfor the new inbound messagemsggoes to a subscription whosechatPushentry foraccount_idiscfg. - strip_
unsupported_ chat_ push - Remove
chatPushentries for accounts not incapsfrom a stored subscription’sextramap before it is returned. - validate_
chat_ push - Check the
chatPushproperty in aPushSubscription’sextramap before it is stored.