The XML HTTP API has been deprecated.
Please ensure that all new customers us the Web Services API
The XML HTTP API is described here for customers who are already using it.
XML Document Format
The XML should be of this example format
<?xml version="1.0" encoding="ISO-8859-1"?> <!DOCTYPE msg_core SYSTEM "msg_core.dtd"> <DOCUMENT MODE="normal"> <SENDER password="xxxxx"> <ADDRESS type="EMAIL" role="FROM" value="name@company.com"></ADDRESS> </SENDER> <REPLYTO> <ADDRESS type="EMAIL" role="REPLYTO" value="name@company.com"></ADDRESS> </REPLYTO> <SMS> <HEADER>SMS From</HEADER> <FOOTER>my signature</FOOTER> </SMS> <MESSAGE > <ADDRESS type="SMS" role="TO" value="0410507753" status="INITIATOR" priority="1"></ADDRESS> <SUBJECT> Example </SUBJECT> <BODY type="TEXT"> <PAYLOAD> Test SMS Message using XML. </PAYLOAD> </BODY> </MESSAGE> </DOCUMENT>
Examples:
Single SMS
The following is an example of sending one message to a single person
<?xml version="1.0" encoding="ISO-8859-1"?> <!DOCTYPE DOCUMENT SYSTEM "http://localhost:8080/gateway/msg_core.dtd"> <DOCUMENT mode="NORMAL"> <SENDER password="xxxx"> <ADDRESS type="EMAIL" role="FROM" value="account@company.com"/> </SENDER> <MESSAGE> <ADDRESS type="EMAIL" role="REPLYTO" value="mailto:sms@company.com?subject=SMS Reply ID#765"/> <ADDRESS type="SMS" role="TO" value="61410123123" status="INITIATOR" priority="1"/> <BODY type="TEXT"> <PAYLOAD type="TEXT" encoding="ASCII">This is an SMS from the gateway. </PAYLOAD> </BODY> </MESSAGE> </DOCUMENT>
One to Many
The following is an example of sending one message to many targets. This example will send the message "Test SMS Message using XML" to the following phone numbers: 0410507753, 0402469846 and 0418235612
<?xml version="1.0" encoding="ISO-8859-1"?> <!DOCTYPE DOCUMENT SYSTEM "http://localhost:8080/gateway/msg_core.dtd"> <DOCUMENT mode="NORMAL"> <SENDER password="xxxx"> <ADDRESS type="EMAIL" role="FROM" value="account@company.com"/> </SENDER> <MESSAGE priority="3"> <ADDRESS type="SMS" role="TO" value="0410507753" status="INITIATOR" priority="1"></ADDRESS> <ADDRESS type="SMS" role="TO" value="0402469846" status="INITIATOR" priority="1"></ADDRESS> <ADDRESS type="SMS" role="TO" value="0418235612" status="INITIATOR" priority="1"></ADDRESS> <SUBJECT> Multicast test </SUBJECT> <BODY type="TEXT"> <PAYLOAD> Test SMS Message using XML. </PAYLOAD> </BODY> </MESSAGE> </DOCUMENT>
Many to Many
The following is an example of sending many messages to many targets. This example will send "Test SMS Message using XML (Batch - 1)." to 0410507753 and "Test SMS Message using XML (Batch - 2)." to 0402469846.
<?xml version="1.0" encoding="ISO-8859-1"?> <!DOCTYPE DOCUMENT SYSTEM "http://localhost:8080/gateway/msg_core.dtd"> <DOCUMENT mode="NORMAL"> <SENDER password="xxxx"> <ADDRESS type="EMAIL" role="FROM" value="account@company.com"/> </SENDER> <MESSAGE priority="3"> <ADDRESS type="SMS" role="TO" value="0410507753" status="INITIATOR" priority="1"></ADDRESS> <SUBJECT> Batch Test </SUBJECT> <BODY type="TEXT"> <PAYLOAD> Test SMS Message using XML (Batch - 1). </PAYLOAD> </BODY> </MESSAGE> <MESSAGE priority="2"> <ADDRESS type="SMS" role="TO" value="0402469846" status="INITIATOR" priority="1"></ADDRESS> <SUBJECT> Batch Test </SUBJECT> <BODY type="TEXT"> <PAYLOAD> Test SMS Message using XML (Batch - 2). </PAYLOAD> </BODY> </MESSAGE> </DOCUMENT>