How to send USSD response

.NET library for SMPP protocol
Locked
amara
Posts: 1
Joined: Tue Jun 03, 2014 1:02 pm

How to send USSD response

Post by amara » Tue Jun 03, 2014 1:18 pm

Hi,

We came across your .net SMPP library, which works well for some of our purposes. We would like to send instant response to a user initiated USSD message in the same session. Kindly assist us with this.

Thanks,
alt
Site Admin
Posts: 985
Joined: Tue Apr 25, 2006 9:45 am

Re: How to send USSD response

Post by alt » Fri Jun 06, 2014 7:27 am

try this code

Code: Select all

  
string shortCode = "7777";
byte ussdSessionId = 0;
byte sessionEnd = 1;

_client.Submit(SMS.ForSubmit()
      .ServiceType("USSD")
      .From(shortCode, 3, 9)
      .To("+79171234567")
      .Text("USSD text")
      .Coding((DataCodings)0x15)
      .AddParameter(OptionalTags.UssdServiceOp, new byte[] { 17 }) //PSSR response
      .AddParameter(OptionalTags.ItsSessionInfo, new byte[] { ussdSessionId, sessionEnd })
 );
Locked