bxsubscribe.proto 11 KB

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