4

How to check for the delivery report of the sent message. I am using PHP and I have the SMPP account. Can somebody help me with the checking of delivery report?

Will I get a delivery report as message like we get in our mobile?
Or the status of the send function will do for it?

informatik01
  • 16,038
  • 10
  • 74
  • 104
Ranoy
  • 98
  • 2
  • 4
  • 17

3 Answers3

6

Using SMPP you can retrieve delivery report in the following ways.

First choice is to set registered_delivery parameter to 1 when you send submit_sm PDU.
In this case SMSC should send you deliver_sm PDU with esm_class = 0x04 containing delivery report.

Other way is to request delivery status with query_sm command but this may generate more traffic if polling SMSC too often.

informatik01
  • 16,038
  • 10
  • 74
  • 104
michael.bochkaryov
  • 2,318
  • 18
  • 14
  • Any example on python? – Gustavo Piris Feb 02 '18 at 14:20
  • @Gustavo Piris, the language doesn't matter.. just get an SMPP class and apply what he told you, you could think of the first choice as a normal message on phone, you set the reports to on and when the msg is delivered the provider will send you a delivery report. You just read that using the `deliver_sm` command. – bakz Apr 05 '18 at 00:10
1

SMS delivery receipts are regular SMS text messages generated by SMSC, but esm_class = 0x04 is used to differentiate them. The esm_class = 0x04 means PDU direction is SMSC > ESME and short message contains SMSC delivery receipt short message.

Short message area of deliver_sm SMPP PDU consists below text format which is encoded using dcs=0x00 data coding scheme (i.e. SMSC Default Alphabet according to the SMPP specification):

id:{message_id} 
sub:{message_sub}  
dlvrd:{message_dlvrd}
submit date:{message_submit_date} done  
date:{message_done_date} 
stat:{message_stat} 
err:{message_err}   

Sample delivery receipt message text:

id:40072910491427628 sub:001 dlvrd:001 submit date:1007291049 done date:1007291049 stat:DELIVRD err:000

Adding the following link here for details of processing the sample message above:

informatik01
  • 16,038
  • 10
  • 74
  • 104
Kemal Atik
  • 307
  • 3
  • 12
1

If you're asking about the format in which the Delivery_Receipt will be delivered back to the source then it's carried as the user data payload in the SMPP deliver_sm or data_sm operation.

The following fields are relevant in the deliver_sm and data_sm operations when used for transmitting delivery receipts:

• source address (i.e. source_addr_ton, source_addr_npi, source_addr)
• destination address (i.e. dest_addr_ton, dest_addr_npi, destination_addr)
• esm_class
• message_state
• network_error_code
• receipted_message_id
Eugene S
  • 6,709
  • 8
  • 57
  • 91