聊天-接收对话信息
开发中POST
/receiveChatMsg本接口时socketio的方式请求,不能直接是用当前接口进行mock
当前事件为客户端接收聊天信息,定义的返回数据就是聊天信息返回的内容
请求参数
Header 参数
Content-Type
string
必需
示例值:
application/json
authorization
string
可选
示例值:
{{Btoken}}
Body 参数application/json
object {0}
示例1
内容为空
示例代码
返回响应
成功(200)
HTTP 状态码: 200
内容格式: JSONapplication/json
数据结构
id
string
聊天消息id
from
string
发送人
fromAvatar
string
发送人头像
to
string
接收人
toAvatar
string
接收人头像
msgType
number
必需
消息的类型1文字
21卡片-患者病情 22卡片-处方信息 23未提交评价24已提交评价
31通知-普通通知(白底黑色)32通知-温馨提示33通知-订单取消(灰色底黑字)4图片
createTime
string
发送时间
msg
object
可选
聊天内容信息,有条件必须返回值
consultRecord
object
可选
msgType为21-患者病情信息
prescription
object
可选
msgType为22-处方信息
content
string
可选
文本类型内容-msgType为1或者3
picture
object
msgType为4
evaluateDoc
object
可选
msgType为24评价医生的信息
示例
{
"id": "string",
"from": "string",
"fromAvatar": "string",
"to": "string",
"toAvatar": "string",
"msgType": 0,
"createTime": "string",
"msg": {
"consultRecord": {
"id": "string",
"orderNo": "string",
"type": 0,
"createTime": "string",
"illnessDesc": "string",
"illnessTime": 0,
"consultFlag": 0,
"liverFunction": 0,
"renalFunction": 0,
"allergicHistory": 0,
"fertilityStatus": 0,
"pictures": [
{
"id": "string",
"url": "string"
}
],
"patientInfo": {
"id": "string",
"name": "string",
"idCard": "string",
"gender": 0,
"genderValue": "string",
"age": "string"
},
"medicines": [
{
"id": "string",
"name": "string",
"specs": "string",
"usageDosag": "string",
"quantity": 0
}
]
},
"prescription": {
"id": "string",
"createTime": "string",
"name": "string",
"recordId": "string",
"gender": 0,
"genderValue": "string",
"age": 0,
"diagnosis": "string",
"status": 1,
"medicines": [
{
"id": "string",
"name": "string",
"amount": "string",
"avatar": "string",
"specs": "string",
"usageDosag": "string",
"prescriptionFlag": 0,
"quantity": 0
}
],
"orderId": "string"
},
"content": "string",
"picture": {
"id": "string",
"url": "string"
},
"evaluateDoc": {
"id": "string",
"score": 0,
"content": "string",
"createTime": "string",
"creator": "string"
}
}
}
最后修改时间: 1 年前