Skip to content

Notification

Canonical path: o6.server.Notification

Root shortcut: o6.Notification

Notification dataclass

One application notification.

A type identifies both the category (lifecycle, secure channel, session, service, subscription, monitored item, discovery, audit) and the specific event within that category. For the lifecycle category type is one of the NotificationType.LIFECYCLE_* members.

Payload keys mirror open62541's UA_KeyValueMap entries — string keys whose values are converted to Python types (NodeIds as o6.NodeId, scalars as the matching o6.* wrapper, etc.). For audit notifications, the keys are event-filter property paths ("/ActionTimeStamp", "/Status", ...) — the same convention used for event field data elsewhere (e.g. o6.Event.fields, a monitored event item's callback).

Attributes:

Name Type Description
type int

The raw open62541 notification type.

payload Mapping[str, Any]

A read-only mapping of str -> Any of the notification's payload fields.

lifecycle str | None

For lifecycle notifications only, the human-readable point name ("started", "shutdown", "stopping", "stopped"). None for notifications of any other category.

auditEventType 'o6.NodeId | None'

For audit notifications only, the standardized AuditEventType subtype (or a supertype thereof) this notification corresponds to, e.g. o6.NodeId(o6.ns.ns0.objtypes.AuditActivateSessionEventType). None for notifications of any other category, and always None on a Client, which never raises audit notifications.

Attributes

type instance-attribute

type

payload class-attribute instance-attribute

payload = field(default_factory=dict)

lifecycle class-attribute instance-attribute

lifecycle = None

auditEventType class-attribute instance-attribute

auditEventType = None

Functions

__post_init__

__post_init__()

__init__

__init__(
    type,
    payload=dict(),
    lifecycle=None,
    auditEventType=None,
)