Hopp til innhold

Alerts

Alerts can be used to notify a user or a machine, or to trigger a process on another machine, etc. We have alerts for both electricity prices and HAN-port energy consumption.

Schemas for alerts are found in the GraphQL Playground.

note

If you have questions, ask us on Slack, chat or send us a mail on support@harktech.no

Some alerts can be configured with webhooks, read more here.

Setting up alerts​

Configure alerts with our API, check out our GraphQL Playground.

Getting alert settings with User Access Token​

Alert settings configured on a user can be found on me on alertSettings.

query me {
me {
alertSettings {
... on HourlyConsumptionLimitEstimationWarningAlertSetting {
deviceId
limitInWatts
alertType
notificationChannels {
... on IntermediaryWebhookNotificationChannel {
metadata
}
}
}
... on EstimatedHourlyActiveEnergyLimitWarningAlertSetting {
deviceId
limitInWattHours
alertType
notificationChannels {
... on IntermediaryWebhookNotificationChannel {
metadata
}
}
}
... on PriceWarningAlertSetting {
id
energyBiddingZone
createdBy {
... on EndUserAlertSettingCreator {
userId
type
}
... on IntermediaryAlertSettingCreator {
intermediaryId
type
}
}
notificationChannels {
... on IntermediaryWebhookNotificationChannel {
metadata
callbackUrl
}
}
}
}
}
}

Getting alerts with API Key​

All alert settings configured with an API Key, can be found on currentIntermediary on alertSettings.

query currentIntermediary {
currentIntermediary {
alertSettings {
... on HourlyConsumptionLimitEstimationWarningAlertSetting {
deviceId
limitInWatts
alertType
notificationChannels {
... on IntermediaryWebhookNotificationChannel {
metadata
}
}
}
... on EstimatedHourlyActiveEnergyLimitWarningAlertSetting {
deviceId
limitInWattHours
alertType
notificationChannels {
... on IntermediaryWebhookNotificationChannel {
metadata
}
}
}
}
}
}