友米聚合 - 开放API
  1. ChatMess
友米聚合 - 开放API
  • 应用场景
    • 自有订单系统 嵌入 企客聊侧边栏
  • v1
    • 文档
      • 介绍
        • 开发文档阅读说明
        • 错误码返回说明
      • 入门说明
        • 生成signature
        • 获取TOKEN方法
        • 请求Headers说明
      • 接口详情
        • 基础数据类接口
        • 数据读取类接口
        • 行为操作类接口
        • 回调数据
  • v2
    • 事件发布格式说明
    • ChatMess
      • 发送消息
        POST
      • 申请接管
        POST
      • 终止接管
        POST
      • 激活会话
        POST
      • 发送通知
        POST
      • 读取聊天记录
        POST
    • Report
      • 获取员工客服统计
      • 获取员工激活客户数统计
    • System
      • 获取部门列表
      • 根据部门获得组
      • 根据组获得员工
      • 获得员工列表
    • Friend
      • 读取粉丝列表
      • 读取粉丝总数
    • Todo
      • 新增待办记录
      • 新增待办记录(返回编号)
      • 获取待办列表
      • 获取待办列表总数
    • Ad
      • 读取广告列表
      • 读取广告条数
    • BulkSend
      • 保存RPA群发
      • 删除RPA群发
    • 注册回调地址
      POST
    • 订阅事件
      POST
    • 获取商户TOKEN
      POST
  1. ChatMess

激活会话

POST
/v2/ChatMess/ActivationConversation
ChatMess

请求参数

Header 参数
Authorization
可选
授权TOKEN,Bearer
TenantId
可选
租户ID,仅限代理商使用
Body 参数application/json
object  | null 
可选
ad_friend_wenober
string 
好友原始微信号
可选
好友原始微信号
ad_original_nober
string 
运营机原始微信号
可选
运营机原始微信号;与运营机ID不能同时为空
ad_wechat_id
integer 
运营机ID
可选
运营机ID;与运营机原始微信号不能同时为空
staff_code
string 
激活或提醒的员工
可选
对应聚合聊天系统的员工号
enforceAttribution
integer 
是否强制归属
必需
是否强制归属(默认0不强制归属,1强制归属,不强制归属时只能激活归属自己好友的会话)
content
string 
提醒内容
必需
提醒的内容(activationType=1或activationType=2必传)
activationType
integer 
激活的类型
可选
0只激活会话,1激活会话并推送一条提醒消息,2激活会话并添加一条系统消息到聊天中
switchSession
integer 
是否切换会话
可选
0不切换,1切换
示例
{
  "ad_friend_wenober": "string",
  "ad_original_nober": "string",
  "ad_wechat_id": 0,
  "staff_code": "string",
  "enforceAttribution": 0,
  "content": "string",
  "activationType": 0,
  "switchSession": 0
}

示例代码

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST '/v2/ChatMess/ActivationConversation' \
--header 'Authorization;' \
--header 'TenantId;' \
--header 'Content-Type: application/json' \
--data-raw '{
    "ad_friend_wenober": "string",
    "ad_original_nober": "string",
    "ad_wechat_id": 0,
    "staff_code": "string",
    "enforceAttribution": 0,
    "content": "string",
    "activationType": 0,
    "switchSession": 0
}'

返回响应

🟢200Success
application/json
Body
requestId
string 
必需
errmsg
integer 
必需
succeed
boolean 
必需
msgTime
string 
必需
values
boolean 
提交成功/提交失败
必需
errdesc
string 
必需
示例
{
  "requestId": "string",
  "errmsg": 0,
  "succeed": true,
  "msgTime": "string",
  "values": true,
  "errdesc": "string"
}
上一页
终止接管
下一页
发送通知
Built with