TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
TbkDgItemGroupMergeRequest req = new TbkDgItemGroupMergeRequest();
req.setSuperRedEnvelope(1L);
req.setNubmbers("2,3");
req.setCoupons("false [\"https://uland.taobao.com/coupon/edetail?e=123\",\"https://uland.taobao.com/quan/detail?sellerId=123&activityId=123\"]");
req.setItemIds("wojDmGmsMCeXQRGSBdYhbtd-jowwbqCvwGPMGgGTw6,v6K3mGVu8Co7AyKtPpzu0te-rYbbjPH2GvxnP38c5");
req.setAdzoneId("123123");
req.setRelationId("123123");
req.setPageId("20150318020015276");
TbkDgItemGroupMergeResponse rsp = client.execute(req);
System.out.println(rsp.getBody());
ITopClient client = new DefaultTopClient(url, appkey, secret);
TbkDgItemGroupMergeRequest req = new TbkDgItemGroupMergeRequest();
req.SuperRedEnvelope = 1L;
req.Nubmbers = "2,3";
req.Coupons = "false [\"https://uland.taobao.com/coupon/edetail?e=123\",\"https://uland.taobao.com/quan/detail?sellerId=123&activityId=123\"]";
req.ItemIds = "wojDmGmsMCeXQRGSBdYhbtd-jowwbqCvwGPMGgGTw6,v6K3mGVu8Co7AyKtPpzu0te-rYbbjPH2GvxnP38c5";
req.AdzoneId = "123123";
req.RelationId = "123123";
req.PageId = "20150318020015276";
TbkDgItemGroupMergeResponse rsp = client.Execute(req);
Console.WriteLine(rsp.Body);
$c = new TopClient;
$c->appkey = $appkey;
$c->secretKey = $secret;
$req = new TbkDgItemGroupMergeRequest;
$req->setSuperRedEnvelope("1");
$req->setNubmbers("2,3");
$req->setCoupons("false [\"https://uland.taobao.com/coupon/edetail?e=123\",\"https://uland.taobao.com/quan/detail?sellerId=123&activityId=123\"]");
$req->setItemIds("wojDmGmsMCeXQRGSBdYhbtd-jowwbqCvwGPMGgGTw6,v6K3mGVu8Co7AyKtPpzu0te-rYbbjPH2GvxnP38c5");
$req->setAdzoneId("123123");
$req->setRelationId("123123");
$req->setPageId("20150318020015276");
$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.dg.item.group.merge' \
-d 'partner_id=apidoc' \
-d 'sign=8C9A0AB67F2F42DE585DC3F7327E8BBF' \
-d 'sign_method=hmac' \
-d 'timestamp=2025-01-16+00%3A49%3A33' \
-d 'v=2.0' \
-d 'adzone_id=123123' \
-d 'coupons=false%09%5B%5C%22https%3A%2F%2Fuland.taobao.com%2Fcoupon%2Fedetail%3Fe%3D123%5C%22%2C%5C%22https%3A%2F%2Fuland.taobao.com%2Fquan%2Fdetail%3FsellerId%3D123%26activityId%3D123%5C%22%5D' \
-d 'item_ids=wojDmGmsMCeXQRGSBdYhbtd-jowwbqCvwGPMGgGTw6%2Cv6K3mGVu8Co7AyKtPpzu0te-rYbbjPH2GvxnP38c5' \
-d 'nubmbers=2%2C3' \
-d 'page_id=20150318020015276' \
-d 'relation_id=123123' \
-d 'super_red_envelope=1'
# -*- coding: utf-8 -*-
import top.api
req=top.api.TbkDgItemGroupMergeRequest(url,port)
req.set_app_info(top.appinfo(appkey,secret))
req.super_red_envelope=1
req.nubmbers="2,3"
req.coupons="false [\"https://uland.taobao.com/coupon/edetail?e=123\",\"https://uland.taobao.com/quan/detail?sellerId=123&activityId=123\"]"
req.item_ids="wojDmGmsMCeXQRGSBdYhbtd-jowwbqCvwGPMGgGTw6,v6K3mGVu8Co7AyKtPpzu0te-rYbbjPH2GvxnP38c5"
req.adzone_id="123123"
req.relation_id="123123"
req.page_id="20150318020015276"
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.dg.item.group.merge");
add_param(pRequest,"super_red_envelope","1");
add_param(pRequest,"nubmbers","2,3");
add_param(pRequest,"coupons","false [\"https://uland.taobao.com/coupon/edetail?e=123\",\"https://uland.taobao.com/quan/detail?sellerId=123&activityId=123\"]");
add_param(pRequest,"item_ids","wojDmGmsMCeXQRGSBdYhbtd-jowwbqCvwGPMGgGTw6,v6K3mGVu8Co7AyKtPpzu0te-rYbbjPH2GvxnP38c5");
add_param(pRequest,"adzone_id","123123");
add_param(pRequest,"relation_id","123123");
add_param(pRequest,"page_id","20150318020015276");
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.dg.item.group.merge', {
'super_red_envelope':'1',
'nubmbers':'2,3',
'coupons':'false [\"https://uland.taobao.com/coupon/edetail?e=123\",\"https://uland.taobao.com/quan/detail?sellerId=123&activityId=123\"]',
'item_ids':'wojDmGmsMCeXQRGSBdYhbtd-jowwbqCvwGPMGgGTw6,v6K3mGVu8Co7AyKtPpzu0te-rYbbjPH2GvxnP38c5',
'adzone_id':'123123',
'relation_id':'123123',
'page_id':'20150318020015276'
}, function(error, response) {
if (!error) console.log(response);
else console.log(error);
})