Skip to main content

Module push

Module push 

Source
Expand description

Common types for the push notifications module.

§Understanding the types of this module

Push rules are grouped in RuleSets, and are grouped in five kinds (for more details about the different kind of rules, see the Ruleset documentation, or the specification). These five kinds are, by order of priority:

  • override rules
  • content rules
  • room rules
  • sender rules
  • underride rules

Structs§

ConditionalPushRule
Like SimplePushRule, but with an additional conditions field.
ConditionalPushRuleInit
Initial set of fields of ConditionalPushRule.
EventMatchConditionData
Data for the event_match PushCondition.
EventPropertyContainsConditionData
Data for the event_property_contains PushCondition.
EventPropertyIsConditionData
Data for the event_property_is PushCondition.
FlattenedJson
The flattened representation of a JSON object.
HttpPusherData
Information for a pusher using the Push Gateway API.
NewConditionalPushRule
A conditional push rule to update or create.
NewPatternedPushRule
A patterned push rule to update or create.
NewSimplePushRule
A simple push rule to update or create.
PatternedPushRule
Like SimplePushRule, but with an additional pattern field.
PatternedPushRuleInit
Initial set of fields of PatternedPushRule.
PushConditionPowerLevelsCtx
The room power levels context to be able to test the corresponding push conditions.
PushConditionRoomCtx
The context of the room associated to an event to be able to test all push conditions.
RoomMemberCountConditionData
Data for the room_member_count PushCondition.
RoomMemberCountIs
A decimal integer optionally prefixed by one of ==, <, >, >= or <=.
RoomVersionSupportsConditionDataunstable-msc3931
Data for the room_version_supports PushCondition.
RuleNotFoundError
The error type returned when trying modify a push rule that could not be found in a Ruleset.
Ruleset
A push ruleset scopes a set of rules according to some criteria.
RulesetIntoIter
Iterator type for Ruleset
RulesetIter
Iterator type for Ruleset
SenderNotificationPermissionConditionData
Data for the sender_notification_permission PushCondition.
SimplePushRule
A push rule is a single rule that states under what conditions an event should be passed onto a push gateway and how the notification should be presented.
SimplePushRuleInit
Initial set of fields of SimplePushRule.
ThreadSubscriptionConditionDataunstable-msc4306
Data for the thread_subscription PushCondition.

Enums§

Action
This represents the different actions that should be taken when a rule is matched, and controls how notifications are delivered to the client.
AnyPushRule
The kinds of push rules that are available.
AnyPushRuleRef
Reference to any kind of push rule.
ComparisonOperator
One of ==, <, >, >= or <=.
FlattenedJsonValue
Possible JSON values after an object is flattened.
HighlightTweakValue
Whether or not a message should be highlighted in the UI.
InsertPushRuleError
The error type returned when trying to insert a user-defined push rule into a Ruleset.
NewPushRule
A push rule to update or create.
PredefinedContentRuleId
The rule IDs of the predefined content server push rules.
PredefinedOverrideRuleId
The rule IDs of the predefined override server push rules.
PredefinedRuleId
The rule IDs of the predefined server push rules.
PredefinedUnderrideRuleId
The rule IDs of the predefined underride server push rules.
PushCondition
A condition that must apply for an associated push rule’s action to be taken.
PushFormat
A special format that the homeserver should use when sending notifications to a Push Gateway. Currently, only event_id_only is supported, see the Push Gateway API.
RemovePushRuleError
The error type returned when trying to remove a user-defined push rule from a Ruleset.
RoomVersionFeatureunstable-msc3931
Features supported by room versions.
RuleKind
The kinds of push rules that are available.
ScalarJsonValue
Scalar (non-compound) JSON values.
SoundTweakValue
A sound to play when a notification arrives.
Tweak
The set_tweak action.

Functions§

insert_and_move_rule
Insert the rule in the given indexset and move it to the given position.