Is there a way to send SMS from an ASP.NET website using a Web API? I know about web services, but don't know how to call those services from my app.
You need to substitute the user name password and sender id in the respective places in the URL. You need to also specify the mobile number too in the URL. If you want to send the SMS to multiple numbers then you need to provide those numbers in comma-separated format. That's all!
A free SMS API allows you to set up an SMS gatewayto send SMS messages directly from a software or application solution. Thus, the integration of SMS sending requests in the heart of your algorithms allows you to automate the sending, receiving and control of SMS messages from your website or your business software.
Web services are the best way to do it. I use Twilio on a site, and it was incredibly easy to get set up and working. Scalability is no issue, and you will more than make up for the cost in not having to spend developer hours building your own solution.
Twilio: http://www.twilio.com/
Twilio libraries available for .NET: https://www.twilio.com/docs/csharp/install
From the twilio-csharp project, here is the example of how to send an SMS (I took this from twilio-csharp. Just reposting it to show how easy it is)
static void Main(string[] args) { TwilioRestClient client; // ACCOUNT_SID and ACCOUNT_TOKEN are from your Twilio account client = new TwilioRestClient(ACCOUNT_SID, ACCOUNT_TOKEN); var result = client.SendMessage(CALLER_ID, "PHONE NUMBER TO SEND TO", "The answer is 42"); if (result.RestException != null) { Debug.Writeline(result.RestException.Message); } }
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With