SubscribeAlarm (RT Unified) - WinCC Unified

WinCC Unified Open Pipe (RT Unified)

ft:publication_title
WinCC Unified Open Pipe (RT Unified)
Product
WinCC Unified
Version
V20
Publication date
06/2025
Language
en-US
SubscribeAlarm

Description

The "SubscribeAlarm" command subscribes systems for monitoring of changes of active alarms.

The first time "NotifySubscribeAlarm" is called, all active alarms are queried. Afterwards "NotifySubscribeAlarm" is only called if the status of an alarm changes.

Request

{"Message":"SubscribeAlarm","Params":{"SystemNames":["<System>","<System>"],"Filter":"<Filter>","LanguageId":<ID>},"ClientCookie":"<Cookie>"}

  • SystemNames: Optional

    When the list is empty or missing, all known systems are subscribed for monitoring.

  • Filter: Optional

  • LanguageID: Optional

  • ClientCookie:

    Is used for "UnsubscribeAlarm" and to assign the notification to its monitoring.

For example:

{"Message":"SubscribeAlarm","Params":{"SystemNames":["System0","System1"],"Filter":"AlarmClassName != ‘Warning’","LanguageId":1033},"ClientCookie":"CookieForSubscribeAlarms123"}

Response

OnSuccess

{"Message":"NotifySubscribeAlarm","ClientCookie":"<Cookie>","params":{"Alarms":[{<Key value pairs for the properties of the first alarm>},{<Key value pairs for the properties of the second alarm>}, {<...>}]}}

For example:

{"Message":"NotifySubscribeAlarm","ClientCookie":"CookieForSubscribeAlarms123","params":{"Alarms":[{"AcknowledgmentTime":"1970-01-01 00:00:00.0000000","AlarmClassName":"Alarm","AlarmClassSymbol":"Alarm","AlarmText1":"","AlarmText2":"","AlarmText3":"","AlarmText4":"","AlarmText5":"","AlarmText6":"","AlarmText7":"","AlarmText8":"","AlarmText9":"","Area":"","BackColor":"4294967295","ChangeReason":"3","ClearTime":"1970-01-01 00:00:00.0000000","Connection":"1.0.0.0.0.0","DeadBand":"No deadband configured.","Duration":"00:00:01.7431098","EventText":"","Flashing":"FALSE","HostName":"md1z5cpc","ID":"0","InfoText":"","InstanceID":"9","LoopInAlarm":"","ModificationTime":"2019-01-30 11:25:39.9780320","Name":"RUNTIME_1::Tag_2:Alarm2","NotificationReason":"1","Origin":"","Priority":"1","RaiseTime":"2019-01-30 11:25:39.9780320","ResetTime":"1970-01-01 00:00:00.0000000","SourceID":"","SourceType":"1","State":"1","StateMachine":"7","StateText":"R","SuppressionState":"0","SystemSeverity":"0","Tag":"RUNTIME_1::Tag_2","TextColor":"4278190080","UserName":"","Value":"7","ValueLimit":"No limit configured.","ValueQuality":"192"},{"AcknowledgmentTime":"1970-01-01 00:00:00.0000000","AlarmClassName":"Alarm","AlarmClassSymbol":"Alarm","AlarmText1":"","AlarmText2":"","AlarmText3":"","AlarmText4":"","AlarmText5":"","AlarmText6":"","AlarmText7":"","AlarmText8":"","AlarmText9":"","Area":"","BackColor":"4294967295","ChangeReason":"3","ClearTime":"1970-01-01 00:00:00.0000000","Connection":"1.0.0.0.0.0","DeadBand":"No deadband configured.","Duration":"00:00:01.7431098","EventText":"","Flashing":"FALSE","HostName":"md1z5cpc","ID":"0","InfoText":"","InstanceID":"9","LoopInAlarm":"","ModificationTime":"2019-01-30 11:25:39.9780320","Name":"RUNTIME_1::Tag_2:Alarm1","NotificationReason":"1","Origin":"","Priority":"1","RaiseTime":"2019-01-30 11:25:39.9780320","ResetTime":"1970-01-01 00:00:00.0000000","SourceID":"","SourceType":"1","State":"1","StateMachine":"7","StateText":"R","SuppressionState":"0","SystemSeverity":"0","Tag":"RUNTIME_1::Tag_2","TextColor":"4278190080","UserName":"","Value":"7","ValueLimit":"No limit configured.","ValueQuality":"192", "AlarmGroupID": "1"}]}

OnError

{"Message":"ErrorSubscribeTag", "ErrorCode":<Value>, "ErrorDescription":"<Error text>", "ClientCookie":"<Cookie>"}

For example:

{"Message":"ErrorSubscribeAlarm","ErrorCode":"-2147483621","ErrorDescription":"Alarm Subscription failed because of invalid filter","ClientCookie":"CookieForSubscribeAlarms123"}