TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AlibabaPurMediaStarIndexinfoRequest req = new AlibabaPurMediaStarIndexinfoRequest();
AlibabaPurMediaStarIndexinfoRequest.StarIndexInfoDTO obj1 = new AlibabaPurMediaStarIndexinfoRequest.StarIndexInfoDTO();
obj1.setPosiNegInfo("{ \"positive_index\":95.56, \"negative_index\":88.16 }");
obj1.setSource("yhzx");
obj1.setExtendInfo("扩展信息");
obj1.setHotSearchInfo("{ \"source\":\"weibo_hot\", \"title\":\"易烊千玺 我们三人合体就是亮点\", \"flag\":\"沸\", \"max_rank\":\"1\", \"max_hot_num\":\"3053674\", \"latest_rank\":\"50\", \"latest_hot_num\":\"73228\", \"url\":\"http://s.weibo.com/weibo?q=%E6%98%93%E7%83%8A%E5%8D%83%E7%8E%BA%20%E6%88%91%E4%BB%AC%E4%B8%89%E4%BA%BA%E5%90%88%E4%BD%93%E5%B0%B1%E6%98%AF%E4%BA%AE%E7%82%B9&Refer=top\" }");
obj1.setNewsInfo("{ \"newses\":\"32278\", \"medias\":\"222\" }");
obj1.setSearches("1597349");
obj1.setStarId("128068");
obj1.setStarName("易烊千玺");
obj1.setTopicInfo("{ \"title\":\"#抖音新农人#\", \"publish_date\":\"20220411\", \"discuss_count\":\"10000\", \"read_count\":\"3053674\", \"url\":\"http://s.weibo.com/weibo?q=%E6%98%93%E7%83%8A%E5%8D%83%E7%8E%BA%20%E6%88%91%E4%BB%AC%E4%B8%89%E4%BA%BA%E5%90%88%E4%BD%93%E5%B0%B1%E6%98%AF%E4%BA%AE%E7%82%B9&Refer=top\" }");
obj1.setMentionInfo("{ \"name_type\":\"\", \"name_form\":\"\", \"content_count\":\"10000\", \"fans_count\":\"10000\", \"word_count\":\"10000\", }");
obj1.setPlatform("wb");
obj1.setFansInfo("{ \"active_fans\":\"2628415\", \"red_fans\":\"1298208\", \"black_fans\":\"52656\", \"page_show_fans\":\"89605004\" }");
req.setStarIndexInfoList(obj1);
AlibabaPurMediaStarIndexinfoResponse rsp = client.execute(req);
System.out.println(rsp.getBody());
ITopClient client = new DefaultTopClient(url, appkey, secret);
AlibabaPurMediaStarIndexinfoRequest req = new AlibabaPurMediaStarIndexinfoRequest();
AlibabaPurMediaStarIndexinfoRequest.StarIndexInfoDTODomain obj1 = new AlibabaPurMediaStarIndexinfoRequest.StarIndexInfoDTODomain();
obj1.PosiNegInfo = "{ \"positive_index\":95.56, \"negative_index\":88.16 }";
obj1.Source = "yhzx";
obj1.ExtendInfo = "扩展信息";
obj1.HotSearchInfo = "{ \"source\":\"weibo_hot\", \"title\":\"易烊千玺 我们三人合体就是亮点\", \"flag\":\"沸\", \"max_rank\":\"1\", \"max_hot_num\":\"3053674\", \"latest_rank\":\"50\", \"latest_hot_num\":\"73228\", \"url\":\"http://s.weibo.com/weibo?q=%E6%98%93%E7%83%8A%E5%8D%83%E7%8E%BA%20%E6%88%91%E4%BB%AC%E4%B8%89%E4%BA%BA%E5%90%88%E4%BD%93%E5%B0%B1%E6%98%AF%E4%BA%AE%E7%82%B9&Refer=top\" }";
obj1.NewsInfo = "{ \"newses\":\"32278\", \"medias\":\"222\" }";
obj1.Searches = "1597349";
obj1.StarId = "128068";
obj1.StarName = "易烊千玺";
obj1.TopicInfo = "{ \"title\":\"#抖音新农人#\", \"publish_date\":\"20220411\", \"discuss_count\":\"10000\", \"read_count\":\"3053674\", \"url\":\"http://s.weibo.com/weibo?q=%E6%98%93%E7%83%8A%E5%8D%83%E7%8E%BA%20%E6%88%91%E4%BB%AC%E4%B8%89%E4%BA%BA%E5%90%88%E4%BD%93%E5%B0%B1%E6%98%AF%E4%BA%AE%E7%82%B9&Refer=top\" }";
obj1.MentionInfo = "{ \"name_type\":\"\", \"name_form\":\"\", \"content_count\":\"10000\", \"fans_count\":\"10000\", \"word_count\":\"10000\", }";
obj1.Platform = "wb";
obj1.FansInfo = "{ \"active_fans\":\"2628415\", \"red_fans\":\"1298208\", \"black_fans\":\"52656\", \"page_show_fans\":\"89605004\" }";
req.StarIndexInfoList_ = obj1;
AlibabaPurMediaStarIndexinfoResponse rsp = client.Execute(req);
Console.WriteLine(rsp.Body);
$c = new TopClient;
$c->appkey = $appkey;
$c->secretKey = $secret;
$req = new AlibabaPurMediaStarIndexinfoRequest;
$star_index_info_list = new StarIndexInfoDTO;
$star_index_info_list->posi_neg_info="{ \"positive_index\":95.56, \"negative_index\":88.16 }";
$star_index_info_list->source="yhzx";
$star_index_info_list->extend_info="扩展信息";
$star_index_info_list->hot_search_info="{ \"source\":\"weibo_hot\", \"title\":\"易烊千玺 我们三人合体就是亮点\", \"flag\":\"沸\", \"max_rank\":\"1\", \"max_hot_num\":\"3053674\", \"latest_rank\":\"50\", \"latest_hot_num\":\"73228\", \"url\":\"http://s.weibo.com/weibo?q=%E6%98%93%E7%83%8A%E5%8D%83%E7%8E%BA%20%E6%88%91%E4%BB%AC%E4%B8%89%E4%BA%BA%E5%90%88%E4%BD%93%E5%B0%B1%E6%98%AF%E4%BA%AE%E7%82%B9&Refer=top\" }";
$star_index_info_list->news_info="{ \"newses\":\"32278\", \"medias\":\"222\" }";
$star_index_info_list->searches="1597349";
$star_index_info_list->star_id="128068";
$star_index_info_list->star_name="易烊千玺";
$star_index_info_list->topic_info="{ \"title\":\"#抖音新农人#\", \"publish_date\":\"20220411\", \"discuss_count\":\"10000\", \"read_count\":\"3053674\", \"url\":\"http://s.weibo.com/weibo?q=%E6%98%93%E7%83%8A%E5%8D%83%E7%8E%BA%20%E6%88%91%E4%BB%AC%E4%B8%89%E4%BA%BA%E5%90%88%E4%BD%93%E5%B0%B1%E6%98%AF%E4%BA%AE%E7%82%B9&Refer=top\" }";
$star_index_info_list->mention_info="{ \"name_type\":\"\", \"name_form\":\"\", \"content_count\":\"10000\", \"fans_count\":\"10000\", \"word_count\":\"10000\", }";
$star_index_info_list->platform="wb";
$star_index_info_list->fans_info="{ \"active_fans\":\"2628415\", \"red_fans\":\"1298208\", \"black_fans\":\"52656\", \"page_show_fans\":\"89605004\" }";
$req->setStarIndexInfoList(json_encode($star_index_info_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.pur.media.star.indexinfo' \
-d 'partner_id=apidoc' \
-d 'sign=1467D1310C3BAB1730379B4C621968B5' \
-d 'sign_method=hmac' \
-d 'timestamp=2025-05-16+18%3A03%3A59' \
-d 'v=2.0' \
-d 'star_index_info_list=null'
# -*- coding: utf-8 -*-
import top.api
req=top.api.AlibabaPurMediaStarIndexinfoRequest(url,port)
req.set_app_info(top.appinfo(appkey,secret))
req.star_index_info_list="数据结构示例JSON格式"
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.pur.media.star.indexinfo");
add_param(pRequest,"star_index_info_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.pur.media.star.indexinfo', {
'star_index_info_list':'数据结构JSON示例'
}, function(error, response) {
if (!error) console.log(response);
else console.log(error);
})