TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
RhinoCrmGatewayRequest req = new RhinoCrmGatewayRequest();
req.setFormCode("style_chance");
req.setOperateType("create");
req.setEventTimestamp(1670824757857L);
RhinoCrmGatewayRequest.CrmEntity obj1 = new RhinoCrmGatewayRequest.CrmEntity();
obj1.setGmtModified(StringUtils.parseDateTime("2022-12-01 11:00:00"));
obj1.setCreator("dd");
obj1.setInstanceId("123");
obj1.setCreatorDingUserId("12345");
obj1.setData("{}");
obj1.setModifierDingUserId("12345");
obj1.setModifier("dd");
obj1.setGmtCreate(StringUtils.parseDateTime("2022-12-01 11:00:00"));
req.setCrmEntity(obj1);
RhinoCrmGatewayResponse rsp = client.execute(req);
System.out.println(rsp.getBody());
ITopClient client = new DefaultTopClient(url, appkey, secret);
RhinoCrmGatewayRequest req = new RhinoCrmGatewayRequest();
req.FormCode = "style_chance";
req.OperateType = "create";
req.EventTimestamp = 1670824757857L;
RhinoCrmGatewayRequest.CrmEntityDomain obj1 = new RhinoCrmGatewayRequest.CrmEntityDomain();
obj1.GmtModified = DateTime.Parse(2022-12-01 11:00:00");
obj1.Creator = "dd";
obj1.InstanceId = "123";
obj1.CreatorDingUserId = "12345";
obj1.Data = "{}";
obj1.ModifierDingUserId = "12345";
obj1.Modifier = "dd";
obj1.GmtCreate = DateTime.Parse(2022-12-01 11:00:00");
req.CrmEntity_ = obj1;
RhinoCrmGatewayResponse rsp = client.Execute(req);
Console.WriteLine(rsp.Body);
$c = new TopClient;
$c->appkey = $appkey;
$c->secretKey = $secret;
$req = new RhinoCrmGatewayRequest;
$req->setFormCode("style_chance");
$req->setOperateType("create");
$req->setEventTimestamp("1670824757857");
$crm_entity = new CrmEntity;
$crm_entity->gmt_modified="2022-12-01 11:00:00";
$crm_entity->creator="dd";
$crm_entity->instance_id="123";
$crm_entity->creator_ding_user_id="12345";
$crm_entity->data="{}";
$crm_entity->modifier_ding_user_id="12345";
$crm_entity->modifier="dd";
$crm_entity->gmt_create="2022-12-01 11:00:00";
$req->setCrmEntity(json_encode($crm_entity));
$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.rhino.crm.gateway' \
-d 'partner_id=apidoc' \
-d 'sign=06797B0A14C6E6CD542272305A193A87' \
-d 'sign_method=hmac' \
-d 'timestamp=2025-04-25+15%3A58%3A07' \
-d 'v=2.0' \
-d 'crm_entity=null' \
-d 'event_timestamp=1670824757857' \
-d 'form_code=style_chance' \
-d 'operate_type=create'
# -*- coding: utf-8 -*-
import top.api
req=top.api.RhinoCrmGatewayRequest(url,port)
req.set_app_info(top.appinfo(appkey,secret))
req.form_code="style_chance"
req.operate_type="create"
req.event_timestamp=1670824757857
req.crm_entity="数据结构示例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,"taobao.rhino.crm.gateway");
add_param(pRequest,"form_code","style_chance");
add_param(pRequest,"operate_type","create");
add_param(pRequest,"event_timestamp","1670824757857");
add_param(pRequest,"crm_entity","数据结构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('taobao.rhino.crm.gateway', {
'form_code':'style_chance',
'operate_type':'create',
'event_timestamp':'1670824757857',
'crm_entity':'数据结构JSON示例'
}, function(error, response) {
if (!error) console.log(response);
else console.log(error);
})