TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AlibabaAliqinFcUtilSmsNumSendRequest req = new AlibabaAliqinFcUtilSmsNumSendRequest();
req.setExtend("123456");
req.setSmsType("normal");
req.setSmsFreeSignName("阿里大鱼");
req.setSmsParamString("");
req.setRecNum("13000000000");
req.setSmsTemplateCode("SMS_585014");
AlibabaAliqinFcUtilSmsNumSendResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());
ITopClient client = new DefaultTopClient(url, appkey, secret);
AlibabaAliqinFcUtilSmsNumSendRequest req = new AlibabaAliqinFcUtilSmsNumSendRequest();
req.Extend = "123456";
req.SmsType = "normal";
req.SmsFreeSignName = "阿里大鱼";
req.SmsParam = "";
req.RecNum = "13000000000";
req.SmsTemplateCode = "SMS_585014";
AlibabaAliqinFcUtilSmsNumSendResponse rsp = client.Execute(req, sessionKey);
Console.WriteLine(rsp.Body);
$c = new TopClient;
$c->appkey = $appkey;
$c->secretKey = $secret;
$req = new AlibabaAliqinFcUtilSmsNumSendRequest;
$req->setExtend("123456");
$req->setSmsType("normal");
$req->setSmsFreeSignName("阿里大鱼");
$req->setSmsParam("");
$req->setRecNum("13000000000");
$req->setSmsTemplateCode("SMS_585014");
$resp = $c->execute($req, $sessionKey);
curl -X POST 'http://gw.api.taobao.com/router/rest' \
-H 'Content-Type:application/x-www-form-urlencoded;charset=utf-8' \
-d 'app_key=12129701' \
-d 'format=json' \
-d 'method=alibaba.aliqin.fc.util.sms.num.send' \
-d 'partner_id=apidoc' \
-d 'session=cdd640ca-17fb-4da9-8266-0dc264544f7f' \
-d 'sign=5248D6E2F04A03211FF4B2BE5944B4B0' \
-d 'sign_method=hmac' \
-d 'timestamp=2024-11-21+14%3A26%3A32' \
-d 'v=2.0' \
-d 'extend=123456' \
-d 'rec_num=13000000000' \
-d 'sms_free_sign_name=%E9%98%BF%E9%87%8C%E5%A4%A7%E9%B1%BC' \
-d 'sms_param=null' \
-d 'sms_template_code=SMS_585014' \
-d 'sms_type=normal'
# -*- coding: utf-8 -*-
import top.api
req=top.api.AlibabaAliqinFcUtilSmsNumSendRequest(url,port)
req.set_app_info(top.appinfo(appkey,secret))
req.extend="123456"
req.sms_type="normal"
req.sms_free_sign_name="阿里大鱼"
req.sms_param=""
req.rec_num="13000000000"
req.sms_template_code="SMS_585014"
try:
resp= req.getResponse(sessionkey)
print(resp)
except Exception,e:
print(e)
pTopRequest pRequest = alloc_top_request();
pTopResponse pResponse = NULL;
pTaobaoClient pClient = alloc_taobao_client(url, appkey, appsecret);
set_api_name(pRequest,"alibaba.aliqin.fc.util.sms.num.send");
add_param(pRequest,"extend","123456");
add_param(pRequest,"sms_type","normal");
add_param(pRequest,"sms_free_sign_name","阿里大鱼");
add_param(pRequest,"sms_param","");
add_param(pRequest,"rec_num","13000000000");
add_param(pRequest,"sms_template_code","SMS_585014");
pResponse = top_execute(pClient,pRequest,sessionKey);
printf("ret code:%d\n",pResponse->code);
if(pResponse->code == 0){
pTopResponseIterator ite = init_response_iterator(pResponse);
pResultItem pResultItem = alloc_result_item();
while(parseNext(ite, pResultItem) == 0){
printf("%s:%s\n",pResultItem->key,pResultItem->value);
}
destroy_response_iterator(ite);
destroy_result_item(pResultItem);
}
destroy_top_request(pRequest);
destroy_top_response(pResponse);
destroy_taobao_client(pClient);
TopClient = require('./topClient').TopClient;
var client = new TopClient({
'appkey': 'appkey',
'appsecret': 'secret',
'REST_URL': 'http://gw.api.taobao.com/router/rest'
});
client.execute('alibaba.aliqin.fc.util.sms.num.send', {
'extend':'123456',
'sms_type':'normal',
'sms_free_sign_name':'阿里大鱼',
'sms_param':'',
'rec_num':'13000000000',
'sms_template_code':'SMS_585014'
}, function(error, response) {
if (!error) console.log(response);
else console.log(error);
})