Re: Obtaining the message ID set by the SMSC
One of the main reasons for this feature is if the SMS is not delivered then you will not get back the SMSC ID in the deliver_sm. In this case if you query the SMS's status with some mobile operators they insist you to give them the SMSC ID. You can't give them your Kannel SMS ID :) so you need to dig around in the database to try find it, which is difficult if you have large systems with many SMSs. So to have a patch for this in CVS would be great. Kannel already calls the dlr-url when it gets the submit_sm_resp from the SMSC. It also gets the SMSC ID from the submit_sm_resp at this point. So to get the SMSC ID is just a simple change, by allowing Kannel to pass to the dlr-url the SMSC ID when it calls it after getting the submit_sm_resp. Its only a few lines of code. However, I've been told this will break the abstraction and so to keep Kannel pure we have never put this in CVS. Fred sent me a patch for a older version of Kannel which is so simple, I only need to change it for the latest CVS. So if the Kannel CVS maintainers will allow it, I'll test it works for the latest CVS or ask Fred to submit it. So Ben your goal is to convince the Kannel CVS maintainers, that this is useful enough, otherwise why create the patch if it will never be added to the Kannel CVS. Rgds
Re: Obtaining the message ID set by the SMSC
One of the main reasons for this feature is if the SMS is not delivered then you will not get back the SMSC ID in the deliver_sm. In this case if you query the SMS's status with some mobile operators they insist you to give them the SMSC ID. You can't give them your Kannel SMS ID :) so you need to dig around in the database to try find it, which is difficult if you have large systems with many SMSs. So to have a patch for this in CVS would be great. Kannel already calls the dlr-url when it gets the submit_sm_resp from the SMSC. It also gets the SMSC ID from the submit_sm_resp at this point. So to get the SMSC ID is just a simple change, by allowing Kannel to pass to the dlr-url the SMSC ID when it calls it after getting the submit_sm_resp. Its only a few lines of code. However, I've been told this will break the abstraction and so to keep Kannel pure we have never put this in CVS. Fred sent me a patch for a older version of Kannel which is so simple, I only need to change it for the latest CVS. So if the Kannel CVS maintainers will allow it, I'll test it works for the latest CVS or ask Fred to submit it. I haven't seen the patch, but would like to, so don't know how it works, but if it allows the ID via a substitution variable like the other ones that can be used in dlr-url I don't see how it can break the abstraction. Ok so not all smsc protocol give back an ID I guess, but lets face it we have things like %o which is dependent on the SMSC module providing it, so thats not consistent, neither I suspect is %B for the incoming billing identifier. Unlike the %o every DLR stored in the database does have something in the ts field, even if its not a unique ID generated by the smsc, its still something that should be available in the dlr-url. Regards Ben
Re: Obtaining the message ID set by the SMSC
I actually share this view. Having the SMSC's ID in hand can help a lot in such cases, especially when you dont want to go though gigabytes of logs. But the delivery reports have the ID's in them and this is the only feedback mechanism we have towards the sender. What for sure would be a big hassle is if we have to provide on the HTTP answer because at that point in time we dont have the message id in our hand (as we have not submitted the message yet). On 23.09.2006, at 16:07, Ben Suffolk wrote: @Ben: can you describe a senseful scenario for this need? Sure, Let suppose you are sending reverse billed SMS messages, i.e. ones that you should get a share of the revenue from the operator for. At the end of the charging period they tell you how many chargeable message you sent. When you reconcile this with the number you actually sent, the chances of it matching are slim. If you have the DLR with the operators assigned ID you are then able to add a little more weight to your argument that supports your message counts not theirs. Its would also be useful for other support resolution issues, such as message that don't get delivered, by having the ID you can pass it to the operators TS people. Although I guess in this instance the ID would be available through the DLR table in the ts field. Regards Ben
Re: Obtaining the message ID set by the SMSC
On 26.09.2006, at 14:28, Ben Suffolk wrote: I actually share this view. Having the SMSC's ID in hand can help a lot in such cases, especially when you dont want to go though gigabytes of logs. But the delivery reports have the ID's in them and this is the only feedback mechanism we have towards the sender. When you say the DLRs have the IDs in them, do you mean I can get at them already, or that it would be relatively easy to add them into the code for the URL call back as they exist in the internal data structure for the DLR? the message text in a SMPP dlr contains the ID same is true for EMI / UCP. Just takes a bit of parsing to break them out of a message like The mesage 1233456789 to 012345 has been delivered at 00:11:22 What for sure would be a big hassle is if we have to provide on the HTTP answer because at that point in time we dont have the message id in our hand (as we have not submitted the message yet). I can see that, and as long as you can access it via the DLRs then its not really that much of an issue. Regards Ben
Re: Obtaining the message ID set by the SMSC
I actually share this view. Having the SMSC's ID in hand can help a lot in such cases, especially when you dont want to go though gigabytes of logs. But the delivery reports have the ID's in them and this is the only feedback mechanism we have towards the sender. When you say the DLRs have the IDs in them, do you mean I can get at them already, or that it would be relatively easy to add them into the code for the URL call back as they exist in the internal data structure for the DLR? What for sure would be a big hassle is if we have to provide on the HTTP answer because at that point in time we dont have the message id in our hand (as we have not submitted the message yet). I can see that, and as long as you can access it via the DLRs then its not really that much of an issue. Regards Ben
Re: Obtaining the message ID set by the SMSC
the message text in a SMPP dlr contains the ID same is true for EMI / UCP. Just takes a bit of parsing to break them out of a message like The mesage 1233456789 to 012345 has been delivered at 00:11:22 Ok, thats cool, I'll check it out. It would still be a nice to have if it was a simple variable for substitution in the dlr-url but have access to it like this is enough for the moment. Thanks Ben
Re: Obtaining the message ID set by the SMSC
Ben Suffolk wrote: Hi, I would like to be able to get the message ID set by the SMSC. I know it is stored in the ts field int he DLR database. I have looked for a substitution variable to add it into the dlr-url but I can only find one for the internal kannel ID of the message. Have I missed it, or is it not possible? Its very useful to get this ID for any issues / reconciliation with the operator. currently there is no way to pass the SMPP message id to the upper layer (application layer, ie. smsbox). Reason: we want as much abstraction to the specific SMSC protocols as possible. But users claimed this issue to be required. Yes, the SMSC side ID is stored in the temp DLR data field 'ts' in order to match the DLR. We could think of transporting the SMSC side ID (message_id in SMPP, or OADC:teimstamp in EMI/UCP) back to smsbox layer. Any suggestions, comments from the list on this? The main question is: why? smsbox should abstract and your application layer wouldn't need that ID. If you have hassle with SMSC, then it's included in the bearerbox.log for reference. @Ben: can you describe a senseful scenario for this need? Stipe --- Kölner Landstrasse 419 40589 Düsseldorf, NRW, Germany tolj.org system architecture Kannel Software Foundation (KSF) http://www.tolj.org/ http://www.kannel.org/ mailto:st_{at}_tolj.org mailto:stolj_{at}_kannel.org ---
Re: Obtaining the message ID set by the SMSC
@Ben: can you describe a senseful scenario for this need? Sure, Let suppose you are sending reverse billed SMS messages, i.e. ones that you should get a share of the revenue from the operator for. At the end of the charging period they tell you how many chargeable message you sent. When you reconcile this with the number you actually sent, the chances of it matching are slim. If you have the DLR with the operators assigned ID you are then able to add a little more weight to your argument that supports your message counts not theirs. Its would also be useful for other support resolution issues, such as message that don't get delivered, by having the ID you can pass it to the operators TS people. Although I guess in this instance the ID would be available through the DLR table in the ts field. Regards Ben