As an alternative to SMPP SMS gateway option, starting from Traccar version 4.2, it's possible to use more common HTTP APIs for SMS notifications. See configuration examples for various services below.
Replace TOKEN with the token from the app. If you want to connect to you phone directly, replace URL with the URL from the app and use API key instead of token.
<entry key='notificator.types'>web,mail,sms</entry> <entry key='notificator.sms.manager.class'>org.traccar.sms.HttpSmsClient</entry> <entry key='sms.http.url'>https://www.traccar.org/sms/</entry> <entry key='sms.http.authorization'>TOKEN</entry> <entry key='sms.http.template'> { "to": "{phone}", "message": "{message}" } </entry>
Replace account SID, token, and source phone number with correct values. Note that phone number has to be URL encoded.
<entry key='notificator.types'>web,mail,sms</entry> <entry key='notificator.sms.manager.class'>org.traccar.sms.HttpSmsClient</entry> <entry key='sms.http.url'>https://api.twilio.com/2010-04-01/Accounts/[YOUR ACCOUNT SID]/Messages.json</entry> <entry key='sms.http.user'>[YOUR ACCOUNT SID]</entry> <entry key='sms.http.password'>[YOUR AUTH TOKEN]</entry> <entry key='sms.http.template'> From=[YOUR PHONE NUMBER]&To={phone}&Body={message} </entry>
Replace token id and token secret with appropriate values for your account.
<entry key='notificator.types'>web,mail,sms</entry> <entry key='notificator.sms.manager.class'>org.traccar.sms.HttpSmsClient</entry> <entry key='sms.http.url'>https://api.bulksms.com/v1/messages</entry> <entry key='sms.http.user'>[YOUR TOKEN ID]</entry> <entry key='sms.http.password'>[YOUR TOKEN SECRET]</entry> <entry key='sms.http.template'> { "to": "{phone}", "body": "{message}" } </entry>