注意:以下文档只适用于TOP接口,请谨慎使用!

文档中心 > API类目 > 天猫汽车

tmall.aliauto.carprofile.sync (ISV同步增量车主档案至TM)

ISV同步增量车主档案至TM

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
list UserCarProfileDTO 必须 车主档案集合
  • └ car_license
  • String
  • 可选
  • 浙A8B7Y1
  • 车牌
  • └ acid
  • Number
  • 必须
  • 50006718
  • 五级车型ID
  • └ channel_profile_id
  • String
  • 必须
  • 1
  • ISV车辆档案ID
  • └ mileage
  • Number
  • 可选
  • 100
  • 里程
  • └ engine_no
  • String
  • 可选
  • 10001
  • 发动机号
  • └ reg_time
  • String
  • 可选
  • 2010-01-01 00:00:00
  • 行驶证注册时间
  • └ gmt_modified
  • Date
  • 必须
  • 2010-01-01 00:00:00
  • 更新时间
  • └ issue_time
  • String
  • 可选
  • 2010-01-01 00:00:00
  • 行驶证发证时间
  • └ car_vin
  • String
  • 可选
  • 1
  • VIN码
  • └ gmt_create
  • Date
  • 必须
  • 2010-01-01 00:00:00
  • 创建时间
  • └ operate_type
  • Number
  • 必须
  • 1
  • 操作类型。1-新增,2-更新,3-删除
  • └ car_profile_id
  • Number
  • 可选
  • 1
  • TM车辆档案ID
channel_id String 必须 1 ISV用户编号
channel_type Number 必须 1 ISV渠道类型。1-天猫养车
phone String 必须 1370000000 用户手机号
data_source String 可选 XKZ
  • 默认值:XKZ
  • 调用来源。例如:XKZ-新康众

    响应参数

    名称 类型 示例值 描述
    data UserCarProfileSyncResultDTO 1 业务结果
    • id_mapping
    • Entry []
    • id映射
    • └ channel_profile_id
    • String
    • 1
    • 1
    • └ car_profile_id
    • Number
    • 1
    • 1
    is_success Boolean true 业务结果
    errcode String 0000 错误代码
    errmsg String 错误信息 错误信息

    请求示例

    • JAVA
    • .NET
    • PHP
    • CURL
    • Python
    • C/C++
    • NodeJS
    TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
    TmallAliautoCarprofileSyncRequest req = new TmallAliautoCarprofileSyncRequest();
    TmallAliautoCarprofileSyncRequest.UserCarProfileDTO obj1 = new TmallAliautoCarprofileSyncRequest.UserCarProfileDTO();
    obj1.setCarLicense("浙A8B7Y1");
    obj1.setAcid(50006718L);
    obj1.setChannelProfileId("1");
    obj1.setMileage(100L);
    obj1.setEngineNo("10001");
    obj1.setRegTime("2010-01-01 00:00:00");
    obj1.setGmtModified(StringUtils.parseDateTime("2010-01-01 00:00:00"));
    obj1.setIssueTime("2010-01-01 00:00:00");
    obj1.setCarVin("1");
    obj1.setGmtCreate(StringUtils.parseDateTime("2010-01-01 00:00:00"));
    obj1.setOperateType(1L);
    obj1.setCarProfileId(1L);
    req.setList(obj1);
    req.setChannelId("1");
    req.setChannelType(1L);
    req.setPhone("1370000000");
    req.setDataSource("XKZ");
    TmallAliautoCarprofileSyncResponse rsp = client.execute(req, sessionKey);
    System.out.println(rsp.getBody());

    响应示例

    • XML示例
    • JSON示例
    <tmall_aliauto_carprofile_sync_response>
        <data>
            <id_mapping>
                <entry>
                    <channel_profile_id>1</channel_profile_id>
                    <car_profile_id>1</car_profile_id>
                </entry>
            </id_mapping>
        </data>
        <is_success>true</is_success>
        <errcode>0000</errcode>
        <errmsg>错误信息</errmsg>
    </tmall_aliauto_carprofile_sync_response>

    异常示例

    • XML示例
    • JSON示例
    <error_response>
        <code>50</code>
        <msg>Remote service error</msg>
        <sub_code>isv.invalid-parameter</sub_code>
        <sub_msg>非法参数</sub_msg>
    </error_response>

    错误码解释

    错误码 错误描述 解决方案

    API工具

    如何获得此API

    FAQ

    返回
    顶部