TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AliexpressLogisticsServiceQueryRequest req = new AliexpressLogisticsServiceQueryRequest();
AliexpressLogisticsServiceQueryRequest.AeopOnlineLogisticsServiceRequest obj1 = new AliexpressLogisticsServiceQueryRequest.AeopOnlineLogisticsServiceRequest();
List<AliexpressLogisticsServiceQueryRequest.Suborderlist> list3 = new ArrayList<AliexpressLogisticsServiceQueryRequest.Suborderlist>();
AliexpressLogisticsServiceQueryRequest.Suborderlist obj4 = new AliexpressLogisticsServiceQueryRequest.Suborderlist();
list3.add(obj4);
obj4.setGoodsWeight("0.1");
obj4.setGoodsLength(1L);
obj4.setGoodsHeight(1L);
obj4.setGoodsWidth(1L);
obj4.setLocale("zh_CN");
obj4.setOrderId(8001498863155804L);
obj1.setSubOrderList(list3);
obj1.setOrderId(8001498863145804L);
obj1.setGoodsLength(1L);
obj1.setGoodsWeight("0.1");
obj1.setGoodsHeight(1L);
obj1.setGoodsWidth(1L);
obj1.setLocale("zh_CN");
req.setInterfaceRequest(obj1);
AliexpressLogisticsServiceQueryResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());
ITopClient client = new DefaultTopClient(url, appkey, secret);
AliexpressLogisticsServiceQueryRequest req = new AliexpressLogisticsServiceQueryRequest();
AliexpressLogisticsServiceQueryRequest.AeopOnlineLogisticsServiceRequestDomain obj1 = new AliexpressLogisticsServiceQueryRequest.AeopOnlineLogisticsServiceRequestDomain();
List<AliexpressLogisticsServiceQueryRequest.SuborderlistDomain> list3 = new List<AliexpressLogisticsServiceQueryRequest.SuborderlistDomain>();
AliexpressLogisticsServiceQueryRequest.SuborderlistDomain obj4 = new AliexpressLogisticsServiceQueryRequest.SuborderlistDomain();
list3.Add(obj4);
obj4.GoodsWeight = "0.1";
obj4.GoodsLength = 1L;
obj4.GoodsHeight = 1L;
obj4.GoodsWidth = 1L;
obj4.Locale = "zh_CN";
obj4.OrderId = 8001498863155804L;
obj1.SubOrderList= list3;
obj1.OrderId = 8001498863145804L;
obj1.GoodsLength = 1L;
obj1.GoodsWeight = "0.1";
obj1.GoodsHeight = 1L;
obj1.GoodsWidth = 1L;
obj1.Locale = "zh_CN";
req.InterfaceRequest_ = obj1;
AliexpressLogisticsServiceQueryResponse rsp = client.Execute(req, sessionKey);
Console.WriteLine(rsp.Body);
$c = new TopClient;
$c->appkey = $appkey;
$c->secretKey = $secret;
$req = new AliexpressLogisticsServiceQueryRequest;
$interface_request = new AeopOnlineLogisticsServiceRequest;
$sub_order_list = new Suborderlist;
$sub_order_list->goods_weight="0.1";
$sub_order_list->goods_length="1";
$sub_order_list->goods_height="1";
$sub_order_list->goods_width="1";
$sub_order_list->locale="zh_CN";
$sub_order_list->order_id="8001498863155804";
$interface_request->sub_order_list = $sub_order_list;
$interface_request->order_id="8001498863145804";
$interface_request->goods_length="1";
$interface_request->goods_weight="0.1";
$interface_request->goods_height="1";
$interface_request->goods_width="1";
$interface_request->locale="zh_CN";
$req->setInterfaceRequest(json_encode($interface_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=aliexpress.logistics.service.query' \
-d 'partner_id=apidoc' \
-d 'session=acb36a6d-7b51-4189-b15e-2e324eb9c859' \
-d 'sign=C318364EFE0B3D6E2E59C908CBBD54CB' \
-d 'sign_method=hmac' \
-d 'timestamp=2025-02-04+14%3A50%3A45' \
-d 'v=2.0' \
-d 'interface_request=null'
# -*- coding: utf-8 -*-
import top.api
req=top.api.AliexpressLogisticsServiceQueryRequest(url,port)
req.set_app_info(top.appinfo(appkey,secret))
req.interface_request=""
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,"aliexpress.logistics.service.query");
add_param(pRequest,"interface_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',
'REST_URL': 'http://gw.api.taobao.com/router/rest'
});
client.execute('aliexpress.logistics.service.query', {
'interface_request':'数据结构JSON示例'
}, function(error, response) {
if (!error) console.log(response);
else console.log(error);
})