TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
TbkScUvidEncryptRequest req = new TbkScUvidEncryptRequest();
req.setTkDomain(1L);
req.setSourceType(1L);
req.setSourceValues("123,123");
req.setMainAccountid(1231231L);
req.setDeviceType("1");
req.setDeviceValue("cdcd-21312-dc");
req.setCaidVersion("20211113");
TbkScUvidEncryptResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());
ITopClient client = new DefaultTopClient(url, appkey, secret);
TbkScUvidEncryptRequest req = new TbkScUvidEncryptRequest();
req.TkDomain = 1L;
req.SourceType = 1L;
req.SourceValues = "123,123";
req.MainAccountid = 1231231L;
req.DeviceType = "1";
req.DeviceValue = "cdcd-21312-dc";
req.CaidVersion = "20211113";
TbkScUvidEncryptResponse rsp = client.Execute(req, sessionKey);
Console.WriteLine(rsp.Body);
$c = new TopClient;
$c->appkey = $appkey;
$c->secretKey = $secret;
$req = new TbkScUvidEncryptRequest;
$req->setTkDomain("1");
$req->setSourceType("1");
$req->setSourceValues("123,123");
$req->setMainAccountid("1231231");
$req->setDeviceType("1");
$req->setDeviceValue("cdcd-21312-dc");
$req->setCaidVersion("20211113");
$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.tbk.sc.uvid.encrypt' \
-d 'partner_id=apidoc' \
-d 'session=ea2a10da-7e9a-439e-8dde-1265bfa7e9e5' \
-d 'sign=27B12E89B7505D159D67AE09458A0D48' \
-d 'sign_method=hmac' \
-d 'timestamp=2025-01-16+01%3A03%3A25' \
-d 'v=2.0' \
-d 'caid_version=20211113' \
-d 'device_type=1' \
-d 'device_value=cdcd-21312-dc' \
-d 'main_accountid=1231231' \
-d 'source_type=1' \
-d 'source_values=123%2C123' \
-d 'tk_domain=1'
# -*- coding: utf-8 -*-
import top.api
req=top.api.TbkScUvidEncryptRequest(url,port)
req.set_app_info(top.appinfo(appkey,secret))
req.tk_domain=1
req.source_type=1
req.source_values="123,123"
req.main_accountid=1231231
req.device_type="1"
req.device_value="cdcd-21312-dc"
req.caid_version="20211113"
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.tbk.sc.uvid.encrypt");
add_param(pRequest,"tk_domain","1");
add_param(pRequest,"source_type","1");
add_param(pRequest,"source_values","123,123");
add_param(pRequest,"main_accountid","1231231");
add_param(pRequest,"device_type","1");
add_param(pRequest,"device_value","cdcd-21312-dc");
add_param(pRequest,"caid_version","20211113");
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.tbk.sc.uvid.encrypt', {
'tk_domain':'1',
'source_type':'1',
'source_values':'123,123',
'main_accountid':'1231231',
'device_type':'1',
'device_value':'cdcd-21312-dc',
'caid_version':'20211113'
}, function(error, response) {
if (!error) console.log(response);
else console.log(error);
})