Bulk SMS India
+91 8305781001
support@smsindiahub.in

HOW TO DEVELOP ASP.NET (C#) API TO SEND SMS

What We Earned

SMSIndiaHub provide reliable services through well designed and thoroughly tested systems for ensuring client satisfation

  

4500000+

SMS Delivered (Per Day)
  

61000+

Satisfied Clients
  

1480+

Reseller Family

How to develop ASP.net (C#) API to Send SMS

using System
using System.IO
using System.Net
using System.Text
using System.Web
string sUser = “USERNAME”;
string spwd = “PASSWORD”;
string sNumber = Session[“Mobile”].ToString();
string sMessage = “Hi Thanks for Signing-up”;
string sSenderID = “WEBSMS”;
string sURL = “http://cloud.smsindiahub.in/vendorsms/pushsms.aspx?user=” + sUser + “&password=” + spwd + “&msisdn=” + sNumber + “&sid=” + sSenderID + “&msg=” + sMessage + “&fl=0?;
string sResponse = GetResponse(sURL);
Response.Write(sResponse);
public static string GetResponse(string sURL)
{
HttpWebRequest request = (HttpWebRequest)WebRequest
.Create(sURL);
request.MaximumAutomaticRedirections = 4;
request.Credentials = CredentialCache.DefaultCredentials;
try
{
HttpWebResponse response = (HttpWebResponse)request
.GetResponse();
Stream receiveStream = response.GetResponseStream(
);
StreamReader readStream = new StreamReader(receiveStream, Encoding.UTF8);
string sResponse = readStream.ReadToEnd();
response.Close();
readStream.Close();
return sResponse;
}
catch
{
return “”;
}
}

Note: For Transaction SMS Please add additional Parameter &gwid=2

Note: This is to update you that above code has been supplied to SMSINDIAHUB by clients. As such, accuracy is not guaranteed by SMSINDIAHUB.

Our Top Features for Sms Gateway

Unicode Message

Now send your messages in your regional langauage using special characters..

Flash SMS

Get your clients attracted from messages that are directly prompted on the mobile phone screen.

Developers API

Now integrate multiple API with SMPP and HTTP for sending SMS using web and desktop apps.

Scheduled SMS

Send messges to your clients automatically by our scheduling feature if you are not available.

Let’s create effective marketing strategies together