Notifications

Notifications is the way to notify users about events.

Notification is standard traccar object that can be created by user and linked to other objects (devices and groups).

Type field corresponds to Event type.

All Devices means that notification will be sent from all user devices, if it is not set the Notification will be sent from only device/group it is linked to.

Any available channels (notificators) can be selected.

Also can be selected Calendar to limit notification working hours.

Push Notifications

Push notifications are available since Traccar version 4.1. Notifications are sent through Firebase platform.

There are two options for push notifications in Traccar:

To receive notifications to the official Traccar Manager app from Google Play all you need to do is configure Traccar with the following parameters:

<entry key='notificator.types'>web,mail,traccar</entry>
<entry key='notificator.traccar.key'>TRACCAR_KEY</entry>

You can find your personal API key on the Account page. You need to be registered on the website.

To receive Firebase push notifications directly you need a custom mobile app that is built with your Firebase keys. Server configuration for direct Firebase notifications should look like this:

<entry key='notificator.types'>web,mail,firebase</entry>
<entry key='notificator.firebase.key'>FIREBASE_KEY</entry>

Web Notifications

Web notification is a simple pop-up window in the web interface or mobile app.

Web notifications are delivered instantly without any delays. It is possible enable sound for the notifications to attract attention of the user.

Email Notifications

There are two ways to configure email notifications:

All possible parameters are listed in the configuration file documentation (see mail.smtp.* parameters).

Tips:

Examples:

Use SSL server-wide:

<entry key='mail.smtp.host'>smtp.gmail.com</entry>
<entry key='mail.smtp.port'>465</entry>
<entry key='mail.smtp.ssl.enable'>true</entry>
<entry key='mail.smtp.from'>traccar@gmail.com</entry>
<entry key='mail.smtp.auth'>true</entry>
<entry key='mail.smtp.username'>traccar@gmail.com</entry>
<entry key='mail.smtp.password'>password</entry>

Use STARTTLS server-wide:

<entry key='mail.smtp.host'>smtp.gmail.com</entry>
<entry key='mail.smtp.port'>587</entry>
<entry key='mail.smtp.starttls.enable'>true</entry>
<entry key='mail.smtp.from'>traccar@gmail.com</entry>
<entry key='mail.smtp.auth'>true</entry>
<entry key='mail.smtp.username'>traccar@gmail.com</entry>
<entry key='mail.smtp.password'>password</entry>

Use SSL per-user:

SMS Notifications

SMS notifications are available since Traccar version 3.11. You need an SMPP service to enable SMS notifications in Traccar.

Some additional information about using SMS as notification can be found in Notificators documentation.

You need access to an SMPP server. Most of the major mobile service providers have SMPP servers. Alternatively you can install own proprietary or open source sever to send SMS via modem or mobile phone.

There are quite a few configuration paremeters required for SMS notifications. All possible parameters are listed in the configuration file documentation (see sms.smpp.* parameters).

Tips:

Examples:

<entry key='sms.enable'>true</entry>
<entry key='sms.smpp.host'>smpp.example.com</entry>
<entry key='sms.smpp.port'>2345</entry>
<entry key='sms.smpp.username'>systemId</entry>
<entry key='sms.smpp.password'>password</entry>
<entry key='sms.smpp.notificationsCharset'>GSM</entry>
<entry key='sms.smpp.notificationsDataCoding'>0</entry>
<entry key='sms.smpp.sourceAddress'>+79000000000</entry>

Templates

Traccar uses Velocity Engine for email and SMS notification templates (Velocity User Guide).

Templates can be easily adjusted to your needs or translated.

You do not need configure anything by default, but if you want you can change templates root folder.

Templates (*.vm) files must be in UTF-8 encoding.

Testing

You can send test message via all currently available notificators in your account dialog: