Skip to Content
Author's profile photo Aashish Sinha

Enhancing CBMA Alerts and Message Monitoring with UDS Attributes

It is very difficult to understand the SAP PI alert JSON message sent to functional/business users. Business users keep asking about the key attributes for alert is generated. This requirement normally takes some custom development for earlier PI versions but for new CBMA alerts we have UDS attributes, which takes cares of this requirement.

At least, adding these attributes will let business/functional team know that for which key values errors occurred and they can contact technical team or by looking into alert error text, can take further action.

Business requirement

  1. Alert messages are not readable or very technical
  2. Not sure for which key fields error occurred
  3. PI Admin takes time to find messages for particular key
  4. Key/Payload based search of messages
  5. Message Monitoring Enhancement

For example – If we are sending PO information to our partner and mapping error occurred, then alert message should contain PO number as UDS attribute so that business and functional team should be aware of PO in error and take further action.

How UDS attributes will look like in CBMA alert message?

After setting up UDS attributes in NWA, alert messages will contain additional field at end of the message called UDSAtrrs {}.

“UDSAttrs”: {“PO Number”: “12345678”}

How to setup UDS attributes in NWA and enhance message monitoring?

Below are the steps to setup UDS attributes in NWA.

Step 1 – In NWA, goto SOA->Monitoring-> User-Defined Message Search Configuration


Step 2 – Click on new in next page.


Fill all details in next page – Name and description – you can fill anything to identify this UDS attributes.

Click on create to make it editable and then fill with relevant values for Sender party, Component, receiver party and component, with interface and Namespace. Select status as active and save it.


After saving this, we need to define search criteria.

Step 3 – Click on new to create search criteria


In Create search criteria provide Name, Description and XPath. Save it once done.


It will look like below.


You are done here with UDS configuration.

Benefits of UDS configuration –

1. A simplified monitoring in Message Monitoring

Go to Message Monitoring – You will see an additional tab for the interface you configured UDS attributes as below –


When you go to this tab, you will see the values from Payload for which you have defined the search criteria. In above case, the PO number.


2. User Defined search criteria and reduced search time for messages

In message monitoring, now you can use user defined search criteria to find particular PO number from all messages processed for the day or any other time variations.


You can use User-Defined Search Criteria as below – Check User-Defined Search Criteria and click on Add Predefined to select Interface and provide User-Defined Search Criteria for interface and then value and select Ok. It will look like this and then you can click on go, to find message in particular time-frame.





How UDS attributes will look in CBMA alerts?

Below is the screenshot of the UDS attribute in CBMA alerts sent to users/admins mailbox once UDS configuration is done.



Michal’s PI tips: How to trigger an alert for Component Based Message Alerts (CBMA) via “API” ?

Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Michal Krawczyk
      Michal Krawczyk


      Please remember to check out blogs in order to avoid writing them for the topics

      which are already described (USD usage):

      Michal's PI tips: How to trigger an alert for Component Based Message Alerts (CBMA) via "API" ?

      Can you update your blog with the link to this one so users can check other references as well ?

      Thank you,


      Michal Krawczyk

      Author's profile photo Aashish Sinha
      Aashish Sinha
      Blog Post Author


      Added your blog in reference.

      Aashish Sinha

      Author's profile photo Former Member
      Former Member

      Hi Aashish,

      We are using PI 7.4 SP 10 , We have tried to setup the UDS attributes ,

      1. Not able to get extra Tab for User-Defined Attributes in Message Display section.

          Are there any other config to be done for that other than mentioned in the blog above.

      2. Even not able to get the extra details in the alert mail like PO Number in the above case.

           we have defined proper search criteria and xpath of the source message field, and also        selected Payload in alert during Alert Rule config.

         Could you please let me know any further details you have on this , We also want to achieve a custom message in the Alert without any ESR API development .Do let me know if you have come across any other alternatives.


      Anil Tripathy

      Author's profile photo Former Member
      Former Member

      Hi Anil,

      Are you using in your task the classic job AlerConsumerJob ?

      Maybe you can also try the new delivered one from SAP AlertConsumerJobV2 (Please refer to Note 2088606) where you can use the variable $uds_attribute$ in your alerting template.

      Another point, in your UDS, have you defined a namespace prefix before activating the filter? please check also the indexing and start it.



      Author's profile photo Nidhi Srivastava
      Nidhi Srivastava

      Hi Aashish,

      I tried implementing the UDS in the same way but not getting UDS tab in monitoring.


      Also, added the indexing option.


      Please suggest what I am missing?



      Author's profile photo Pooja Tiwari
      Pooja Tiwari

      Hi All,



      Could any one help me with this:

      System- SAP PI 7.4 dual stack SP 12 patch 38.

      I am trying to implement this but UDS value is coming empty in alerts.

      Is there some background setting I need to change in NWA or somewhere else.





      Author's profile photo Satish BabuK
      Satish BabuK

      Hi Michal,

      I'm working on CBMA(Custom email alerts) as you suggested in SAP PO-single stack and not able to get UDS fields in custom email alerts but when I do UDS test alone it's working fine. did I miss anything here while refereeing UDS syntax in emails, I refer UDS data in custom email template as below.

      User Defined data from the PI message : $uds_attributes$


      Can you please help me..