shortdrama.proto 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209
  1. syntax = "proto3";
  2. package gorpc;
  3. option go_package = "code.clickto.dev/nomo-server/go-service-pb/client";
  4. import "pb/common.proto";
  5. message ShortDramaEpisodeVo {
  6. int64 id = 1;
  7. int64 dramaId = 2;
  8. int64 type = 3;
  9. string name = 4;
  10. int64 sort = 5;
  11. string videos = 6;
  12. string subtitles = 7;
  13. Status status = 8;
  14. int64 createTime = 9;
  15. int64 updateTime = 10;
  16. string danmakuUrl = 11;
  17. }
  18. message ShortDramaEpisodeGetReq { ShortDramaEpisodeVo vo = 1; }
  19. message ShortDramaEpisodeListReq {
  20. Page page = 1;
  21. ShortDramaEpisodeVo vo = 2;
  22. repeated int64 dramaIds = 3;
  23. }
  24. message ShortDramaEpisodeListResp {
  25. int64 total = 1;
  26. repeated ShortDramaEpisodeVo list = 2;
  27. }
  28. message ShortDramaEpisodeBatchAddReq {
  29. int64 dramaId = 1;
  30. repeated ShortDramaEpisodeVo episodes = 2;
  31. }
  32. message ShortDramaEpisodeBatchRefreshUpdateTimeReq { int64 dramaId = 1; }
  33. message ShortDramaLanguageVo {
  34. int64 id = 1;
  35. int64 dramaId = 2;
  36. string lang = 3;
  37. string title = 4;
  38. string description = 5;
  39. string covers = 6;
  40. string coverDominantColor = 7;
  41. int64 createTime = 8;
  42. int64 updateTime = 9;
  43. }
  44. message ShortDramaVo {
  45. int64 id = 1;
  46. string productCodes = 2;
  47. string title = 3;
  48. string description = 4;
  49. string covers = 5;
  50. string coverDominantColor = 6;
  51. string type = 7;
  52. string tags = 8;
  53. string releaseRegions = 9;
  54. int64 releaseDate = 10;
  55. int64 totalEpisodes = 11;
  56. int64 completedStatus = 12;
  57. string copyrightSupplier = 13;
  58. string copyrightDoc = 14;
  59. int64 copyrightPurchaseDate = 15;
  60. int64 copyrightExpireDate = 16;
  61. int64 status = 17;
  62. int64 createTime = 18;
  63. int64 updateTime = 19;
  64. string ghostCutId = 20;
  65. int64 recommend = 21;
  66. string otherConfig = 22;
  67. repeated ShortDramaLanguageVo shortDramaLanguages = 23;
  68. int64 mainEpisodeCount = 24;
  69. int64 trailerEpisodeCount = 25;
  70. int64 copyrightId = 26;
  71. int64 creator = 27;
  72. int64 modifier = 28;
  73. }
  74. message ShortDramaGetReq {
  75. ShortDramaVo vo = 1;
  76. string productCode = 2;
  77. string countryCode = 3;
  78. string lang = 4;
  79. }
  80. message ShortDramaListReq {
  81. Page page = 1;
  82. ShortDramaVo vo = 2;
  83. repeated int64 excludeIds = 3;
  84. string productCode = 4;
  85. string countryCode = 5;
  86. string lang = 6;
  87. }
  88. message ShortDramaListResp {
  89. int64 total = 1;
  90. repeated ShortDramaVo list = 2;
  91. }
  92. message ShortDramaLanguageListReq {
  93. Page page = 1;
  94. ShortDramaLanguageVo vo = 2;
  95. }
  96. message ShortDramaLanguageListResp {
  97. int64 total = 1;
  98. repeated ShortDramaLanguageVo list = 2;
  99. }
  100. message ShortDramaEpisodeCountVo {
  101. int64 dramaId = 1;
  102. int64 episodeCount = 2;
  103. }
  104. message ShortDramaEpisodeCountReq {
  105. Page page = 1;
  106. Status status = 2;
  107. int64 type = 3;
  108. repeated int64 dramaIds = 4;
  109. }
  110. message ShortDramaEpisodeCountResp {
  111. int64 total = 1;
  112. repeated ShortDramaEpisodeCountVo list = 2;
  113. }
  114. message ShortDramaCheckNameReq {
  115. string title = 1; // 短剧名称
  116. int64 id = 2; // 编辑时排除当前短剧ID
  117. }
  118. message ShortDramaCheckNameResp {
  119. bool exists = 1; // 是否存在
  120. }
  121. message ShortDramaUpdateModifierReq {
  122. int64 id = 1;
  123. int64 modifier = 2;
  124. }
  125. message SetTotalStatsReq {
  126. int64 dramaId = 1;
  127. string country = 2;
  128. int64 todayPlayCount = 3;
  129. int64 weeklyPlayCount = 4;
  130. int64 monthlyPlayCount = 5;
  131. }
  132. message ShortDramaStatsPlaysTotalVo {
  133. int64 id = 1;
  134. int64 dramaId = 2;
  135. string country = 3;
  136. int64 todayPlayCount = 4;
  137. int64 weeklyPlayCount = 5;
  138. int64 monthlyPlayCount = 6;
  139. int64 createTime = 7;
  140. int64 updateTime = 8;
  141. }
  142. message ShortDramaStatsPlaysTotalListReq {
  143. Page page = 1;
  144. string country = 2; // 国家代码
  145. }
  146. message ShortDramaStatsPlaysTotalListResp {
  147. int64 total = 1;
  148. repeated ShortDramaStatsPlaysTotalVo list = 2;
  149. }
  150. service GoShortDramaClient {
  151. // ShortDrama
  152. rpc ShortDramaAdd(ShortDramaVo) returns (ShortDramaVo);
  153. rpc ShortDramaUpdate(ShortDramaVo) returns (Empty);
  154. rpc ShortDramaDel(Ids) returns (Empty);
  155. rpc ShortDramaGet(ShortDramaGetReq) returns (ShortDramaVo);
  156. rpc ShortDramaList(ShortDramaListReq) returns (ShortDramaListResp);
  157. rpc ShortDramaUpdateModifier(ShortDramaUpdateModifierReq) returns (Empty);
  158. // ShortDramaLanguage
  159. rpc ShortDramaLanguageList(ShortDramaLanguageListReq)
  160. returns (ShortDramaLanguageListResp);
  161. // ShortDramaEpisode
  162. rpc ShortDramaEpisodeAdd(ShortDramaEpisodeVo) returns (ShortDramaEpisodeVo);
  163. rpc ShortDramaEpisodeBatchAdd(ShortDramaEpisodeBatchAddReq) returns (Empty);
  164. rpc ShortDramaEpisodeUpdate(ShortDramaEpisodeVo) returns (Empty);
  165. rpc ShortDramaEpisodeDel(Ids) returns (Empty);
  166. rpc ShortDramaEpisodeGet(ShortDramaEpisodeGetReq)
  167. returns (ShortDramaEpisodeVo);
  168. rpc ShortDramaEpisodeList(ShortDramaEpisodeListReq)
  169. returns (ShortDramaEpisodeListResp);
  170. rpc ShortDramaEpisodeBatchRefreshUpdateTime(
  171. ShortDramaEpisodeBatchRefreshUpdateTimeReq) returns (Empty);
  172. // ShortDramaEpisodeCount
  173. rpc ShortDramaEpisodeCount(ShortDramaEpisodeCountReq)
  174. returns (ShortDramaEpisodeCountResp);
  175. rpc ShortDramaCheckName(ShortDramaCheckNameReq)
  176. returns (ShortDramaCheckNameResp);
  177. // ShortDramaStats
  178. rpc SetTotalStats(SetTotalStatsReq) returns (Empty);
  179. // ShortDramaStatsPlaysTotal
  180. rpc ShortDramaStatsPlaysTotalList(ShortDramaStatsPlaysTotalListReq)
  181. returns (ShortDramaStatsPlaysTotalListResp);
  182. }