123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178 |
- syntax = "v1"
- type CountReq {
- UserType int64 `json:"userType"`
- NewUserId int64 `header:"newUserId,optional"`
- EntUserId int64 `header:"entUserId,optional"`
- }
- type CountResp {
- Count int64 `json:"count"`
- ErrorCode int64 `json:"error_code"`
- ErrorMsg string `json:"error_msg"`
- }
- type UserReq {
- Phone string `json:"phone,optional"`
- UserType int64 `json:"userType"`
- StartTime string `json:"startTime,optional"`
- EndTime string `json:"endTime,optional"`
- NewUserId int64 `header:"newUserId"`
- EntId int64 `header:"entId,optional"`
- EntUserId int64 `header:"entUserId,optional"`
- Page int64 `json:"page,optional"`
- Size int64 `json:"size,optional"`
- IsArtificial int64 `json:"isArtificial,optional"`
- FiltrationId string `json:"filtrationId,optional"`
- }
- type MessageEntity {
- OwnType int64 `json:"ownType"`
- Title string `json:"title"`
- Content string `json:"content"`
- Item int64 `json:"item"`
- Type int64 `json:"type"`
- Link string `json:"link"`
- Appid string `header:"appId"`
- ItemType int64 `json:"itemType"`
- SendId string `json:"sendId,optional"`
- EntUserId int64 `header:"entUserId,optional"`
- NewUserId int64 `header:"newUserId"`
- ReceiveId string `json:"receiveId,optional"`
- }
- type MessageReq {
- MsgType int64 `json:"msgType"`
- UserType int64 `json:"userType"`
- SendId string `json:"sendId,optional"`
- LastId string `json:"lastId,optional"`
- PageSize int64 `json:"pageSize"`
- NewUserId int64 `header:"newUserId"`
- EntUserId int64 `header:"entUserId,optional"`
- EntId int64 `header:"entId,optional"`
- Sort string `json:"sort,optional"`
- ChatGroupId int64 `json:"chatGroupId,optional"`
- }
- type CommonRes {
- Error_code int `json:"error_code"`
- Error_msg string `json:"error_msg"`
- Data interface{} `json:"data"`
- Count int64 `json:"count"`
- }
- type ChatSessionReq {
- MsgType int64 `json:"msgType"`
- UserType int64 `json:"userType"`
- EntId int64 `header:"entId,optional"`
- AppId string `header:"appId"`
- ReceiveEntId string `json:"receiveEntId,optional"`
- EntUserId int64 `header:"entUserId,optional"`
- NewUserId int64 `header:"newUserId"`
- ReceiveAppId string `json:"receiveAppId,optional"`
- ReceiveId string `json:"receiveId,optional"`
- CustomerserviceName string `json:"customerserviceName,optional"`
- }
- type CloseSessionReq {
- SessionId string `json:"sessionId"`
- }
- type ShuntReq {
- Type string `json:"type"`
- }
- type ReadStateReq {
- MessageId string `json:"messageId"`
- EntUserId int64 `header:"entUserId,optional"`
- NewUserId int64 `header:"newUserId"`
- }
- type ChatGroupListReq {
- EntId int64 `header:"entId,optional"`
- UserName string `json:"userName"`
- GroupName string `json:"groupName"`
- PositionId int64 `header:"positionId,optional"`
- Appid string `header:"appId"`
- }
- type ChatGroupAddReq {
- EntId int64 `header:"entId,optional"`
- PositionId int64 `header:"positionId,optional"`
- UserIdArr []string `json:"userIdArr"`
- Appid string `header:"appId"`
- }
- type ChatGroupPersonReq {
- ChatGroupId string `json:"chatGroupId"`
- EntId int64 `header:"entId,optional"`
- Appid string `header:"appId"`
- }
- type ChatGroupJoinReq {
- ChatGroupId string `json:"chatGroupId"`
- PositionId int64 `json:"positionId"`
- Appid string `header:"appId"`
- UserIdArr []string `json:"userIdArr"`
- }
- type GroupNameUpdateReq {
- ChatGroupId string `json:"chatGroupId"`
- PositionId int64 `header:"positionId,optional"`
- GroupName string `json:"groupName"`
- Appid string `header:"appId"`
- }
- type GroupNoticeAddReq {
- ChatGroupId string `json:"chatGroupId"`
- Content string `json:"content"`
- Appid string `header:"appId"`
- }
- type GroupNoticeUpdateReq {
- Content string `json:"content"`
- GroupNoticeId string `json:"groupNoticeId"`
- Appid string `header:"appId"`
- }
- type ReadWithdrawReq {
- MessageId string `json:"messageId"`
- Appid string `header:"appid"`
- NewUserId int64 `header:"newUserId,optional"`
- EntUserId int64 `header:"entUserId,optional"`
- UserType int64 `json:"userType"`
- }
- type AppraiseMessageReq {
- EntId int64 `header:"entId,optional"`
- AppId string `header:"appId"`
- NewUserId int64 `header:"newUserId"`
- MessageId string `json:"messageId"`
- Appraise int64 `json:"appraise,options=-1|1"`
- }
- service messagecenter-api {
- @handler messageCount
- post /message/messageCount (CountReq) returns (CommonRes);
- @handler messageAdd
- post /message/messageAdd (MessageEntity) returns (CommonRes);
- @handler findMessage
- post /message/findMessage (MessageReq) returns (CommonRes);
- @handler userList
- post /message/userList (UserReq) returns (CommonRes);
- @handler createChatSession
- post /message/createChatSession (ChatSessionReq) returns (CommonRes);
- @handler closeChatSession
- post /message/closeChatSession (CloseSessionReq) returns (CommonRes);
- @handler obtainShunt
- post /message/obtainShunt (ShuntReq) returns (CommonRes);
- @handler updateReadById
- post /message/updateReadById (ReadStateReq) returns (CommonRes);
- @handler chatGroupList
- post /message/chatGroupList (ChatGroupListReq) returns (CommonRes);
- @handler chatGroupAdd
- post /message/chatGroupAdd (ChatGroupAddReq) returns (CommonRes);
- @handler chatGroupPerson
- post /message/chatGroupPerson (ChatGroupPersonReq) returns (CommonRes);
- @handler chatGroupJoin
- post /message/chatGroupJoin (ChatGroupJoinReq) returns (CommonRes);
- @handler groupNameUpdate
- post /message/groupNameUpdate (GroupNameUpdateReq) returns (CommonRes);
- @handler groupNoticeAdd
- post /message/groupNoticeAdd (GroupNoticeAddReq) returns (CommonRes);
- @handler groupNoticeUpdate
- post /message/groupNoticeUpdate (GroupNoticeUpdateReq) returns (CommonRes);
- @handler groupNoticeGet
- post /message/groupNoticeGet (ChatGroupPersonReq) returns (CommonRes);
- @handler withdrawMessage //撤回消息
- post /message/withdrawMessage (ReadWithdrawReq) returns (CommonRes);
- @handler AppraiseMessage // 消息评价
- post /message/appraiseMessage (AppraiseMessageReq) returns (CommonRes);
- @handler ConversationList // 会话列表
- post /message/conversationList (UserReq) returns (CommonRes);
- }
|