Notification Side effect and Silent notification

In my application We want to use notifications not just to alert users, but to trigger some side effects events too. Passing extra data and calling callbacks. But I didn’t find any documentation related to a feature like this. Have you implemented it or can tell me a workaround for it?