on_subscription_request Event
This event fires when a subscription request is received.
Syntax
class XMPPSubscriptionRequestEventParams(object): @property def from_() -> str: ... @property def domain() -> str: ... @property def accept() -> bool: ... @accept.setter def accept(value) -> None: ... # In class XMPP: @property def on_subscription_request() -> Callable[[XMPPSubscriptionRequestEventParams], None]: ... @on_subscription_request.setter def on_subscription_request(event_hook: Callable[[XMPPSubscriptionRequestEventParams], None]) -> None: ...
Remarks
This event fires whenever another XMPP entity requests a subscription to this entity's presence. The XMPP class will parse the requesting entity's Jabber ID into the From and Domain parameters. There is no need to know which resource sent the request, since all instances of the requesting entity's account have access to the same roster.
Accept will initially be false, but setting it to true will cause the XMPP class to allow the remote subscription. Otherwise, the XMPP class will actively deny the subscription request.