TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AuctionApplyAddRequest req = new AuctionApplyAddRequest();
req.setItemId(127612L);
AuctionApplyAddRequest.ApplyAuctionRequestDo obj1 = new AuctionApplyAddRequest.ApplyAuctionRequestDo();
obj1.setRealName("张三");
obj1.setPaidMoney(100L);
obj1.setPhone("18888888888");
obj1.setCardId("594011253898883");
obj1.setCardType(2L);
obj1.setContactAddress("浙江省杭州市余杭区阿里巴巴西溪园区A区");
obj1.setOutUserId("U_123");
obj1.setSignToken("sign_token_123");
obj1.setUserIp("192.168.1.1");
req.setApplyAuctionRequestDO(obj1);
AuctionApplyAddResponse rsp = client.execute(req);
System.out.println(rsp.getBody());
ITopClient client = new DefaultTopClient(url, appkey, secret);
AuctionApplyAddRequest req = new AuctionApplyAddRequest();
req.ItemId = 127612L;
AuctionApplyAddRequest.ApplyAuctionRequestDoDomain obj1 = new AuctionApplyAddRequest.ApplyAuctionRequestDoDomain();
obj1.RealName = "张三";
obj1.PaidMoney = 100L;
obj1.Phone = "18888888888";
obj1.CardId = "594011253898883";
obj1.CardType = 2L;
obj1.ContactAddress = "浙江省杭州市余杭区阿里巴巴西溪园区A区";
obj1.OutUserId = "U_123";
obj1.SignToken = "sign_token_123";
obj1.UserIp = "192.168.1.1";
req.ApplyAuctionRequestDO_ = obj1;
AuctionApplyAddResponse rsp = client.Execute(req);
Console.WriteLine(rsp.Body);
$c = new TopClient;
$c->appkey = $appkey;
$c->secretKey = $secret;
$req = new AuctionApplyAddRequest;
$req->setItemId("127612");
$apply_auction_request_d_o = new ApplyAuctionRequestDo;
$apply_auction_request_d_o->real_name="张三";
$apply_auction_request_d_o->paid_money="100";
$apply_auction_request_d_o->phone="18888888888";
$apply_auction_request_d_o->card_id="594011253898883";
$apply_auction_request_d_o->card_type="2";
$apply_auction_request_d_o->contact_address="浙江省杭州市余杭区阿里巴巴西溪园区A区";
$apply_auction_request_d_o->out_user_id="U_123";
$apply_auction_request_d_o->sign_token="sign_token_123";
$apply_auction_request_d_o->user_ip="192.168.1.1";
$req->setApplyAuctionRequestDO(json_encode($apply_auction_request_d_o));
$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.auction.apply.add' \
-d 'partner_id=apidoc' \
-d 'sign=B8BB12B3A8C5E8A56C78CF6F71E81616' \
-d 'sign_method=hmac' \
-d 'timestamp=2025-05-03+23%3A58%3A13' \
-d 'v=2.0' \
-d 'apply_auction_request_d_o=null' \
-d 'item_id=127612'
# -*- coding: utf-8 -*-
import top.api
req=top.api.AuctionApplyAddRequest(url,port)
req.set_app_info(top.appinfo(appkey,secret))
req.item_id=127612
req.apply_auction_request_d_o=""
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.auction.apply.add");
add_param(pRequest,"item_id","127612");
add_param(pRequest,"apply_auction_request_d_o","数据结构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.auction.apply.add', {
'item_id':'127612',
'apply_auction_request_d_o':'数据结构JSON示例'
}, function(error, response) {
if (!error) console.log(response);
else console.log(error);
})