文档中心 > API类目 > 场景金融保险

alibaba.fin.tao.insurance.pet.info.get (场景金融提供的宠物信息查询接口)

场景金融提供的宠物信息查询接口

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
param_pet_get_request PetGetRequest 必须 入参
  • customer
  • CustomerDTO
  • 必须
  • 用户信息
  • └ customer_type
  • String
  • 必须
  • ALI
  • 用户id类型
  • └ customer_id
  • String
  • 必须
  • 123456
  • 用户id
  • └ pet_id
  • String
  • 必须
  • 123456
  • 宠物id
  • └ product_code
  • String
  • 必须
  • PET_INSURANCE
  • 产品码
  • └ tenant
  • String
  • 必须
  • DTAO
  • 租户

响应参数

名称 类型 示例值 描述
result PetGetResponse 出参
  • pet_info
  • PetResultInfoDTO
  • 宠物信息
  • └ pet_age
  • String
  • 1天
  • 宠物年龄
  • └ pet_birthday
  • Date
  • 1472745600000
  • 宠物生日,年-月-日
  • └ pet_id
  • String
  • 123456
  • 宠物id
  • └ pet_image
  • String
  • https://img.alicdn.com/imgextra/i3/O1CN01tKFQL31RfFZDFieFW_!!0-mtopupload.jpg
  • 宠物头像
  • └ pet_nick
  • String
  • wangwang
  • 宠物昵称
  • └ pet_nobaby
  • Number
  • 1
  • 宠物是否绝育,0-否,1-是,2未知
  • └ pet_pics
  • String
  • json
  • 宠物照片
  • └ pet_sex
  • Number
  • 1
  • 宠物性别,1-男,2-女
  • └ pet_type
  • String
  • 1000
  • 宠物类型编码
  • └ pet_type_name
  • String
  • 挪威森林猫
  • 宠物类型名称
  • └ response_code
  • String
  • SYSTEM_ERROR
  • 错误编码
  • └ response_message
  • String
  • 系统异常
  • 错误信息
  • └ success
  • Boolean
  • true
  • 调用结果

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AlibabaFinTaoInsurancePetInfoGetRequest req = new AlibabaFinTaoInsurancePetInfoGetRequest();
AlibabaFinTaoInsurancePetInfoGetRequest.PetGetRequest obj1 = new AlibabaFinTaoInsurancePetInfoGetRequest.PetGetRequest();
AlibabaFinTaoInsurancePetInfoGetRequest.CustomerDTO obj2 = new AlibabaFinTaoInsurancePetInfoGetRequest.CustomerDTO();
obj2.setCustomerType("ALI");
obj2.setCustomerId("123456");
obj1.setCustomer(obj2);
obj1.setPetId("123456");
obj1.setProductCode("PET_INSURANCE");
obj1.setTenant("DTAO");
req.setParamPetGetRequest(obj1);
AlibabaFinTaoInsurancePetInfoGetResponse rsp = client.execute(req);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<alibaba_fin_tao_insurance_pet_info_get_response>
    <result>
        <pet_info>
            <pet_age>1天</pet_age>
            <pet_birthday>1472745600000</pet_birthday>
            <pet_id>123456</pet_id>
            <pet_image>https://img.alicdn.com/imgextra/i3/O1CN01tKFQL31RfFZDFieFW_!!0-mtopupload.jpg</pet_image>
            <pet_nick>wangwang</pet_nick>
            <pet_nobaby>1</pet_nobaby>
            <pet_pics>json</pet_pics>
            <pet_sex>1</pet_sex>
            <pet_type>1000</pet_type>
            <pet_type_name>挪威森林猫</pet_type_name>
        </pet_info>
        <response_code>SYSTEM_ERROR</response_code>
        <response_message>系统异常</response_message>
        <success>true</success>
    </result>
</alibaba_fin_tao_insurance_pet_info_get_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

返回
顶部