Sending SMS with HTTP GET/POST
  • 23 Nov 2021
  • 1 Minute to read
  • Contributors
  • Dark
    Light
  • PDF

Sending SMS with HTTP GET/POST

  • Dark
    Light
  • PDF

Article Summary

This article provides an overview of the HTTP POST/GET SMS functionality in the SiteManager. Examples will use curl, but the information is transferable to any other method of passing HTTP requests.

Prerequisites:
A SiteManager with an agent configured for the device which will be sending the SMS request.

HTTP GET

curl -X GET http://[SiteManager IP]:26864/SMS/[Target phonenumber(s)]/Testing_GET

The line above will send the text "Testing_GET" to your desired phonenumber, provided you replace [SiteManager IP] and [Target phonenumber(s)] with the appropriate details for your setup.

If the resulting traffic of this command is examined using a program like Wireshark, you get this readout:

The "Full request URI" can also be used in a browser to achieve the same effect.

HTTP POST

curl -d "Testing_POST" -X POST http://[SiteManager IP]:26864/SMS/[Target phonenumber(s)]

The line above will send the text "Testing_POST" to your desired phonenumber, provided you replace [SiteManager IP] and [Target phonenumber(s)] with the appropriate details for your setup. 

If the resulting traffic of this command is examined using a program like Wireshark, you get this readout:

Note that the default Content-Type in curl is "application/x-www-form-urlencoded" in some other tools you may need to specify it.





Was this article helpful?

What's Next