TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AlibabaDecorationSkuPriceBranchSaveRequest req = new AlibabaDecorationSkuPriceBranchSaveRequest();
req.setSkuId("235086149575151616");
List<AlibabaDecorationSkuPriceBranchSaveRequest.OpenBranchPriceReq> list2 = new ArrayList<AlibabaDecorationSkuPriceBranchSaveRequest.OpenBranchPriceReq>();
AlibabaDecorationSkuPriceBranchSaveRequest.OpenBranchPriceReq obj3 = new AlibabaDecorationSkuPriceBranchSaveRequest.OpenBranchPriceReq();
list2.add(obj3);
obj3.setBranchId("asfasd");
obj3.setSellingPrice(12345L);
obj3.setMarketPrice(12321L);
obj3.setCostPrice(10000L);
req.setBranchPriceList(list2);
AlibabaDecorationSkuPriceBranchSaveResponse rsp = client.execute(req);
System.out.println(rsp.getBody());
ITopClient client = new DefaultTopClient(url, appkey, secret);
AlibabaDecorationSkuPriceBranchSaveRequest req = new AlibabaDecorationSkuPriceBranchSaveRequest();
req.SkuId = "235086149575151616";
List<AlibabaDecorationSkuPriceBranchSaveRequest.OpenBranchPriceReqDomain> list2 = new List<AlibabaDecorationSkuPriceBranchSaveRequest.OpenBranchPriceReqDomain>();
AlibabaDecorationSkuPriceBranchSaveRequest.OpenBranchPriceReqDomain obj3 = new AlibabaDecorationSkuPriceBranchSaveRequest.OpenBranchPriceReqDomain();
list2.Add(obj3);
obj3.BranchId = "asfasd";
obj3.SellingPrice = 12345L;
obj3.MarketPrice = 12321L;
obj3.CostPrice = 10000L;
req.BranchPriceList_ = list2;
AlibabaDecorationSkuPriceBranchSaveResponse rsp = client.Execute(req);
Console.WriteLine(rsp.Body);
$c = new TopClient;
$c->appkey = $appkey;
$c->secretKey = $secret;
$req = new AlibabaDecorationSkuPriceBranchSaveRequest;
$req->setSkuId("235086149575151616");
$branch_price_list = new OpenBranchPriceReq;
$branch_price_list->branch_id="asfasd";
$branch_price_list->selling_price="12345";
$branch_price_list->market_price="12321";
$branch_price_list->cost_price="10000";
$req->setBranchPriceList(json_encode($branch_price_list));
$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=alibaba.decoration.sku.price.branch.save' \
-d 'partner_id=apidoc' \
-d 'sign=D55B1BBF166A8B1CAC017717C6F05F0B' \
-d 'sign_method=hmac' \
-d 'timestamp=2025-05-15+13%3A46%3A27' \
-d 'v=2.0' \
-d 'branch_price_list=null' \
-d 'sku_id=235086149575151616'
# -*- coding: utf-8 -*-
import top.api
req=top.api.AlibabaDecorationSkuPriceBranchSaveRequest(url,port)
req.set_app_info(top.appinfo(appkey,secret))
req.sku_id="235086149575151616"
req.branch_price_list=""
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,"alibaba.decoration.sku.price.branch.save");
add_param(pRequest,"sku_id","235086149575151616");
add_param(pRequest,"branch_price_list","数据结构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('alibaba.decoration.sku.price.branch.save', {
'sku_id':'235086149575151616',
'branch_price_list':'数据结构JSON示例'
}, function(error, response) {
if (!error) console.log(response);
else console.log(error);
})