bxsubscribe.proto 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463
  1. syntax = "proto3";
  2. //import "google/protobuf/struct.proto";
  3. package bxsubscribe;
  4. option go_package = "./bxsubscribe";
  5. message SubscribeInfosReq {
  6. int64 pageNum = 1;
  7. int64 pageSize = 2;
  8. string selectTime = 3;
  9. string area = 4;
  10. string city = 5;
  11. string industry = 6;
  12. string buyerClass = 7;
  13. string keyWords = 8;
  14. string subtype = 9;
  15. string userType = 10;//fType:普通用户;vType:超级订阅用户;mType:大会员用户;eType:商机管理用户;
  16. string userId = 11;
  17. string entId = 12;
  18. string appId = 13;
  19. string price = 14;
  20. string fileExists = 15;
  21. string isRead = 16; //是否已读
  22. string staffs = 17;//分发人员
  23. string source = 18; //信息来源
  24. string entUserId = 19;
  25. string deptId = 20;
  26. int64 newUserId = 21;
  27. bool IsEnt = 22;
  28. string SelectIds = 23;
  29. int64 positionType = 24;
  30. string accountId = 25; //账户id
  31. string positionId = 26; //职位id
  32. string mgoUserId = 27; //原userId
  33. int64 notReturnCount = 28;
  34. string item = 29;
  35. string selectKeys = 30;
  36. string district = 31;
  37. string stag = 32;
  38. }
  39. message SubscribeInfosResp {
  40. int64 err_code = 1;
  41. string err_msg = 2;
  42. subscribeData data = 3;
  43. }
  44. message subscribeData{
  45. int64 count = 1;
  46. bool hasNextPage = 2;
  47. repeated subscribeInfo list = 3;
  48. string isRecommend = 4;
  49. }
  50. message subscribeInfo {
  51. string _id = 1;//和推送程序 缓存保持一致
  52. string title = 2;
  53. string area = 3;
  54. string buyerClass = 4;
  55. string subtype = 5;
  56. string industry = 6;
  57. int64 publishTime = 7;
  58. int64 ca_index = 8;
  59. int64 ca_date = 9;
  60. int64 ca_isvisit = 10;
  61. int64 ca_type = 11;
  62. repeated string matchKeys = 12;
  63. double budget = 13;// 预算
  64. double bidAmount = 14;
  65. int64 collection = 15;
  66. string buyer = 16;
  67. string projectName = 17;
  68. string winner = 18;
  69. int64 bidOpenTime = 19;
  70. int64 ca_isvip = 20;
  71. bool ca_fileExists = 21;
  72. int64 source = 22;//来源;1:个人订阅 2:企业自动分发 3:企业手动分发
  73. string site = 23; // 网站名称
  74. string buyerTel = 24; // 采购单位联系方式
  75. string buyerPerson = 25; // 采购单位联系人
  76. string agency = 26;//代理机构
  77. string agencyPerson = 27;//代理机构联系人
  78. string agencyTel = 28;//代理机构联系电话
  79. int64 signendTime = 29 ;// 报名截止日期
  80. int64 bidendTime = 30;// 投标截止日期
  81. repeated WinnerInfo winnerInfo = 31;// 中标企业信息
  82. string spiderCode = 33;//网站代码
  83. string city = 34; //城市
  84. string toptype = 35; //一级信息类型
  85. bool isValidFile = 36; //是否有附件
  86. string sourceAll = 37; //来源;1:个人订阅 2:企业自动分发 3:企业手动分发 多个
  87. }
  88. //
  89. message WinnerInfo{
  90. string winner = 1;
  91. string winnerTel = 2;
  92. string winnerPerson = 3;
  93. string winnerId = 4;
  94. }
  95. //
  96. message SomeInfoReq{
  97. string appId = 1;
  98. string userId = 2;
  99. string userType = 3;
  100. string newUserId = 4;
  101. string entId = 5;
  102. string accountId = 6;
  103. string positionType = 7;
  104. string positionId = 8;
  105. }
  106. message SomeInfoResp {
  107. int64 err_code = 1;
  108. string err_msg = 2;
  109. SomeInfo data = 3;
  110. }
  111. message SomeInfo{
  112. bool hasKey = 1;//免费用户和超级订阅是否有订阅词
  113. bool isInTSguide = 2;//是否进入向导
  114. int64 isExpire = 3;//超级订阅到期提醒
  115. int64 isOnTail = 4;//超级订阅试用状态
  116. bool isPassCount = 5;//推送数量校验
  117. bool otherFlag = 6;//首次用户推送查询“其他”
  118. bool isRead = 7;//某个通知??是否已读
  119. repeated string industry = 8;//会员订阅的行业
  120. string userId = 9;//用户id
  121. }
  122. //
  123. message StatusResp{
  124. string error_msg = 1;
  125. int64 error_code = 2;
  126. int64 status = 3;
  127. }
  128. message ByPushHistoryResp{
  129. string error_msg = 1;
  130. int64 error_code = 2;
  131. string data = 3;
  132. }
  133. message UpdateSubScribeInfoReq{
  134. bytes subSet = 1;//订阅设置
  135. string userId = 2;//用户id
  136. int64 PositionType = 3;
  137. int64 positionId = 4;
  138. int64 baseUserId = 5;
  139. }
  140. //城市
  141. message CityList {
  142. repeated string city = 1;
  143. }
  144. //分类
  145. message Items{
  146. string s_item = 1;//分类名称
  147. int64 updateTime = 2;
  148. repeated Keys a_key = 3;
  149. }
  150. //关键词
  151. message Keys {
  152. repeated string key = 1;
  153. repeated string notkey = 2;
  154. int64 updateTime = 3;
  155. int64 matchway = 4;
  156. repeated string appendKey = 5;
  157. }
  158. message KeyItems{
  159. string s_item = 1;//分类名称
  160. int64 updateTime = 2;
  161. repeated Key a_key = 3;
  162. }
  163. //关键词
  164. message Key {
  165. repeated string key = 1;
  166. repeated string notkey = 2;
  167. int64 updateTime = 3;
  168. int64 matchway = 4;
  169. repeated string appendkey = 5;
  170. }
  171. message SetReadReq{
  172. string appId = 1;
  173. string userId = 2;
  174. string userType = 3;
  175. int64 vsid = 4;
  176. string EntId = 5;
  177. int64 newUserId = 6;
  178. string entUserId = 7;
  179. bool isEnt = 8;
  180. int64 positionType = 9;
  181. }
  182. message GetKeyReq{
  183. string appId = 1;
  184. string userId = 2;
  185. string userType = 3;
  186. string entId = 5;
  187. int64 newUserId = 6;
  188. string entUserId = 7;
  189. bool isEnt = 8;
  190. int64 vipPower = 4;
  191. int64 memberPower = 10;
  192. int64 powerSource = 11;
  193. int64 userPower = 12;
  194. string deptId = 13;
  195. int64 positionType = 14;
  196. }
  197. message GetDistributorReq{
  198. string appId = 1;
  199. string entId = 2;
  200. string entUserId = 3;
  201. string region = 4;
  202. string selectIds = 5;
  203. string queryType = 6;
  204. }
  205. message MsgDistributorReq{
  206. string appId = 1;
  207. string entId = 2;
  208. string entUserId = 3;
  209. string messageId = 4;//分发信息
  210. string staffs = 5; //分发的员工
  211. }
  212. message KeyResp {
  213. int64 err_code = 1;
  214. string err_msg = 2;
  215. repeated KeyItems items = 3;//关键词
  216. }
  217. message List{
  218. repeated string value = 1;
  219. }
  220. //订阅设置
  221. message Subscribe{
  222. map<string, List> area = 1;//地区
  223. repeated string buyerclass = 2;//采购单位类型
  224. repeated string infotype = 3;//信息类型
  225. repeated Items items = 4;//关键词
  226. int64 matchway = 5;//匹配方式 1标题 2正文
  227. int64 projectmatch = 6;//项目匹配
  228. bool keytip = 7;
  229. }
  230. message UserReq{
  231. string appId = 1;
  232. int64 entUserId = 2;
  233. string types = 3;//类型,不传按默认规则获取 m大会员 e商机管理 v超级订阅 f免费订阅
  234. int64 positionType = 4;//职位类型 0个人 1企业
  235. string userId = 5;
  236. int64 entId = 6;
  237. }
  238. //用户权益
  239. message UserResq{
  240. Subscribe data = 1;
  241. string error_msg = 2;
  242. int64 error_code = 3;
  243. }
  244. message DistributorResp {
  245. int64 err_code = 1;
  246. string err_msg = 2;
  247. repeated userResp items = 3;//分发人员
  248. }
  249. message userResp {
  250. string name = 1;
  251. int64 id = 2;
  252. string phone = 3;
  253. }
  254. message GetViewStatusReq{
  255. string appId = 1;
  256. string entId = 2;
  257. string entUserId = 3;
  258. string infoId = 4;
  259. }
  260. message ViewStatusResp {
  261. int64 err_code = 1;
  262. string err_msg = 2;
  263. repeated UserStatus items = 3;//分发人员
  264. }
  265. message UserStatus {
  266. string name = 1;
  267. int64 id = 2;
  268. int64 isvisit = 3;
  269. string visittime = 4;
  270. string date = 5;
  271. string phone = 6;
  272. int64 source = 7;
  273. }
  274. message GetUserInfoReq{
  275. string appId = 1;
  276. int64 entId = 2;
  277. int64 entUserId = 3;
  278. string userId = 4;
  279. int64 positionType = 5;
  280. int64 baseUserId = 6;
  281. string serviceType = 7;
  282. }
  283. message GetUserInfoResq{
  284. GetUserInfo data = 1;
  285. string error_msg = 2;
  286. int64 error_code = 3;
  287. }
  288. message GetUserInfo{
  289. string mail = 1;
  290. int64 state = 2;
  291. string imgUrl = 3;
  292. string appUrl = 4;
  293. bool showWx = 5;
  294. }
  295. message SetUserInfoReq{
  296. string appId = 1;
  297. int64 entId = 2;
  298. int64 entUserId = 3;
  299. string userId = 4;
  300. int64 positionType = 5;
  301. string mail = 6;
  302. }
  303. message GetPushSetReq{
  304. string appId = 1;
  305. int64 entId = 2;
  306. int64 entUserId = 3;
  307. string userId = 4;
  308. int64 positionType = 5;
  309. int64 positionId = 6;
  310. int64 accountId = 7;
  311. int64 baseUserId = 8;
  312. string mgoUserId = 9; //原userId
  313. }
  314. message GetPushSetResp{
  315. map<string, PushSet> data = 1;
  316. map<int64, TimeJson> timeData = 3;
  317. string error_msg = 4;
  318. int64 error_code = 5;
  319. }
  320. message TimeJson{
  321. repeated string a_times = 1;
  322. }
  323. message PushSet{
  324. repeated string a_times = 1;
  325. int64 i_wxpush = 2;
  326. int64 i_apppush = 3;
  327. int64 i_mailpush = 4;
  328. int64 i_ratemode = 5;
  329. int64 isWxShow = 6;
  330. int64 interested = 7;
  331. int64 isMailShow = 8;
  332. int64 i_nomsgtip = 9;
  333. int64 i_apppush_tip = 10;
  334. }
  335. message SetPushSetReq{
  336. string appId = 1;
  337. int64 entId = 2;
  338. int64 entUserId = 3;
  339. string userId = 4;
  340. int64 positionType = 5;
  341. string item = 6;
  342. string setType = 7;
  343. int64 ratemode = 8;
  344. string pushType = 9;
  345. repeated string times = 10;
  346. int64 pushValue = 11;
  347. int64 interested = 12;
  348. }
  349. message StaffSubscribeReq {
  350. string appId = 1;
  351. int64 entId = 2;
  352. int64 entUserId = 3;
  353. string query = 4;
  354. int64 eStatus = 6;
  355. int64 pStatus = 7;
  356. int64 pageNum = 8;
  357. int64 pageSize = 9;
  358. }
  359. message StaffSubscribeListResp {
  360. int64 err_code = 1;
  361. string err_msg = 2;
  362. int64 total = 3;
  363. repeated StaffSubscribe items = 4;
  364. }
  365. message StaffSubscribe {
  366. string token = 1;
  367. string name = 2;
  368. string phone = 3;
  369. int64 eStatus = 4;
  370. int64 pStatus = 5;
  371. }
  372. message StaffSubscribeDetailReq{
  373. int64 entId = 1;
  374. int64 entUserId = 2;
  375. string token = 3;
  376. }
  377. message StaffSubscribeDetail{
  378. int64 err_code = 1;
  379. string err_msg = 2;
  380. bytes data = 3;
  381. }
  382. message BidDistributorReq{
  383. string appId = 1;
  384. string entId = 2;
  385. string entUserId = 3;
  386. repeated string infoIds = 4;//分发信息
  387. string staffs = 5; //分发的员工
  388. }
  389. message BidRecListReq {
  390. string appId = 1;
  391. string entId = 2;
  392. string sPath = 3;
  393. string userId = 4;
  394. string entUserId = 5;
  395. int64 positionType = 6;
  396. }
  397. service Bxsubscribe {
  398. //获取订阅推送列表
  399. rpc GetSubList(SubscribeInfosReq) returns(SubscribeInfosResp);
  400. //获取订阅推送相关信息
  401. rpc GetSubSomeInfo(SomeInfoReq) returns(SomeInfoResp);
  402. //修改订阅信息接口
  403. rpc UpdateSubScribeInfo(UpdateSubScribeInfoReq)returns(StatusResp);
  404. //推送页面筛选导出
  405. rpc ByPushHistory(SubscribeInfosReq)returns(ByPushHistoryResp);
  406. //推送数据浏览状态修改
  407. rpc SetRead(SetReadReq)returns(StatusResp);
  408. //关键词获取
  409. rpc GetKey(GetKeyReq)returns(KeyResp);
  410. //订阅设置获取
  411. rpc GetSubScribeInfo(UserReq)returns(UserResq);
  412. //信息分发
  413. rpc MsgDistributor(MsgDistributorReq)returns(StatusResp);
  414. //手动分发人员查询
  415. rpc GetDistributor(GetDistributorReq)returns(DistributorResp);
  416. //查看状态
  417. rpc GetViewStatus(GetViewStatusReq)returns(ViewStatusResp);
  418. //用户推送信息查看
  419. rpc userInfo(GetUserInfoReq)returns(GetUserInfoResq);
  420. //用户邮箱保存
  421. rpc setUser(SetUserInfoReq)returns(StatusResp);
  422. //用户推送设置查看
  423. rpc getPushSet(GetPushSetReq)returns(GetPushSetResp);
  424. //用户推送设置修改
  425. rpc setPushSet(SetPushSetReq)returns(StatusResp);
  426. //查看企业员工用户订阅
  427. rpc getStaffSubscribeList(StaffSubscribeReq)returns(StaffSubscribeListResp);
  428. //查看企业员工用户订阅详情
  429. rpc getStaffSubscribeDetail(StaffSubscribeDetailReq)returns(StaffSubscribeDetail);
  430. //标讯信息分发
  431. rpc bidDistributor(BidDistributorReq)returns(StatusResp);
  432. // 订阅推荐列表
  433. rpc bidRecList(BidRecListReq)returns(SubscribeInfosResp);
  434. }