The first step:
Using System;
Using System.Collections.Generic;
Using System.Linq;
Using System.Text;
Using System.Threading.Tasks;
Using Top.api;
Using Top.Api.Request;
Using Top.Api.Response;
Namespace Sqnum
{
public class Sendmsg
{
public string Sendmssage (string url,string appkey,string secret)
{
Itopclient client = new Defaulttopclient (URL, Appkey, secret);
Alibabaaliqinfcsmsnumsendrequest req = new Alibabaaliqinfcsmsnumsendrequest ();
Req. Extend = "123456";
Req. Smstype = "normal";
Req. Smsfreesignname = "Registration verification";
Req. Smsparam = "{\" code\ ": \" 1234\ ", \" product\ ": \" Ali big fish \ ", \" item\ ": \" Ali big Fish \ "}";
Req. Recnum = "012345678";
Req. Smstemplatecode = "sms_5087666";
Alibabaaliqinfcsmsnumsendresponse RSP = client. Execute (req);
Console.WriteLine (RSP. Body);
return RSP. Body;
}
}
}
Step Two:
Using System;
Using System.Collections.Generic;
Using System.Linq;
Using System.Management;
Using System.Text;
Using System.Threading.Tasks;
Namespace Sqnum
{
Class Program
{
static void Main (string[] args)
{
Numhelper numhelper = new Sqnum.numhelper ();
String str = Numhelper.getrnum ();
Console.WriteLine (str);
Console.readkey ();
Redishelper redishelper = new Redishelper ();
Redishelper.testredis ();
sendmsg sm = new sendmsg ();
string res = Sm. Sendmssage ("Http://gw.api.taobao.com/router/rest", "000000", "000000");
Console.WriteLine (RES);
Console.readkey ();
}
}
}
Appendix: Ali Big Fish official website: http://www.alidayu.com/
Ali Fish Registration SMS Send code