TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
XhotelOrderFutureInfoPutRequest req = new XhotelOrderFutureInfoPutRequest();
req.setOutUuid("123abc");
req.setOperateType(1L);
req.setHotelCode("HC01093");
req.setContext("<OrderInfo> <Order> <tid>12222</tid> <OutOrderId>r23323323</OutOrderId> <HotelCode>酒店编码</HotelCode> <Status>1</Status> </Order> <Order> <tid>12222</tid> <OutOrderId>r23323323</OutOrderId> <HotelCode>酒店编码</HotelCode> <Status>1</Status> </Order> </OrderInfo>");
req.setVendor("chinaonline");
req.setRequestId("132aaa1322");
XhotelOrderFutureInfoPutResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());
ITopClient client = new DefaultTopClient(url, appkey, secret);
XhotelOrderFutureInfoPutRequest req = new XhotelOrderFutureInfoPutRequest();
req.OutUuid = "123abc";
req.OperateType = 1L;
req.HotelCode = "HC01093";
req.Context = "<OrderInfo> <Order> <tid>12222</tid> <OutOrderId>r23323323</OutOrderId> <HotelCode>酒店编码</HotelCode> <Status>1</Status> </Order> <Order> <tid>12222</tid> <OutOrderId>r23323323</OutOrderId> <HotelCode>酒店编码</HotelCode> <Status>1</Status> </Order> </OrderInfo>";
req.Vendor = "chinaonline";
req.RequestId = "132aaa1322";
XhotelOrderFutureInfoPutResponse rsp = client.Execute(req, sessionKey);
Console.WriteLine(rsp.Body);
$c = new TopClient;
$c->appkey = $appkey;
$c->secretKey = $secret;
$req = new XhotelOrderFutureInfoPutRequest;
$req->setOutUuid("123abc");
$req->setOperateType("1");
$req->setHotelCode("HC01093");
$req->setContext("<OrderInfo> <Order> <tid>12222</tid> <OutOrderId>r23323323</OutOrderId> <HotelCode>酒店编码</HotelCode> <Status>1</Status> </Order> <Order> <tid>12222</tid> <OutOrderId>r23323323</OutOrderId> <HotelCode>酒店编码</HotelCode> <Status>1</Status> </Order> </OrderInfo>");
$req->setVendor("chinaonline");
$req->setRequestId("132aaa1322");
$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.xhotel.order.future.info.put' \
-d 'partner_id=apidoc' \
-d 'session=f9f46e56-e643-4292-b3b8-f172144350b0' \
-d 'sign=428CFF5FD703644B766A3EA6C2A1B0A0' \
-d 'sign_method=hmac' \
-d 'timestamp=2024-11-21+20%3A08%3A38' \
-d 'v=2.0' \
-d 'context=%3COrderInfo%3E++++%3COrder%3E+++++%3Ctid%3E12222%3C%2Ftid%3E+++++%3COutOrderId%3Er23323323%3C%2FOutOrderId%3E+++++%3CHotelCode%3E%E9%85%92%E5%BA%97%E7%BC%96%E7%A0%81%3C%2FHotelCode%3E+++++%3CStatus%3E1%3C%2FStatus%3E+++%3C%2FOrder%3E+++%3COrder%3E+++++%3Ctid%3E12222%3C%2Ftid%3E+++++%3COutOrderId%3Er23323323%3C%2FOutOrderId%3E+++++%3CHotelCode%3E%E9%85%92%E5%BA%97%E7%BC%96%E7%A0%81%3C%2FHotelCode%3E+++++%3CStatus%3E1%3C%2FStatus%3E+++%3C%2FOrder%3E+%3C%2FOrderInfo%3E' \
-d 'hotel_code=HC01093' \
-d 'operate_type=1' \
-d 'out_uuid=123abc' \
-d 'request_id=132aaa1322' \
-d 'vendor=chinaonline'
# -*- coding: utf-8 -*-
import top.api
req=top.api.XhotelOrderFutureInfoPutRequest(url,port)
req.set_app_info(top.appinfo(appkey,secret))
req.out_uuid="123abc"
req.operate_type=1
req.hotel_code="HC01093"
req.context="<OrderInfo> <Order> <tid>12222</tid> <OutOrderId>r23323323</OutOrderId> <HotelCode>酒店编码</HotelCode> <Status>1</Status> </Order> <Order> <tid>12222</tid> <OutOrderId>r23323323</OutOrderId> <HotelCode>酒店编码</HotelCode> <Status>1</Status> </Order> </OrderInfo>"
req.vendor="chinaonline"
req.request_id="132aaa1322"
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.xhotel.order.future.info.put");
add_param(pRequest,"out_uuid","123abc");
add_param(pRequest,"operate_type","1");
add_param(pRequest,"hotel_code","HC01093");
add_param(pRequest,"context","<OrderInfo> <Order> <tid>12222</tid> <OutOrderId>r23323323</OutOrderId> <HotelCode>酒店编码</HotelCode> <Status>1</Status> </Order> <Order> <tid>12222</tid> <OutOrderId>r23323323</OutOrderId> <HotelCode>酒店编码</HotelCode> <Status>1</Status> </Order> </OrderInfo>");
add_param(pRequest,"vendor","chinaonline");
add_param(pRequest,"request_id","132aaa1322");
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('taobao.xhotel.order.future.info.put', {
'out_uuid':'123abc',
'operate_type':'1',
'hotel_code':'HC01093',
'context':'<OrderInfo> <Order> <tid>12222</tid> <OutOrderId>r23323323</OutOrderId> <HotelCode>酒店编码</HotelCode> <Status>1</Status> </Order> <Order> <tid>12222</tid> <OutOrderId>r23323323</OutOrderId> <HotelCode>酒店编码</HotelCode> <Status>1</Status> </Order> </OrderInfo>',
'vendor':'chinaonline',
'request_id':'132aaa1322'
}, function(error, response) {
if (!error) console.log(response);
else console.log(error);
})