Hi,
I'm trying to understand how to associate requests to the dlr-url with
the original message. I have patched kannel (I'm using version 1.4.3)
to return the SMS ID when a request is made to send a message to the
smsbox. So a request that looks like this:

[u...@localhost]$ curl
"http://127.0.0.1:13013/cgi-bin/sendsms?username=foo&password=bar&from=12345&to=4155551212&text=Hello+world&dlr-mask=31";

returns the following result:

0: Accepted for delivery: c8d487ac-181f-4f2e-97d7-ffb7abfe99b9

The SMS ID is the same that appears in the bearerbox logs:

2009-09-07 14:21:55 [14176] [8] DEBUG: boxc_receiver: sms received
2009-09-07 14:21:55 [14176] [8] DEBUG: DLR[internal]: Adding DLR
smsc=FAKE, ts=c8d487ac-181f-4f2e-97d7-ffb7abfe99b9, src=12345,
dst=4155551212, mask=31, boxc=
2009-09-07 14:21:55 [14176] [8] DEBUG: send_msg: sending msg to box: <127.0.0.1>
2009-09-07 14:21:55 [14176] [6] DEBUG: smsc_fake: sending message to client
2009-09-07 14:21:55 [14176] [6] DEBUG: SMSC[FAKE]: creating DLR message
2009-09-07 14:21:55 [14176] [6] DEBUG: SMSC[FAKE]: DLR =
2009-09-07 14:21:55 [14176] [6] DEBUG: DLR[internal]: Looking for DLR
smsc=FAKE, ts=c8d487ac-181f-4f2e-97d7-ffb7abfe99b9, dst=4155551212,
type=1
2009-09-07 14:21:55 [14176] [6] DEBUG: DLR[internal]: created DLR
message for URL <>
2009-09-07 14:21:55 [14176] [9] DEBUG: send_msg: sending msg to box: <127.0.0.1>
2009-09-07 14:21:55 [14176] [9] DEBUG: boxc_sender: sent message to <127.0.0.1>
2009-09-07 14:21:55 [14176] [9] DEBUG: send_msg: sending msg to box: <127.0.0.1>
2009-09-07 14:21:55 [14176] [9] DEBUG: boxc_sender: sent message to <127.0.0.1>
2009-09-07 14:21:55 [14176] [8] DEBUG: boxc_receiver: got ack
2009-09-07 14:21:55 [14176] [8] DEBUG: boxc_receiver: got ack
2009-09-07 14:21:56 [14176] [8] DEBUG: boxc_receiver: heartbeat with
load value 0 received

However, when I receive delivery reports to the dlr-url I have
specified ( dlr-url = http://localhost:1234/%d/%A/%I/%F ), I get
different SMS ID values. From the smsbox logs:

2009-09-07 14:21:55 [14184] [9] DEBUG: Parsing URL
`http://localhost:1234/8/ACK%2F/da3892f9-7f87-4b4f-ad37-041fbeca1bbb/':
2009-09-07 14:21:55 [14184] [9] DEBUG: Parsing URL
`http://localhost:1234/1//df3a088d-da98-43ab-be1e-f8d3083e9355/c8d487ac-181f-4f2e-97d7-ffb7abfe99b9':

Note that the %F value is the same as the original SMS ID only in some
delivery reports, and only when using the fakesmsc.

My question is, how am I supposed associate the delivery reports with
the original message, if the SMS ID changes?

Thanks,
Garth

Reply via email to