Skip to main content
Version: 8.3

Configuration

Alarm Notification Profile

After installing the module, create an Alarm Notification Profile of type Teltonika Notification.

Profile Settings

Gateway

ParameterTypeRequiredDescription
HostTextYesIP address (or hostname) and port of the Teltonika router. Used as http://<host>/..., so include a non-default port here (e.g. 192.168.1.1:80).

Credentials

ParameterTypeRequiredDescription
UsernameTextYesRouter authentication username.
PasswordSecretYesRouter authentication password. Resolved at startup; the profile errors if retrieval fails.

Two-Way Messaging

ParameterTypeRequiredDescription
Two-Way MessagingCheckboxNoEnables SMS-reply acknowledgement.
Callback TokenSecretConditionalShared secret required by the /system/teltonika servlet as a token query parameter. A mismatch returns 403. Blank = the endpoint accepts unauthenticated callbacks (a warning is logged). Sent in cleartext over HTTP.
Auto-configure Forwarding Base URLTextNoBase gateway URL the router can reach (e.g. http://gateway-host:8088). When set in REST mode, the module PUTs the router's to_http SMS-forwarding rule on startup. Blank = configure forwarding manually. /system/teltonika is appended automatically if missing.
Auto-configure Forwarding Verify CertificateCheckboxNoSets the router rule's verify_cert to verify/ignore. Leave off for plain HTTP or self-signed certificates.

Advanced

ParameterTypeRequiredDefaultDescription
ModemTextNo(blank)Name of the modem, e.g. 1-1. Leave blank to auto-detect the router's primary modem. Unused in Legacy mode.
LegacyCheckboxNofalseUse the legacy URL-authenticated API instead of the REST API.
Modem Is Optional

Unlike earlier documentation, the Modem field is not required. In REST mode, leaving it blank makes the module auto-discover the router's primary modem (falling back to the first modem) via GET /api/modems/status.

Auditing

ParameterTypeRequiredDescription
Audit ProfileReference (ignition/audit-profile)NoOptional audit profile for logging SMS activity. Delete-protected and rename-tracked.

API Modes

The Legacy checkbox selects the communication mode. It is not auto-detected from firmware.

REST API Mode (Default, Legacy = off)

Modern RUTOS firmware uses a token-based REST API.

Flow:

  1. POST http://<host>/api/login with body {username, password} → returns data.token (cached ~299 s).
  2. POST http://<host>/api/messages/actions/send with Authorization: Bearer <token> and body {"data":{number, message, modem}}. Success = success: true.
  3. The modem is the configured Modem if set, otherwise auto-discovered from GET /api/modems/status (primary, else first).

REST mode also enables SMS-channel health monitoring and optional forwarding auto-configuration.

Legacy API Mode (Legacy = on)

Older firmware uses URL-based authentication.

Flow:

  • GET http://<host>/cgi-bin/sms_send?username=&password=&number=&text=

Legacy mode does not use tokens, modem selection, health monitoring, or forwarding auto-configuration.

Legacy Credentials Are Sent in the URL

In Legacy mode the username and password are passed as URL query parameters over plain HTTP. Prefer REST mode where possible.


SMS-Channel Health Monitoring

In REST mode only, the module monitors the SMS channel: starting 15 s after startup, then every 60 s, it probes /api/login and /api/modems/status. Two consecutive DOWN probes are required before the channel is marked errored.

StatusMeaning
OKChannel healthy.
WEAK SIGNALRSSI ≤ -105 dBm or SINR < 0 dB.
SIM NOT READYSIM not in a ready state.
NO NETWORKModem not registered on a network.
GATEWAY UNREACHABLERouter could not be reached.
LOGIN FAILEDAuthentication failed.
UNAUTHORIZEDCredentials/permissions rejected.
MODEM QUERY FAILEDModem status query failed.

Two-Way Messaging

When enabled, each SMS gets a reply code appended ( Send <code> to acknowledge). The recipient replies with the code; the router forwards the inbound SMS to the gateway servlet /system/teltonika, which acknowledges the alarm attributed to the notified user.

  • Authentication: the servlet requires the Callback Token as a token query parameter (constant-time comparison; 403 on mismatch). A blank token means unauthenticated callbacks plus a warning.
  • Auto-configuration (REST only): setting Auto-configure Forwarding Base URL makes the module PUT the router's to_http forwarding rule on startup (PUT /api/sms_gateway/sms_forwarding/to_http/config/to_http), appending /system/teltonika to the URL if missing, and setting verify_cert from the Verify Certificate checkbox.
One Two-Way Profile per Gateway

The callback token and pending reply codes are gateway-wide state shared by a single /system/teltonika servlet. Only one two-way-messaging profile is supported per gateway — with more than one, the last profile to start or save wins and clobbers the others' token and pending codes.


User Contact Configuration

Users receive Teltonika SMS via their SMS contact info. The first SMS contact on the user is used.

  1. Navigate to Platform > Security > User Sources.
  2. Open the user source's menu, choose Manage Users, and edit the user.
  3. In Contact Info, add a contact of type SMS.
  4. Enter the phone number in international format (e.g. +33612345678).
Phone Number Normalization

Numbers are normalized before sending: +CC… becomes 00CC…; numbers already starting with 00 are kept; anything else is passed through with a warning.


Message Templates

The profile provides two expression templates:

PropertyDefault
MessageAt {eventTime|hh:mm:ss}, alarm "{name}" at "{displayPath}" transitioned to {eventState}.
Throttled Message{alarmEvents.Count} alarm events have occurred.

The Throttled Message is used when multiple alarm events are delivered together.

Per-Alarm Custom Message

You can override the message for a specific alarm via its extended configuration property CustomTeltonikaMessage:

  1. Open the alarm configuration in the Designer.
  2. Expand the Extended Config section.
  3. Set the Custom Message (CustomTeltonikaMessage) property.

When set, it overrides the Message template for that alarm (the Throttled Message still applies to batched events).


Auditing

When an audit profile is configured, the module logs:

FieldDescription
ActionSMS Request (outbound sends) or SMS Acknowledgement (reply acks)
ActorUsername of the notification recipient
TargetAlarm path with event ID
TimestampTime of the event