Docs
Global functions

Notifications

sendPushNotification, sendPersistentNotification, sendEmail, sendSms

Global functions available to smart-app code. Call them by bare name; there is no object to import.

FunctionSummary
sendPushNotificationSend a push notification to the account's users.
sendPersistentNotificationPost a notification that stays in the app’s notification centre until the user dismisses it.
sendEmailSend an email via the cloud (AWS SES).
sendSmsSend an SMS via the cloud (Twilio).

sendPushNotification

Send a push notification to the account's users.

  • critical: true asks for TIME-SENSITIVE delivery (iOS interruption-level: time-sensitive, Android high priority): the push arrives promptly even under Focus / Doze, but it never bypasses Do Not Disturb — that tier is reserved for real alarms raised by the security system. - userIds (optional) narrows the fan-out to those account users. Omit (or pass empty) to fan out to every user on the account — the legacy behavior. The cloud rejects userIds that don't belong to the hub's account.

Signature

function sendPushNotification(message: string, title?: string, critical?: boolean, userIds?: string[]): void

Parameters

NameTypeRequiredDefaultDescription
messagestringyes—Body text. Empty strings are ignored.
titlestringno'Notification from NOVON Edge Device'Notification title.
criticalbooleannofalsetrue requests time-sensitive delivery (prompt under Focus / Doze). Never bypasses Do Not Disturb; that tier is reserved for alarms.
userIdsstring[]noundefinedRestrict delivery to these account users. Omit or pass [] for everyone on the account. Use an accountUserId input to let the installer pick.

Returns

void

Examples

sendPushNotification(`${evt.entityId} opened while away`, 'Security', true, $g.recipients);

See also

sendPersistentNotification · notifications


sendPersistentNotification

Post a notification that stays in the app’s notification centre until the user dismisses it.

Signature

function sendPersistentNotification(message: string, title?: string): void

Parameters

NameTypeRequiredDefaultDescription
messagestringyes—Body text.
titlestringno'Notification from NOVON Edge Device'Title.

Returns

void

See also

sendPushNotification


sendEmail

Not available to AI-generated user automations.

Send an email via the cloud (AWS SES). Fire-and-forget — smart-app callers don't get delivery confirmation. The hub validates the address before forwarding, and the cloud handler logs failures.

Signature

function sendEmail(to: string, subject: string, body: string): void

Parameters

NameTypeRequiredDefaultDescription
tostringyes—Recipient address; the hub validates it before forwarding.
subjectstringyes—Subject line.
bodystringyes—Plain-text body.

Returns

void

Notes

  • Not available to AI-generated user automations.

See also

sendSms


sendSms

Not available to AI-generated user automations.

Send an SMS via the cloud (Twilio). Fire-and-forget. The cloud handler normalizes the phone number (digits only, drops leading country-code 1) before handing off. US 10-digit numbers only.

Signature

function sendSms(to: string, message: string): void

Parameters

NameTypeRequiredDefaultDescription
tostringyes—US 10-digit number; a leading country code 1 is stripped.
messagestringyes—Message text.

Returns

void

Notes

  • Not available to AI-generated user automations.

See also

sendEmail

Generated from docs-bundle v0.1.0, novon-platform 9ce3486c (2026-10-09).

On this page