cmdbff.api 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. syntax = "v1"
  2. info(
  3. title: "api前端服务"
  4. desc: "api前端服务 "
  5. author: "#Suyghur"
  6. version: "v1"
  7. )
  8. import (
  9. "bean.api"
  10. )
  11. @server(
  12. group: player
  13. prefix: api/v1/cmd
  14. jwt: JwtAuth
  15. )
  16. service cmdbff {
  17. @doc "玩家获取客服信息"
  18. @handler fetchCsInfo
  19. post /player/fetch-cs-info (PlayerFetchCsInfoReq) returns (PlayerFetchCsInfoResp)
  20. @doc "玩家获取历史消息"
  21. @handler fetchHistoryMsg
  22. post /player/fetch-history-msg (PlayerFetchHistoryMsgReq) returns (PlayerFetchHistoryMsgResp)
  23. @doc "玩家获取消息"
  24. @handler fetchMsg
  25. post /player/fetch-msg returns (PlayerFetchMsgResp)
  26. @doc "玩家发送消息"
  27. @handler sendMsg
  28. post /player/send-msg (PlayerSendMsgReq)
  29. @doc "玩家断开连接客服"
  30. @handler disconnect
  31. post /player/disconnect
  32. }
  33. @server(
  34. group : cs
  35. prefix : api/v1/cmd
  36. jwt : JwtAuth
  37. )
  38. service cmdbff {
  39. @doc "客服获取玩家等待队列"
  40. @handler fetchPlayerQueue
  41. post /cs/fetch-player-queue (CsFetchPlayerQueueReq) returns (CsFetchPlayerQueueResp)
  42. @doc "客服连接玩家"
  43. @handler connectPlayer
  44. post /cs/connect-player (CsConnectPlayerReq)
  45. @doc "客服获取历史会话列表"
  46. @handler fetchHistoryList
  47. post /cs/fetch-history-list (CsFetchHistoryChatReq) returns (CsFetchHistoryChatResp)
  48. @doc "客服获取历史消息"
  49. @handler fetchHistoryMsg
  50. post /cs/fetch-history-msg (CsFetchHistoryMsgReq) returns (CsFetchHistoryMsgResp)
  51. @doc "客服获取消息"
  52. @handler fetchMsg
  53. post /cs/fetch-msg (CsFetchMsgReq) returns (CsFetchMsgResp)
  54. @doc "客服发送消息"
  55. @handler sendMsg
  56. post /cs/send-msg (CsSendMsgReq)
  57. }