SMSEagle NXS-9750-4G, NXS-9750-3G, NXS-9700-4G, NXS-9700-3G User Manual

SMSEAGLE
NXS-9750-3G
NXS-9750-4G
Congratulations
on purchasing
SMSEAGLE
The materials used in this publication are copyright and are
not to be duplicated, copied, or used without the prior consent
of the copyright holder. Technical specifications are subject
Document version: 3.32
to change without prior notice being given.
CONTENTS
What’s In The Box ...................................................................................................................................................... 8
Prepare for First Start ............................................................................................................................................... 9
Get to know with Connectors, Ports and LEDs ................................................................................................ 14
Basic Operations ...................................................................................................................................................... 15
SMSEagle basic features ........................................................................................................................................ 16
Compose SMS ....................................................................................................................................................... 16
Phonebook ............................................................................................................................................................. 17
Phonebook Contacts ...................................................................................................................................... 17
Phonebook Groups ......................................................................................................................................... 18
Phonebook Working Shifts ........................................................................................................................... 18
Reporting module ................................................................................................................................................ 19
Statistics view .................................................................................................................................................. 19
SMSEagle plugins ..................................................................................................................................................... 20
Autoreply plugin ................................................................................................................................................... 20
Network Monitoring plugin ............................................................................................................................... 21
Email to SMS plugin ........................................................................................................................................... 24
Email to SMS Poller ............................................................................................................................................. 27
SMS to Email plugin ........................................................................................................................................... 29
Callback URL plugin ............................................................................................................................................ 30
SMS Forward ........................................................................................................................................................ 32
Periodic SMS ......................................................................................................................................................... 33
Digital input/output ........................................................................................................................................... 34
Temperature & humidity sensor .................................................................................................................... 37
LDAP plugin .......................................................................................................................................................... 40
Multimodem features ............................................................................................................................................. 42
SMSEagle API ............................................................................................................................................................ 43
1. Send SMS: HTTP GET method ..................................................................................................................... 43
2. Send SMS: JSONRPC method ...................................................................................................................... 45
3. Send SMS to a group: HTTP GET method ................................................................................................ 46
4. Send SMS to a group: JSONRPC method .................................................................................................. 48
5. Send SMS to contact: HTTP GET method ................................................................................................ 49
6. Send SMS to contact: JSONRPC method .................................................................................................. 51
7. Send USSD code: HTTP GET method ......................................................................................................... 52
8. Send USSD code: JSONRPC method .......................................................................................................... 53
9. Send binary SMS: HTTP GET method ........................................................................................................ 54
10. Send binary SMS: JSONRPC method ....................................................................................................... 56
11. Read SMS: HTTP GET method .................................................................................................................. 57
12. Read SMS: JSONRPC method .................................................................................................................... 65
13. Delete SMS: HTTP GET method ............................................................................................................... 77
14. Delete SMS: JSONRPC method ................................................................................................................. 78
15. Get outgoing queue length: HTTP GET method ................................................................................... 79
16. Get outgoing queue length: JSONRPC method .................................................................................... 80
17. Get inbox length: HTTP GET method ...................................................................................................... 81
18. Get inbox length: JSONRPC method ........................................................................................................ 82
19. Get sentitems length: HTTP GET method ............................................................................................. 83
20. Get sentitems length: JSONRPC method ............................................................................................... 84
21. Get GSM/3G signal strength: HTTP GET method ................................................................................ 84
22. Get GSM/3G signal strength: JSONRPC method ................................................................................. 86
23. Phonebook group create: HTTP GET method ....................................................................................... 86
24. Phonebook group create: JSONRPC method ........................................................................................ 87
25. Phonebook group read: HTTP GET method .......................................................................................... 88
26. Phonebook group read: JSONRPC method ............................................................................................ 90
27. Phonebook group update: HTTP GET method ..................................................................................... 91
28. Phonebook group update: JSONRPC method ....................................................................................... 92
29. Phonebook group delete: HTTP GET method ....................................................................................... 93
30. Phonebook group delete: JSONRPC method ........................................................................................ 95
31. Phonebook group add contact: HTTP GET method ............................................................................. 96
32. Phonebook group add contact: JSONRPC method .............................................................................. 97
33. Phonebook group remove contact: HTTP GET method ..................................................................... 98
34. Phonebook group remove contact: JSONRPC method ................................................................... 100
35. Phonebook contact create: HTTP GET method ................................................................................. 101
36. Phonebook contact create: JSONRPC method .................................................................................. 102
37. Phonebook contact read: HTTP GET method .................................................................................... 103
38. Phonebook contact read: JSONRPC method ...................................................................................... 105
39. Phonebook contact update: HTTP GET method ............................................................................... 106
40. Phonebook contact update: JSONRPC method ................................................................................. 108
41. Phonebook contact delete: HTTP GET method ................................................................................. 109
42. Phonebook contact delete: JSONRPC method .................................................................................. 110
43. Call with termination: HTTP GET method ........................................................................................... 111
44. Call with termination: JSONRPC method ............................................................................................ 112
45. Phonebook shift create: HTTP GET method ...................................................................................... 114
46. Phonebook shift create: JSONRPC method ........................................................................................ 115
47. Phonebook shift read: HTTP GET method .......................................................................................... 116
48. Phonebook shift read: JSONRPC method ........................................................................................... 117
49. Phonebook shift update: HTTP GET method ..................................................................................... 119
50. Phonebook shift update: JSONRPC method ...................................................................................... 121
51. Phonebook shift delete: HTTP GET method ...................................................................................... 122
52. Phonebook shift delete: JSONRPC method ........................................................................................ 123
53. Phonebook shift add contact: HTTP GET method ............................................................................ 124
54. Phonebook shift add contact: JSONRPC method ............................................................................. 125
55. Phonebook shift remove contact: HTTP GET method .................................................................... 126
56. Phonebook shift remove contact: JSONRPC method ...................................................................... 127
57. Get modem state: HTTP GET method .................................................................................................. 128
58. Get modem state: JSONRPC method ................................................................................................... 130
59. Set modem state: HTTP GET method .................................................................................................. 131
60. Set modem state: JSONRPC method ................................................................................................... 132
61. User ID read: HTTP GET method ........................................................................................................... 133
62. User ID read: JSONRPC method ............................................................................................................. 134
63. Group members read: HTTP GET method .......................................................................................... 135
64. Group members read: JSONRPC method............................................................................................ 136
Plugins and integration manuals for NMS & Auth systems ..................................................................... 138
Extras ........................................................................................................................................................................ 139
Connecting directly to SMSEagle database ............................................................................................ 139
Injecting short SMS using SQL .................................................................................................................... 139
Injecting long SMS using SQL ...................................................................................................................... 140
Database cleaning scripts .............................................................................................................................. 142
SNMP agent ....................................................................................................................................................... 143
Setting up SNMP v3 access control ........................................................................................................ 146
Failover (HA-cluster) feature ........................................................................................................................ 148
Forwarding logs to external server.............................................................................................................. 151
Automatic software updates checks .......................................................................................................... 152
Troubleshooting..................................................................................................................................................... 154
Verification of LEDs .......................................................................................................................................... 154
Checking the device logs................................................................................................................................. 154
When the device is not reachable ................................................................................................................ 154
Restoring factory defaults ............................................................................................................................. 155
Service & Repair..................................................................................................................................................... 158
Warranty ............................................................................................................................................................ 158
Service ................................................................................................................................................................. 158
Tech Specs & Safety Information ..................................................................................................................... 160
Technical Specification .................................................................................................................................... 160
Important Safety Information ...................................................................................................................... 163
Regulatory Statements ....................................................................................................................................... 164
EU declaration of conformity ........................................................................................................................ 164
FCC compliance statement ............................................................................................................................ 164
Canadian regulatory statement ................................................................................................................... 165
Disposal and recycling information ............................................................................................................. 165
Restriction of Hazardous Substances Directive (RoHS) ........................................................................ 165
7 | SMSEagle NXS-9700-3G | Users Manual
GET READY
TO START
I
8 | SMSEagle NXS-9700-3G | User’s Manual
WHAT’S IN THE BOX
Your SMSEagle box contains:
SMSEagle hardware SMS gateway
2x External omnidirectional antenna (with magnetic foot)
AC/DC power supply (input voltage: 100-240V)
Warranty card
9 | SMSEagle NXS-9700-3G | User’s Manual
Your SMSEagle is designed so that you can set it up quickly and start using it right away. Follow the steps
below to get started.
STEP 1: Install 3G/4G antennas
ANTENNA INSTALLATION GUIDELINES
Install antennas in a location with access to a cellular network radio signal.
Antennas must be installed such that it provides a separation distance of at least 20 cm from all
persons and must not be co-located or operating in conjunction with antenna from any other
transmitter.
Antennas must not be installed inside metal cases.
Make sure the SMSEagle antennas remain with 20cm spacing from each other.
Plug in both antenna connectors to the SMSEagle device.
STEP 2: Insert SIM Card
Please install SIM Card when the device is SWITCHED OFF. SIM Card slots is located at the bottom of the
device. Use a ball-pen or small screwdriver to eject SIM Card tray. Insert card into tray and push it gently into
slot.
STEP 3: Power the device
The device is powered with AC/DC power supply adaptor delivered in the box. The device needs a power
source of 12V DC / 1A. In order to power the device simply plug in a connector from AC/DC adaptor into the
device.
PREPARE FOR FIRST START
10 | SMSEagle NXS-9700-3G | User’s Manual
STEP 4: Configure IP settings
A) CONNECT SMSEAGLE TO YOUR LAN AND OBTAIN IP ADDRESS AUTOMATICALLY
connect the device to your LAN using Ethernet cable
SMSEagle will obtain IP address automatically from your DHCP
read assigned IP address on your DHCP server
B) OR SET IP ADDRESS FOR SMSEAGLE MANUALLY
connect a display using HDMI connector, connect a keyboard to USB port (note: cables are not
provided)
login to the SSH console using root credentials (these were provided with your device)
edit configuration file with command:
mcedit /mnt/nand-user/smseagle/syscfg
change the following lines:
HOST_IP= (set IP address for your device) GW_IP= (default gateway IP address) NET_MASK= (set subnet mask) START_DHCP=Y (set to START_DHCP=N to disable DHCP client)
save and exit the file
shutdown the device
now connect SMSEagle to your LAN using Ethernet cable
SMSEAGLE DEFAULT NETWORK CONFIGURATION:
DHCP CLIENT IS ON
(IP ADDRESS WILL BE OBTAINED AUTOMATICALLY FROM YOUR DHCP SERVER)
PREPARE FOR FIRST START
11 | SMSEagle NXS-9700-3G | User’s Manual
C) LOG IN TO SMSEAGLE
Open an internet browser on your PC and go to the IP address assigned to your gateway
SMSEAGLE DEFAULT USER:
Login to application with above username and password.
PREPARE FOR FIRST START
D) CONFIGURE STATIC IP SETTINGS IN WEB-GUI (OPTIONAL)
Click on menu position “Settings” and navigate to tab “IP Settings”.
Disable DHCP server. Enter your IP settings. > Press “Save” button.
Username: admin
Password: password
12 | SMSEagle NXS-9700-3G | User’s Manual
STEP 5: Setting SIM Card PIN
This step should ONLY be done if your SIM-card requires PIN.
If your SIM-card requires PIN number at startup, go to Settings > Maintenance Tab.
Enter your PIN number in the field “SIM Card PIN”
STEP 6: Reboot the device
Go to Settings > Maintenance Tab. Press Reboot button.
PREPARE FOR FIRST START
> Press “Save” button.
13 | SMSEagle NXS-9700-3G | Users Manual
USING OF
SMSEAGLE
II
14 | SMSEagle NXS-9700-3G | User’s Manual
GET TO KNOW WITH CONNECTORS, PORTS AND LEDS
Element
Label
Description
VCC (Rev.3 only)
VCC
Power connector
12-pole connector
Hardware Rev.3: 4x digital Input, 4x digital output, 1x 1Wire, 1x 5V, 2x GND Hardware Rev. 2, Rev.1: Power connector, 2x digital input, 2x digital output, 2x serial port, 2x GND
SIM Card Slot
SIM1, SIM2
SIM card slots
HDMI port
HDMI
HDMI port (for debugging purposes only)
USB port
USB
USB port
Ethernet Port
ETH
Ethernet RJ45 socket
Antenna
ANT
Antenna socket
Power LED
PWR
LED indicating power-on
User LED
USER
LED for user application purpose (not used)
SIM1,2 LEDs
Modem 1,2 (optional)
LED indicator for modem status (only in 3G devices)
Ready LED
RDY
LED indication device status
Reset
RST
Switch for rebooting the device
User Switch
SW
Switch for restoring to factory settings
15 | SMSEagle NXS-9700-3G | User’s Manual
BASIC OPERATIONS
SMSEagle is capable to work in various screen resolutions, making it accessible for wide range of devices:
computers, laptops, tablets, smartphones, etc.
Open a web browser on your device, type in SMSEagle’s IP address (as set in previous chapter). At login
screen type in your username/password. Default username and password is given in chapter Prepare for
First Start.
16 | SMSEagle NXS-9700-3G | User’s Manual
SMSEAGLE BASIC FEATURES
Sending & Receiving SMS (managing messages with Inbox, Outbox, Sent Items)
Smartphone-like conversation mode (messages are nicely grouped by phone number). You can
easily track history of what you send and receive
Sending to single numbers, contacts or groups from phonebook
Import messages for sending from CSV file
SMS Scheduling by specified date and time or delay
Message templates (save & edit your own templates)
Different message types (normal SMS, flash, WAP push, USSD codes)
Unicode support (support of national characters)
Multiuser support (each user has access to a private Inbox, Outbox, Sent Items)
Compose SMS
Here we show the various ways of sending an SMS form your device.
Screenshot of default Compose SMS view
17 | SMSEagle NXS-9700-3G | User’s Manual
In Compose SMS users can:
Send SMS to contact from phonebook, input manually or import from file
Set send date to now, at a date and time or after a delay
Set duration validity of SMS
Type of SMS, normal, flash, WAP Push Link or USSD Code
Set a message template to be saved and used at another time
Send as Unicode (for special character use)
Send message or Send and Repeat
Phonebook
Web-GUI of SMSEagle device is equipped with Phonebook for managing contacts, groups and shifts. Each
user can create private and public contacts, gather contacts in private and public groups. Contacts can also
be optionally assigned to working shifts. Contacts and groups from Phonebook allows users efficient
sending of messages.
Phonebook Contacts
Below we present a main Phonebook view, where user manages his Contacts.
Screenshot of default phonebook view
In Phonebook Contact Management users can:
Add/edit/delete contacts via web-gui
Import contacts from CSV file
Set contact to public or private visibility
Add contacts to groups
Add contacts to working shifts
Send message to a contact
View message conversation of a contact
Public contacts are visible to all users on the device while private contacts are visible to single user.
18 | SMSEagle NXS-9700-3G | User’s Manual
Phonebook Groups
Screenshot taken from phonebook groups
In Phonebook Group Management view users can:
Add/edit/delete groups
Set groups to public or private visbility
View group content (contacts beloning to the group)
Send message to a group
Phonebook Working Shifts
The Shift management feature allows to assign Phonebook contacts to working shifts. If a contact is
assigned to any working shift, before sending a message the device will check if the contact is on a working
shift. If the contact is not on shift the message will be skipped or moved to beginning of a next shift. To start
using working shifts define shifts here and add contact to a shift in contact details.
Screenshot of shift management in phonebook
19 | SMSEagle NXS-9700-3G | User’s Manual
Reporting module
Reporting module is an extension of basic search feature. The module allows users to filter messages from
Inbox/Sent items folders based on custom criteria and display filtered messages. Filtered list of messages
can be exported to PDF or CSV file.
Screenshot of Reporting module
Statistics view
The reporting module allows also to view daily statistics of sent/received messages. The statistics view
displays number of messages per day and sender/receiver number.
Screenshot of Statistics view in Reporting module
20 | SMSEagle NXS-9700-3G | User’s Manual
SMSEAGLE PLUGINS
Basic features of SMSEagle software are extended by plugins that provide extra features to the software.
Below you will find a description of plugins available in each SMSEagle device. All plugins are an integral part
of SMSEagle software. That means that all described plugins are installed in a standard software of SMSEagle
device and are available for free.
Autoreply plugin
Plugin allows to automatically respond to each received message with defined text response.
PLUGIN CONFIGURATION
Plugin “Autoreply” allows to add many autoreply rules. Each rule can be enabled or disabled by user.
Screenshot from plugin main window
For each rule user can define:
When autoreply message should be sent:
o always, o when incoming message contains defined text, o and/or when message sender belongs to Phonebook contact/group
If autoreply message text should be sent as Unicode characters
Plugin also allows to define sending limit for autoreply messages. It is possible to set limitation of max 5 messages / 10 minutes / phone number.
21 | SMSEagle NXS-9700-3G | User’s Manual
Screenshot form “Add/edit autoreply rule”
Network Monitoring plugin
SMSEagle is equipped with network monitoring features. With that features you can monitor any device or
service that has listening port open. SMSEagle Network Monitoring plugin sequentially controls availability
of defined hosts/ports in Network Monitoring feature and sends defined SMS alert when port is
unavailable/goes back to life. Below you will find a brief overview of plugin capabilities.
22 | SMSEagle NXS-9700-3G | User’s Manual
Control status of all your defined tasks
see a settings’ overview for all of your tasks
check which server/service is currently unavailable
see when a specific server/service was last down (last downtime)
check what happened at last downtime (see server/service response)
edit/delete your tasks
disable tasks when needed (e.g. when doing a machine upgrades)
Define what you want to monitor in each task
choose a name for the task
enter a host (IP address or Hostname)
23 | SMSEagle NXS-9700-3G | User’s Manual
choose ICMP (ping) to monitor a server with ICMP protocol
or PORT (TCP/UDP) to monitor your service on a selected port (SMSEagle will check if port is open)
or SNMP to monitor objects via SNMP protocol (supported return types: numeric, string)
increase a default timeout value for busy servers (by default we set it to 30 seconds)
Define a schedule
choose if task should be always enabled…
…or disable it in chosen times
(during a night, when a machine goes through planned restarts, during resource intensive backups, etc.)
enter a phone number or choose a group of users to send your SMS alert to
select when to send SMS alert (when host/service goes down, when host/service goes up after
failure)
Define a SMS alert message
24 | SMSEagle NXS-9700-3G | User’s Manual
Define your SMS messages when host or service becomes unavailable/comes back to life. Choose field placeholders for your SMS text:
{TASKNAME} – puts a taskname inside SMS text
{HOST} – hostname or IP address
{RESPONSE} – message received (in case of no response from server/service)
{TIMESTAMP} – timestamp of an error
Receive SMS alerts
be immediately alerted when your services/servers go down (or go up after failure)
give yourself a chance to react quickly
Go to our website www.smseagle.eu for more details of this plugin.
Email to SMS plugin
Email To SMS plugin allows you to convert an email to SMS message.
BASIC USAGE
If the plugin is enabled, email sent to the email address:
PHONE_NUMBER@IP_ADDRESS_OF_SMSEAGLE will be converted to SMS message.
PHONE_NUMBER is a destination phone number
IP_ADDRESS_OF_SMSEAGLE is the IP address of your device.
The text of the email is the text of the SMS message (optionally you can append email subject at
the beginning of SMS message).
Example: email message sent to the address: 123456789@192.168.0.101 will be converted to SMS
message and delivered to phone number 123456789.
25 | SMSEagle NXS-9700-3G | User’s Manual
SEND TO USERNAME/GROUP
Email sent to the email address:
NAME_IN_PHONEBOOK@IP_ADDRESS_OF_SMSEAGLE will be converted to SMS message and
will be sent to a user or users group from SMSEagle’s phonebook.
NAME_IN_PHONEBOOK is a username or group name (must be a public group) from SMSEagle’s
phonebook
IP_ADDRESS_OF_SMSEAGLE is the IP address of your device.
The text of the email is the text of the SMS message (optionally you can append email subject at
the beginning of SMS message).
Example: email message sent to the address: db-admins@192.168.0.101 will be converted to SMS
message and delivered to all members of db-admin group. The db-admin group must be defined in your
SMSEagle phonebook.
USING FQDN IN EMAIL ADDRESS
It is also possible to use Fully Qualified Domain Name in an email address sent to SMSEagle box
(eg.: 123456789@mydomain.com). Please refer to our FAQ article: How do I configure Email2SMS
plugin to accept FQDN email addresses for more details.
EMAIL SUBJECT - ADDITIONAL PARAMETERS (OPTIONAL)
It is possible to set additional flags for single converted message using email subject. Currently the
following flags are available:
date - date and time in format YYYYmmDDHHMM (YYYY – year, mm – month, DD – day, HH –
hour, MM – minute). If this parameter is not null SMS will be scheduled for sending at the given date and time
modem_no - sets sending modem number (available only for multimodem devices)
If you send email with subject containing FLAG=VALUE the flag will be set for this particular
email2SMS message.
Example 1: email message with subject containing modem_no=2 will be converted to SMS message and sent via
modem number 2.
Example 2: email message with subject containing date=201801010005&modem_no=2 will be converted to SMS message and sent on 2018-01-01 00:05 via modem number 2.
26 | SMSEagle NXS-9700-3G | User’s Manual
PLUGIN CONFIGURATION
Screenshot from Email to SMS settings
if you want to use the plugin, set ‘Email2sms active’ to ‘Yes’
if you want to include a subject of an email in SMS message, set ‘What to do with email subject’
setting to ‘Include in SMS’. The email subject will be appended at the beginning of SMS message
if you want to use user authentication, set ‘What to do with email subject’ setting to ‘Use for
authentication’. If user authentication is enabled, provide in a subject of an email your login and
password in the following form: login=john&pass=doe
if you want to include only a subject of an email in SMS message, set ‘What to do with email
subject’ setting to ‘Send only subject without email body’. Only the email subject will inserted in
SMS message
the text of an email will be cropped to the value ‘Maximum number of characters’. Maximum
allowed length of SMS message is 1300 characters
if you want to include in SMS message special national characters (like ąäàöß ) set “Unicode
encoding of SMS text” to ‘Yes’
27 | SMSEagle NXS-9700-3G | User’s Manual
Email to SMS Poller
Email2SMS Poller is an alternative for Email2SMS plugin for convert incoming emails to SMS message. This
plugin should be used when you need to fetch emails from existing mailbox on your mail server. The
Email2SMS Poller plugin connects to configured email account and polls it in specified periods of time for
new emails. Once new email is received, it is automatically converted to SMS message.
The plugin supports POP3 and IMAP accounts.
To send SMS using Email2SMS Poller you have to send an email to specified email account, with email
subject containing mobile number (or multiple phone numbers separated with comma) or phonebook
contact/group name.
BASIC EXAMPLE
For example, such email message:
TO: smseagle@mycompany.com
FROM: john.doe@mycompany.com
SUBJECT: +48333444555
BODY: Hello world!
In this case SMSEagle gateway will fetch incoming email from smseagle@mycompany.com account and
send it’s body as SMS message to +48333444555 mobile number.
SEND TO USERNAME/GROUP
If you want to send SMS to a contact or group from SMSEagle phonebook, put the contact/group name in
SUBJECT field.
Notice:
Messages that are processed by Email2SMS Poller (but not deleted) are marked in the mailbox as read. Software is
based on flagging messages- Read/Unread. Marking a read message in the mailbox as unread will result in being
processed again by Email2SMS Poller. We suggest using a separate email account to avoid situation with resending
the same message (marking unread already processed read message).
28 | SMSEagle NXS-9700-3G | User’s Manual
PLUGIN CONFIGURATION
Screenshot from Email to SMS Poller
if you want to use the plugin, set ‘Enable Email2sms Poller’ to ‘Yes’
Set email fetching interval (in seconds)
the text of an email will be cropped to the value ‘Maximum number of characters’. Maximum
allowed length of SMS message is 1300 characters.
If you want to include special national characters, enable "Unicode encoding of SMS text"
Choose protocol from IMAP or POP3
Provide mailbox configuration (host, port, user, password, encryption settings)
If you want to delete emails from the mailbox after they are fetched by Email2SMS Poller, please
mark "Delete emails from server after processing"
29 | SMSEagle NXS-9700-3G | User’s Manual
SMS to Email plugin
SMS to Email plugin allows you to forward incoming SMS messages to email address.
The plugin can be used in two modes:
a. forwarding of incoming SMS to email of last sender (so called Two-way Email2SMS & SMS2Email)
In this mode, when SMSEagle receives incoming SMS, it checks if earlier anyone was sending SMS to the number from incoming SMS using Emai2SMS. If last sender is found, the incoming SMS is forwarded to the email address of last sender. If no last sender is found, then the incoming message is forwarded to a default email address given in plugin settings.
b. It forwards all the incoming messages to one fixed email address.
In this mode all incoming SMS messages are forwarded to always the same email address.
Plugin uses an external SMTP server for sending emails.
PLUGIN CONFIGURATION
30 | SMSEagle NXS-9700-3G | User’s Manual
Screenshot from SMS to Email settings
if you want to use the plugin, set ‘Enable forwarding to email’ to ‘Yes’
choose a type of email forwarding: “To email of last sending user” (so called “Two-way Email2SMS
& SMS&Email”) or “To fixed email address”
enter an email address to which incoming SMS messages are to sent
enter SMTP configuration for your SMTP server that will be used for sending emails
EMAIL TEXT FROM PLUGIN
Email body from SMS To Email plugin contains:
phone number from incoming SMS (and phonebook contact name if found)
Date, time when SMS is received
SMS message
Sample email text:
From: +483334455 (John Doe)
Received: 2017-06-01 14:38:12
Message: My SMS message
Callback URL plugin
Callback URL plugin allows you to forward incoming SMS message to a defined URL address. If the plugin is enabled, on each incoming SMS message SMSEagle will trigger HTTP(S) request to a defined URL. HTTP(S) request can be of type GET or POST.
PLUGIN CONFIGURATION
Plugin “Callback URL” allows to add unlimited number of rules. Each rule can be enabled or disabled by user.
31 | SMSEagle NXS-9700-3G | User’s Manual
Screenshot from Callback URL settings
For each new rule user has to fill in the requested fields:
‘URL’ field defines remote address of your callback script
‘Test URL’ button allows to test whether your Callback URL configuration is correct. SMSEagle will
make a callback request with test parameters and will verify the response of remote server
‘URL method’ allows to choose whether callback to your URL is done with HTTP(S) GET or POST
method
“Send request when” defines if the request is always sent, sent only when SMS sender belongs to a
given contact/group or only when incoming message contains a given character string
Optionally you can define “API key of your service” value. This will be passed to your callback URL in
parameter ‘apikey’. If you leave the field blank, ‘apikey’ parameter will not be passed to your
callback URL
User may also choose whether to enable support of self-signed SSL certificate
After sending HTTP(S) GET/POST request to your callback URL, SMSEagle will be expecting HTTP response:
200 [OK]. If other or no response is received from your callback URL, SMSEagle will keep retrying every 2 minutes for 24 hours.
32 | SMSEagle NXS-9700-3G | User’s Manual
SMS Forward
The plugin “SMS forward” allows to forward incoming SMS messages to one/may recipients according to defined rules.
PLUGIN CONFIGURATION
Plugin “SMS Forward” allows to add many forwarding rules. Each rule can be enabled or disabled by user.
Screenshot from plugin main window
For each rule user can define:
When incoming SMS should be forwarded (Rule type) and to what number(s) the message should
be forwarded (SMS Recipient).
Whether or not include in SMS a sender number from which original SMS came from.
When defining a rule user can choose SMS recipient (who gets the forwarded SMS). It can be
either phone number or name of group from phonebook.
User may define many forwarding rules in the plugin.
Message header can be set to include original sender number or not to include.
Each rule is processed independently.
There is a possibility to enable/disable each rule.
Screenshot form “Add/edit forwarding rule”
33 | SMSEagle NXS-9700-3G | User’s Manual
Periodic SMS
The plugin “Periodic SMS” allows to send SMS messages or USSD codes at a desired time interval. User may
define many sending rules, and each rule will be processed independently.
PLUGIN CONFIGURATION
Plugin “Periodic SMS” allows to add many sending rules. Each rule can be enabled or disabled by user.
Screenshot from main plugin window
For each rule the user can define:
The rule name
Sending interval (Hourly, Daily, Weekly, Monthly or Annually)
Message type (SMS, USSD Code)
The content of the SMS text
The recipients (phone number(s) separated with comma or group(s) from phonebook)
34 | SMSEagle NXS-9700-3G | User’s Manual
Screenshot from “Add new rule” window
Digital input/output
The NXS- family of SMSEagle devices is equipped with digital inputs (DI) and digital outputs (DO). The digital
inputs can be used to receive signals from outside sensors or devices and automatically trigger sending of
SMS message based on input state. On the other hand the digital outputs may be used to activate external
devices connected to the outputs when certain SMS messages are received by SMSEagle.
Number of available DI/DO ports depends on hardware revision:
Port type
Hardware Rev.3
Hardware Rev.2, Rev.1
DI 4 2
DO 4 2
The logical states of inputs and outputs of SMSEagle NXS-family of devices are represented by the following
states:
Logical level
Hardware Rev.3
Hardware Rev. 2, Rev.1
LOW (0)
Closed
0 V
HIGH (1)
Open
+5 V
35 | SMSEagle NXS-9700-3G | User’s Manual
PLUGIN CONFIGURATION
The plugin “Digital input/output” allows you to define rules that control the behaviour of digital
inputs/outputs on SMSEagle device. User may define several processing rules for both inputs and outputs.
Screenshot from plugin window
DIGITAL INPUTS
For each processing rule for digital input user can define:
The rule name
Port number (1,2)
State of input signal that will trigger sending of SMS message (field “When input signal”)
SMS text (field “Send SMS message”)
The recipient’s name from phonebook
36 | SMSEagle NXS-9700-3G | User’s Manual
Screenshot from digital input “Add or edit rule” window
DIGITAL OUTPUTS
For each processing rule for digital output user can define:
The rule name
Port number (1,2)
On what condition digital output should be set (all incoming messages, when incoming SMS comes
from specified contact in phonebook or when incoming SMS text contains given value)
State of output signal that will be triggered by incoming SMS message
Output signal duration in seconds (0 = without time limit)
Output signal delay before signal is set
37 | SMSEagle NXS-9700-3G | User’s Manual
Screenshot from digital output “Add or edit rule” window
WARNING: There is no over-voltage protection on the board. Randomly plugging wires and power sources into your
digital inputs may kill it. Digital outputs has a current efficiency of 200mA. Consider using a relay for high power
output devices.
Temperature & humidity sensor
The NXS-family of SMSEagle devices is equipped with internal temperature and humidity sensor. The
DHT22 sensor allows to measure temperature with ±0.5°C accuracy and humidity with ±2% RH accuracy.
The measured temperature and humidity values can be displayed in web-gui of SMSEagle and used to
trigger SMS message to single/many recipients.
38 | SMSEagle NXS-9700-3G | User’s Manual
Screenshot from plugin main window
PLUGIN CONFIGURATION - ALARMS
Tab “Alarms” allows to define triggering rules for SMS alarms for temperature and humidity. User may
define several processing rules.
Screenshot from “Alarms” window
For each processing rule for digital output user can define:
The rule name
Sensor (currently only 1 sensor is available)
On what condition SMS alarm should be sent (temperature/humidity is higher/lower than given
value)
SMS text
SMS recipient: contact name or group name from Phonebook
39 | SMSEagle NXS-9700-3G | User’s Manual
Screenshot from “Add or edit rule” window
PLUGIN CONFIGURATION - SETTINGS
Tab “Settings” allows to control sensor settings. User may enable/disable sensor and set sensor reading
period (in minutes).
Screenshot from “Settings” window
40 | SMSEagle NXS-9700-3G | User’s Manual
LDAP plugin
The LDAP plugin allows to access Active Directory (hereinafter referred to as “AD”) and read contacts and
groups in SMSEagle web-GUI.
PLUGIN CONFIGURATION
Choose “LDAP” from left side menu in SMSEagle web-GUI to access plugin configuration. After enabling the
plugin, user needs to fill in all requested fields according to AD settings.
In the “AD phone attribute” field user needs to choose which phone attribute from AD will be shown in
SMSEagle web-gui.
Screenshot from “LDAP settings” window
Click “Save” and “Test connection” to make sure that SMSEagle is connected with AD server.
Screenshot showing successful connection to AD server.
41 | SMSEagle NXS-9700-3G | User’s Manual
With connection established, AD contacts/groups suggestions are shown in selected modules of web -gui.
Start typing any part of contact/group name or number to show AD contact suggestions.
Type “LDAP” (case sensitive) to check all contacts listed in AD directory.
Screenshot from “Compose” module with LDAP connection enabled
LDAP directory suggestions can be used in “Compose”, “Autoreply” and “Digital input/output” modules.
42 | SMSEagle NXS-9700-3G | User’s Manual
MULTIMODEM FEATURES
SMSeagle NXS-9750 is equipped with two built-in modems. You can manage modem settings in web-gui
menu Settings > Maintenance Tab. There are following options available for multimodem device:
Multimodem selection strategy
This setting is responsible for modem choice strategy when sending SMS messages from SMSEagle. The
following options are possible:
Round-robin
In this strategy modems are selected sequentially one-by-one when sending out SMS messages. This means that device sends messages using modem1 > modem2 > modem1 > modem2, etc.
SIM1 as Master modem
In this strategy modem1 is always selected when sending out SMS messages. If failover is enabled (see below) modem2 will be always used as a backup in failover strategy
SIM2 as Master modem
In this strategy modem1 is always selected when sending out SMS messages. If failover is enabled (see below) modem2 will be always used as a backup in failover strategy
Enable modem failover mechanism
If this setting is enabled, when one modem stops working other will automatically take over his job. This
feature requires at least two active SIM cards in the device. The health check for each modem is performed
with 3 minutes frequency. If during a health check a modem is not connected to network the other will
automatically take over his jobs (including messages waiting in Outbox folder).
43 | SMSEagle NXS-9700-3G | User’s Manual
SMSEAGLE API
SMSEagle has powerful built-in HTTP API functionalities. REST API is dedicated for integration of SMSEagle
with any external system or application. Below you will find a detailed description of API functionalities.
Please note, that SMSEagle API supports both HTTP and HTTPS protocol.
For your convenience sample usage of SMSEagle’s API in most popular programming languages are available
at: http://www.smseagle.eu/code-samples/
1. Send SMS: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/send_sms
PARAMETERS:
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
to
recipient telephone number (or numbers separated with comma)
message
your SMS message
date
(optional parameter) date and time in format YYYYmmDDHHMM (YYYY – year, mm – month, DD – day, HH – hour, MM – minute). If this parameter is not null SMS will be scheduled for sending at the given date and time
highpriority
(optional parameter) 0 = normal priority, 1 = SMS will have higher priority in Outbox queue when processed by GSM-modem
unicode
(optional parameter) 0 = no Unicode encoding (default), 1 = SMS will be encoded using Unicode (you can send national characters)
flash
(optional parameter) 0 = normal SMS (default), 1 = SMS will be sent as flash message
oid
(optional parameter) This attribute specifies a user-defined unique ID that is assigned to a message-recipient pair. The oid is a varchar(36) that uniquely identifies a message sent to a particular recipient (particular phone number). The value of this ID allows client applications to match incoming reply messages to outgoing messages. If no oid was assigned to the outgoing message this attribute will have a value of null for incoming message.
The oid value will be automatically assigned to incoming message only if incoming phone number matches exactly the phone number (including country code) from outgoing message.
modem_no
(optional parameter) sending modem number (only for multimodem devices)
44 | SMSEagle NXS-9700-3G | User’s Manual
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/send_sms? login=john&pass=doe&to=1234567&message=mymessage
https://url-of-smseagle/index.php/http_api/send_sms? login=john&pass=doe&to=1234567&message=mymessage&date=201401152132
https://url-of-smseagle/index.php/http_api/send_sms? login=john&pass=doe&to=1234567&message=mymessage&highpriority=1
RESPONSE:
Response: OK; ID=[ID of message in outbox] Sample response: OK; ID=297
Response (when wrong logindata): Invalid login or password Response (when wrong parameters): Wrong parameters
RESPONSE (XML):
Response: <xml> <message_id>[ID of message in outbox]</message_id> <status>ok</status> </xml>
Sample response: <xml> <message_id>297</message_id> <status>ok</status> </xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong parameters</error_text> <status>error</status> </xml>
45 | SMSEagle NXS-9700-3G | User’s Manual
Important notice: You must encode URL before sending it to gateway if you use national characters in SMS
message text.
2. Send SMS: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
PARAMETERS:
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
to
recipient telephone number (or numbers separated with comma)
message
your SMS message
date
(optional parameter) date and time in format YYYYmmDDHHMM (YYYY – year, mm – month, DD – day, HH – hour, MM – minute). If this parameter is not null SMS will be scheduled for sending at the given date and time
highpriority
(optional parameter) 0 = normal priority, 1 = SMS will have higher priority in Outbox queue when processed by GSM-modem
unicode
(optional parameter) 0 = no Unicode encoding (default), 1 = SMS will be encoded using Unicode (you can send national characters)
flash
(optional parameter) 0 = normal SMS (default), 1 = SMS will be sent as flash message
oid
(optional parameter) This attribute specifies a user-defined unique ID that is assigned to a message-recipient pair. The oid is a varchar(36) that uniquely identifies a message sent to a particular recipient (particular phone number). The value of this ID allows client applications to match incoming reply messages to outgoing messages. If no oid was assigned to the outgoing message this attribute will have a value of null for incoming message.
The oid value will be automatically assigned to incoming message only if incoming phone number matches exactly the phone number (including country code) from outgoing message.
modem_no
(optional parameter) sending modem number (only for multimodem devices)
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
SAMPLE BODY:
{"method":"sms.send_sms", "params":{"login":"john","pass":"doe","to":"481234567″,"message":"My message"}}
46 | SMSEagle NXS-9700-3G | User’s Manual
or {"method":"sms.send_sms", "params":{"login":"john","pass":"doe","to":"481234567″,"message":"My message","date":"201401152132″}} or {"method":"sms.send_sms", "params":{"login":"john","pass":"doe","to":"481234567″,"message":"My message","highpriority":"1″}}
RESPONSE:
Response: {"result": "OK; ID=[ID of message in outbox]"} Sample response: {"result": "OK; ID=297"}
Response (when wrong logindata): {"result": "Invalid login or password"} Response (when wrong parameters): {"result": "Wrong parameters"}
RESPONSE (EXTENDED):
Response:
{"result": {"message_id":"[ID of message in outbox]","status":"ok"}}
Sample response: {"result": {"message_id":"748","status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong parameters","status":"error"}}
3. Send SMS to a group: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/send_togroup
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
groupname
group name defined in your SMSEagle Phonebook. The group must be defined as Public
message
your SMS message
date
(optional parameter) date and time in format YYYYmmDDHHMM (YYYY – year, mm – month, DD – day, HH – hour, MM – minute). If this parameter is not null SMS will be scheduled for sending at the given date and time
highpriority
(optional parameter) 0 = normal priority, 1 = SMS will have higher priority in Outbox queue when processed by GSM-modem
47 | SMSEagle NXS-9700-3G | User’s Manual
unicode
(optional parameter) 0 = no Unicode encoding (default), 1 = SMS will be encoded using Unicode (you can send national characters)
flash
(optional parameter) 0 = normal SMS (default), 1 = SMS will be sent as flash message
modem_no
(optional parameter) sending modem number (only for multimodem devices)
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/send_togroup? login=john&pass=doe&groupname=admins&message=mymessage
https://url-of-smseagle/index.php/http_api/send_togroup? login=john&pass=doe&groupname=admins&message=mymessage&date=201401152132
https://url-of-smseagle/index.php/http_api/send_togroup? login=john&pass=doe&groupname=admins&message=mymessage&highpriority=1
RESPONSE:
Response: OK; ID=[ID of message in outbox]
Sample response: OK; ID=297
Response (when wrong logindata): Invalid login or password
Response (when wrong parameters): Wrong parameters
RESPONSE (XML):
Response: <xml> <message_id>[ID of message in outbox]</message_id> <status>ok</status> </xml>
Sample response: <xml> <message_id>297</message_id> <status>ok</status> </xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
48 | SMSEagle NXS-9700-3G | User’s Manual
Response (when wrong parameters): <xml> <error_text>Wrong parameters</error_text> <status>error</status> </xml>
4. Send SMS to a group: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
groupname
group name defined in your SMSEagle Phonebook. The group must be defined as Public
message
your SMS message
date
(optional parameter) date and time in format YYYYmmDDHHMM (YYYY – year, mm – month, DD – day, HH – hour, MM – minute). If this parameter is not null SMS will be scheduled for sending at the given date and time
highpriority
(optional parameter) 0 = normal priority, 1 = SMS will have higher priority in Outbox queue when processed by GSM-modem
unicode
(optional parameter) 0 = no Unicode encoding (default), 1 = SMS will be encoded using Unicode (you can send national characters)
flash
(optional parameter) 0 = normal SMS (default), 1 = SMS will be sent as flash message
modem_no
(optional parameter) sending modem number (only for multimodem devices)
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
{"method":"sms.send_togroup", "params":{"login":"john","pass":"doe","groupname":"admins","message":"mymes sage"}} or {"method":"sms.send_togroup", "params":{"login":"john","pass":"doe","groupname":"admins","message":"mymes sage","date":"201401152132"}} or {"method":"sms.send_togroup", "params":{"login":"john","pass":"doe","groupname":"admins","message":"mymes sage","highpriority":"1"}}
49 | SMSEagle NXS-9700-3G | User’s Manual
RESPONSE:
Response: {"result": "OK; ID=[ID of message in outbox]"}
Sample response: {"result": "OK; ID=[297]"}
Response (when wrong logindata): {"result": "Invalid login or password"}
Response (when wrong parameters): {"result": "Wrong parameters"}
RESPONSE (EXTENDED):
Response:
{"result": {"message_id":"[ID of message in outbox]","status":"ok"}}
Sample response: {"result": {"message_id":"748","status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong parameters","status":"error"}}
5. Send SMS to contact: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/send_tocontact
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
contactname
contact name (or names separated by comma) defined in your SMSEagle Phonebook . Contacts must be defined as Public
message
your SMS message
date
(optional parameter) date and time in format YYYYmmDDHHMM (YYYY – year, mm – month, DD – day, HH – hour, MM – minute). If this parameter is not null SMS will be scheduled for sending at the given date and time
highpriority
(optional parameter) 0 = normal priority, 1 = SMS will have higher priority in Outbox queue when processed by GSM-modem
unicode
(optional parameter) 0 = no Unicode encoding (default), 1 = SMS will be encoded using Unicode (you can send national characters)
flash
(optional parameter) 0 = normal SMS (default), 1 = SMS will be sent as flash message
modem_no
(optional parameter) sending modem number (only for multimodem devices)
50 | SMSEagle NXS-9700-3G | User’s Manual
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/send_tocontact? login=john&pass=doe&contactname=johndoe&message=mymessage
https://url-of-smseagle/index.php/http_api/send_tocontact? login=john&pass=doe&contactname=johndoe&message=mymessage&date=201401152132
https://url-of-smseagle/index.php/http_api/send_tocontact? login=john&pass=doe&contactname=johndoe&message=mymessage&highpriority=1
RESPONSE:
Response: OK; ID=[ID of message in outbox]
Sample response: OK; ID=297
Response (when wrong logindata): Invalid login or password
Response (when contact doesn’t exist): Invalid contact name – [contact_name]
Response (when wrong parameters): Wrong parameters
RESPONSE (XML):
Response: <xml> <message_id>[ID of message in outbox]</message_id> <status>ok</status> </xml>
Sample response: <xml> <message_id>297</message_id> <status>ok</status> </xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when contact doesn’t exist): <xml> <error_text>Invalid contact name – [contact_name]</error_text> <status>error</status> </xml>
51 | SMSEagle NXS-9700-3G | User’s Manual
Response (when wrong parameters): <xml> <error_text>Wrong parameters</error_text> <status>error</status> </xml>
6. Send SMS to contact: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
contactname
contact name defined in your SMSEagle Phonebook. The contact must be defined as Public
message
your SMS message
date
(optional parameter) date and time in format YYYYmmDDHHMM (YYYY – year, mm – month, DD – day, HH – hour, MM – minute). If this parameter is not null SMS will be scheduled for sending at the given date and time
highpriority
(optional parameter) 0 = normal priority, 1 = SMS will have higher priority in Outbox queue when processed by GSM-modem
unicode
(optional parameter) 0 = no Unicode encoding (default), 1 = SMS will be encoded using Unicode (you can send national characters)
flash
(optional parameter) 0 = normal SMS (default), 1 = SMS will be sent as flash message
modem_no
(optional parameter) sending modem number (only for multimodem devices)
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
{"method":"sms.send_tocontact", "params":{"login":"john","pass":"doe","contactname":"johndoe","message":"my message"}} or {"method":"sms.send_tocontact", "params":{"login":"john","pass":"doe","contactname":"johndoe","message":"my message","date":"201401152132"}} or {"method":"sms.send_tocontact", "params":{"login":"john","pass":"doe","contactname":"johndoe","message":"my message","highpriority":"1"}}
52 | SMSEagle NXS-9700-3G | User’s Manual
RESPONSE:
Response: {"result": "OK; ID=[ID of message in outbox]"}
Sample response: {"result": "OK; ID=[297]"}
Response (when wrong logindata): {"result": "Invalid login or password"}
Response (when contact doesn’t exist): {"result": "Invalid contact name –
contact_name]"}
Response (when wrong parameters): {"result": "Wrong parameters"}
RESPONSE (EXTENDED):
Response:
{"result": {"message_id":"[ID of message in outbox]","status":"ok"}}
Sample response: {"result": {"message_id":"748","status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when contact doesn’t exist):
{"result": {"error_text":"Invalid contact name – contact_name]","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong parameters","status":"error"}}
7. Send USSD code: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/send_ussd
Parameters:
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
to
USSD code (url-encoded)
modem_no
(optional parameter) sending modem number (only for multimodem devices)
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/send_ussd?
53 | SMSEagle NXS-9700-3G | User’s Manual
login=john&pass=doe&to= %2A101%23
RESPONSE:
Response: OK; ID=[ID of message in outbox] Sample response: OK; ID=297
Response (when wrong logindata): Invalid login or password Response (when wrong parameters): Wrong parameters
RESPONSE (XML):
Response: <xml> <message_id>[ID of message in outbox]</message_id> <status>ok</status> </xml>
Sample response: <xml> <message_id>297</message_id> <status>ok</status> </xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong parameters</error_text> <status>error</status> </xml>
Important notice: You must urlencode USSD code before sending it to gateway. Response from GSM/3G network
will show up in device Inbox folder.
8. Send USSD code: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
54 | SMSEagle NXS-9700-3G | User’s Manual
Parameters:
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
to
USSD code
modem_no
(optional parameter) sending modem number (only for multimodem devices)
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
SAMPLE BODY:
{"method":"sms.send_ussd", "params":{"login":"john","pass":"doe","to":"*101#″}}
RESPONSE:
Response: {"result": "OK; ID=[ID of message in outbox]"} Sample response: {"result": "OK; ID=297"}
Response (when wrong logindata): {"result": "Invalid login or password"} Response (when wrong parameters): {"result": "Wrong parameters"}
RESPONSE (EXTENDED):
Response:
{"result": {"message_id":"[ID of message in outbox]","status":"ok"}}
Sample response: {"result": {"message_id":"748","status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong parameters","status":"error"}}
Important notice: Response from GSM/3G network will show up in device Inbox folder.
9. Send binary SMS: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/send_binary_sms
PARAMETERS:
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
55 | SMSEagle NXS-9700-3G | User’s Manual
to
recipient telephone number (or numbers separated with comma)
udh
(optional parameter) UDH header for the message (in hex format)
data
binary message (in hex format)
class
(optional parameter) message class
modem_no
(optional parameter) sending modem number (only for multimodem devices)
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/send_binary_sms? login=john&pass=doe&to=1234567&udh=0605040B8423F0&data=EA0601AE02056A0045C6 0C037777772E736D736561676C652E657500080103534D534561676C65000101
RESPONSE:
Response: OK; ID=[ID of message in outbox]
Sample response: OK; ID=297
Response (when wrong logindata): Invalid login or password Response (when wrong parameters): Wrong or missing >>udh<< parameter Response (when wrong parameters): Wrong or missing >>data<< parameter
RESPONSE (XML):
Response: <xml> <message_id>[ID of message in outbox]</message_id> <status>ok</status> </xml>
Sample response: <xml> <message_id>297</message_id> <status>ok</status> </xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text> Wrong or missing >>udh<< parameter </error_text> <status>error</status>
56 | SMSEagle NXS-9700-3G | User’s Manual
</xml>
Response (when wrong parameters): <xml> <error_text> Wrong or missing >>data<< parameter </error_text> <status>error</status> </xml>
10. Send binary SMS: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
PARAMETERS:
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
to
recipient telephone number (or numbers separated with comma)
udh
(optional parameter) UDH header for the message (in hex format)
data
binary message (in hex format)
class
(optional parameter) message class
modem_no
(optional parameter) sending modem number (only for multimodem devices)
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
{"method":"sms.send_binary_sms", "params":{"login":"john","pass":"doe","to":"1234567","udh":"0605040B8423F0" ,"data":"EA0601AE02056A0045C60C037777772E736D736561676C652E657500080103534D 534561676C65000101"}}
RESPONSE:
Response: {"result": "OK; ID=[ID of message in outbox]"} Sample response: {"result": "OK; ID=297"}
Response (when wrong logindata): {"result": "Invalid login or password"} Response (when wrong parameters): {"result": "Wrong or missing >>udh<< parameter"} Response (when wrong parameters): {"result": "Wrong or missing >>data<< parameter"}
RESPONSE (EXTENDED):
Response:
57 | SMSEagle NXS-9700-3G | User’s Manual
{"result": {"message_id":"[ID of message in outbox]","status":"ok"}}
Sample response: {"result": {"message_id":"748","status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":" Wrong or missing >>udh<< parameter ","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong or missing >>data<< parameter", "status":"error"}}
11. Read SMS: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/read_sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
folder
one of the following: inbox, outbox, sentitems
idfrom
(optional parameter) minimal message-id
idto
(optional parameter) maximum message-id
from
(optional parameter) telephone number of SMS sender (for inbox)
to
(optional parameter) telephone number of SMS receiver (for sentitems)
datefrom
(optional parameter) date and time in format YYYYmmDDHHMMSS (YYYY – year, mm – month, DD – day, HH – hour, MM – minutes, SS – seconds). Show only messages sent/received on this date/time and later
dateto
(optional parameter) date and time in format YYYYmmDDHHMMSS (YYYY – year, mm – month, DD – day, HH – hour, MM – minutes, SS – seconds). Show only messages sent/received on this date/time and earlier
limit
(optional parameter) how many messages to show
unread
(optional parameter) 1 = show only unread messages
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
Show all messages from inbox: https://url-of-smseagle/index.php/http_api/read_sms? login=john&pass=doe&folder=inbox
58 | SMSEagle NXS-9700-3G | User’s Manual
Show all unread messages from inbox: https://url-of-smseagle/index.php/http_api/read_sms? login=john&pass=doe&folder=inbox&unread=1
Show messages from sentitems folder with id=1234 to 1236: https://url-of-smseagle/index.php/http_api/read_sms? login=john&pass=doe&folder=sentitems&idfrom=1234&idto=1236
Show messages from inbox folder with sender phone number +481234567: https://url-of-smseagle/index.php/http_api/read_sms? login=john&pass=doe&folder=inbox&from=+481234567
Show messages from sentitems folder with receiver phone number 7654321 and datetime from 2014-12-24 08:10:00 to 2014-12-31 23:59:59: https://url-of-smseagle/index.php/http_api/read_sms? login=john&pass=doe&folder=sentitems&to=7654321&datefrom=20141224081000&dat eto=20141231235959
RESPONSE:
Sample responses: inbox folder, sentitems folder
Response (when no data): No data to display
Response (when wrong logindata): Invalid login or password
Response (when wrong parameters): Wrong parameters
RESPONSE (XML):
Sample response (inbox folder):
<xml> <messages> <item> <UpdatedInDB>2018-07-17 15:11:31</UpdatedInDB> <ReceivingDateTime>2018-07-17 15:04:04</ReceivingDateTime> <Text>005400650073007400200031</Text> <SenderNumber>+48123456789</SenderNumber> <Coding>Default_No_Compression</Coding> <UDH></UDH> <SMSCNumber>+48790998250</SMSCNumber> <Class>-1</Class> <TextDecoded>Test 1</TextDecoded> <ID>124</ID> <RecipientID>smseagle1</RecipientID> <Processed>t</Processed> <id_folder>1</id_folder> <readed>true</readed> <oid></oid> <Status>0</Status> </item> <item> <UpdatedInDB>2018-07-17 15:11:31</UpdatedInDB> <ReceivingDateTime>2018-07-17 15:04:10</ReceivingDateTime> <Text>005400650073007400200032</Text> <SenderNumber>+48123456788</SenderNumber> <Coding>Default_No_Compression</Coding> <UDH></UDH>
59 | SMSEagle NXS-9700-3G | User’s Manual
<SMSCNumber>+48790998250</SMSCNumber> <Class>-1</Class> <TextDecoded>Test 2</TextDecoded> <ID>125</ID> <RecipientID>smseagle1</RecipientID> <Processed>t</Processed> <id_folder>1</id_folder> <readed>true</readed> <oid>5208facc-5912-4d21-8d31-7f830cf8f24e</oid> <Status>0</Status> </item> <item> <UpdatedInDB>2018-07-17 15:11:31</UpdatedInDB> <ReceivingDateTime>2018-07-17 15:05:49</ReceivingDateTime>
<Text>004C006F00720065006D00200069007000730075006D00200064006F006C006F00720 02000730069007400200061006D00650074002C00200063006F006E00730065006300740065 007400750072002000610064006900700069007300630069006E006700200065006C0069007 4002E002000430072006100730020006600650072006D0065006E00740075006D0020007500 6C006C0061006D0063006F007200700065007200200065006700650073007400610073002E0 020004E0075006C006C006100200070006C006100630065007200610074002000660069006E 006900620075007300200064006F006C006F0072002C0020006D0061006C006500730075006 10064006100200076006100720069007500730020006C006900670075006C00610020006800 65006E006400720065</Text> <SenderNumber>+48123456787</SenderNumber> <Coding>Default_No_Compression</Coding> <UDH>050003590301</UDH> <SMSCNumber>+48790998250</SMSCNumber> <Class>-1</Class> <TextDecoded>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras fermentum ullamcorper egestas. Nulla placerat finibus dolor, malesuada varius ligula hendrerit sed. Nullam nisl sapien, molestie rhoncus orci vel, viverra luctus ipsum. Praesent maximus luctus orci. Vestibulum lacus dui, vestibulum ac aliquam eget, ultrices et mi. In ac felis urna. Phasellus eget leo a leo congue ultricies. Donec tincidunt volutpat arcu a commodo</TextDecoded> <ID>126</ID> <RecipientID>smseagle1</RecipientID> <Processed>t</Processed> <id_folder>1</id_folder> <readed>true</readed> <oid></oid> <Status>0</Status> </item> </messages> <status>ok</status> </xml>
Sample response (sentitems folder):
<xml> <messages> <item> <UpdatedInDB>2018-06-07 11:29:56</UpdatedInDB> <InsertIntoDB>2018-06-07 11:29:43</InsertIntoDB> <SendingDateTime>2018-06-07 11:29:56</SendingDateTime> <DeliveryDateTime>2018-06-07 11:30:05</DeliveryDateTime> <Text>0074006500730074</Text> <DestinationNumber>123456789</DestinationNumber> <Coding>Default_No_Compression</Coding> <UDH></UDH> <SMSCNumber>+48501200777</SMSCNumber> <Class>-1</Class>
60 | SMSEagle NXS-9700-3G | User’s Manual
<TextDecoded>test</TextDecoded> <ID>456</ID> <SenderID>smseagle1</SenderID> <SequencePosition>1</SequencePosition> <Status>DeliveryOK</Status> <StatusError>-1</StatusError> <TPMR>116</TPMR> <RelativeValidity>255</RelativeValidity> <CreatorID>admin</CreatorID> <id_folder>3</id_folder> <StatusCode>-1</StatusCode> </item> <item> <UpdatedInDB>2018-07-13 11:40:45</UpdatedInDB> <InsertIntoDB>2018-07-13 11:40:40</InsertIntoDB> <SendingDateTime>2018-07-13 11:40:45</SendingDateTime> <DeliveryDateTime></DeliveryDateTime> <Text></Text> <DestinationNumber>*101#</DestinationNumber> <Coding>8bit</Coding> <UDH></UDH> <SMSCNumber>+48501200777</SMSCNumber> <Class>127</Class> <TextDecoded></TextDecoded> <ID>525</ID> <SenderID>smseagle1</SenderID> <SequencePosition>1</SequencePosition> <Status>SendingOK</Status> <StatusError>-1</StatusError> <TPMR>-1</TPMR> <RelativeValidity>255</RelativeValidity> <CreatorID>admin</CreatorID> <id_folder>3</id_folder> <StatusCode>-1</StatusCode> </item> <item> <UpdatedInDB>2018-07-18 14:25:41</UpdatedInDB> <InsertIntoDB>2018-07-18 14:25:23</InsertIntoDB> <SendingDateTime>2018-07-18 14:25:28</SendingDateTime> <DeliveryDateTime>2018-07-18 14:25:28</DeliveryDateTime> <Text>0054006500730074002000740065007300740031</Text> <DestinationNumber>+48123456788</DestinationNumber> <Coding>Default_No_Compression</Coding> <UDH></UDH> <SMSCNumber>+48601000310</SMSCNumber> <Class>-1</Class> <TextDecoded>Test test1</TextDecoded> <ID>574</ID> <SenderID>smseagle1</SenderID> <SequencePosition>1</SequencePosition> <Status>DeliveryOK</Status> <StatusError>0</StatusError> <TPMR>84</TPMR> <RelativeValidity>255</RelativeValidity> <CreatorID>admin</CreatorID> <id_folder>3</id_folder> <StatusCode>-1</StatusCode> </item> <item> <UpdatedInDB>2018-07-18 14:27:13</UpdatedInDB> <InsertIntoDB>2018-07-18 14:27:03</InsertIntoDB> <SendingDateTime>2018-07-18 14:27:13</SendingDateTime> <DeliveryDateTime></DeliveryDateTime>
61 | SMSEagle NXS-9700-3G | User’s Manual
<Text>00540065007300740020007700690074006800200075006E00690063006F006400650 0200065006E0063006F00640069006E0067003A00200105014200F30119017A0107</Text> <DestinationNumber>123456788</DestinationNumber> <Coding>Unicode_No_Compression</Coding> <UDH></UDH> <SMSCNumber>+48601000310</SMSCNumber> <Class>-1</Class> <TextDecoded>Test with unicode encoding: ąłóęźć</TextDecoded> <ID>576</ID> <SenderID>smseagle2</SenderID> <SequencePosition>1</SequencePosition> <Status>SendingOK</Status> <StatusError>-1</StatusError> <TPMR>86</TPMR> <RelativeValidity>255</RelativeValidity> <CreatorID>admin</CreatorID> <id_folder>3</id_folder> <StatusCode>-1</StatusCode> </item> <item> <UpdatedInDB>2018-07-18 14:27:36</UpdatedInDB> <InsertIntoDB>2018-07-18 14:27:32</InsertIntoDB> <SendingDateTime>2018-07-18 14:27:36</SendingDateTime> <DeliveryDateTime></DeliveryDateTime>
<Text>00540065007300740020006F006600200066006C0061007300680020006D006500730 073006100670065</Text> <DestinationNumber>123456788</DestinationNumber> <Coding>Default_No_Compression</Coding> <UDH></UDH> <SMSCNumber>+48601000310</SMSCNumber> <Class>0</Class> <TextDecoded>Test of flash message</TextDecoded> <ID>577</ID> <SenderID>smseagle2</SenderID> <SequencePosition>1</SequencePosition> <Status>SendingOK</Status> <StatusError>-1</StatusError> <TPMR>87</TPMR> <RelativeValidity>255</RelativeValidity> <CreatorID>admin</CreatorID> <id_folder>3</id_folder> <StatusCode>-1</StatusCode> </item> <item> <UpdatedInDB>2018-07-18 14:29:29</UpdatedInDB> <InsertIntoDB>2018-07-18 14:28:46</InsertIntoDB> <SendingDateTime>2018-07-18 14:29:29</SendingDateTime> <DeliveryDateTime></DeliveryDateTime>
<Text>0054006500730074002000770069007400680020006200610064002000700068006F0 06E00650020006E0075006D006200650072</Text> <DestinationNumber>11</DestinationNumber> <Coding>Default_No_Compression</Coding> <UDH></UDH> <SMSCNumber></SMSCNumber> <Class>-1</Class> <TextDecoded>Test with bad phone number</TextDecoded> <ID>578</ID> <SenderID>smseagle2</SenderID> <SequencePosition>1</SequencePosition> <Status>SendingError</Status> <StatusError>-1</StatusError>
62 | SMSEagle NXS-9700-3G | User’s Manual
<TPMR>-1</TPMR> <RelativeValidity>255</RelativeValidity> <CreatorID>admin</CreatorID> <id_folder>3</id_folder> <StatusCode>21</StatusCode> </item> </messages> <status>ok</status> </xml>
Response (when no data): <xml> <error_text>No data to display</error_text> <status>error</status> </xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong parameters</error_text> <status>error</status> </xml>
FIELD DESCRIPTION OF RESPONSE DATA – INBOX FOLDER:
Field
Data type
Description
UpdatedInDB
timestamp
when somebody (software, user) updated the message content or state
ReceivingDateTime
timestamp
when SMS was received
Text
text
SMS text encoded using hex values
SenderNumber
character varying(30)
SMS sender number
Coding
character varying(255)
SMS text coding. Possible values:
‘Default_No_Compression’, ‘Unicode_No_Compression’, ‘8bit’, ‘Default_Compression’, ‘Unicode_Compression’
UDH
text
User Data Header encoded using hex values
SMSCNumber
character varying(20)
SMSC number
Class
integer
SMS class (0 is flash SMS, -1 is normal SMS, 127 is USSD)
TextDecoded
text
decoded SMS text
ID
serial
SMS unique identification number
63 | SMSEagle NXS-9700-3G | User’s Manual
RecipientID
text
which modem received the message
(for example: smseagle1, smseagle2)
Processed
boolean
whether SMS was processed by SMSEagle application
id_folder
integer
identification of storage folder. Possible values:
1 Inbox 5 Trash 11… Custom folder
readed
text
whether SMS was read in GUI or via API
oid
character varying(36)
user-defined unique ID that is assigned to a message­recipient pair. The oid uniquely identifies a message sent to a particular recipient (particular phone number).
More information: see send_sms method description
Status
integer
Status of incoming message. Currently only used for USSD messages with following meaning:
1 Unknown status. 2 No action is needed, maybe network initiated USSD. 3 Reply is expected. 4 USSD dialog terminated. 5 Another client replied. 6 Operation not supported. 7 Network timeout.
FIELD DESCRIPTION OF RESPONSE DATA – SENTITEMS FOLDER:
Field
Data type
Description
UpdatedInDB
timestamp
when somebody (software, user) updated the message content or state
InsertIntoDB
timestamp
when message was inserted into database
SendingDateTime
timestamp
when message has been sent
DeliveryDateTime
timestamp
time of receiving a delivery report (if it has been enabled). Null if delivery report was not received.
Text
text
SMS text encoded using hex values
DestinationNumber
character varying(30)
destination number for SMS
Coding
character varying(255)
SMS text coding. Possible values:
‘Default_No_Compression’, ‘Unicode_No_Compression’, ‘8bit’, ‘Default_Compression’, ‘Unicode_Compression’
UDH
text
User Data Header encoded using hex values
SMSCNumber
character varying(20)
number of SMSC, which sent SMS
Class
integer
SMS class (0 is flash SMS, -1 is normal SMS, 127 is USSD)
TextDecoded
text
decoded SMS text
ID
serial
SMS unique identification number
64 | SMSEagle NXS-9700-3G | User’s Manual
SenderID
character varying(255)
which modem sent the message
(for example: smseagle1, smseagle2)
SequencePosition
integer
SMS number in SMS sequence
Status
character varying(255)
Status of message sending. Possible values:
SendingOK Message has been sent, waiting for delivery report SendingOKNoReport Message has been sent without asking for delivery report SendingError Sending has failed DeliveryOK Delivery report arrived and reported success DeliveryFailed Delivery report arrived and reports failure DeliveryPending Delivery report announced pending deliver DeliveryUnknown Delivery report reported unknown status Error Some other error happened during sending
Notice: some cellular operators return “SendingOK” status instead of “DeliveryOK” for correctly delivered SMS. If you want to check for delivery status, please verify what you receive from your operator or instead use the field DeliveryDateTime.
StatusError
integer
Status of delivery from delivery report message, codes are defined in GSM specification 03.40 section
9.2.3.15 (TP-Status)
TPMR
integer
The Message Reference field (TP-MR) as defined in GSM 03.40
RelativeValidity
integer
SMS relative validity (TP-VP) encoded as defined in GSM 03.40
CreatorID
text
username that created the SMS message
id_folder
integer
identification of storage folder. Possible values:
3 Sent items 5 Trash 11… Custom folder
StatusCode
integer
CMS status code (also known as CMS ERROR) received from cellular network.
- 1 No CMS Error > -1 CMS Error occurred. CMS error number is saved in this field.
65 | SMSEagle NXS-9700-3G | User’s Manual
12. Read SMS: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
folder
one of the following: inbox, outbox, sentitems
idfrom
(optional parameter) minimal message-id
idto
(optional parameter) maximum message-id
from
(optional parameter) telephone number of SMS sender (for inbox)
to
(optional parameter) telephone number of SMS receiver (for sentitems)
datefrom
(optional parameter) date and time in format YYYYmmDDHHMMSS (YYYY – year, mm – month, DD – day, HH – hour, MM – minutes, SS – seconds). Show only messages sent/received on this date/time and later
dateto
(optional parameter) date and time in format YYYYmmDDHHMMSS (YYYY – year, mm – month, DD – day, HH – hour, MM – minutes, SS – seconds). Show only messages sent/received on this date/time and earlier
limit
(optional parameter) how many messages to show
unread
(optional parameter) 1 = show only unread messages
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
Show all messages from inbox: {"method":"sms.read_sms", "params":{"login":"john","pass":"doe","folder":"inbox"}}
Show all unread messages from inbox: {"method":"sms.read_sms", "params":{"login":"john","pass":"doe","folder":"inbox","unread":"1"}}
Show messages from sentitems folder with id=1234 to 1236: {"method":"sms.read_sms", "params":{"login":"john","pass":"doe","folder":"sentitems","idfrom":"1234", "idto":"1236"}}
Show messages from inbox folder with sender phone number +481234567: {"method":"sms.read_sms", "params":{"login":"john","pass":"doe","folder":"inbox","from":" 481234567"}}
Show messages from sentitems folder with receiver phone number 7654321 and datetime from 2014-12-24 08:10:00 to 2014-12-31 23:59:59:
66 | SMSEagle NXS-9700-3G | User’s Manual
{"method":"sms.read_sms", "params":{"login":"john","pass":"doe","folder":"sentitems","to":"7654321"," datefrom":"20141224081000","dateto":"20141231235959"}}
RESPONSE:
Sample response (inbox folder):
{ "result": [ { "UpdatedInDB": "2018-07-18 13:56:16", "ReceivingDateTime": "2018-07-17 15:04:04", "Text": "005400650073007400200031", "SenderNumber": "+48123456789", "Coding": "Default_No_Compression", "UDH": "", "SMSCNumber": "+48790998250", "Class": "-1", "TextDecoded": "Test 1", "ID": "124", "RecipientID": "smseagle1", "Processed": "t", "id_folder": "1", "readed": "true", "oid": "", "Status": "0" }, { "UpdatedInDB": "2018-07-18 13:56:16", "ReceivingDateTime": "2018-07-17 15:04:10", "Text": "005400650073007400200032", "SenderNumber": "+48123456788", "Coding": "Default_No_Compression", "UDH": "", "SMSCNumber": "+48790998250", "Class": "-1", "TextDecoded": "Test 2", "ID": "125", "RecipientID": "smseagle1", "Processed": "t", "id_folder": "1", "readed": "true", "oid": "5208facc-5912-4d21-8d31-7f830cf8f24e", "Status": "0" }, { "UpdatedInDB": "2018-07-18 13:56:16", "ReceivingDateTime": "2018-07-17 15:05:49", "Text": "004C006F00720065006D00200069007000730075006D00200064006F006C006F0072002000 730069007400200061006D00650074002C00200063006F006E0073006500630074006500740 0750072002000610064006900700069007300630069006E006700200065006C00690074002E 002000430072006100730020006600650072006D0065006E00740075006D00200075006C006 C0061006D0063006F007200700065007200200065006700650073007400610073002E002000 4E0075006C006C006100200070006C006100630065007200610074002000660069006E00690
67 | SMSEagle NXS-9700-3G | User’s Manual
0620075007300200064006F006C006F0072002C0020006D0061006C00650073007500610064 006100200076006100720069007500730020006C006900670075006C0061002000680065006 E006400720065", "SenderNumber": "+48123456787", "Coding": "Default_No_Compression", "UDH": "050003590301", "SMSCNumber": "+48790998250", "Class": "-1", "TextDecoded": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras fermentum ullamcorper egestas. Nulla placerat finibus dolor, malesuada varius ligula hendrerit sed. Nullam nisl sapien, molestie rhoncus orci vel, viverra luctus ipsum. Praesent maximus luctus orci. Vestibulum lacus dui, vestibulum ac aliquam eget, ultrices et mi. In ac felis urna. Phasellus eget leo a leo congue ultricies. Donec tincidunt volutpat arcu a commodo", "ID": "126", "RecipientID": "smseagle1", "Processed": "t", "id_folder": "1", "readed": "true", "oid": "", "Status": "0" } ] }
Sample response (sentitems folder):
{ "result": [ { "UpdatedInDB": "2018-06-07 11:29:56", "InsertIntoDB": "2018-06-07 11:29:43", "SendingDateTime": "2018-06-07 11:29:56", "DeliveryDateTime": "2018-06-07 11:30:05", "Text": "0074006500730074", "DestinationNumber": "+48123456789", "Coding": "Default_No_Compression", "UDH": "", "SMSCNumber": "+48501200777", "Class": "-1", "TextDecoded": "test", "ID": "456", "SenderID": "smseagle1", "SequencePosition": "1", "Status": "DeliveryOK", "StatusError": "-1", "TPMR": "116", "RelativeValidity": "255", "CreatorID": "admin", "id_folder": "3", "StatusCode": "-1" }, { "UpdatedInDB": "2018-07-13 11:40:45", "InsertIntoDB": "2018-07-13 11:40:40", "SendingDateTime": "2018-07-13 11:40:45",
68 | SMSEagle NXS-9700-3G | User’s Manual
"DeliveryDateTime": null, "Text": "", "DestinationNumber": "*101#", "Coding": "8bit", "UDH": "", "SMSCNumber": "+48501200777", "Class": "127", "TextDecoded": "", "ID": "525", "SenderID": "smseagle1", "SequencePosition": "1", "Status": "SendingOK", "StatusError": "-1", "TPMR": "-1", "RelativeValidity": "255", "CreatorID": "admin", "id_folder": "3", "StatusCode": "-1" }, { "UpdatedInDB": "2018-07-18 14:25:41", "InsertIntoDB": "2018-07-18 14:25:23", "SendingDateTime": "2018-07-18 14:25:28", "DeliveryDateTime": "2018-07-18 14:25:28", "Text": "0054006500730074002000740065007300740031", "DestinationNumber": "+48123456788", "Coding": "Default_No_Compression", "UDH": "", "SMSCNumber": "+48601000310", "Class": "-1", "TextDecoded": "Test test1", "ID": "574", "SenderID": "smseagle1", "SequencePosition": "1", "Status": "DeliveryOK", "StatusError": "0", "TPMR": "84", "RelativeValidity": "255", "CreatorID": "admin", "id_folder": "3", "StatusCode": "-1" }, { "UpdatedInDB": "2018-07-18 14:27:13", "InsertIntoDB": "2018-07-18 14:27:03", "SendingDateTime": "2018-07-18 14:27:13", "DeliveryDateTime": null, "Text": "00540065007300740020007700690074006800200075006E00690063006F00640065002000 65006E0063006F00640069006E0067003A00200105014200F30119017A0107", "DestinationNumber": "123456788", "Coding": "Unicode_No_Compression", "UDH": "", "SMSCNumber": "+48601000310", "Class": "-1", "TextDecoded": "Test with unicode encoding: ąłóęźć",
69 | SMSEagle NXS-9700-3G | User’s Manual
"ID": "576", "SenderID": "smseagle1", "SequencePosition": "1", "Status": "SendingOK", "StatusError": "-1", "TPMR": "86", "RelativeValidity": "255", "CreatorID": "admin", "id_folder": "3", "StatusCode": "-1" }, { "UpdatedInDB": "2018-07-18 14:27:36", "InsertIntoDB": "2018-07-18 14:27:32", "SendingDateTime": "2018-07-18 14:27:36", "DeliveryDateTime": null, "Text": "00540065007300740020006F006600200066006C0061007300680020006D00650073007300 6100670065", "DestinationNumber": "123456788", "Coding": "Default_No_Compression", "UDH": "", "SMSCNumber": "+48601000310", "Class": "0", "TextDecoded": "Test of flash message", "ID": "577", "SenderID": "smseagle1", "SequencePosition": "1", "Status": "SendingOK", "StatusError": "-1", "TPMR": "87", "RelativeValidity": "255", "CreatorID": "admin", "id_folder": "3", "StatusCode": "-1" }, { "UpdatedInDB": "2018-07-18 14:29:29", "InsertIntoDB": "2018-07-18 14:28:46", "SendingDateTime": "2018-07-18 14:29:29", "DeliveryDateTime": null, "Text": "0054006500730074002000770069007400680020006200610064002000700068006F006E00 650020006E0075006D006200650072", "DestinationNumber": "11", "Coding": "Default_No_Compression", "UDH": "", "SMSCNumber": "", "Class": "-1", "TextDecoded": "Test with bad phone number", "ID": "578", "SenderID": "smseagle1", "SequencePosition": "1", "Status": "SendingError", "StatusError": "-1", "TPMR": "-1",
70 | SMSEagle NXS-9700-3G | User’s Manual
"RelativeValidity": "255", "CreatorID": "admin", "id_folder": "3", "StatusCode": "21" } ] }
Response (when no data): {"result": "No data to display"}
Response (when wrong logindata): {"result": "Invalid login or password"}
Response (when wrong parameters): {"result": "Wrong parameters"}
RESPONSE (EXTENDED):
Sample response (inbox folder):
{ "result": { "messages": [ { "UpdatedInDB": "2018-07-18 14:06:06", "ReceivingDateTime": "2018-07-17 15:04:04", "Text": "005400650073007400200031", "SenderNumber": "+48123456789", "Coding": "Default_No_Compression", "UDH": "", "SMSCNumber": "+48790998250", "Class": "-1", "TextDecoded": "Test 1", "ID": "124", "RecipientID": "smseagle1", "Processed": "t", "id_folder": "1", "readed": "true", "oid": "", "Status": "0" }, { "UpdatedInDB": "2018-07-18 14:06:06", "ReceivingDateTime": "2018-07-17 15:04:10", "Text": "005400650073007400200032", "SenderNumber": "+48123456788", "Coding": "Default_No_Compression", "UDH": "", "SMSCNumber": "+48790998250", "Class": "-1", "TextDecoded": "Test 2", "ID": "125", "RecipientID": "smseagle1", "Processed": "t", "id_folder": "1", "readed": "true", "oid": "5208facc-5912-4d21-8d31-7f830cf8f24e",
71 | SMSEagle NXS-9700-3G | User’s Manual
"Status": "0" }, { "UpdatedInDB": "2018-07-18 14:06:06", "ReceivingDateTime": "2018-07-17 15:05:49", "Text": "004C006F00720065006D00200069007000730075006D00200064006F006C006F0072002000 730069007400200061006D00650074002C00200063006F006E0073006500630074006500740 0750072002000610064006900700069007300630069006E006700200065006C00690074002E 002000430072006100730020006600650072006D0065006E00740075006D00200075006C006 C0061006D0063006F007200700065007200200065006700650073007400610073002E002000 4E0075006C006C006100200070006C006100630065007200610074002000660069006E00690 0620075007300200064006F006C006F0072002C0020006D0061006C00650073007500610064 006100200076006100720069007500730020006C006900670075006C0061002000680065006 E006400720065", "SenderNumber": "+48123456787", "Coding": "Default_No_Compression", "UDH": "050003590301", "SMSCNumber": "+48790998250", "Class": "-1", "TextDecoded": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras fermentum ullamcorper egestas. Nulla placerat finibus dolor, malesuada varius ligula hendrerit sed. Nullam nisl sapien, molestie rhoncus orci vel, viverra luctus ipsum. Praesent maximus luctus orci. Vestibulum lacus dui, vestibulum ac aliquam eget, ultrices et mi. In ac felis urna. Phasellus eget leo a leo congue ultricies. Donec tincidunt volutpat arcu a commodo", "ID": "126", "RecipientID": "smseagle1", "Processed": "t", "id_folder": "1", "readed": "true", "oid": "", "Status": "0" } ], "status": "ok" } }
Sample response (sentitems folder):
{ "result": { "messages": [ { "UpdatedInDB": "2018-06-07 11:29:56", "InsertIntoDB": "2018-06-07 11:29:43", "SendingDateTime": "2018-06-07 11:29:56", "DeliveryDateTime": "2018-06-07 11:30:05", "Text": "0074006500730074", "DestinationNumber": "+48123456789", "Coding": "Default_No_Compression", "UDH": "", "SMSCNumber": "+48501200777",
72 | SMSEagle NXS-9700-3G | User’s Manual
"Class": "-1", "TextDecoded": "test", "ID": "456", "SenderID": "smseagle1", "SequencePosition": "1", "Status": "DeliveryOK", "StatusError": "-1", "TPMR": "116", "RelativeValidity": "255", "CreatorID": "admin", "id_folder": "3", "StatusCode": "-1" }, { "UpdatedInDB": "2018-07-13 11:40:45", "InsertIntoDB": "2018-07-13 11:40:40", "SendingDateTime": "2018-07-13 11:40:45", "DeliveryDateTime": null, "Text": "", "DestinationNumber": "*101#", "Coding": "8bit", "UDH": "", "SMSCNumber": "+48501200777", "Class": "127", "TextDecoded": "", "ID": "525", "SenderID": "smseagle1", "SequencePosition": "1", "Status": "SendingOK", "StatusError": "-1", "TPMR": "-1", "RelativeValidity": "255", "CreatorID": "admin", "id_folder": "3", "StatusCode": "-1" }, { "UpdatedInDB": "2018-07-18 14:25:41", "InsertIntoDB": "2018-07-18 14:25:23", "SendingDateTime": "2018-07-18 14:25:28", "DeliveryDateTime": "2018-07-18 14:25:28", "Text": "0054006500730074002000740065007300740031", "DestinationNumber": "+48123456788", "Coding": "Default_No_Compression", "UDH": "", "SMSCNumber": "+48601000310", "Class": "-1", "TextDecoded": "Test test1", "ID": "574", "SenderID": "smseagle1", "SequencePosition": "1", "Status": "DeliveryOK", "StatusError": "0", "TPMR": "84", "RelativeValidity": "255", "CreatorID": "admin",
73 | SMSEagle NXS-9700-3G | User’s Manual
"id_folder": "3", "StatusCode": "-1" }, { "UpdatedInDB": "2018-07-18 14:27:13", "InsertIntoDB": "2018-07-18 14:27:03", "SendingDateTime": "2018-07-18 14:27:13", "DeliveryDateTime": null, "Text": "00540065007300740020007700690074006800200075006E00690063006F00640065002000 65006E0063006F00640069006E0067003A00200105014200F30119017A0107", "DestinationNumber": "123456788", "Coding": "Unicode_No_Compression", "UDH": "", "SMSCNumber": "+48601000310", "Class": "-1", "TextDecoded": "Test with unicode encoding: ąłóęźć", "ID": "576", "SenderID": "smseagle1", "SequencePosition": "1", "Status": "SendingOK", "StatusError": "-1", "TPMR": "86", "RelativeValidity": "255", "CreatorID": "admin", "id_folder": "3", "StatusCode": "-1" }, { "UpdatedInDB": "2018-07-18 14:27:36", "InsertIntoDB": "2018-07-18 14:27:32", "SendingDateTime": "2018-07-18 14:27:36", "DeliveryDateTime": null, "Text": "00540065007300740020006F006600200066006C0061007300680020006D00650073007300 6100670065", "DestinationNumber": "123456788", "Coding": "Default_No_Compression", "UDH": "", "SMSCNumber": "+48601000310", "Class": "0", "TextDecoded": "Test of flash message", "ID": "577", "SenderID": "smseagle1", "SequencePosition": "1", "Status": "SendingOK", "StatusError": "-1", "TPMR": "87", "RelativeValidity": "255", "CreatorID": "admin", "id_folder": "3", "StatusCode": "-1" }, { "UpdatedInDB": "2018-07-18 14:29:29", "InsertIntoDB": "2018-07-18 14:28:46",
74 | SMSEagle NXS-9700-3G | User’s Manual
"SendingDateTime": "2018-07-18 14:29:29", "DeliveryDateTime": null, "Text": "0054006500730074002000770069007400680020006200610064002000700068006F006E00 650020006E0075006D006200650072", "DestinationNumber": "11", "Coding": "Default_No_Compression", "UDH": "", "SMSCNumber": "", "Class": "-1", "TextDecoded": "Test with bad phone number", "ID": "578", "SenderID": "smseagle1", "SequencePosition": "1", "Status": "SendingError", "StatusError": "-1", "TPMR": "-1", "RelativeValidity": "255", "CreatorID": "admin", "id_folder": "3", "StatusCode": "21" } ], "status": "ok" }
Response (when no data):
{"result": {"error_text":" No data to display ", "status":"error"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":" Wrong or missing >>udh<< parameter ","status":"error"}}
FIELD DESCRIPTION OF RESPONSE DATA – INBOX FOLDER:
Field
Data type
Description
UpdatedInDB
timestamp
when somebody (software, user) updated the message content or state
ReceivingDateTime
timestamp
when SMS was received
Text
text
SMS text encoded using hex values
SenderNumber
character varying(30)
SMS sender number
Coding
character varying(255)
SMS text coding. Possible values:
‘Default_No_Compression’, ‘Unicode_No_Compression’, ‘8bit’, ‘Default_Compression’, ‘Unicode_Compression’
UDH
text
User Data Header encoded using hex values
SMSCNumber
character varying(20)
SMSC number
75 | SMSEagle NXS-9700-3G | User’s Manual
Class
integer
SMS class (0 is flash SMS, -1 is normal SMS, 127 is USSD)
TextDecoded
text
decoded SMS text
ID
serial
SMS unique identification number
RecipientID
text
which modem received the message
(for example: smseagle1, smseagle2)
Processed
boolean
whether SMS was processed by SMSEagle application
id_folder
integer
identification of storage folder. Possible values:
1 Inbox 5 Trash 11… Custom folder
readed
text
whether SMS was read in GUI or via API
oid
character varying(36)
user-defined unique ID that is assigned to a message­recipient pair. The oid uniquely identifies a message sent to a particular recipient (particular phone number).
More information: see send_sms method description
Status
integer
Status of incoming message. Currently only used for USSD messages with following meaning:
1 Unknown status. 2 No action is needed, maybe network initiated USSD. 3 Reply is expected. 4 USSD dialog terminated. 5 Another client replied. 6 Operation not supported. 7 Network timeout.
FIELD DESCRIPTION OF RESPONSE DATA – SENTITEMS FOLDER:
Field
Data type
Description
UpdatedInDB
timestamp
when somebody (software, user) updated the message content or state
InsertIntoDB
timestamp
when message was inserted into database
SendingDateTime
timestamp
when message has been sent
DeliveryDateTime
timestamp
time of receiving a delivery report (if it has been enabled). Null if delivery report was not received.
Text
text
SMS text encoded using hex values
DestinationNumber
character varying(30)
destination number for SMS
Coding
character varying(255)
SMS text coding. Possible values:
‘Default_No_Compression’, ‘Unicode_No_Compression’, ‘8bit’, ‘Default_Compression’, ‘Unicode_Compression’
UDH
text
User Data Header encoded using hex values
SMSCNumber
character varying(20)
number of SMSC, which sent SMS
76 | SMSEagle NXS-9700-3G | User’s Manual
Class
integer
SMS class (0 is flash SMS, -1 is normal SMS, 127 is USSD)
TextDecoded
text
decoded SMS text
ID
serial
SMS unique identification number
SenderID
character varying(255)
which modem sent the message
(for example: smseagle1, smseagle2)
SequencePosition
integer
SMS number in SMS sequence
Status
character varying(255)
Status of message sending. Possible values:
SendingOK Message has been sent, waiting for delivery report SendingOKNoReport Message has been sent without asking for delivery report SendingError Sending has failed DeliveryOK Delivery report arrived and reported success DeliveryFailed Delivery report arrived and reports failure DeliveryPending Delivery report announced pending deliver DeliveryUnknown Delivery report reported unknown status Error Some other error happened during sending
Notice: some cellular operators return “SendingOK” status instead of “DeliveryOK” for correctly delivered SMS. If you want to check for delivery status, please verify what values you receive from your operator or instead use the field DeliveryDateTime.
StatusError
integer
Status of delivery from delivery report message, codes are defined in GSM specification 03.40 section
9.2.3.15 (TP-Status)
TPMR
integer
The Message Reference field (TP-MR) as defined in GSM 03.40
RelativeValidity
integer
SMS relative validity (TP-VP) encoded as defined in GSM 03.40
CreatorID
text
username that created the SMS message
id_folder
integer
identification of storage folder. Possible values:
3 Sent items 5 Trash 11… Custom folder
StatusCode
integer
CMS status code (also known as CMS ERROR) received from cellular network.
- 1 No CMS Error > -1 CMS Error occurred. CMS error number is saved in this field.
77 | SMSEagle NXS-9700-3G | User’s Manual
13. Delete SMS: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/delete_sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
folder
one of the following: inbox, outbox, sentitems
idfrom
minimal id of message
idto
maximal id of message
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
Delete message with id=1234 from inbox: https://url-of-smseagle/index.php/http_api/delete_sms? login=john&pass=doe&folder=inbox&idfrom=1234&idto=1234
Delete messages with id 1234 – 1250 from inbox: https://url-of-smseagle/index.php/http_api/delete_sms? login=john&pass=doe&folder=inbox&idfrom=1234&idto=1250
Delete all messages from outbox: https://url-of-smseagle/index.php/http_api/delete_sms?
login=john&pass=doe&folder=outbox&idfrom=1&idto=999999999
RESPONSE:
Response: OK Response (when delete operation was not successful): Error Response (when wrong logindata): Invalid login or password
RESPONSE (XML):
Response: <xml> <status>ok</status> </xml>
Response (when delete operation was not successful): <xml> <status>error</status> </xml>
78 | SMSEagle NXS-9700-3G | User’s Manual
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
14. Delete SMS: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
folder
one of the following: inbox, outbox, sentitems
idfrom
minimal id of message
idto
maximal id of message
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
Delete message with id=1234 from inbox: {"method":"sms.delete_sms", "params":{"login":"john","pass":"doe","folder":"inbox","idfrom":"1234""idto ":"1234"}}
Delete messages with id 1234 – 1250 from inbox: {"method":"sms.delete_sms", "params":{"login":"john","pass":"doe","folder":"inbox","idfrom":"1234","idt o":"1250"}}
Delete all messages from outbox: {"method":"sms.delete_sms", "params":{"login":"john","pass":"doe","folder":"outbox","idfrom":"1","idto"
:"999999999"}}
RESPONSE:
Response: {"result": "OK"} Response (when delete operation was not successful): {"result": "Error"} Response (when wrong logindata): {"result": "Invalid login or password"}
RESPONSE (EXTENDED):
Response: {"result":{"status":"ok"}}
79 | SMSEagle NXS-9700-3G | User’s Manual
Response (when delete operation was not successful):
{"result":{"status":"error"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
15. Get outgoing queue length: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/get_queue_length
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/get_queue_length? login=john&pass=doe
RESPONSE:
Response: [number of messages in database that wait to be processed by GSM-modem] Sample response: 7 Response (when wrong logindata): Invalid login or password Response (when wrong parameters): Wrong parameters
RESPONSE (XML):
Response: <xml> <queue_length> [number of messages in database that wait to be processed by GSM-modem] </queue_length > <status>ok</status> </xml>
Sample response: <xml> <queue_length>7</queue_length > <status>ok</status> </xml>
80 | SMSEagle NXS-9700-3G | User’s Manual
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong parameters</error_text> <status>error</status> </xml>
16. Get outgoing queue length: JSONRPC method
HTTP POST METHOD CALL:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
BODY:
{"method":"sms.get_queue_length", "params":{"login":"john","pass":"doe"}}
RESPONSE:
Response: {"result": [number of messages in database that wait to be
processed by GSM-modem]}
Sample response: {"result":7}
Response: {"result": "Invalid login or password"}
Response: {"result": "Wrong parameters"}
RESPONSE (EXTENDED):
Response:
{"result":{"queue_length":[number of messages in database that wait to be processed by GSM-modem],"status":"ok"}}
Sample response: {"result": {"queue_length":"419","status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
81 | SMSEagle NXS-9700-3G | User’s Manual
Response (when wrong parameters):
{"result": {"error_text":"Wrong parameters","status":"error"}}
17. Get inbox length: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/get_inbox_length
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/get_inbox_length? login=john&pass=doe
RESPONSE:
Response: [number of messages in database Inbox folder]
Sample response: 3
Response (when wrong logindata): Invalid login or password
Response (when wrong parameters): Wrong parameters
RESPONSE (XML):
Response: <xml> <queue_length> [number of messages in database Inbox folder] </queue_length> <status>ok</status> </xml>
Sample response: <xml> <inbox_length>3</inbox_length> <status>ok</status> </xml>
Response (when wrong logindata): <xml>
82 | SMSEagle NXS-9700-3G | User’s Manual
<error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong parameters</error_text> <status>error</status> </xml>
18. Get inbox length: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
{"method":"sms.get_inbox_length", "params":{"login":"john","pass":"doe"}}
RESPONSE:
Response: {"result": "[number of messages in database Inbox folder]"}
Sample response: 3
Response (when wrong logindata): {"result": "Invalid login or password"}
Response (when wrong parameters): {"result": "Wrong parameters"}
RESPONSE (EXTENDED):
Response:
{"result":{"inbox_length":[number of messages in database Inbox folder],"status":"ok"}}
Sample response: {"result": {"inbox_length":"3","status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong parameters","status":"error"}}
83 | SMSEagle NXS-9700-3G | User’s Manual
19. Get sentitems length: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/get_inbox_length
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/get_sentitems_length?
login=john&pass=doe
RESPONSE:
Response: [number of messages in database Sentitems folder] Sample response: 21 Response (when wrong logindata): Invalid login or password Response (when wrong parameters): Wrong parameters
RESPONSE (XML):
Response: <xml> <sentitems_length> [number of messages in database Inbox folder] </sentitems_length> <status>ok</status> </xml>
Sample response: <xml> <sentitems_length>21</sentitems_length> <status>ok</status> </xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong parameters</error_text>
84 | SMSEagle NXS-9700-3G | User’s Manual
<status>error</status> </xml>
20. Get sentitems length: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
{"method":"sms.get_sentitems_length",
"params":{"login":"john","pass":"doe"}}
RESPONSE:
Response: {"result": "[number of messages in database Sentitems folder]"} Sample response: {"result": "21"} Response (when wrong logindata): {"result": "Invalid login or password"} Response (when wrong parameters): {"result": "Wrong parameters"}
RESPONSE (EXTENDED):
Response:
{"result":{"sentitems_length":[number of messages in database Sentitems folder],"status":"ok"}}
Sample response: {"result": {"sentitems_length":"21","status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong parameters","status":"error"}}
21. Get GSM/3G signal strength: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/get_gsmsignal
Parameter
Description
login
your user to login to SMSEagle
85 | SMSEagle NXS-9700-3G | User’s Manual
pass
your password to login to SMSEagle
modem_no
(optional parameter) modem number to be queried (default = 1). Used only in multimodem devices
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/get_gsmsignal?
login=john&pass=doe&modem_no=1
RESPONSE:
Response: GSM/3G signal strength in percent (values between 0-100). If 3G modem is disconnected from GSM/3G network, method returns -1 Sample response: 74 Response (when wrong logindata): Invalid login or password Response (when wrong parameters): Wrong parameters
RESPONSE (XML):
Response: <xml> <signal_strength> [GSM signal strength in percent (values between 0-100)] </signal_strength> <status>ok</status> </xml>
Sample response: <xml> <signal_strength>74</signal_strength> <status>ok</status> </xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong parameters</error_text> <status>error</status> </xml>
86 | SMSEagle NXS-9700-3G | User’s Manual
22. Get GSM/3G signal strength: JSONRPC method
HTTP POST METHOD CALL:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
modem_no
(optional parameter) modem number to be queried (default = 1). Used only in multimodem devices
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
BODY:
{"method":"signal.get_gsmsignal", "params":{"login":"john","pass":"doe"}}
RESPONSE:
Response: {"result": GSM signal strength in percent: values between 0-100. If 3G modem is disconnected from GSM/3G network, method returns -1 }
Sample response: {"result":7} Response: {"result": "Invalid login or password"} Response: {"result": "Wrong parameters"}
RESPONSE (EXTENDED):
Response:
{"result":{"signal_strength":[number of messages in database Sentitems folder],"status":"ok"}}
Sample response: {"result": {"signal_strength":"7","status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
23. Phonebook group create: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/group_create
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
87 | SMSEagle NXS-9700-3G | User’s Manual
groupname
name for the created group
public
(optional parameter) 0 = private group, 1 = public group
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/group_create? login=john&pass=doe&groupname=myusers&public=1
RESPONSE:
Response: OK; ID=[ID of created group] Sample response: OK; ID=5 Response (when wrong logindata): Invalid login or password Response (when wrong parameters): Wrong or missing >>groupname<< parameter
RESPONSE (XML):
Response: <xml> <group_id>[ID of created group]</group_id> <status>ok</status> </xml>
Sample response: <xml> <group_id>5</group_id> <status>ok</status> </xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong or missing >>groupname<< parameter</error_text> <status>error</status> </xml>
24. Phonebook group create: JSONRPC method
HTTP POST METHOD:
88 | SMSEagle NXS-9700-3G | User’s Manual
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
groupname
name for the created group
public
(optional parameter) 0 = private group, 1 = public group
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
{"method":"phonebook.group_create", "params":{"login":"john","pass":"doe","groupname":"myusers","public":"1"}}
RESPONSE:
Response: {"result": "OK; ID=[ID of created group]"} Sample response: {"result": "OK; ID=5"} Response (when wrong logindata): {"result": "Invalid login or password"} Response (when wrong parameters): {"result": "Wrong or missing >>groupname<<
parameter"}
RESPONSE (EXTENDED):
Response:
{"result": {"group_id":"[ID of created group]","status":"ok"}}
Sample response: {"result": {"group_id":"748","status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong parameters","status":"error"}}
25. Phonebook group read: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/group_read
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
public
(optional parameter) 0 = private group (default value), 1 = public group
uid
(optional parameter) id of user who created the group
89 | SMSEagle NXS-9700-3G | User’s Manual
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/group_read? login=john&pass=doe&public=1&uid=12
RESPONSE:
Sample response: link
Response (when no data): No data to display
Response (when wrong logindata): Invalid login or password
Response (when wrong parameters):
Wrong or missing >>uid<< parameter
Wrong or missing >>public<< parameter
RESPONSE (XML):
Sample response:
<xml> <groups> <item> <Name>private</Name> <ID>2</ID> <id_user>2</id_user> <is_public>true</is_public> </item> <item> <Name>Everyone</Name> <ID>3</ID> <id_user>1</id_user> <is_public>true</is_public> </item> <item> <Name>work</Name> <ID>4</ID> <id_user>1</id_user> <is_public>true</is_public> </item></groups> <status>ok</status> </xml>
Response (when no data): <xml> <error_text>No data to display</error_text> <status>error</status>
90 | SMSEagle NXS-9700-3G | User’s Manual
</xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong or missing >>uid<< parameter</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong or missing >>public<< parameter</error_text> <status>error</status> </xml>
26. Phonebook group read: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
public
(optional parameter) 0 = private group (default value), 1 = public group
uid
(optional parameter) id of user who created the group
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
{"method":"phonebook.group_read", "params":{"login":"john","pass":"doe","public":"1","uid":"12"}}
RESPONSE:
Sample response:
{"result":[ {"Name":"private","ID":"2","id_user":"1","is_public":"true"}, {"Name":"Everyone","ID":"3","id_user":"1","is_public":"true"}, {"Name":"work","ID":"4","id_user":"2","is_public":"true"} ]}
91 | SMSEagle NXS-9700-3G | User’s Manual
Response (when no data): {"result": "No data to display"}
Response (when wrong logindata): {"result": "Invalid login or password"}
Response (when wrong parameters):
{"result": "Wrong or missing >>uid<< parameter"} {"result": "Wrong or missing >>public<< parameter"}
RESPONSE (EXTENDED):
Sample response:
{"result":[ {"groups":[ {"Name":"private","ID":"2","id_user":"1","is_public":"true"}, {"Name":"Everyone","ID":"3","id_user":"1","is_public":"true"}, {"Name":"work","ID":"4","id_user":"2","is_public":"true"} ],"status":"ok"}}
Response (when no data):
{"result": {"error_text":" No data to display","status":"error"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong or missing >>uid<< parameter","status":"error"}}
{"result": {"error_text":"Wrong or missing >>public<< parameter","status":"error"}}
27. Phonebook group update: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/group_update
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
group_id
id of existing group
groupname
name for the group
public
(optional parameter) 0 = private group, 1 = public group
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/group_update? login=john&pass=doe&group_id=2&groupname=myusers&public=1
92 | SMSEagle NXS-9700-3G | User’s Manual
RESPONSE:
Response: OK
Response (when wrong logindata): Invalid login or password
Response (when wrong parameters):
Wrong or missing >>groupname<< parameter
Wrong or missing >>group_id<< parameter
Response (when group_id is wrong): Group with the given id does not exists
RESPONSE (XML):
Response: <xml> <status>ok</status> </xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong or missing >>groupname<< parameter</error_text> <status>error</status> </xml>
<xml> <error_text>Wrong or missing >>group_id<< parameter</error_text> <status>error</status> </xml>
Response (when group_id is wrong): <xml> <error_text>Group with the given id does not exists</error_text> <status>error</status> </xml>
28. Phonebook group update: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
93 | SMSEagle NXS-9700-3G | User’s Manual
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
group_id
id of existing group
groupname
name for the group
public
(optional parameter) 0 = private group, 1 = public group
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
{"method":"phonebook.group_update", "params":{"login":"john","pass":"doe","group_id":"2","groupname":"myusers", "public":"1"}}
RESPONSE:
Response: {"result": "OK"}
Response (when wrong logindata): {"result": "Invalid login or password"}
Response (when wrong parameters):
{"result": "Wrong or missing >>groupname<< parameter"} {"result": "Wrong or missing >>group_id<< parameter"}
Response (when group_id is wrong): {"result": "Group with the given id does not
exists"}
RESPONSE (EXTENDED):
Response: {"result":{"status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong or missing >>groupname<< parameter","status":"error"}}
{"result": {"error_text":"Wrong or missing >>group_id<< parameter","status":"error"}}
Response (when group_id is wrong):
{"result": {"error_text":"Group with the given id does not exists","status":"error"}}
29. Phonebook group delete: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/group_delete
94 | SMSEagle NXS-9700-3G | User’s Manual
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
group_id
id of existing group
groupname
name of existing group
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/group_delete? login=john&pass=doe&group_id=2&groupname=myusers
RESPONSE:
Response: OK
Response (when wrong logindata): Invalid login or password
Response (when wrong parameters):
Wrong or missing >>groupname<< parameter
Wrong or missing >>group_id<< parameter
Response (when group_id is wrong): Group with the given id and name does not exist
RESPONSE (XML):
Response: <xml> <status>ok</status> </xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong or missing >>groupname<< parameter</error_text> <status>error</status> </xml>
<xml> <error_text>Wrong or missing >>group_id<< parameter</error_text> <status>error</status> </xml>
95 | SMSEagle NXS-9700-3G | User’s Manual
Response (when group_id is wrong): <xml> <error_text>Group with the given id does not exists</error_text> <status>error</status> </xml>
30. Phonebook group delete: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
group_id
id of existing group
groupname
name of existing group
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
{"method":"phonebook.group_delete", "params":{"login":"john","pass":"doe","group_id":"2","groupname":"myusers"} }
RESPONSE:
Response: {"result": "OK"}
Response (when wrong logindata): {"result": "Invalid login or password"}
Response (when wrong parameters):
{"result": "Wrong or missing >>groupname<< parameter"} {"result": "Wrong or missing >>group_id<< parameter"}
Response (when group_id is wrong): {"result": "Group with the given id and name does
not exist"}
RESPONSE (EXTENDED):
Response: {"result":{"status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong or missing >>groupname<< parameter","status":"error"}}
96 | SMSEagle NXS-9700-3G | User’s Manual
{"result": {"error_text":"Wrong or missing >>group_id<< parameter","status":"error"}}
Response (when group_id is wrong):
{"result": {"error_text":"Group with the given id does not exists","status":"error"}}
31. Phonebook group add contact: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/group_addcontact
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
group_id
id of existing group (or id’s separated with comma)
contact_id
id of contact. The contact will be added to the group
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/group_addcontact? login=john&pass=doe&group_id=2&contact_id=1
RESPONSE:
Response: OK
Response (when wrong logindata): Invalid login or password
Response (when wrong parameters):
Wrong or missing >>group_id<< parameter
Wrong or missing >>contact_id<< parameter
Response (when id is wrong):
Group with the given id does not exists
Contact with the given id does not exists
RESPONSE (XML):
Response: <xml> <status>ok</status> </xml>
Response (when wrong logindata): <xml>
97 | SMSEagle NXS-9700-3G | User’s Manual
<error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong or missing >>group_id<< parameter</error_text> <status>error</status> </xml>
<xml> <error_text>Wrong or missing >>contact_id<< parameter</error_text> <status>error</status> </xml>
Response (when id is wrong): <xml> <error_text>Group with the given id does not exists</error_text> <status>error</status> </xml>
<xml> <error_text>Contact with the given id does not exists</error_text> <status>error</status> </xml>
32. Phonebook group add contact: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
group_id
id of existing group (or id’s separated with comma)
contact_id
id of contact. The contact will be added to the group
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
{"method":"phonebook.group_addcontact", "params":{"login":"john","pass":"doe","group_id":"2","contact_id":"1"}}
98 | SMSEagle NXS-9700-3G | User’s Manual
RESPONSE:
Response: {"result": "OK"}
Response (when wrong logindata): {"result": "Invalid login or password"}
Response (when wrong parameters):
{"result": "Wrong or missing >>group_id<< parameter"} {"result": "Wrong or missing >>contact_id<< parameter"}
Response (when id is wrong):
{"result": "Group with the given id does not exists"} {"result": "Contact with the given id does not exists"}
RESPONSE (EXTENDED):
Response: {"result":{"status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong or missing >>group_id<< parameter","status":"error"}}
{"result": {"error_text":"Wrong or missing >>contact_id<< parameter","status":"error"}}
Response (when id is wrong):
{"result": {"error_text":"Group with the given id does not exists","status":"error"}}
{"result": {"error_text":"Contact with the given id does not exists","status":"error"}}
33. Phonebook group remove contact: HTTP GET method
HTTP GET METHOD:
https://url-of-smseagle/index.php/http_api/group_removecontact
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
group_id
id of existing group (or id’s separated with comma)
contact_id
id of contact. The contact will be removed from the group
responsetype
(optional parameter) text = format response as text (default), xml = format response as XML object
EXAMPLES:
https://url-of-smseagle/index.php/http_api/group_removecontact? login=john&pass=doe&group_id=2&contact_id=1
99 | SMSEagle NXS-9700-3G | User’s Manual
RESPONSE:
Response: OK
Response (when wrong logindata): Invalid login or password
Response (when wrong parameters):
Wrong or missing >>group_id<< parameter
Wrong or missing >>contact_id<< parameter
Response (when id is wrong):
Group with the given id does not exists
Contact with the given id does not exists
RESPONSE (XML):
Response: <xml> <status>ok</status> </xml>
Response (when wrong logindata): <xml> <error_text>Invalid login or password</error_text> <status>error</status> </xml>
Response (when wrong parameters): <xml> <error_text>Wrong or missing >>group_id<< parameter</error_text> <status>error</status> </xml>
<xml> <error_text>Wrong or missing >>contact_id<< parameter</error_text> <status>error</status> </xml>
Response (when id is wrong): <xml> <error_text>Group with the given id does not exists</error_text> <status>error</status> </xml>
<xml> <error_text>Contact with the given id does not exists</error_text> <status>error</status> </xml>
100 | SMSEagle NXS-9700-3G | User’s Manual
34. Phonebook group remove contact: JSONRPC method
HTTP POST METHOD:
https://url-of-smseagle/index.php/jsonrpc/sms
Parameter
Description
login
your user to login to SMSEagle
pass
your password to login to SMSEagle
group_id
id of existing group (or id’s separated with comma)
contact_id
id of contact. The contact will be removed from the group
responsetype
(optional parameter) simple = format response as simple object with one result field (default), extended = format response as extended JSON object
EXAMPLES:
{"method":"phonebook.group_removecontact", "params":{"login":"john","pass":"doe","group_id":"2","contact_id":"1"}}
RESPONSE:
Response: {"result": "OK"}
Response (when wrong logindata): {"result": "Invalid login or password"}
Response (when wrong parameters):
{"result": "Wrong or missing >>group_id<< parameter"} {"result": "Wrong or missing >>contact_id<< parameter"}
Response (when id is wrong):
{"result": "Group with the given id does not exists"} {"result": "Contact with the given id does not exists"}
RESPONSE (EXTENDED):
Response: {"result":{"status":"ok"}}
Response (when wrong logindata):
{"result": {"error_text":"Invalid login or password","status":"error"}}
Response (when wrong parameters):
{"result": {"error_text":"Wrong or missing >>group_id<< parameter","status":"error"}}
{"result": {"error_text":"Wrong or missing >>contact_id<< parameter","status":"error"}}
Response (when id is wrong):
{"result": {"error_text":"Group with the given id does not exists","status":"error"}}
Loading...