ravenx v2.0.0 Ravenx.Notification View Source
Base module for notifications implemented using Ravenx strategies.
Link to this section Summary
Functions
Macro to inject notification features in application’s modules
Function used to send a using a configuration tuple like the ones that get_notifications_config
should return
Link to this section Functions
Macro to inject notification features in application’s modules.
Link to this function
dispatch_notification(notification, dispatch_type)
View Source
dispatch_notification(Ravenx.notif_config, Ravenx.dispatch_type) :: Ravenx.notif_result
Function used to send a using a configuration tuple like the ones that get_notifications_config
should return.
The tuple should have this objects:
- Strategy atom: defining which strategy to use
- Payload map: including the payload data of the notification.
- Options map (optional): the special configuration of the notification
It will respond with a tuple, with an atom that could be :ok
or :error
and
the result of the operation, as an standard notification dispatch returns.