TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
SnManageConsignReportRequest req = new SnManageConsignReportRequest();
SnManageConsignReportRequest.TopSnConsignReportRequest obj1 = new SnManageConsignReportRequest.TopSnConsignReportRequest();
obj1.setMailNo("SF123456789");
obj1.setBizOrderId(123456789L);
List<SnManageConsignReportRequest.DeviceCodeInfoDTO> list3 = new ArrayList<SnManageConsignReportRequest.DeviceCodeInfoDTO>();
SnManageConsignReportRequest.DeviceCodeInfoDTO obj4 = new SnManageConsignReportRequest.DeviceCodeInfoDTO();
list3.add(obj4);
obj4.setSnCode("SN123123");
obj4.setImeiCode("IMEI12321");
obj1.setDeviceCodeList(list3);
obj1.setBizSceneCode("HNFK");
obj1.setBizSubOrderId(234567890L);
req.setTopSnConsignReportRequest(obj1);
SnManageConsignReportResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());
ITopClient client = new DefaultTopClient(url, appkey, secret);
SnManageConsignReportRequest req = new SnManageConsignReportRequest();
SnManageConsignReportRequest.TopSnConsignReportRequestDomain obj1 = new SnManageConsignReportRequest.TopSnConsignReportRequestDomain();
obj1.MailNo = "SF123456789";
obj1.BizOrderId = 123456789L;
List<SnManageConsignReportRequest.DeviceCodeInfoDTODomain> list3 = new List<SnManageConsignReportRequest.DeviceCodeInfoDTODomain>();
SnManageConsignReportRequest.DeviceCodeInfoDTODomain obj4 = new SnManageConsignReportRequest.DeviceCodeInfoDTODomain();
list3.Add(obj4);
obj4.SnCode = "SN123123";
obj4.ImeiCode = "IMEI12321";
obj1.DeviceCodeList= list3;
obj1.BizSceneCode = "HNFK";
obj1.BizSubOrderId = 234567890L;
req.TopSnConsignReportRequest_ = obj1;
SnManageConsignReportResponse rsp = client.Execute(req, sessionKey);
Console.WriteLine(rsp.Body);
$c = new TopClient;
$c->appkey = $appkey;
$c->secretKey = $secret;
$req = new SnManageConsignReportRequest;
$top_sn_consign_report_request = new TopSnConsignReportRequest;
$top_sn_consign_report_request->mail_no="SF123456789";
$top_sn_consign_report_request->biz_order_id="123456789";
$device_code_list = new DeviceCodeInfoDTO;
$device_code_list->sn_code="SN123123";
$device_code_list->imei_code="IMEI12321";
$top_sn_consign_report_request->device_code_list = $device_code_list;
$top_sn_consign_report_request->biz_scene_code="HNFK";
$top_sn_consign_report_request->biz_sub_order_id="234567890";
$req->setTopSnConsignReportRequest(json_encode($top_sn_consign_report_request));
$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=taobao.sn.manage.consign.report' \
-d 'partner_id=apidoc' \
-d 'session=63033a33-54fb-453c-8d20-8460bc0b47e3' \
-d 'sign=978100CFA264FD2EA050E5655B6B396D' \
-d 'sign_method=hmac' \
-d 'timestamp=2026-01-09+09%3A41%3A32' \
-d 'v=2.0' \
-d 'top_sn_consign_report_request=null'
# -*- coding: utf-8 -*-
import top.api
req=top.api.SnManageConsignReportRequest(url,port)
req.set_app_info(top.appinfo(appkey,secret))
req.top_sn_consign_report_request="数据结构示例JSON格式"
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,"taobao.sn.manage.consign.report");
add_param(pRequest,"top_sn_consign_report_request","数据结构JSON示例");
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',
'url': 'http://gw.api.taobao.com/router/rest'
});
client.execute('taobao.sn.manage.consign.report', {
'top_sn_consign_report_request':'数据结构JSON示例'
}, function(error, response) {
if (!error) console.log(response);
else console.log(error);
})