TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
TbkThorTaskSelectRequest req = new TbkThorTaskSelectRequest();
TbkThorTaskSelectRequest.TopSelectOption obj1 = new TbkThorTaskSelectRequest.TopSelectOption();
TbkThorTaskSelectRequest.TopDeviceDetail obj2 = new TbkThorTaskSelectRequest.TopDeviceDetail();
obj2.setIdfa("9C287922-EE26-4501-94B5-DDE6F83E1475");
obj2.setImeiMd5("52CF20235A5A6346");
obj2.setImei("358000046760359");
obj2.setOaid("47befdff-fb1f-4b96-ddff-bf3fb77f744e");
obj2.setMac("07-16-76-00-02-86");
obj1.setTopDeviceDetail(obj2);
obj1.setUnionSessionId("afcc931f750340c8a662623aa3966be9");
obj1.setPid("mm_234_43_64");
obj1.setClientId("524646");
obj1.setTaskId(124L);
req.setReq(obj1);
TbkThorTaskSelectResponse rsp = client.execute(req);
System.out.println(rsp.getBody());
ITopClient client = new DefaultTopClient(url, appkey, secret);
TbkThorTaskSelectRequest req = new TbkThorTaskSelectRequest();
TbkThorTaskSelectRequest.TopSelectOptionDomain obj1 = new TbkThorTaskSelectRequest.TopSelectOptionDomain();
TbkThorTaskSelectRequest.TopDeviceDetailDomain obj2 = new TbkThorTaskSelectRequest.TopDeviceDetailDomain();
obj2.Idfa = "9C287922-EE26-4501-94B5-DDE6F83E1475";
obj2.ImeiMd5 = "52CF20235A5A6346";
obj2.Imei = "358000046760359";
obj2.Oaid = "47befdff-fb1f-4b96-ddff-bf3fb77f744e";
obj2.Mac = "07-16-76-00-02-86";
obj1.TopDeviceDetail= obj2;
obj1.UnionSessionId = "afcc931f750340c8a662623aa3966be9";
obj1.Pid = "mm_234_43_64";
obj1.ClientId = "524646";
obj1.TaskId = 124L;
req.Req_ = obj1;
TbkThorTaskSelectResponse rsp = client.Execute(req);
Console.WriteLine(rsp.Body);
$c = new TopClient;
$c->appkey = $appkey;
$c->secretKey = $secret;
$req = new TbkThorTaskSelectRequest;
$req = new TopSelectOption;
$top_device_detail = new TopDeviceDetail;
$top_device_detail->idfa="9C287922-EE26-4501-94B5-DDE6F83E1475";
$top_device_detail->imei_md5="52CF20235A5A6346";
$top_device_detail->imei="358000046760359";
$top_device_detail->oaid="47befdff-fb1f-4b96-ddff-bf3fb77f744e";
$top_device_detail->mac="07-16-76-00-02-86";
$req->setTopDeviceDetail(json_encode($top_device_detail));
$req->union_session_id="afcc931f750340c8a662623aa3966be9";
$req->pid="mm_234_43_64";
$req->client_id="524646";
$req->task_id="124";
$req->setReq(json_encode($req));
$resp = $c->execute($req);
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.tbk.thor.task.select' \
-d 'partner_id=apidoc' \
-d 'sign=9D68A32FB4B80487F5A4C5843A8CD84B' \
-d 'sign_method=hmac' \
-d 'timestamp=2025-01-16+01%3A13%3A46' \
-d 'v=2.0' \
-d 'req=null'
# -*- coding: utf-8 -*-
import top.api
req=top.api.TbkThorTaskSelectRequest(url,port)
req.set_app_info(top.appinfo(appkey,secret))
req.req=""
try:
resp= req.getResponse()
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.tbk.thor.task.select");
add_param(pRequest,"req","数据结构JSON示例");
pResponse = top_execute(pClient,pRequest,NULL);
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('taobao.tbk.thor.task.select', {
'req':'数据结构JSON示例'
}, function(error, response) {
if (!error) console.log(response);
else console.log(error);
})