TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AlibabaTianmaoLanpeiUopCreateRequest req = new AlibabaTianmaoLanpeiUopCreateRequest();
AlibabaTianmaoLanpeiUopCreateRequest.HiErpOrderEvent obj1 = new AlibabaTianmaoLanpeiUopCreateRequest.HiErpOrderEvent();
AlibabaTianmaoLanpeiUopCreateRequest.HiErpOrderDTO obj2 = new AlibabaTianmaoLanpeiUopCreateRequest.HiErpOrderDTO();
obj2.setOutOrderCode("12341231");
obj2.setChannel("213");
obj2.setOwnerId(1234L);
obj2.setSellerNick("测试商家");
obj2.setOutSellerNick("外部测试商家");
obj2.setTradeId("123123");
obj2.setOrderType("0");
obj2.setOrderTime("2022-01-01 00:11:11");
obj2.setPayTime("2022-01-01 00:11:11");
obj2.setCipherText(false);
obj2.setBuyerMemo("测试买家留言");
obj2.setStoreCode("T10001");
obj2.setFeature("{\"key\":1, \"key1\": \"value1\"}");
obj2.setSellerMessage("测试卖家备注");
obj1.setHiErpOrderDto(obj2);
AlibabaTianmaoLanpeiUopCreateRequest.HiErpReceiverDTO obj3 = new AlibabaTianmaoLanpeiUopCreateRequest.HiErpReceiverDTO();
obj3.setReceiverName("张三");
obj3.setCellPhone("18900000000");
obj3.setTelePhone("0210000000");
obj3.setCountry("中国");
obj3.setProvince("浙江省");
obj3.setCity("杭州市");
obj3.setArea("西湖区");
obj3.setTown("测试街道");
obj3.setDetailAddress("测试地址");
obj3.setFeature("{\"key\":1, \"key1\": \"value1\"}");
obj1.setHiErpReceiverDto(obj3);
List<AlibabaTianmaoLanpeiUopCreateRequest.HiErpItemDTO> list5 = new ArrayList<AlibabaTianmaoLanpeiUopCreateRequest.HiErpItemDTO>();
AlibabaTianmaoLanpeiUopCreateRequest.HiErpItemDTO obj6 = new AlibabaTianmaoLanpeiUopCreateRequest.HiErpItemDTO();
list5.add(obj6);
obj6.setOutOrderItemId("123123");
obj6.setSubTradeId("123123");
obj6.setScItemId(123123L);
obj6.setScItemCode("123");
obj6.setItemAmount(123L);
obj6.setItemQty(123L);
obj6.setFeature("{\"key\":1, \"key1\": \"value1\"}");
obj1.setHiErpItemDtoList(list5);
req.setHiErpOrderEvent(obj1);
AlibabaTianmaoLanpeiUopCreateResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());
ITopClient client = new DefaultTopClient(url, appkey, secret);
AlibabaTianmaoLanpeiUopCreateRequest req = new AlibabaTianmaoLanpeiUopCreateRequest();
AlibabaTianmaoLanpeiUopCreateRequest.HiErpOrderEventDomain obj1 = new AlibabaTianmaoLanpeiUopCreateRequest.HiErpOrderEventDomain();
AlibabaTianmaoLanpeiUopCreateRequest.HiErpOrderDTODomain obj2 = new AlibabaTianmaoLanpeiUopCreateRequest.HiErpOrderDTODomain();
obj2.OutOrderCode = "12341231";
obj2.Channel = "213";
obj2.OwnerId = 1234L;
obj2.SellerNick = "测试商家";
obj2.OutSellerNick = "外部测试商家";
obj2.TradeId = "123123";
obj2.OrderType = "0";
obj2.OrderTime = "2022-01-01 00:11:11";
obj2.PayTime = "2022-01-01 00:11:11";
obj2.CipherText = false;
obj2.BuyerMemo = "测试买家留言";
obj2.StoreCode = "T10001";
obj2.Feature = "{\"key\":1, \"key1\": \"value1\"}";
obj2.SellerMessage = "测试卖家备注";
obj1.HiErpOrderDto= obj2;
AlibabaTianmaoLanpeiUopCreateRequest.HiErpReceiverDTODomain obj3 = new AlibabaTianmaoLanpeiUopCreateRequest.HiErpReceiverDTODomain();
obj3.ReceiverName = "张三";
obj3.CellPhone = "18900000000";
obj3.TelePhone = "0210000000";
obj3.Country = "中国";
obj3.Province = "浙江省";
obj3.City = "杭州市";
obj3.Area = "西湖区";
obj3.Town = "测试街道";
obj3.DetailAddress = "测试地址";
obj3.Feature = "{\"key\":1, \"key1\": \"value1\"}";
obj1.HiErpReceiverDto= obj3;
List<AlibabaTianmaoLanpeiUopCreateRequest.HiErpItemDTODomain> list5 = new List<AlibabaTianmaoLanpeiUopCreateRequest.HiErpItemDTODomain>();
AlibabaTianmaoLanpeiUopCreateRequest.HiErpItemDTODomain obj6 = new AlibabaTianmaoLanpeiUopCreateRequest.HiErpItemDTODomain();
list5.Add(obj6);
obj6.OutOrderItemId = "123123";
obj6.SubTradeId = "123123";
obj6.ScItemId = 123123L;
obj6.ScItemCode = "123";
obj6.ItemAmount = 123L;
obj6.ItemQty = 123L;
obj6.Feature = "{\"key\":1, \"key1\": \"value1\"}";
obj1.HiErpItemDtoList= list5;
req.HiErpOrderEvent_ = obj1;
AlibabaTianmaoLanpeiUopCreateResponse rsp = client.Execute(req, sessionKey);
Console.WriteLine(rsp.Body);
$c = new TopClient;
$c->appkey = $appkey;
$c->secretKey = $secret;
$req = new AlibabaTianmaoLanpeiUopCreateRequest;
$hi_erp_order_event = new HiErpOrderEvent;
$hi_erp_order_dto = new HiErpOrderDTO;
$hi_erp_order_dto->out_order_code="12341231";
$hi_erp_order_dto->channel="213";
$hi_erp_order_dto->owner_id="1234";
$hi_erp_order_dto->seller_nick="测试商家";
$hi_erp_order_dto->out_seller_nick="外部测试商家";
$hi_erp_order_dto->trade_id="123123";
$hi_erp_order_dto->order_type="0";
$hi_erp_order_dto->order_time="2022-01-01 00:11:11";
$hi_erp_order_dto->pay_time="2022-01-01 00:11:11";
$hi_erp_order_dto->cipher_text="false";
$hi_erp_order_dto->buyer_memo="测试买家留言";
$hi_erp_order_dto->store_code="T10001";
$hi_erp_order_dto->feature="{\"key\":1, \"key1\": \"value1\"}";
$hi_erp_order_dto->seller_message="测试卖家备注";
$hi_erp_order_event->hi_erp_order_dto = $hi_erp_order_dto;
$hi_erp_receiver_dto = new HiErpReceiverDTO;
$hi_erp_receiver_dto->receiver_name="张三";
$hi_erp_receiver_dto->cell_phone="18900000000";
$hi_erp_receiver_dto->tele_phone="0210000000";
$hi_erp_receiver_dto->country="中国";
$hi_erp_receiver_dto->province="浙江省";
$hi_erp_receiver_dto->city="杭州市";
$hi_erp_receiver_dto->area="西湖区";
$hi_erp_receiver_dto->town="测试街道";
$hi_erp_receiver_dto->detail_address="测试地址";
$hi_erp_receiver_dto->feature="{\"key\":1, \"key1\": \"value1\"}";
$hi_erp_order_event->hi_erp_receiver_dto = $hi_erp_receiver_dto;
$hi_erp_item_dto_list = new HiErpItemDTO;
$hi_erp_item_dto_list->out_order_item_id="123123";
$hi_erp_item_dto_list->sub_trade_id="123123";
$hi_erp_item_dto_list->sc_item_id="123123";
$hi_erp_item_dto_list->sc_item_code="123";
$hi_erp_item_dto_list->item_amount="123";
$hi_erp_item_dto_list->item_qty="123";
$hi_erp_item_dto_list->feature="{\"key\":1, \"key1\": \"value1\"}";
$hi_erp_order_event->hi_erp_item_dto_list = $hi_erp_item_dto_list;
$req->setHiErpOrderEvent(json_encode($hi_erp_order_event));
$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.tianmao.lanpei.uop.create' \
-d 'partner_id=apidoc' \
-d 'session=5043e63a-d3b4-4bd7-aa31-87e730de18fd' \
-d 'sign=2F4FCF77C4CD486D25B97BCCF3CAB31D' \
-d 'sign_method=hmac' \
-d 'timestamp=2025-05-04+15%3A24%3A00' \
-d 'v=2.0' \
-d 'hi_erp_order_event=null'
# -*- coding: utf-8 -*-
import top.api
req=top.api.AlibabaTianmaoLanpeiUopCreateRequest(url,port)
req.set_app_info(top.appinfo(appkey,secret))
req.hi_erp_order_event="数据结构示例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,"alibaba.tianmao.lanpei.uop.create");
add_param(pRequest,"hi_erp_order_event","数据结构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('alibaba.tianmao.lanpei.uop.create', {
'hi_erp_order_event':'数据结构JSON示例'
}, function(error, response) {
if (!error) console.log(response);
else console.log(error);
})