SMS Server configuration

Hi there. I spoke briefly with Saptarshi about this and he gave me a few tips. I added a file called SMSServer.conf in my DHIS2_HOME directory.

gateway.0=myClickatell, ClickatellHttp

myClickatell.api_id=1234

myClickatell.username=foo

myClickatell.password=bar

myClickatell.secure=no

myClickatell.outbound=yes

SMS is still not available. Could maybe someone give me some tips how (or if) Clickatell works with 2.6?

Regards,

Jason

Hi Jason,

SMS config is somewhat experimental at the moment. You need to
configure it using xml e.g. using curl :wink: I am copying in an
explanation I got from Jo (who made this):

curl -XPUT -H'Content-Type: application/xml' -uadmin:district -v -d
@sms.xml http://dhis-instance/api/config/sms

where sms.xml looks like this:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<smsConfiguration xmlns="http://dhis2.org/schema/dxf/2.0">
<enabled>true</enabled>
<longNumber>(dependent on what is configured on gateway side)</longNumber>
<gateways>
       relevant gateway*
</gateways>
</smsConfiguration>

Gateways:

bulksms.com:

    <bulksms>
      <name>bulk</name>
      <username>username</username>
      <password>password</password>
    </bulksms>

clickatell:

    <clickatell>
      <name>click</name>
      <username>username</username>
      <password>password</password>
      <apiId>apikey</apiId>
    </clickatell>

Generic http get:

- Tested with bullksms interface:

  <http>
      <name>simplebulk</name>
      <urlTemplate>http://bulksms.vsms.net:5567/eapi/submission/send_sms/2/2.0?username={username}&password={password}&message={message}&msisdn={recipient}</urlTemplate>
      <parameters>
        <parameter key="username" value="*username*" />
        <parameter key="password" value="*password*" />
      </parameters>
    </http>

- Tested with http://www.mysmsmantra.com/ :

    <http>
      <name>mysmsmantra</name>
      <urlTemplate>http://bulksms.mysmsmantra.com:8080/WebSMS/SMSAPI.jsp?username={username}&password={password}&sendername={sender}&message={message}&mobileno={recipient}</urlTemplate>
      <parameters>
        <parameter key="username" value="*username*" />
        <parameter key="password" value="*password*" />
      </parameters>
    </http>

Lars