Omnichannel alerts resource
Generated reference for ovok_sdk: omnichannel alerts resource.
- Stable unknown
- Release candidate not available
- Development since 0.2.0-dev.51+80996d9
NotificationsRulesResource
class NotificationsRulesResourceThe project's alert notifications rule, JSON Logic passed through as it is.
Reached through ovok.omnichannelAlerts.rules.
Constructors
NotificationsRulesResource.new
NotificationsRulesResource(HttpClient _alerts)Built by Ovok; use ovok.omnichannelAlerts.rules instead.
| Parameter | Type | Kind | Default |
|---|---|---|---|
_alerts | HttpClient | positional |
Methods
NotificationsRulesResource.retrieve
Future<JsonMap> retrieve()Reads the rule under notifications, null when the project has none. Calls GET v1/omnichannel-alerts/rules.
Returns Future<Map<String, dynamic>>.
NotificationsRulesResource.update
Future<JsonMap> update(JsonMap rule)Sets rule, with its JSON Logic under logic.
Calls PUT v1/omnichannel-alerts/rules. Ovok checks the channels and recipients it names.
| Parameter | Type | Kind | Default |
|---|---|---|---|
rule | JsonMap | positional |
Returns Future<Map<String, dynamic>>.
NotificationsRulesResource.remove
Future<void> remove()Removes the rule, so nobody is told of a new alert. Calls DELETE v1/omnichannel-alerts/rules.
Returns Future<void>.
OmnichannelAlertsResource
class OmnichannelAlertsResourceOmni-channel alerts: Ovok runs the project's rule on each Signals alert event, and tells the people it names by push and email.
Reached through ovok.omnichannelAlerts. Every route is under v1/omnichannel-alerts. For project admins.
Every request throws an OvokException subclass when it fails.
Constructors
OmnichannelAlertsResource.new
OmnichannelAlertsResource(HttpClient http)Built by Ovok; use ovok.omnichannelAlerts instead.
| Parameter | Type | Kind | Default |
|---|---|---|---|
http | HttpClient | positional |
Properties
OmnichannelAlertsResource.rules
final NotificationsRulesResource rulesThe project's alert notifications rule.
Methods
OmnichannelAlertsResource.preview
Future<JsonMap> preview(JsonMap preview)Previews who the rule tells of a sample alert event; nothing is sent.
preview holds the patientId, an optional event (alert.triggered when omitted), an optional sample
alert and an optional notifications rule to try. Calls POST v1/omnichannel-alerts/preview and answers
the notify entries the rule gives, each with the people it reaches.
| Parameter | Type | Kind | Default |
|---|---|---|---|
preview | JsonMap | positional |
Returns Future<Map<String, dynamic>>.
Last updated on