Viewing event payloads

You can view the payloads of incoming events in IBM Cloud Event Notifications to validate payload formats, set up filters, and troubleshoot issues without routing them to external webhooks.

The ability to view event payloads allows you to inspect the format and content of events sent to your Event Notifications instance. By examining the payload data, you can identify available fields, understand data formats, and verify that payloads contain the expected information. This capability is particularly valuable when setting up topic filters to route events based on specific field values, and when troubleshooting notification delivery issues to diagnose why these notifications may not be reaching their intended destinations.

Enabling storage of event payloads

By default, Event Notifications does not store incoming event payloads. You must explicitly enable Capture events for a source for Event Notifications to begin storing event payloads from that source. Only event payloads that arrive after you enable this option are stored.

Capture events is not supported for periodic timer sources.

To enable this storage:

  1. Click Sources in your Event Notifications instance.
  2. Locate the source for which you want to store event payloads and enable Capture events for that source.

After you enable Capture events, Event Notifications begins storing all incoming event payloads for that source. Event payloads are retained for 7 days and are automatically purged after this period. Event Notifications stores a maximum of 100 event payloads per instance. When this limit is reached, older event payloads are automatically deleted to make room for new ones.

Viewing stored event payloads

After you enable Capture events, you can view stored event payloads for the source. Only events received after you enable this option are available for viewing.

To view event payloads:

  1. Select View events from the Options menu for the source for which you enabled storage of event payloads.

  2. The Source Events dialog contains the following sections:

    Source details
    The top section displays Source name, Source ID and Source type of the selected source.
Search
A search field allows you to filter event payloads by entering search criteria. The search filters event payloads based on notification ID, timestamp, summary (ibmendefaultshort parameter from the payload).

List of events payloads displays Notification ID, Summary and Timestamp of each event payload.

Viewing event payload details

To view the complete event payload:

  1. In the list of event payloads on the Source Events dialog, locate the event payload you want to inspect.
  2. Click the expand icon on the event payload row to view the payload.

You can copy the JSON payload by clicking the copy icon in the upper right corner of the payload display.

Disabling storage of event payloads

When you no longer need to view event payloads, you can disable Capture events to stop storing event payloads.

When you disable Capture events, Event Notifications stops storing new event payloads for that source. Existing stored event payloads are retained for 7 days or until the total count reaches 100, at which point older event payloads are automatically deleted.