文档中心 > API类目 > 闲鱼电商SAAS

alibaba.idle.local.message.send (闲鱼同城IM消息发送)

闲鱼同城IM消息发送

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
message MessageDTO 必须 消息体
  • └ item_id
  • Number
  • 必须
  • 981938121131
  • 商品id
  • └ msg_type
  • String
  • 必须
  • 1001
  • 消息类型
  • └ msg_content
  • String
  • 必须
  • xxx
  • 消息内容
  • └ biz_type
  • Number
  • 必须
  • 1
  • 行业类型
  • └ encrypt_session_id
  • String
  • 必须
  • xxx
  • 加密会话id
  • └ encrypt_buyer_id
  • String
  • 必须
  • xxx
  • 加密买家id
  • └ encrypt_seller_id
  • String
  • 必须
  • xxx
  • 加密卖家id

响应参数

名称 类型 示例值 描述
result Result 结果
  • └ msg_id
  • String
  • xxxxx
  • 消息唯一id
  • └ success
  • Boolean
  • true
  • 请求结果
  • └ error_code
  • String
  • SYSTEM_ERROR
  • 错误码
  • └ error_msg
  • String
  • 系统错误
  • 错误信息

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AlibabaIdleLocalMessageSendRequest req = new AlibabaIdleLocalMessageSendRequest();
AlibabaIdleLocalMessageSendRequest.MessageDTO obj1 = new AlibabaIdleLocalMessageSendRequest.MessageDTO();
obj1.setItemId(981938121131L);
obj1.setMsgType("1001");
obj1.setMsgContent("xxx");
obj1.setBizType(1L);
obj1.setEncryptSessionId("xxx");
obj1.setEncryptBuyerId("xxx");
obj1.setEncryptSellerId("xxx");
req.setMessage(obj1);
AlibabaIdleLocalMessageSendResponse rsp = client.execute(req);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<alibaba_idle_local_message_send_response>
    <result>
        <msg_id>xxxxx</msg_id>
        <success>true</success>
        <error_code>SYSTEM_ERROR</error_code>
        <error_msg>系统错误</error_msg>
    </result>
</alibaba_idle_local_message_send_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

返回
顶部