Hi. experts 

I have done some reading up on setting up DLR's for Kannel and drew up this 
little step by step. I added a few questions for each step that I require some 
help with, if you wouldn't mind answering them? This is not complete guide yet 
but I hope we can draw up some form of conclusion or documentation for 
implementing simple DLRs. Any help and contributions, would be highly 
appreciated. 

If anyone has any links or useful sites on this, it would help allot. 



DLR Setup step by steps: 



1.Config Changes: 


Set DLR-Storage = mysql 

2. Create database table with structure 

§ #---- DLR table structure 

§ group = dlr-db 

§ id = dlr 

§ table = dlr 

§ field-smsc = smsc 

§ field-timestamp = ts 

§ field-destination = destination 

§ field-source = source 

§ field-service = service 

§ field-url = url 

§ field-mask = mask 

§ field-status = status 

§ field-boxc-id = boxc 



3.Create script to update received status DLR statuses 


<?php 

UPDATE table SET state=$HTTP_GET_VARS["state"] WHERE 

id_sms=$HTTP_GET_VARS["msgid"] 

?> 

4.Append to sendsms call 

dlr-url=urlencode(http://yourhost/dlr.php?msgid=<id_sms>&state=%d&msisdn=%p) 

dlr-mask = 31 

e.g 

http://localhost:8811/sendsms?username=xxx&password=yyy&to=6281111&text=test+sms&dlr-mask=31&dlr-url=http%3A%2F%2F127.0.0.1%2Fdlr.php%3Fmsgid%3D1%26state%3D%25d%26msisdn%3D%25p
 



Questions per step: 

· 1.Q: Are there any other configuration changes to be made? 

· 2.Q: Do you need to create these tables manually or does Kannel create them 
itself? Would this table then hold my DLRs for further processing, permanently? 
Is there any place I can find the predefined kannel variables for the DLR call 

e.g 

CREATE TABLE dlr (smsc varchar(40), ts varchar(40), destination varchar(40), 
source varchar(40), service varchar(40), url varchar(255), mask int(10), status 
int(10), boxc varchar(40)) 

· 3.Q: Would this script suffice for updating DLR statuses? Would you place 
this script into the default WWW directory? 

· 4.Q: Would appending the mask/dlr url to the sendsms call be enough? Is there 
anything else to look into/change? 

Thanks you in advance 




Aubrey 

Reply via email to