gorpc.proto 110 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630
  1. syntax = "proto3";
  2. package gorpc;
  3. option go_package = "./pb";
  4. enum RegisterMode {
  5. RegisterModeUnknown = 0;
  6. RegisterModeGuest = 1;
  7. RegisterModeApp = 2;
  8. RegisterModeWeb = 3;
  9. RegisterModePc = 4;
  10. RegisterModeInvalid = 9999;
  11. }
  12. // enum Provider {
  13. // ProviderUnknown = 0;
  14. // ProviderGoogle = 1;
  15. // ProviderApple = 2;
  16. // ProviderMeta = 3;
  17. // ProviderGithub = 4;
  18. // }
  19. // 根据需要增加状态
  20. enum CommonResultCode {
  21. Success = 0;
  22. }
  23. enum Status {
  24. UnknownStatus = 0;
  25. StatusValid = 1;
  26. StatusInValid = 2;
  27. StatusDefault = 9;
  28. }
  29. enum BoolInt {
  30. BoolIntUnknown = 0;
  31. BoolIntTrue = 1;
  32. BoolIntFalse = 2;
  33. }
  34. enum UserType {
  35. UserTypeUnknown = 0;
  36. UserTypeDevice = 1;
  37. UserTypeAccount= 2;
  38. }
  39. enum AuthType {
  40. AuthTypeUnknown = 0;
  41. AuthTypeAuth = 1;
  42. AuthTypeCancel = 2;
  43. }
  44. enum UserLevel {
  45. UserLevelUnknown = 0;
  46. UserLevelTrial = 1;// 试用 1
  47. UserLevelFree = 2; // 免费 2
  48. UserLevelMember = 3; // 会员 3
  49. UserLevelInternal = 9999; // 内部 9999
  50. }
  51. message Empty {}
  52. message Int64SelectController {
  53. repeated int64 values = 1;
  54. bool exclude = 2;
  55. }
  56. message IntSelectController {
  57. repeated int32 values = 1;
  58. bool exclude = 2;
  59. }
  60. message StringSelectController {
  61. repeated string values = 1;
  62. bool exclude = 2;
  63. }
  64. message Page {
  65. message OrderItem {
  66. string column = 1;
  67. bool asc = 2;
  68. bool isFunc = 3;
  69. }
  70. int64 pageNo = 1;
  71. int64 pageSize = 2;
  72. int64 startTime = 3;
  73. int64 endTime = 4;
  74. repeated OrderItem sortBy = 5;
  75. bool ignoreTotal = 6; // 忽略总条数
  76. bool ignoreStat = 7; // 忽略总条数
  77. bool ignoreList = 8; // 忽略列表
  78. repeated int64 ids = 9;
  79. repeated string groupBy = 10;
  80. }
  81. message CommonResult {
  82. CommonResultCode code = 1;
  83. string msg = 2;
  84. }
  85. message BaseReq {
  86. int64 timeZoneOffset = 1;
  87. string lan = 2;
  88. }
  89. message DeleteIdResp { repeated int64 failedIds = 1; }
  90. message Ids { repeated int64 ids = 1; }
  91. message Request {}
  92. message Response { string msg = 1; }
  93. message TransactionOperation {
  94. string table = 1; // 表名
  95. string operate = 2; // delete,insert,update
  96. string data = 3; // json格式
  97. }
  98. message TransactionReq { repeated TransactionOperation transactions = 1; }
  99. message GameVo {
  100. int64 id = 1;
  101. string name = 2;
  102. string pkg = 3;
  103. string categories = 4;
  104. string icon = 5;
  105. string internal_icon = 6;
  106. string source_icon = 7;
  107. int64 status = 8;
  108. int64 state = 9;
  109. int64 enableRating = 10;
  110. int64 gameUpdateTime = 11;
  111. int64 gameBoostCount = 12;
  112. string gameBoostCountryCount = 13;
  113. int64 createTime = 14;
  114. int64 updateTime = 15;
  115. }
  116. message GameReq { GameVo vo = 1; }
  117. message GameListReq {
  118. Page page = 1;
  119. repeated string pkgs = 2;
  120. GameVo vo = 3;
  121. }
  122. message GameListRes {
  123. int64 total = 1;
  124. repeated GameVo list = 2;
  125. }
  126. message RelGameRankVo {
  127. int64 id = 1;
  128. int64 gameId = 2;
  129. int64 rankId = 3;
  130. int64 weight = 4;
  131. int64 createTime = 5;
  132. int64 updateTime = 6;
  133. }
  134. message RelGameRankReq { RelGameRankVo vo = 1; }
  135. message RelGameRankListReq {
  136. Page page = 1;
  137. RelGameRankVo vo = 2;
  138. }
  139. message RelGameRankListRes {
  140. int64 total = 1;
  141. repeated RelGameRankVo list = 2;
  142. }
  143. message RelGameVpnGroupVo {
  144. int64 id = 1;
  145. int64 gameId = 2;
  146. string productCode = 3;
  147. int64 vpnGroupId = 4;
  148. int64 status = 5;
  149. int64 createTime = 6;
  150. int64 updateTime = 7;
  151. }
  152. message RelGameVpnGroupReq { RelGameVpnGroupVo vo = 1; }
  153. message RelGameVpnGroupListReq {
  154. repeated int64 gameIds = 1;
  155. RelGameVpnGroupVo vo = 2;
  156. }
  157. message RelGameVpnGroupListRes {
  158. int64 total = 1;
  159. repeated RelGameVpnGroupVo list = 2;
  160. }
  161. message GameRedisHScanByNameReq {
  162. string name = 1;
  163. int64 cursor = 2;
  164. int64 count = 3;
  165. }
  166. message GameRedisHScanByNameResp {
  167. repeated int64 ids = 1;
  168. int64 cursor = 2;
  169. }
  170. message GameCustomerVo {
  171. int64 id = 1;
  172. string name = 2;
  173. string pkg = 3;
  174. string icon = 4;
  175. int64 createTime = 5;
  176. int64 updateTime = 6;
  177. }
  178. message GameCustomerListReq {
  179. Page page = 1;
  180. repeated string pkgs = 2;
  181. GameCustomerVo vo = 3;
  182. }
  183. message GameCustomerListRes {
  184. int64 total = 1;
  185. repeated GameCustomerVo list = 2;
  186. }
  187. message GameCustomerAddResp {
  188. GameCustomerVo vo = 1;
  189. bool ExistBoost = 2;
  190. }
  191. message GameCategoryVo {
  192. int64 id = 1;
  193. string code = 2;
  194. string name = 3;
  195. string described = 4;
  196. int64 createTime = 5;
  197. int64 updateTime = 6;
  198. }
  199. message GameCategoryReq { GameCategoryVo vo = 1; }
  200. message GameCategoryListReq {
  201. Page page = 1;
  202. GameCategoryVo vo = 3;
  203. }
  204. message GameCategoryListRes {
  205. int64 total = 1;
  206. repeated GameCategoryVo list = 2;
  207. }
  208. // 定义一个GameRank的属性字段
  209. message GameRankOption { bool showRanking = 1; }
  210. service GoGameClient {
  211. // 加速器游戏管理
  212. rpc GameAdd(GameVo) returns (GameVo);
  213. rpc GameUpdate(GameVo) returns (Empty);
  214. rpc GameDel(Ids) returns (Empty);
  215. rpc GameGet(GameReq) returns (GameVo);
  216. rpc GameList(GameListReq) returns (GameListRes);
  217. rpc GameAll(Request) returns (GameListRes);
  218. rpc GameRedisHScanByName(GameRedisHScanByNameReq)
  219. returns (GameRedisHScanByNameResp);
  220. // 游戏榜单关联关系
  221. rpc RelGameRankAdd(RelGameRankVo) returns (RelGameRankVo);
  222. rpc RelGameRankUpdate(RelGameRankVo) returns (Empty);
  223. rpc RelGameRankDel(Ids) returns (Empty);
  224. rpc RelGameRankGet(RelGameRankReq) returns (RelGameRankVo);
  225. rpc RelGameRankList(RelGameRankListReq) returns (RelGameRankListRes);
  226. // 游戏地域关联关系
  227. rpc RelGameVpnGroupAdd(RelGameVpnGroupVo) returns (RelGameVpnGroupVo);
  228. rpc RelGameVpnGroupUpdate(RelGameVpnGroupVo) returns (Empty);
  229. rpc RelGameVpnGroupDel(Ids) returns (Empty);
  230. rpc RelGameVpnGroupGet(RelGameVpnGroupReq) returns (RelGameVpnGroupVo);
  231. rpc RelGameVpnGroupList(RelGameVpnGroupListReq)
  232. returns (RelGameVpnGroupListRes);
  233. // 用户提交游戏
  234. rpc GameCustomerList(GameCustomerListReq) returns (GameCustomerListRes);
  235. rpc GameCustomerAdd(GameCustomerVo) returns (GameCustomerAddResp);
  236. rpc GameCustomerDel(Ids) returns (Empty);
  237. rpc GameCategoryAdd(GameCategoryVo) returns (GameCategoryVo);
  238. rpc GameCategoryUpdate(GameCategoryVo) returns (Empty);
  239. rpc GameCategoryDel(Ids) returns (Empty);
  240. rpc GameCategoryGet(GameCategoryReq) returns (GameCategoryVo);
  241. rpc GameCategoryList(GameCategoryListReq) returns (GameCategoryListRes);
  242. rpc GameCategoryAll(Request) returns (GameCategoryListRes);
  243. }
  244. message UserPayOrderVo { //用户支付订单表
  245. int64 id = 1; //主键ID,自增
  246. int64 userId = 2; //用户ID
  247. string productCode = 3; //产品Code
  248. string orderId = 4; //订单号
  249. float amount = 5; //订单金额(美元)
  250. float settleAmount = 6; //结算金额(美元)
  251. string currency = 7; //收款货币类型
  252. float currencyAmount = 8; //订单货币金额
  253. BoolInt orderType = 9; //订单类型:1非订阅 或者 2 订阅
  254. string payType = 10; //支付方式:visa, wx, alipay, paypal, coinpal, applePay, googlePay
  255. string platform = 11; //支付平台
  256. string snNo = 12; //支付平台流水号
  257. string payUrl = 13; //支付平台生成的付款地址
  258. string paidAddress = 14; //支付地址
  259. string ip = 15; //IP地址
  260. string remark = 16; //订单说明,可选
  261. string state = 17; //订单流转状态
  262. string stateDesc = 18; //订单状态说明,每次更新订单状态时更新
  263. int32 status = 19; //订单记录状态,1有效 2暂停
  264. int64 createTime = 20; //订单创建时间
  265. int64 updateTime = 21; //订单修改时间
  266. }
  267. message UserAuthLogVo { //用户授权日志表
  268. int64 id = 1; //自增ID
  269. string productCode = 2; //产品Code
  270. int64 userId = 3; //用户ID
  271. int64 beforeId = 4; //前一个授权记录ID
  272. BoolInt isCurrentService = 5; //最后一次有效套餐,退款级联不能设置true
  273. int64 servicePlanId = 6; //内部套餐ID
  274. int64 serviceChannelPlanId = 7; //渠道套餐ID
  275. string title = 8; //当前套餐标题
  276. string subTitle = 9; //当前套餐子标题
  277. string introduce = 10; //当前套餐说明
  278. string channelItemId = 11; //sku
  279. float orgPrice = 12; //原价
  280. float price = 13; //现价
  281. int64 currency = 14; //货币类型 1 美元
  282. BoolInt isSubscribe = 15; //是否是订阅类型 1非订阅 2订阅
  283. SubscribePeriodType subscribeType = 16; //订阅周期类型 1Day 2Week 3Month 4Year(仅当订阅类型为1时有效)
  284. int64 subscribePeriodValue = 17; //订阅周期值(仅当订阅类型为1时有效)
  285. UserLevel userLevel = 18; //会员等级
  286. int64 licenseDays = 19; //套餐天数
  287. int64 licenseMinutes = 20; //套餐分钟(设备活用仅适),不合并到账户中
  288. int64 deviceLimit = 21; //设备数量上限
  289. int64 speedLimit = 22; //速度上限100Kb
  290. int64 trafficLimit = 23; //流量上限
  291. int64 startTime = 24; //套餐开始时间
  292. int64 createTime = 25; //创建时间
  293. int64 updateTime = 26; //修改时间
  294. int64 createAt = 27; //授权人(创建)
  295. int64 updateAt = 28; //授权人(修改)
  296. Status status = 29; //记录状态 1有效 2无效
  297. AuthType authType = 30; //授权类型:1授权 2取消授权
  298. int64 userPayOrderId = 31; //支付订单ID
  299. }
  300. message UserAuthLogAddReq { UserAuthLogVo vo = 1; }
  301. message UserAuthLogAddResp { UserAuthLogVo vo = 1; }
  302. message UserAuthLogListReq {
  303. Page page = 1;
  304. UserAuthLogVo vo = 2;
  305. }
  306. message UserAuthLogListResp {
  307. int64 total = 1;
  308. repeated UserAuthLogVo list = 2;
  309. }
  310. message UserAuthLogGetReq { UserAuthLogVo vo = 1; }
  311. message UserAuthLogGetResp { UserAuthLogVo vo = 1; }
  312. message UserAuthLogDelReq { repeated int64 ids = 1; }
  313. message UserAuthLogUpdateReq { UserAuthLogVo vo = 1; }
  314. message UserAuthLogUpdateResp { UserAuthLogVo vo = 1; }
  315. message UserPayOrderAddReq { UserPayOrderVo vo = 1; }
  316. message UserPayOrderAddResp { UserPayOrderVo vo = 1; }
  317. message UserPayOrderListReq {
  318. Page page = 1;
  319. UserPayOrderVo vo = 2;
  320. }
  321. message UserPayOrderListResp {
  322. int64 total = 1;
  323. repeated UserPayOrderVo list = 2;
  324. }
  325. message UserPayOrderGetReq { UserPayOrderVo vo = 1; }
  326. message UserPayOrderGetResp { UserPayOrderVo vo = 1; }
  327. message UserPayOrderDelReq { repeated int64 ids = 1; }
  328. message UserPayOrderUpdateReq { UserPayOrderVo vo = 1; }
  329. message UserPayOrderUpdateResp { UserPayOrderVo vo = 1; }
  330. service GoPayClient {
  331. //UserAuthLog
  332. rpc UserAuthLogAdd(UserAuthLogAddReq) returns (UserAuthLogAddResp);
  333. rpc UserAuthLogList(UserAuthLogListReq) returns (UserAuthLogListResp);
  334. rpc UserAuthLogGet(UserAuthLogGetReq) returns (UserAuthLogGetResp);
  335. rpc UserAuthLogDel(UserAuthLogDelReq) returns (Empty);
  336. rpc UserAuthLogUpdate(UserAuthLogUpdateReq) returns (UserAuthLogUpdateResp);
  337. //UserPayOrder
  338. rpc UserPayOrderAdd(UserPayOrderAddReq) returns (UserPayOrderAddResp);
  339. rpc UserPayOrderList(UserPayOrderListReq) returns (UserPayOrderListResp);
  340. rpc UserPayOrderGet(UserPayOrderGetReq) returns (UserPayOrderGetResp);
  341. rpc UserPayOrderDel(UserPayOrderDelReq) returns (Empty);
  342. rpc UserPayOrderUpdate(UserPayOrderUpdateReq) returns (UserPayOrderUpdateResp);
  343. }
  344. // ServiceTypes
  345. message ServiceTypesVo {
  346. int64 id = 1; // ID
  347. string productCode = 2; // 产品标识
  348. string code = 3; // 权益类型标识
  349. string name = 4; // 权益类型名称
  350. int64 sort = 5; // 排序
  351. Status status = 6; // 状态 1启用 2禁用
  352. string remark = 7; // 备注
  353. int64 createTime = 8; // 创建时间
  354. int64 createAt = 9; // 创建者ID
  355. int64 updateTime = 10; // 更新时间
  356. int64 updateAt = 11; // 更新者ID
  357. }
  358. message ServiceTypesWithValueVo {
  359. ServiceTypesVo vo = 1;
  360. int64 value = 2;
  361. }
  362. message ServiceTypesGetReq { ServiceTypesVo vo = 1; }
  363. message ServiceTypesGetResp { ServiceTypesVo vo = 1; }
  364. message ServiceTypesAddReq { ServiceTypesVo vo = 1; }
  365. message ServiceTypesAddResp { ServiceTypesVo vo = 1; }
  366. message ServiceTypesUpdateReq { ServiceTypesVo vo = 1; }
  367. message ServiceTypesUpdateResp { ServiceTypesVo vo = 1; }
  368. message ServiceTypesDelReq { repeated int64 ids = 1; }
  369. message ServiceTypesListReq {
  370. Page page = 1;
  371. ServiceTypesVo vo = 2;
  372. repeated string productCodes = 3;
  373. repeated int64 excludeIds = 4;
  374. }
  375. message ServiceTypesListResp {
  376. int64 total = 1;
  377. repeated ServiceTypesVo list = 2;
  378. }
  379. // end ServiceTypes
  380. // ServiceBox
  381. message ServiceBoxVo {
  382. int64 id = 1; // ID
  383. string productCode = 2; // 产品标识
  384. string code = 3; // 权益包标识
  385. string name = 4; // 权益包名称
  386. int64 sort = 5; // 排序
  387. Status status = 6; // 状态 1启用 2禁用
  388. string remark = 7; // 备注
  389. int64 createTime = 8; // 创建时间
  390. int64 createAt = 9; // 创建者ID
  391. int64 updateTime = 10; // 更新时间
  392. int64 updateAt = 11; // 更新者ID
  393. }
  394. message ServiceBoxWithDetailsVo {
  395. ServiceBoxVo serviceBox = 1;
  396. repeated ServiceTypesWithValueVo serviceTypes = 2;
  397. }
  398. message ServiceBoxWithDurationVo {
  399. ServiceBoxVo serviceBox = 1;
  400. int64 licenseDurationDay = 2;
  401. int64 licenseDurationMinutes = 3;
  402. BoolInt isMaster = 4;
  403. int64 bindId = 5;
  404. }
  405. message ServiceBoxGetReq { ServiceBoxVo vo = 1; }
  406. message ServiceBoxGetResp { ServiceBoxVo vo = 1; }
  407. message ServiceBoxGetWithDetailsReq {
  408. ServiceBoxVo vo = 1;
  409. }
  410. message ServiceBoxGetWithDetailsResp {
  411. ServiceBoxVo serviceBox = 1;
  412. repeated ServiceTypesWithValueVo serviceTypes = 2;
  413. }
  414. message ServiceBoxAddReq { ServiceBoxVo vo = 1; }
  415. message ServiceBoxAddResp { ServiceBoxVo vo = 1; }
  416. message ServiceBoxAddWithDetailsReq {
  417. ServiceBoxVo serviceBox = 1;
  418. repeated ServiceTypesWithValueVo serviceTypes = 2;
  419. }
  420. message ServiceBoxAddWithDetailsResp {
  421. ServiceBoxVo serviceBox = 1;
  422. repeated ServiceTypesWithValueVo serviceTypes = 2;
  423. }
  424. message ServiceBoxUpdateReq { ServiceBoxVo vo = 1; }
  425. message ServiceBoxUpdateResp { ServiceBoxVo vo = 1; }
  426. message ServiceBoxUpdateWithDetailsReq {
  427. ServiceBoxVo serviceBox = 1;
  428. repeated ServiceTypesWithValueVo serviceTypes = 2;
  429. }
  430. message ServiceBoxUpdateWithDetailsResp {
  431. ServiceBoxVo serviceBox = 1;
  432. repeated ServiceTypesWithValueVo serviceTypes = 2;
  433. }
  434. message ServiceBoxDelReq { repeated int64 ids = 1; }
  435. message ServiceBoxListReq {
  436. Page page = 1;
  437. ServiceBoxVo vo = 2;
  438. repeated string productCodes = 3;
  439. repeated int64 excludeIds = 4;
  440. }
  441. message ServiceBoxListResp {
  442. int64 total = 1;
  443. repeated ServiceBoxVo list = 2;
  444. }
  445. // end ServiceBox
  446. // ServiceBoxTypes
  447. message ServiceBoxTypesVo {
  448. int64 id = 1; // ID
  449. int64 serviceBoxId = 2; // 权益包ID
  450. int64 serviceTypeId = 3; // 权益类型ID
  451. int64 serviceValue = 4; // 权益值 根据不同的 serviceTypeId,这里的值的含义不同
  452. int64 createTime = 5; // 创建时间
  453. int64 createAt = 6; // 创建者ID
  454. int64 updateTime = 7; // 更新时间
  455. int64 updateAt = 8; // 更新者ID
  456. }
  457. message ServiceBoxTypesGetReq { ServiceBoxTypesVo vo = 1; }
  458. message ServiceBoxTypesGetResp { ServiceBoxTypesVo vo = 1; }
  459. message ServiceBoxTypesAddReq { ServiceBoxTypesVo vo = 1; }
  460. message ServiceBoxTypesAddResp { ServiceBoxTypesVo vo = 1; }
  461. message ServiceBoxTypesUpdateReq { ServiceBoxTypesVo vo = 1; }
  462. message ServiceBoxTypesUpdateResp { ServiceBoxTypesVo vo = 1; }
  463. message ServiceBoxTypesDelReq { repeated int64 ids = 1; }
  464. message ServiceBoxTypesListReq {
  465. Page page = 1;
  466. ServiceBoxTypesVo vo = 2;
  467. repeated int64 serviceBoxIds = 3;
  468. repeated int64 serviceTypeIds = 4;
  469. repeated int64 excludeIds = 5;
  470. int64 boxStatus = 6;
  471. }
  472. message ServiceBoxTypesListResp {
  473. int64 total = 1;
  474. repeated ServiceBoxTypesVo list = 2;
  475. }
  476. // end ServiceBoxTypes
  477. // SubscribePeriodType 订阅周期类型
  478. enum SubscribePeriodType {
  479. SubscribePeriodTypeUnknown = 0;
  480. SubscribePeriodTypeDay = 1;
  481. SubscribePeriodTypeWeek = 2;
  482. SubscribePeriodTypeMonth = 3;
  483. SubscribePeriodTypeYear = 4;
  484. }
  485. // ServicePlan
  486. message ServicePlanVo {
  487. int64 id = 1; // ID
  488. string productCode = 2; // 产品标识
  489. string code = 3; // 套餐code
  490. string name = 4; // 套餐名称
  491. string title = 5; // 标题(默认值,对外显示)
  492. string subTitle = 6; // 副标题(默认值,对外显示)
  493. string introduce = 7; // 简介(默认值,对外显示)
  494. string tag = 8; // 标签内容(默认值,对外显示)
  495. float orgPrice = 9; // 原价(默认值)
  496. float price = 10; // 现价(默认值)
  497. int64 currency = 11; // 价格货币类型(默认值)
  498. BoolInt recommend = 12; // 是否推荐套餐(默认值) 1推荐 2不推荐
  499. BoolInt isDefault = 13; // 是否默认套餐(默认值) 1默认 2不默认
  500. BoolInt subscribeType = 14; // 订阅类型 1订阅类型 2非订阅类型
  501. SubscribePeriodType subscribePeriodType = 15; // 订阅周期类型 1Day 2Week 3Month 4Year(仅当订阅类型为1时有效)
  502. int64 subscribePeriodValue = 16; // 订阅周期值(仅当订阅类型为1时有效)
  503. int64 priority = 17; // 套餐使用优先级
  504. int64 mergeRule = 18; // 套餐合并规则(规则一样的套餐包含的权益可以合并到一起)
  505. int64 sort = 19; // 排序
  506. Status status = 20; // 状态 1启用 2禁用
  507. string remark = 21; // 备注
  508. int64 createTime = 22; // 创建时间
  509. int64 createAt = 23; // 创建者ID
  510. int64 updateTime = 24; // 更新时间
  511. int64 updateAt = 25; // 更新者ID
  512. int64 tagType = 26; // 标签类型(与客户端约定)
  513. }
  514. message ServicePlanWithBoxesVo {
  515. ServicePlanVo servicePlan = 1;
  516. repeated ServiceBoxWithDurationVo serviceBoxes = 2;
  517. }
  518. message ServicePlanGetReq { ServicePlanVo vo = 1; }
  519. message ServicePlanGetResp { ServicePlanVo vo = 1; }
  520. message ServicePlanGetWithBoxesReq { ServicePlanVo vo = 1; }
  521. message ServicePlanGetWithBoxesResp {
  522. ServicePlanVo servicePlan = 1;
  523. repeated ServiceBoxWithDurationVo serviceBoxes = 2;
  524. }
  525. message ServicePlanAddReq { ServicePlanVo vo = 1; }
  526. message ServicePlanAddResp { ServicePlanVo vo = 1; }
  527. message ServicePlanAddWithBoxesReq {
  528. ServicePlanVo servicePlan = 1;
  529. repeated ServiceBoxWithDurationVo serviceBoxes = 2;
  530. }
  531. message ServicePlanAddWithBoxesResp {
  532. ServicePlanVo servicePlan = 1;
  533. repeated ServiceBoxWithDurationVo serviceBoxes = 2;
  534. }
  535. message ServicePlanUpdateReq { ServicePlanVo vo = 1; }
  536. message ServicePlanUpdateResp { ServicePlanVo vo = 1; }
  537. message ServicePlanUpdateWithBoxesReq {
  538. ServicePlanVo servicePlan = 1;
  539. repeated ServiceBoxWithDurationVo serviceBoxes = 2;
  540. }
  541. message ServicePlanUpdateWithBoxesResp {
  542. ServicePlanVo servicePlan = 1;
  543. repeated ServiceBoxWithDurationVo serviceBoxes = 2;
  544. }
  545. message ServicePlanDelReq { repeated int64 ids = 1; }
  546. message ServicePlanListReq {
  547. Page page = 1;
  548. ServicePlanVo vo = 2;
  549. repeated string productCodes = 3;
  550. repeated int64 excludeIds = 4;
  551. }
  552. message ServicePlanListResp {
  553. int64 total = 1;
  554. repeated ServicePlanVo list = 2;
  555. }
  556. message ServicePlanListWithBoxesReq {
  557. Page page = 1;
  558. ServicePlanVo vo = 2;
  559. repeated string productCodes = 3;
  560. repeated int64 excludeIds = 4;
  561. }
  562. message ServicePlanListWithBoxesResp {
  563. int64 total = 1;
  564. repeated ServicePlanWithBoxesVo list = 2;
  565. }
  566. // end ServicePlan
  567. // ServicePlanBoxes
  568. message ServicePlanBoxesVo {
  569. int64 id = 1; // ID
  570. int64 servicePlanId = 2; // 套餐ID
  571. int64 serviceBoxId = 3; // 权益包ID
  572. int64 licenseDurationDay = 4; // 权益包持续天数
  573. int64 licenseDurationMinutes = 5; // 权益包额外持续分钟数
  574. BoolInt isMaster = 6; // 是否主权益包 1是 2否
  575. int64 createTime = 7; // 创建时间
  576. int64 createAt = 8; // 创建者ID
  577. int64 updateTime = 9; // 更新时间
  578. int64 updateAt = 10; // 更新者ID
  579. }
  580. message ServicePlanBoxesGetReq { ServicePlanBoxesVo vo = 1; }
  581. message ServicePlanBoxesGetResp { ServicePlanBoxesVo vo = 1; }
  582. message ServicePlanBoxesAddReq { ServicePlanBoxesVo vo = 1; }
  583. message ServicePlanBoxesAddResp { ServicePlanBoxesVo vo = 1; }
  584. message ServicePlanBoxesUpdateReq { ServicePlanBoxesVo vo = 1; }
  585. message ServicePlanBoxesUpdateResp { ServicePlanBoxesVo vo = 1; }
  586. message ServicePlanBoxesDelReq { repeated int64 ids = 1; }
  587. message ServicePlanBoxesListReq {
  588. Page page = 1;
  589. ServicePlanBoxesVo vo = 2;
  590. repeated int64 servicePlanIds = 3;
  591. repeated int64 serviceBoxIds = 4;
  592. repeated int64 excludeIds = 5;
  593. int64 planStatus = 6;
  594. }
  595. message ServicePlanBoxesListResp {
  596. int64 total = 1;
  597. repeated ServicePlanBoxesVo list = 2;
  598. }
  599. // end ServicePlanBoxes
  600. // ServicePlanChannel
  601. message ServicePlanChannelVo {
  602. int64 id = 1; // ID
  603. string productCode = 2; // 产品标识
  604. string channel = 3; // 渠道标识
  605. string channelItemId = 4; // 套餐唯一ID或商店SKUID
  606. int64 servicePlanId = 5; // 套餐ID
  607. string title = 6; // 自定义标题(对外显示)
  608. string subTitle = 7; // 自定义副标题(对外显示)
  609. string introduce = 8; // 自定义简介(对外显示)
  610. string tag = 9; // 自定义标签内容(对外显示)
  611. float orgPrice = 10; // 在该渠道下的原价
  612. float price = 11; // 在该渠道下的现价
  613. int64 currency = 12; // 价格货币类型
  614. BoolInt recommend = 13; // 是否推荐商品(默认值) 1推荐 2不推荐
  615. BoolInt isDefault = 14; // 是否默认商品(默认值) 1默认 2不默认
  616. string displayPolicyConfig = 15; // 显示策略
  617. int64 sort = 16; // 排序
  618. Status status = 17; // 状态 1启用 2禁用
  619. string remark = 18; // 备注
  620. int64 createTime = 19; // 创建时间
  621. int64 createAt = 20; // 创建者ID
  622. int64 updateTime = 21; // 更新时间
  623. int64 updateAt = 22; // 更新者ID
  624. int64 tagType = 23; // 标签类型(与客户端约定)
  625. }
  626. message ServicePlanChannelGetReq { ServicePlanChannelVo vo = 1; }
  627. message ServicePlanChannelGetResp { ServicePlanChannelVo vo = 1; }
  628. message ServicePlanChannelAddReq { ServicePlanChannelVo vo = 1; }
  629. message ServicePlanChannelAddResp { ServicePlanChannelVo vo = 1; }
  630. message ServicePlanChannelUpdateReq { ServicePlanChannelVo vo = 1; }
  631. message ServicePlanChannelUpdateResp { ServicePlanChannelVo vo = 1; }
  632. message ServicePlanChannelDelReq { repeated int64 ids = 1; }
  633. message ServicePlanChannelListReq {
  634. Page page = 1;
  635. ServicePlanChannelVo vo = 2;
  636. repeated string productCodes = 3;
  637. repeated string channels = 4;
  638. repeated string channelItemIds = 5;
  639. repeated int64 servicePlanIds = 6;
  640. repeated int64 excludeIds = 7;
  641. }
  642. message ServicePlanChannelListResp {
  643. int64 total = 1;
  644. repeated ServicePlanChannelVo list = 2;
  645. }
  646. // end ServicePlanChannel
  647. service GoPlanClient {
  648. /** ServiceTypes Model */
  649. // ServiceTypesAdd
  650. rpc ServiceTypesAdd(ServiceTypesAddReq) returns (ServiceTypesAddResp);
  651. rpc ServiceTypesUpdate(ServiceTypesUpdateReq) returns (ServiceTypesUpdateResp);
  652. rpc ServiceTypesDel(ServiceTypesDelReq) returns (Empty);
  653. rpc ServiceTypesGet(ServiceTypesGetReq) returns (ServiceTypesGetResp);
  654. rpc ServiceTypesList(ServiceTypesListReq) returns (ServiceTypesListResp);
  655. /** ServiceBox Model */
  656. // ServiceBoxAdd
  657. rpc ServiceBoxAdd(ServiceBoxAddReq) returns (ServiceBoxAddResp);
  658. rpc ServiceBoxAddWithDetails(ServiceBoxAddWithDetailsReq) returns (ServiceBoxAddWithDetailsResp);
  659. rpc ServiceBoxUpdate(ServiceBoxUpdateReq) returns (ServiceBoxUpdateResp);
  660. rpc ServiceBoxUpdateWithDetails(ServiceBoxUpdateWithDetailsReq) returns (ServiceBoxUpdateWithDetailsResp);
  661. rpc ServiceBoxDel(ServiceBoxDelReq) returns (Empty);
  662. rpc ServiceBoxGet(ServiceBoxGetReq) returns (ServiceBoxGetResp);
  663. rpc ServiceBoxGetWithDetails(ServiceBoxGetWithDetailsReq) returns (ServiceBoxGetWithDetailsResp);
  664. rpc ServiceBoxList(ServiceBoxListReq) returns (ServiceBoxListResp);
  665. /** ServiceBoxTypes Model */
  666. // ServiceBoxTypesAdd
  667. rpc ServiceBoxTypesAdd(ServiceBoxTypesAddReq) returns (ServiceBoxTypesAddResp);
  668. rpc ServiceBoxTypesUpdate(ServiceBoxTypesUpdateReq) returns (ServiceBoxTypesUpdateResp);
  669. rpc ServiceBoxTypesDel(ServiceBoxTypesDelReq) returns (Empty);
  670. rpc ServiceBoxTypesGet(ServiceBoxTypesGetReq) returns (ServiceBoxTypesGetResp);
  671. rpc ServiceBoxTypesList(ServiceBoxTypesListReq) returns (ServiceBoxTypesListResp);
  672. /** ServicePlan Model */
  673. // ServicePlanAdd
  674. rpc ServicePlanAdd(ServicePlanAddReq) returns (ServicePlanAddResp);
  675. rpc ServicePlanAddWithBoxes(ServicePlanAddWithBoxesReq) returns (ServicePlanAddWithBoxesResp);
  676. rpc ServicePlanUpdate(ServicePlanUpdateReq) returns (ServicePlanUpdateResp);
  677. rpc ServicePlanUpdateWithBoxes(ServicePlanUpdateWithBoxesReq) returns (ServicePlanUpdateWithBoxesResp);
  678. rpc ServicePlanDel(ServicePlanDelReq) returns (Empty);
  679. rpc ServicePlanGet(ServicePlanGetReq) returns (ServicePlanGetResp);
  680. rpc ServicePlanGetWithBoxes(ServicePlanGetWithBoxesReq) returns (ServicePlanGetWithBoxesResp);
  681. rpc ServicePlanList(ServicePlanListReq) returns (ServicePlanListResp);
  682. /** ServicePlanBoxes Model */
  683. // ServicePlanBoxesAdd
  684. rpc ServicePlanBoxesAdd(ServicePlanBoxesAddReq) returns (ServicePlanBoxesAddResp);
  685. rpc ServicePlanBoxesUpdate(ServicePlanBoxesUpdateReq) returns (ServicePlanBoxesUpdateResp);
  686. rpc ServicePlanBoxesDel(ServicePlanBoxesDelReq) returns (Empty);
  687. rpc ServicePlanBoxesGet(ServicePlanBoxesGetReq) returns (ServicePlanBoxesGetResp);
  688. rpc ServicePlanBoxesList(ServicePlanBoxesListReq) returns (ServicePlanBoxesListResp);
  689. /** ServicePlanChannel Model */
  690. // ServicePlanChannelAdd
  691. rpc ServicePlanChannelAdd(ServicePlanChannelAddReq) returns (ServicePlanChannelAddResp);
  692. rpc ServicePlanChannelUpdate(ServicePlanChannelUpdateReq) returns (ServicePlanChannelUpdateResp);
  693. rpc ServicePlanChannelDel(ServicePlanChannelDelReq) returns (Empty);
  694. rpc ServicePlanChannelGet(ServicePlanChannelGetReq) returns (ServicePlanChannelGetResp);
  695. rpc ServicePlanChannelList(ServicePlanChannelListReq) returns (ServicePlanChannelListResp);
  696. }
  697. message I18nVo {
  698. string code = 1;
  699. string value = 2;
  700. }
  701. message ConfigGetReq {
  702. int64 id = 1; // ID
  703. string code = 2; // 类型标识
  704. }
  705. // GlobalParam
  706. message GlobalParamVo {
  707. int64 id = 1;
  708. string paramKey = 2;
  709. string paramValue = 3;
  710. string valueType = 4;
  711. float minValue = 5;
  712. float maxValue = 6;
  713. string name = 7;
  714. BoolInt editable = 8;
  715. BoolInt nullable = 9;
  716. BoolInt hidden = 10;
  717. BoolInt mutiLang = 11;
  718. int64 sort = 12;
  719. string remark = 13;
  720. BoolInt apiExport = 14;
  721. string apiExportName = 15;
  722. int64 createTime = 16;
  723. int64 updateTime = 17;
  724. // valueType 为 string、text、json、string[], 且 mutiLang 为 true 时,需要同时干查询/修改/插入多语言数据
  725. repeated I18nVo i18ns = 18;
  726. }
  727. message GlobalParamGetReq {
  728. GlobalParamVo vo = 1;
  729. string lang = 2;
  730. }
  731. message GlobalParamListReq {
  732. Page page = 1;
  733. GlobalParamVo vo = 2;
  734. repeated int64 excludeIds = 3; // 排除的ID
  735. };
  736. message GlobalParamListResp {
  737. int64 total = 1;
  738. repeated GlobalParamVo list = 2;
  739. };
  740. // end GlobalParam
  741. // Product
  742. message ProductVo {
  743. int64 id = 1;
  744. string code = 2;
  745. string name = 3;
  746. string domain = 4;
  747. Status status = 5;
  748. string langs = 6;
  749. string defaultLang = 7;
  750. string remark = 8;
  751. int64 createTime = 9;
  752. int64 updateTime = 10;
  753. }
  754. message ProductListReq {
  755. Page page = 1;
  756. ProductVo vo = 2;
  757. repeated string productCodes = 3;
  758. repeated int64 excludeIds = 4;
  759. }
  760. message ProductListResp {
  761. int64 total = 1;
  762. repeated ProductVo list = 2;
  763. }
  764. // end Product
  765. // ProductParam
  766. message ProductParamVo {
  767. int64 id = 1;
  768. string productCode = 2;
  769. string paramKey = 3;
  770. string paramValue = 4;
  771. string valueType = 5;
  772. float minValue = 6;
  773. float maxValue = 7;
  774. string name = 8;
  775. BoolInt editable = 9;
  776. BoolInt nullable = 10;
  777. BoolInt hidden = 11;
  778. BoolInt mutiLang = 12;
  779. int64 sort = 13;
  780. string remark = 14;
  781. BoolInt apiExport = 15;
  782. string apiExportName = 16;
  783. int64 createTime = 17;
  784. int64 updateTime = 18;
  785. // valueType 为 string、text、json、string[], 且 mutiLang 为 true
  786. // 时,需要同时干查询/修改/插入多语言数据
  787. repeated I18nVo i18ns = 19;
  788. }
  789. message ProductParamGetReq {
  790. ProductParamVo vo = 1;
  791. string lang = 2;
  792. }
  793. message ProductParamListReq {
  794. Page page = 1;
  795. ProductParamVo vo = 2;
  796. repeated string productCodes = 3;
  797. repeated int64 excludeIds = 4;
  798. };
  799. message ProductParamListResp {
  800. int64 total = 1;
  801. repeated ProductParamVo list = 2;
  802. };
  803. // end ProductParam
  804. // ProductAction
  805. message ProductActionVo {
  806. int64 id = 1;
  807. int64 groupId = 2;
  808. string productCode = 3;
  809. string imgUrl = 4;
  810. string actionType = 5;
  811. string actionData = 6;
  812. string title = 7;
  813. Status status = 8;
  814. int64 createTime = 9;
  815. int64 updateTime = 10;
  816. int64 sort = 11;
  817. string versionPolicy = 12;
  818. string platform = 13;
  819. string channel = 14;
  820. }
  821. message ProductActionReq { ProductActionVo vo = 1; }
  822. message ProductActionListReq {
  823. Page page = 1;
  824. ProductActionVo vo = 2;
  825. repeated string productCodes = 3;
  826. repeated int64 excludeIds = 4;
  827. repeated int64 groupIds = 5;
  828. }
  829. message ProductActionListResp {
  830. int64 total = 1;
  831. repeated ProductActionVo list = 2;
  832. }
  833. // end ProductAction
  834. // ProductActionGroup 产品行为分组
  835. message ProductActionGroupVo {
  836. int64 id = 1;
  837. string productCode = 2;
  838. string area = 3; // 地区,存储json字符串
  839. string platform = 4; // 平台,存储json字符串
  840. string channel = 5; // 渠道,存储json字符串
  841. string versionPolicy = 6; // 版本策略,存储json字符串
  842. int64 sort = 7; // 排序
  843. Status status = 8; // 状态 0未知 1正常 2禁用
  844. string title = 9; // 标题
  845. int64 createTime = 10;
  846. int64 updateTime = 11;
  847. }
  848. message ProductActionGroupReq { ProductActionGroupVo vo = 1; }
  849. message ProductActionGroupListReq {
  850. Page page = 1;
  851. ProductActionGroupVo vo = 2;
  852. repeated string productCodes = 3;
  853. repeated int64 excludeIds = 4;
  854. }
  855. message ProductActionGroupListResp {
  856. int64 total = 1;
  857. repeated ProductActionGroupVo list = 2;
  858. }
  859. message ProductActionGroupDisableReq { repeated int64 ids = 1; }
  860. message ProductActionGroupEnableReq { repeated int64 ids = 1; }
  861. // end ProductActionGroup
  862. // ProductActionPolicyGroup 产品行为策略分组
  863. message ProductActionPolicyGroupVo {
  864. int64 id = 1;
  865. string productCode = 2;
  866. int64 groupId = 3; // productActionGroupID
  867. string platform = 4; // 平台,存储json字符串
  868. string channel = 5; // 渠道,存储json字符串
  869. string versionPolicy = 6; // 版本策略,存储json字符串
  870. int64 sort = 7; // 排序
  871. Status status = 8; // 状态 0未知 1正常 2禁用
  872. string title = 9; // 标题
  873. int64 createTime = 10;
  874. int64 updateTime = 11;
  875. string Position = 12;
  876. }
  877. message ProductActionPolicyGroupReq { ProductActionPolicyGroupVo vo = 1; }
  878. message ProductActionPolicyGroupListReq {
  879. Page page = 1;
  880. ProductActionPolicyGroupVo vo = 2;
  881. repeated string productCodes = 3;
  882. repeated int64 excludeIds = 4;
  883. repeated int64 groupIds = 5;
  884. }
  885. message ProductActionPolicyGroupListResp {
  886. int64 total = 1;
  887. repeated ProductActionPolicyGroupVo list = 2;
  888. }
  889. message ProductActionPolicyGroupDisableReq { repeated int64 ids = 1; }
  890. message ProductActionPolicyGroupEnableReq { repeated int64 ids = 1; }
  891. // end ProductActionPolicyGroup
  892. // ProductActionType 产品行为类型
  893. message ProductActionTypeVo {
  894. int64 id = 1;
  895. string name = 2; // 名称
  896. string description = 3; // 描述
  897. int64 createTime = 4;
  898. int64 updateTime = 5;
  899. }
  900. message ProductActionTypeReq { ProductActionTypeVo vo = 1; }
  901. message ProductActionTypeListReq {
  902. Page page = 1;
  903. ProductActionTypeVo vo = 2;
  904. repeated int64 excludeIds = 3;
  905. }
  906. message ProductActionTypeListResp {
  907. int64 total = 1;
  908. repeated ProductActionTypeVo list = 2;
  909. }
  910. // end ProductActionType
  911. // AreaParam
  912. message AreaParamVo {
  913. int64 id = 1;
  914. string productCode = 2;
  915. string name = 3;
  916. string areas = 4;
  917. string paramValue = 5;
  918. Status status = 6;
  919. int64 sort = 7;
  920. string remark = 8;
  921. int64 createTime = 9;
  922. int64 updateTime = 10;
  923. string version = 11;
  924. }
  925. message AreaParamListReq {
  926. Page page = 1;
  927. AreaParamVo vo = 2;
  928. repeated string productCodes = 3; // 产品code
  929. repeated int64 excludeIds = 4; // 排除的ID
  930. }
  931. message AreaParamListResp {
  932. int64 total = 1;
  933. repeated AreaParamVo list = 2;
  934. }
  935. // end AreaParam
  936. // NationalLanguage
  937. message NationalLanguageVo {
  938. int64 id = 1;
  939. string tbName = 2;
  940. int64 tbRowId = 3;
  941. string tbFieldName = 4;
  942. string lan = 5;
  943. string value = 6;
  944. Status status = 7;
  945. int64 updateTime = 8;
  946. int64 createTime = 9;
  947. }
  948. message NationalLanguageListReq {
  949. Page page = 1;
  950. NationalLanguageVo vo = 2;
  951. repeated int64 excludeIds = 3; // 排除的ID
  952. }
  953. message NationalLanguageListResp {
  954. int64 total = 1;
  955. repeated NationalLanguageVo list = 2;
  956. }
  957. // end NationalLanguage
  958. // Tip
  959. message TipVo {
  960. int64 id = 1;
  961. string productCode = 2;
  962. string paramKey = 3;
  963. string paramValue = 4;
  964. string code = 5;
  965. int64 showType = 6;
  966. int64 sort = 7;
  967. string remark = 8;
  968. int64 createTime = 9;
  969. int64 updateTime = 10;
  970. repeated I18nVo i18ns = 11;
  971. }
  972. message TipGetReq {
  973. TipVo vo = 1;
  974. string lang = 2;
  975. }
  976. message TipListReq {
  977. Page page = 1;
  978. TipVo vo = 2;
  979. repeated string productCodes = 3;
  980. repeated int64 excludeIds = 4; // 排除的ID
  981. }
  982. message TipListResp {
  983. int64 total = 1;
  984. repeated TipVo list = 2;
  985. }
  986. // end Tip
  987. // Dict
  988. message DictVo {
  989. int64 id = 1;
  990. string productCode = 2;
  991. int64 parentId = 3;
  992. string dataType = 4;
  993. string name = 5;
  994. string payload = 6;
  995. int64 sort = 7;
  996. Status status = 8;
  997. string remark = 9;
  998. int64 createTime = 10;
  999. int64 updateTime = 11;
  1000. string payloadJson = 12;
  1001. }
  1002. message DictGetReq { DictVo vo = 1; }
  1003. message DictListReq {
  1004. Page page = 1;
  1005. DictVo vo = 2;
  1006. repeated string productCodes = 3;
  1007. repeated int64 excludeIds = 4;
  1008. }
  1009. message DictListResp {
  1010. int64 total = 1;
  1011. repeated DictVo list = 2;
  1012. }
  1013. // end Dict
  1014. // message UpgradeResVo {
  1015. // int64 id = 1;
  1016. // string title = 2;
  1017. // string path = 3;
  1018. // string fileMd5 = 4;
  1019. // string filePath = 5;
  1020. // string metadataId = 6;
  1021. // string createdAt = 7;
  1022. // string runtimeVersion = 8;
  1023. // int64 runtimeVersionCode = 9;
  1024. // string appVersionName = 10;
  1025. // int64 appVersionCode = 11;
  1026. // Status status = 12;
  1027. // string remark = 13;
  1028. // int64 createTime = 14;
  1029. // int64 updateTime = 15;
  1030. // int64 resSize = 16;
  1031. // }
  1032. // message UpgradeResConfigVo {
  1033. // int64 id = 1;
  1034. // int64 productId = 2;
  1035. // string platform = 3;
  1036. // string channel = 4;
  1037. // int64 resId = 5;
  1038. // int64 isForceUpdate = 6;
  1039. // string forceIntro = 7;
  1040. // string areaConfigs = 8;
  1041. // string versionConfigs = 9;
  1042. // int64 interval = 10;
  1043. // int64 upgradeRate = 11;
  1044. // string intro = 12;
  1045. // string apis = 13;
  1046. // Status status = 14;
  1047. // string remark = 15;
  1048. // string userIds = 16;
  1049. // int64 createTime = 17;
  1050. // int64 updateTime = 18;
  1051. // string forceVersionConfigs = 19;
  1052. // string forceAreaConfigs = 20;
  1053. // string runtimeVersionConfigs = 21;
  1054. // string title = 22;
  1055. // int64 isSilent = 23;
  1056. // }
  1057. // message UpgradePkgVo {
  1058. // int64 id = 1;
  1059. // int64 productId = 2;
  1060. // string platform = 3;
  1061. // string channel = 4;
  1062. // int64 versionCode = 5;
  1063. // string versionName = 6;
  1064. // string fileMd5 = 7;
  1065. // string areaConfigs = 8;
  1066. // string versionConfigs = 9;
  1067. // int64 interval = 10;
  1068. // int64 upgradeRate = 11;
  1069. // string intro = 12;
  1070. // string appStoreUrl = 13;
  1071. // string url = 14;
  1072. // string onlineUrls = 15;
  1073. // string userIds = 16;
  1074. // int64 isForceUpdate = 17;
  1075. // string forceIntro = 18;
  1076. // string forceVersionConfigs = 19;
  1077. // Status status = 20;
  1078. // string remark = 21;
  1079. // int64 createTime = 22;
  1080. // int64 updateTime = 23;
  1081. // string title = 24;
  1082. // string forceAreaConfigs = 25;
  1083. // }
  1084. // message UpgradeResConfigGetReq {
  1085. // Page page = 1;
  1086. // int64 id = 2;
  1087. // }
  1088. // message UpgradeResConfigListReq {
  1089. // Page page = 1;
  1090. // UpgradeResConfigVo vo = 2;
  1091. // }
  1092. // message UpgradeResConfigListResp {
  1093. // int64 total = 1;
  1094. // repeated UpgradeResConfigVo list = 2;
  1095. // }
  1096. // message UpgradePkgGetReq { UpgradePkgVo vo = 1; }
  1097. // message UpgradePkgListReq {
  1098. // Page page = 1;
  1099. // UpgradePkgVo vo = 2;
  1100. // }
  1101. // message UpgradePkgListResp {
  1102. // int64 total = 1;
  1103. // repeated UpgradePkgVo list = 2;
  1104. // }
  1105. // message UpgradeResGetReq { UpgradeResVo vo = 1; }
  1106. // message UpgradeResListReq {
  1107. // Page page = 1;
  1108. // UpgradeResVo vo = 2;
  1109. // }
  1110. // message UpgradeResListResp {
  1111. // int64 total = 1;
  1112. // repeated UpgradeResVo list = 2;
  1113. // }
  1114. // message ResourceDelReq {
  1115. // repeated int64 ids = 1;
  1116. // string fileMd5 = 2;
  1117. // }
  1118. // UpgradePkgPlan
  1119. message UpgradePkgPlanVo {
  1120. int64 id = 1;
  1121. string productCode = 2; // 产品code
  1122. string areas = 3; // 地区列表
  1123. int64 sort = 4;
  1124. Status status = 5; // 状态
  1125. string remark = 6;
  1126. int64 createTime = 7;
  1127. int64 updateTime = 8;
  1128. }
  1129. message UpgradePkgPlanListReq {
  1130. Page page = 1;
  1131. UpgradePkgPlanVo vo = 2;
  1132. repeated string productCodes = 3;
  1133. repeated int64 excludeIds = 4;
  1134. }
  1135. message UpgradePkgPlanListResp {
  1136. int64 total = 1;
  1137. repeated UpgradePkgPlanVo list = 2;
  1138. }
  1139. // end UpgradePkgPlan
  1140. // UpgradePkgPlanDetail
  1141. message UpgradePkgPlanDetailVo {
  1142. int64 id = 1;
  1143. int64 planId = 2; // 方案ID
  1144. string platform = 3; // 平台
  1145. string channel = 4; // 渠道
  1146. string name = 5; // 名称
  1147. int64 ver = 6; // 版本号
  1148. string url = 7; // 商店地址
  1149. string websiteUrl = 8; // 官网地址
  1150. string directUrl = 9; // 直接下载地址
  1151. string md5 = 10; // MD5
  1152. string info = 11; // 更新信息
  1153. string testUpgradePolicyConfig = 12; // 测试更新策略配置
  1154. string upgradePolicyConfig = 13; // 更新策略配置
  1155. string forceUpgradePolicyConfig = 14; // 强制更新策略
  1156. Status status = 15; // 状态
  1157. string remark = 16;
  1158. int64 createTime = 17;
  1159. int64 updateTime = 18;
  1160. }
  1161. message UpgradePkgPlanDetailListReq {
  1162. Page page = 1;
  1163. UpgradePkgPlanDetailVo vo = 2;
  1164. repeated int64 planIds = 3;
  1165. }
  1166. message UpgradePkgPlanDetailListResp {
  1167. int64 total = 1;
  1168. repeated UpgradePkgPlanDetailVo list = 2;
  1169. }
  1170. // end UpgradePkgPlanDetail
  1171. // UpgradeResPlan
  1172. message UpgradeResPlanVo {
  1173. int64 id = 1;
  1174. string productCode = 2; // 产品code
  1175. string areas = 3; // 地区列表
  1176. int64 sort = 4;
  1177. Status status = 5; // 状态
  1178. string remark = 6;
  1179. int64 createTime = 7;
  1180. int64 updateTime = 8;
  1181. }
  1182. message UpgradeResPlanListReq {
  1183. Page page = 1;
  1184. UpgradeResPlanVo vo = 2;
  1185. repeated string productCodes = 3;
  1186. repeated int64 excludeIds = 4;
  1187. }
  1188. message UpgradeResPlanListResp {
  1189. int64 total = 1;
  1190. repeated UpgradeResPlanVo list = 2;
  1191. }
  1192. // end UpgradeResPlan
  1193. // UpgradeResPlanDetail
  1194. message UpgradeResPlanDetailVo {
  1195. int64 id = 1; // ID
  1196. int64 planId = 2; // 方案ID
  1197. string platform = 3; // 平台
  1198. string channel = 4; // 渠道
  1199. string name = 5; // 名称
  1200. int64 ver = 6; // 资源版本号
  1201. string url = 7; // 资源地址
  1202. string info = 8; // 更新信息
  1203. string md5 = 9; // 资源 md5值
  1204. int64 size = 10; // 资源大小
  1205. string testUpgradePolicyConfig = 11; // 测试更新策略配置
  1206. string upgradePolicyConfig = 12; // 更新策略配置
  1207. string forceUpgradePolicyConfig = 13; // 强制更新策略
  1208. Status status = 14; // 状态,1=正常,2=冻结
  1209. string remark = 15; // 备注
  1210. int64 createTime = 16; // 创建时间秒
  1211. int64 updateTime = 17; // 修改时间秒
  1212. }
  1213. message UpgradeResPlanDetailListReq {
  1214. Page page = 1;
  1215. UpgradeResPlanDetailVo vo = 2;
  1216. repeated int64 planIds = 3;
  1217. }
  1218. message UpgradeResPlanDetailListResp {
  1219. int64 total = 1;
  1220. repeated UpgradeResPlanDetailVo list = 2;
  1221. }
  1222. // end UpgradeResPlanDetail
  1223. // AdPlan
  1224. message AdPlanVo {
  1225. int64 id = 1;
  1226. string productCode = 2; // 产品code
  1227. string areas = 3; // 地区列表
  1228. string config = 4; // 配置
  1229. int64 sort = 5;
  1230. Status status = 6; // 状态
  1231. string remark = 7;
  1232. int64 createTime = 8;
  1233. int64 updateTime = 9;
  1234. }
  1235. message AdPlanListReq {
  1236. Page page = 1;
  1237. AdPlanVo vo = 2;
  1238. repeated string productCodes = 3;
  1239. repeated int64 excludeIds = 4;
  1240. }
  1241. message AdPlanListResp {
  1242. int64 total = 1;
  1243. repeated AdPlanVo list = 2;
  1244. }
  1245. // end AdPlan
  1246. // AdPlanDetail
  1247. message AdPlanDetailVo {
  1248. int64 id = 1;
  1249. int64 planId = 2; // 方案ID
  1250. string adPlatform = 3; // 平台
  1251. string adType = 4; // 广告类型
  1252. string adSlot = 5; // 广告位置
  1253. string adDatas = 6; // 广告资源
  1254. string testPolicyConfig = 7; // 策略配置
  1255. string policyConfig = 8; // 策略配置
  1256. int64 sort = 9; // 排序
  1257. Status status = 10; // 0未知,1正常,2暂停
  1258. string remark = 11;
  1259. int64 createTime = 12;
  1260. int64 updateTime = 13;
  1261. string version = 14;
  1262. }
  1263. message AdPlanDetailListReq {
  1264. Page page = 1;
  1265. AdPlanDetailVo vo = 2;
  1266. repeated int64 planIds = 3;
  1267. }
  1268. message AdPlanDetailListResp {
  1269. int64 total = 1;
  1270. repeated AdPlanDetailVo list = 2;
  1271. }
  1272. // end AdPlanDetail
  1273. // AdGlobalConfig
  1274. message AdGlobalConfigVo {
  1275. int64 id = 1;
  1276. string productCode = 2; // 产品code
  1277. string platforms = 3; // 按平台分类的广告配置JSON
  1278. string remark = 4; // 备注
  1279. int64 createTime = 5; // 创建时间
  1280. int64 updateTime = 6; // 更新时间
  1281. }
  1282. message AdGlobalConfigGetReq {
  1283. string productCode = 1; // 产品代码
  1284. }
  1285. // end AdGlobalConfig
  1286. // JobBatch
  1287. message JobBatchVo {
  1288. int64 id = 1; // ID
  1289. string name = 2; // 作业名称
  1290. string type = 3; // 作业类型
  1291. string initParams = 4; // 作业初始化参数
  1292. string contextData = 5; // 上下文数据,可用于存储此次批量作业的任务过程中产生的通用的中间数据
  1293. string beginHandler = 6; // 预处理函数/URL
  1294. string afterHandler = 7; // 后处理函数/URL
  1295. int64 concurrency = 8; // 并发控制数
  1296. string retryPolicy = 9; // 子任务重试策略
  1297. int64 startedTime = 10; // 批量作业开始时间
  1298. int64 finishedTime = 11; // 批量作业完成时间
  1299. string result = 12; // 批量作业返回结果
  1300. string status = 13; // 批量作业完成状态
  1301. string remark = 14; // 备注
  1302. int64 createAt = 15; // 创建者ID
  1303. int64 updateAt = 16; // 更新者ID
  1304. int64 createTime = 17; // 创建时间
  1305. int64 updateTime = 18; // 更新时间
  1306. }
  1307. message JobBatchWithTasksVo {
  1308. JobBatchVo jobBatch = 1;
  1309. repeated JobTasksVo jobTasks = 2;
  1310. }
  1311. message TimeRange {
  1312. int64 start = 1;
  1313. int64 end = 2;
  1314. }
  1315. message JobBatchListReq {
  1316. Page page = 1;
  1317. JobBatchVo vo = 2;
  1318. TimeRange startedTimeRange = 3;
  1319. TimeRange finishedTimeRange = 4;
  1320. repeated string statuses = 5;
  1321. repeated int64 excludeIds = 6;
  1322. }
  1323. message JobBatchListResp {
  1324. int64 total = 1;
  1325. repeated JobBatchVo list = 2;
  1326. }
  1327. message JobBatchListWithTasksResp {
  1328. int64 total = 1;
  1329. repeated JobBatchWithTasksVo list = 2;
  1330. }
  1331. // end JobBatch
  1332. // JobTasks
  1333. message JobTasksVo {
  1334. int64 id = 1; // 任务id
  1335. int64 batchId = 2; // 批量作业Id
  1336. string name = 3; // 任务名称
  1337. string initParams = 4; // 任务初始化配置及数据
  1338. string runtimeData = 5; // 任务运行时数据,用于临时存储任务过程中各个关键节点的中间数据
  1339. string externalRefs = 6; // 外部系统引用,用于记录与外部系统交互产生的关联标识
  1340. int64 startedTime = 7; // 任务开始时间
  1341. int64 finishedTime = 8; // 任务结束时间
  1342. int64 retryCount = 9; // 当前已重试次数
  1343. string result = 10; // 任务执行结果
  1344. string status = 11; // 任务状态
  1345. string remark = 12; // 备注
  1346. int64 createAt = 13; // 创建者ID
  1347. int64 updateAt = 14; // 更新者ID
  1348. int64 createTime = 15; // 创建时间
  1349. int64 updateTime = 16; // 更新时间
  1350. }
  1351. message JobTasksListReq {
  1352. Page page = 1;
  1353. JobTasksVo vo = 2;
  1354. TimeRange startedTimeRange = 3;
  1355. TimeRange finishedTimeRange = 4;
  1356. repeated string statuses = 5;
  1357. repeated int64 excludeIds = 6;
  1358. }
  1359. message JobTasksListResp {
  1360. int64 total = 1;
  1361. repeated JobTasksVo list = 2;
  1362. }
  1363. // end JobTasks
  1364. // DeployConfig
  1365. message DeployConfigVo {
  1366. int64 id = 1; // ID
  1367. string name = 2; // 名称
  1368. string type = 3; // 类型
  1369. string data = 4; // 数据
  1370. Status status = 5; // 状态
  1371. string remark = 6; // 备注
  1372. int64 createTime = 7; // 创建时间
  1373. int64 updateTime = 8; // 更新时间
  1374. }
  1375. message DeployConfigListReq {
  1376. Page page = 1;
  1377. DeployConfigVo vo = 2;
  1378. repeated int64 excludeIds = 3;
  1379. }
  1380. message DeployConfigListResp {
  1381. int64 total = 1;
  1382. repeated DeployConfigVo list = 2;
  1383. }
  1384. // end DeployConfig
  1385. // OperationLog
  1386. message OperationLogVo {
  1387. int64 id = 1;
  1388. int64 sysUserId = 2;
  1389. string productCode = 3;
  1390. string model = 4;
  1391. string action = 5;
  1392. string details = 6;
  1393. string result = 7;
  1394. int64 updateTime = 8;
  1395. int64 createTime = 9;
  1396. }
  1397. message OperationLogListReq {
  1398. Page page = 1;
  1399. OperationLogVo vo = 2;
  1400. repeated string productCodes = 3;
  1401. repeated int64 excludeIds = 4;
  1402. }
  1403. message OperationLogListResp {
  1404. int64 total = 1;
  1405. repeated OperationLogVo list = 2;
  1406. }
  1407. // end OperationLog
  1408. // AnnouncePlan
  1409. message AnnouncePlanVo {
  1410. int64 id = 1;
  1411. string productCode = 2; // 产品code
  1412. string areas = 3; // 地区列表
  1413. int64 sort = 4;
  1414. Status status = 5; // 状态
  1415. string remark = 6;
  1416. int64 createTime = 7;
  1417. int64 updateTime = 8;
  1418. }
  1419. message AnnouncePlanListReq {
  1420. Page page = 1;
  1421. AnnouncePlanVo vo = 2;
  1422. repeated string productCodes = 3;
  1423. repeated int64 excludeIds = 4;
  1424. }
  1425. message AnnouncePlanListResp {
  1426. int64 total = 1;
  1427. repeated AnnouncePlanVo list = 2;
  1428. }
  1429. // end AnnouncePlan
  1430. // AnnouncePlanDetail
  1431. message AnnouncePlanDetailVo {
  1432. int64 id = 1;
  1433. int64 planId = 2; // 方案ID
  1434. string platforms = 3; // 平台
  1435. string channels = 4; // 渠道
  1436. string icon = 5; // 图标
  1437. string title = 6; // 标题
  1438. string content = 7; // 内容
  1439. string url = 8; // 商店地址
  1440. string buttonText = 9; // 按钮文本
  1441. int64 closeable = 10; // 是否可关闭
  1442. int64 sort = 11; // 排序
  1443. string policyConfig = 12; // 更新策略配置
  1444. Status status = 13; // 状态
  1445. string remark = 14;
  1446. int64 createTime = 15;
  1447. int64 updateTime = 16;
  1448. }
  1449. message AnnouncePlanDetailListReq {
  1450. Page page = 1;
  1451. AnnouncePlanDetailVo vo = 2;
  1452. repeated int64 planIds = 3;
  1453. }
  1454. message AnnouncePlanDetailListResp {
  1455. int64 total = 1;
  1456. repeated AnnouncePlanDetailVo list = 2;
  1457. }
  1458. // end AnnouncePlanDetail
  1459. message MessagePushVo {
  1460. int64 id = 1;
  1461. string status = 2;
  1462. int64 operator = 3;
  1463. string module = 4;
  1464. string title = 5;
  1465. string message = 6;
  1466. string imgUrl = 7;
  1467. string data = 8;
  1468. string productCode = 9;
  1469. int64 areaParam = 10;
  1470. repeated string topics = 11;
  1471. repeated string firebaseTokens = 12;
  1472. int64 publishTime = 13;
  1473. int64 createTime = 14;
  1474. int64 updateTime = 15;
  1475. string pushType = 16;
  1476. int64 publishCount = 17;
  1477. string exData = 18;
  1478. }
  1479. message MessagePushListReq {
  1480. Page page = 1;
  1481. MessagePushVo vo = 2;
  1482. }
  1483. message MessagePushListResp {
  1484. int64 total = 1;
  1485. repeated MessagePushVo list = 2;
  1486. }
  1487. // 基础服务: 产品管理,产品配置,升级配置、更新资源管理,资源版本管理,全局配置
  1488. service GoPmpClient {
  1489. rpc Ping(Request) returns (Response);
  1490. // GlobalParamVo Model
  1491. // GlobalParamAdd
  1492. rpc GlobalParamAdd(GlobalParamVo) returns (GlobalParamVo);
  1493. rpc GlobalParamUpdate(GlobalParamVo) returns (GlobalParamVo);
  1494. rpc GlobalParamDel(Ids) returns (Empty);
  1495. rpc GlobalParamGet(GlobalParamVo) returns (GlobalParamVo); // 兼容旧接口,新版本代码中请不要调用
  1496. rpc GlobalParamGetWithLang(GlobalParamGetReq) returns (GlobalParamVo);
  1497. rpc GlobalParamList(GlobalParamListReq) returns (GlobalParamListResp);
  1498. // ProductVo Model
  1499. // ProductAdd
  1500. rpc ProductAdd(ProductVo) returns (ProductVo);
  1501. rpc ProductUpdate(ProductVo) returns (ProductVo);
  1502. rpc ProductDel(Ids) returns (Empty);
  1503. rpc ProductGet(ProductVo) returns (ProductVo);
  1504. rpc ProductList(ProductListReq) returns (ProductListResp);
  1505. rpc ProductAll(Request) returns (ProductListResp);
  1506. // ProductParamVo Model
  1507. // ProductParamAdd
  1508. rpc ProductParamAdd(ProductParamVo) returns (ProductParamVo);
  1509. rpc ProductParamUpdate(ProductParamVo) returns (ProductParamVo);
  1510. rpc ProductParamDel(Ids) returns (Empty);
  1511. rpc ProductParamGet(ProductParamVo) returns (ProductParamVo); // 兼容旧接口,新版本代码中请不要调用
  1512. rpc ProductParamGetWithLang(ProductParamGetReq) returns (ProductParamVo);
  1513. rpc ProductParamList(ProductParamListReq) returns (ProductParamListResp);
  1514. // ProductAction 产品行为配置
  1515. rpc ProductActionAdd(ProductActionVo) returns (ProductActionVo);
  1516. rpc ProductActionUpdate(ProductActionVo) returns (ProductActionVo);
  1517. rpc ProductActionDel(Ids) returns (Empty);
  1518. rpc ProductActionGet(ProductActionReq) returns (ProductActionVo);
  1519. rpc ProductActionList(ProductActionListReq) returns (ProductActionListResp);
  1520. // ProductActionGroup 产品行为分组
  1521. rpc ProductActionGroupAdd(ProductActionGroupVo) returns (ProductActionGroupVo);
  1522. rpc ProductActionGroupUpdate(ProductActionGroupVo) returns (ProductActionGroupVo);
  1523. rpc ProductActionGroupDel(Ids) returns (Empty);
  1524. rpc ProductActionGroupGet(ProductActionGroupReq) returns (ProductActionGroupVo);
  1525. rpc ProductActionGroupList(ProductActionGroupListReq) returns (ProductActionGroupListResp);
  1526. rpc ProductActionGroupDisable(ProductActionGroupDisableReq) returns (Empty);
  1527. rpc ProductActionGroupEnable(ProductActionGroupEnableReq) returns (Empty);
  1528. // ProductActionPolicyGroup 产品行为策略分组
  1529. rpc ProductActionPolicyGroupAdd(ProductActionPolicyGroupVo) returns (ProductActionPolicyGroupVo);
  1530. rpc ProductActionPolicyGroupUpdate(ProductActionPolicyGroupVo) returns (ProductActionPolicyGroupVo);
  1531. rpc ProductActionPolicyGroupDel(Ids) returns (Empty);
  1532. rpc ProductActionPolicyGroupGet(ProductActionPolicyGroupReq) returns (ProductActionPolicyGroupVo);
  1533. rpc ProductActionPolicyGroupList(ProductActionPolicyGroupListReq) returns (ProductActionPolicyGroupListResp);
  1534. rpc ProductActionPolicyGroupDisable(ProductActionPolicyGroupDisableReq) returns (Empty);
  1535. rpc ProductActionPolicyGroupEnable(ProductActionPolicyGroupEnableReq) returns (Empty);
  1536. // ProductActionType 产品行为类型
  1537. rpc ProductActionTypeAdd(ProductActionTypeVo) returns (ProductActionTypeVo);
  1538. rpc ProductActionTypeUpdate(ProductActionTypeVo) returns (ProductActionTypeVo);
  1539. rpc ProductActionTypeDel(Ids) returns (Empty);
  1540. rpc ProductActionTypeGet(ProductActionTypeReq) returns (ProductActionTypeVo);
  1541. rpc ProductActionTypeList(ProductActionTypeListReq) returns (ProductActionTypeListResp);
  1542. // AreaParamVo Model
  1543. // AreaParamAdd
  1544. rpc AreaParamAdd(AreaParamVo) returns (AreaParamVo);
  1545. rpc AreaParamUpdate(AreaParamVo) returns (AreaParamVo);
  1546. rpc AreaParamDel(Ids) returns (Empty);
  1547. rpc AreaParamGet(AreaParamVo) returns (AreaParamVo);
  1548. rpc AreaParamList(AreaParamListReq) returns (AreaParamListResp);
  1549. // NationalLanguage Model
  1550. // NationalLanguageAdd
  1551. rpc NationalLanguageAdd(NationalLanguageVo) returns (NationalLanguageVo);
  1552. rpc NationalLanguageUpdate(NationalLanguageVo) returns (NationalLanguageVo);
  1553. rpc NationalLanguageDel(Ids) returns (Empty);
  1554. rpc NationalLanguageGet(NationalLanguageVo) returns (NationalLanguageVo);
  1555. rpc NationalLanguageList(NationalLanguageListReq) returns (NationalLanguageListResp);
  1556. // Tip Model
  1557. // TipAdd
  1558. rpc TipAdd(TipVo) returns (TipVo);
  1559. rpc TipUpdate(TipVo) returns (TipVo);
  1560. rpc TipDel(Ids) returns (Empty);
  1561. rpc TipGet(TipGetReq) returns (TipVo);
  1562. rpc TipList(TipListReq) returns (TipListResp);
  1563. // Dict Model
  1564. // DictAdd
  1565. rpc DictAdd(DictVo) returns (DictVo);
  1566. rpc DictUpdate(DictVo) returns (DictVo);
  1567. rpc DictDel(Ids) returns (Empty);
  1568. rpc DictGet(DictGetReq) returns (DictVo);
  1569. rpc DictList(DictListReq) returns (DictListResp);
  1570. // // UpgradeRes 热更新代码资源管理
  1571. // rpc UpgradeResAdd(UpgradeResVo) returns (UpgradeResVo);
  1572. // rpc UpgradeResUpdate(UpgradeResVo) returns (Empty);
  1573. // rpc UpgradeResDel(ResourceDelReq) returns (Empty);
  1574. // rpc UpgradeResGet(UpgradeResGetReq) returns (UpgradeResVo);
  1575. // rpc UpgradeResList(UpgradeResListReq) returns (UpgradeResListResp);
  1576. // // UpgradePkg app 包更新管理
  1577. // rpc UpgradePkgAdd(UpgradePkgVo) returns (UpgradePkgVo);
  1578. // rpc UpgradePkgUpdate(UpgradePkgVo) returns (Empty);
  1579. // rpc UpgradePkgDel(Ids) returns (Empty);
  1580. // rpc UpgradePkgGet(UpgradePkgGetReq) returns (UpgradePkgVo);
  1581. // rpc UpgradePkgList(UpgradePkgListReq) returns (UpgradePkgListResp);
  1582. // // UpgradeResConfig Model
  1583. // // UpgradeResConfigAdd
  1584. // 热更新【代码资源】配置管理,控制哪些版本地区的用户可以更新
  1585. // rpc UpgradeResConfigAdd(UpgradeResConfigVo) returns (UpgradeResConfigVo);
  1586. // rpc UpgradeResConfigUpdate(UpgradeResConfigVo) returns (Empty);
  1587. // rpc UpgradeResConfigDel(Ids) returns (Empty);
  1588. // rpc UpgradeResConfigGet(UpgradeResConfigGetReq) returns (UpgradeResConfigVo);
  1589. // rpc UpgradeResConfigList(UpgradeResConfigListReq) returns (UpgradeResConfigListResp);
  1590. // UpgradePkgPlan Model
  1591. // UpgradePkgPlanAdd
  1592. rpc UpgradePkgPlanAdd(UpgradePkgPlanVo) returns (UpgradePkgPlanVo);
  1593. rpc UpgradePkgPlanUpdate(UpgradePkgPlanVo) returns (UpgradePkgPlanVo);
  1594. rpc UpgradePkgPlanDel(Ids) returns (Empty);
  1595. rpc UpgradePkgPlanGet(UpgradePkgPlanVo) returns (UpgradePkgPlanVo);
  1596. rpc UpgradePkgPlanList(UpgradePkgPlanListReq) returns (UpgradePkgPlanListResp);
  1597. // UpgradePkgPlanDetail Model
  1598. // UpgradePkgPlanDetailAdd
  1599. rpc UpgradePkgPlanDetailAdd(UpgradePkgPlanDetailVo) returns (UpgradePkgPlanDetailVo);
  1600. rpc UpgradePkgPlanDetailUpdate(UpgradePkgPlanDetailVo) returns (UpgradePkgPlanDetailVo);
  1601. rpc UpgradePkgPlanDetailDel(Ids) returns (Empty);
  1602. rpc UpgradePkgPlanDetailGet(UpgradePkgPlanDetailVo) returns (UpgradePkgPlanDetailVo);
  1603. rpc UpgradePkgPlanDetailList(UpgradePkgPlanDetailListReq) returns (UpgradePkgPlanDetailListResp);
  1604. // UpgradeResPlan Model
  1605. // UpgradeResPlanAdd
  1606. rpc UpgradeResPlanAdd(UpgradeResPlanVo) returns (UpgradeResPlanVo);
  1607. rpc UpgradeResPlanUpdate(UpgradeResPlanVo) returns (UpgradeResPlanVo);
  1608. rpc UpgradeResPlanDel(Ids) returns (Empty);
  1609. rpc UpgradeResPlanGet(UpgradeResPlanVo) returns (UpgradeResPlanVo);
  1610. rpc UpgradeResPlanList(UpgradeResPlanListReq) returns (UpgradeResPlanListResp);
  1611. // UpgradeResPlanDetail Model
  1612. // UpgradeResPlanDetailAdd
  1613. rpc UpgradeResPlanDetailAdd(UpgradeResPlanDetailVo) returns (UpgradeResPlanDetailVo);
  1614. rpc UpgradeResPlanDetailUpdate(UpgradeResPlanDetailVo) returns (UpgradeResPlanDetailVo);
  1615. rpc UpgradeResPlanDetailDel(Ids) returns (Empty);
  1616. rpc UpgradeResPlanDetailGet(UpgradeResPlanDetailVo) returns (UpgradeResPlanDetailVo);
  1617. rpc UpgradeResPlanDetailList(UpgradeResPlanDetailListReq) returns (UpgradeResPlanDetailListResp);
  1618. // AdPlan Model
  1619. // AdPlanAdd
  1620. rpc AdPlanAdd(AdPlanVo) returns (AdPlanVo);
  1621. rpc AdPlanUpdate(AdPlanVo) returns (AdPlanVo);
  1622. rpc AdPlanDel(Ids) returns (Empty);
  1623. rpc AdPlanGet(AdPlanVo) returns (AdPlanVo);
  1624. rpc AdPlanList(AdPlanListReq) returns (AdPlanListResp);
  1625. // AdPlanDetail Model
  1626. // AdPlanDetailAdd
  1627. rpc AdPlanDetailAdd(AdPlanDetailVo) returns (AdPlanDetailVo);
  1628. rpc AdPlanDetailUpdate(AdPlanDetailVo) returns (AdPlanDetailVo);
  1629. rpc AdPlanDetailDel(Ids) returns (Empty);
  1630. rpc AdPlanDetailGet(AdPlanDetailVo) returns (AdPlanDetailVo);
  1631. rpc AdPlanDetailList(AdPlanDetailListReq) returns (AdPlanDetailListResp);
  1632. // AdGlobalConfig Model
  1633. // AdGlobalConfigGet
  1634. rpc AdGlobalConfigGet(AdGlobalConfigGetReq) returns (AdGlobalConfigVo);
  1635. rpc AdGlobalConfigUpdate(AdGlobalConfigVo) returns (AdGlobalConfigVo);
  1636. // JobBatch Model
  1637. // JobBatchAdd
  1638. rpc JobBatchAdd(JobBatchVo) returns (JobBatchVo);
  1639. rpc JobBatchAddWithTasks(JobBatchWithTasksVo) returns (JobBatchWithTasksVo);
  1640. rpc JobBatchUpdate(JobBatchVo) returns (JobBatchVo);
  1641. rpc JobBatchDel(Ids) returns (Empty);
  1642. rpc JobBatchGet(JobBatchVo) returns (JobBatchVo);
  1643. rpc JobBatchGetWithTasks(JobBatchVo) returns (JobBatchWithTasksVo);
  1644. rpc JobBatchList(JobBatchListReq) returns (JobBatchListResp);
  1645. rpc JobBatchListWithTasks(JobBatchListReq) returns (JobBatchListWithTasksResp);
  1646. // JobTasks Model
  1647. // JobTasksAdd
  1648. rpc JobTasksAdd(JobTasksVo) returns (JobTasksVo);
  1649. rpc JobTasksUpdate(JobTasksVo) returns (JobTasksVo);
  1650. rpc JobTasksDel(Ids) returns (Empty);
  1651. rpc JobTasksGet(JobTasksVo) returns (JobTasksVo);
  1652. rpc JobTasksList(JobTasksListReq) returns (JobTasksListResp);
  1653. // DeployConfig Model
  1654. // DeployConfigAdd
  1655. rpc DeployConfigAdd(DeployConfigVo) returns (DeployConfigVo);
  1656. rpc DeployConfigUpdate(DeployConfigVo) returns (DeployConfigVo);
  1657. rpc DeployConfigDel(Ids) returns (Empty);
  1658. rpc DeployConfigGet(DeployConfigVo) returns (DeployConfigVo);
  1659. rpc DeployConfigList(DeployConfigListReq) returns (DeployConfigListResp);
  1660. // OperationLog Model
  1661. // OperationLogAdd
  1662. rpc OperationLogAdd(OperationLogVo) returns (OperationLogVo);
  1663. rpc OperationLogUpdate(OperationLogVo) returns (OperationLogVo);
  1664. rpc OperationLogGet(OperationLogVo) returns (OperationLogVo);
  1665. rpc OperationLogList(OperationLogListReq) returns (OperationLogListResp);
  1666. // AnnouncePlan Model
  1667. // AnnouncePlanAdd
  1668. rpc AnnouncePlanAdd(AnnouncePlanVo) returns (AnnouncePlanVo);
  1669. rpc AnnouncePlanUpdate(AnnouncePlanVo) returns (AnnouncePlanVo);
  1670. rpc AnnouncePlanDel(Ids) returns (Empty);
  1671. rpc AnnouncePlanGet(AnnouncePlanVo) returns (AnnouncePlanVo);
  1672. rpc AnnouncePlanList(AnnouncePlanListReq) returns (AnnouncePlanListResp);
  1673. // AnnouncePlanDetail Model
  1674. // AnnouncePlanDetailAdd
  1675. rpc AnnouncePlanDetailAdd(AnnouncePlanDetailVo) returns (AnnouncePlanDetailVo);
  1676. rpc AnnouncePlanDetailUpdate(AnnouncePlanDetailVo) returns (AnnouncePlanDetailVo);
  1677. rpc AnnouncePlanDetailDel(Ids) returns (Empty);
  1678. rpc AnnouncePlanDetailGet(AnnouncePlanDetailVo) returns (AnnouncePlanDetailVo);
  1679. rpc AnnouncePlanDetailList(AnnouncePlanDetailListReq) returns (AnnouncePlanDetailListResp);
  1680. // MessagePush Model
  1681. // MessagePushAdd
  1682. rpc MessagePushAdd(MessagePushVo) returns (MessagePushVo);
  1683. rpc MessagePushUpdate(MessagePushVo) returns (MessagePushVo);
  1684. rpc MessagePushList(MessagePushListReq) returns (MessagePushListResp);
  1685. }
  1686. message ShortDramaEpisodeVo {
  1687. int64 id = 1;
  1688. int64 dramaId = 2;
  1689. int64 type = 3;
  1690. string name = 4;
  1691. int64 sort = 5;
  1692. string videos = 6;
  1693. string subtitles = 7;
  1694. Status status = 8;
  1695. int64 createTime = 9;
  1696. int64 updateTime = 10;
  1697. string danmakuUrl = 11;
  1698. }
  1699. message ShortDramaEpisodeGetReq { ShortDramaEpisodeVo vo = 1; }
  1700. message ShortDramaEpisodeListReq {
  1701. Page page = 1;
  1702. ShortDramaEpisodeVo vo = 2;
  1703. repeated int64 dramaIds = 3;
  1704. }
  1705. message ShortDramaEpisodeListResp {
  1706. int64 total = 1;
  1707. repeated ShortDramaEpisodeVo list = 2;
  1708. }
  1709. message ShortDramaEpisodeBatchAddReq {
  1710. int64 dramaId = 1;
  1711. repeated ShortDramaEpisodeVo episodes = 2;
  1712. }
  1713. message ShortDramaEpisodeBatchRefreshUpdateTimeReq { int64 dramaId = 1; }
  1714. message ShortDramaLanguageVo {
  1715. int64 id = 1;
  1716. int64 dramaId = 2;
  1717. string lang = 3;
  1718. string title = 4;
  1719. string description = 5;
  1720. string covers = 6;
  1721. string coverDominantColor = 7;
  1722. int64 createTime = 8;
  1723. int64 updateTime = 9;
  1724. }
  1725. message ShortDramaVo {
  1726. int64 id = 1;
  1727. string productCodes = 2;
  1728. string title = 3;
  1729. string description = 4;
  1730. string covers = 5;
  1731. string coverDominantColor = 6;
  1732. string type = 7;
  1733. string tags = 8;
  1734. string releaseRegions = 9;
  1735. int64 releaseDate = 10;
  1736. int64 totalEpisodes = 11;
  1737. int64 completedStatus = 12;
  1738. string copyrightSupplier = 13;
  1739. string copyrightDoc = 14;
  1740. int64 copyrightPurchaseDate = 15;
  1741. int64 copyrightExpireDate = 16;
  1742. int64 status = 17;
  1743. int64 createTime = 18;
  1744. int64 updateTime = 19;
  1745. string ghostCutId = 20;
  1746. int64 recommend = 21;
  1747. string otherConfig = 22;
  1748. repeated ShortDramaLanguageVo shortDramaLanguages = 23;
  1749. int64 mainEpisodeCount = 24;
  1750. int64 trailerEpisodeCount = 25;
  1751. int64 copyrightId = 26;
  1752. int64 creator = 27;
  1753. int64 modifier = 28;
  1754. string operationTags = 29;
  1755. string extraInfo = 30;
  1756. int64 schedulePublishTime = 31;
  1757. int64 publishTime = 32;
  1758. }
  1759. message ShortDramaGetReq {
  1760. ShortDramaVo vo = 1;
  1761. string productCode = 2;
  1762. string countryCode = 3;
  1763. string lang = 4;
  1764. }
  1765. message ShortDramaListReq {
  1766. Page page = 1;
  1767. ShortDramaVo vo = 2;
  1768. repeated int64 excludeIds = 3;
  1769. string productCode = 4;
  1770. string countryCode = 5;
  1771. string lang = 6;
  1772. string publishTimeStart = 7;
  1773. string publishTimeEnd = 8;
  1774. repeated int64 statusList = 9;
  1775. }
  1776. message ShortDramaListResp {
  1777. int64 total = 1;
  1778. repeated ShortDramaVo list = 2;
  1779. }
  1780. message ShortDramaLanguageListReq {
  1781. Page page = 1;
  1782. ShortDramaLanguageVo vo = 2;
  1783. }
  1784. message ShortDramaLanguageListResp {
  1785. int64 total = 1;
  1786. repeated ShortDramaLanguageVo list = 2;
  1787. }
  1788. message ShortDramaEpisodeCountVo {
  1789. int64 dramaId = 1;
  1790. int64 episodeCount = 2;
  1791. }
  1792. message ShortDramaEpisodeCountReq {
  1793. Page page = 1;
  1794. Status status = 2;
  1795. int64 type = 3;
  1796. repeated int64 dramaIds = 4;
  1797. }
  1798. message ShortDramaEpisodeCountResp {
  1799. int64 total = 1;
  1800. repeated ShortDramaEpisodeCountVo list = 2;
  1801. }
  1802. message ShortDramaCheckNameReq {
  1803. string title = 1; // 短剧名称
  1804. int64 id = 2; // 编辑时排除当前短剧ID
  1805. }
  1806. message ShortDramaCheckNameResp {
  1807. bool exists = 1; // 是否存在
  1808. }
  1809. message ShortDramaUpdateModifierReq {
  1810. int64 id = 1;
  1811. int64 modifier = 2;
  1812. }
  1813. message ShortDramaUpdateReleaseRegionsReq {
  1814. int64 id = 1;
  1815. string releaseRegions = 2;
  1816. }
  1817. message ShortDramaCopyrightInfoVo {
  1818. int64 id = 1;
  1819. int64 copyrightId = 2;
  1820. string releaseRegions = 3;
  1821. }
  1822. message ShortDramaFindIdsWithCopyrightResp {
  1823. repeated ShortDramaCopyrightInfoVo list = 1;
  1824. }
  1825. message SetTotalStatsReq {
  1826. int64 dramaId = 1;
  1827. string country = 2;
  1828. int64 todayPlayCount = 3;
  1829. int64 weeklyPlayCount = 4;
  1830. int64 monthlyPlayCount = 5;
  1831. }
  1832. message ShortDramaStatsPlaysTotalVo {
  1833. int64 id = 1;
  1834. int64 dramaId = 2;
  1835. string country = 3;
  1836. int64 todayPlayCount = 4;
  1837. int64 weeklyPlayCount = 5;
  1838. int64 monthlyPlayCount = 6;
  1839. int64 createTime = 7;
  1840. int64 updateTime = 8;
  1841. }
  1842. message ShortDramaStatsPlaysTotalListReq {
  1843. Page page = 1;
  1844. string country = 2; // 国家代码
  1845. }
  1846. message ShortDramaStatsPlaysTotalListResp {
  1847. int64 total = 1;
  1848. repeated ShortDramaStatsPlaysTotalVo list = 2;
  1849. }
  1850. message FindSchedulePublishListReq { int64 status = 1; }
  1851. message FindSchedulePublishListResp { repeated ShortDramaVo list = 1; }
  1852. message PublishScheduleDramaReq {
  1853. repeated int64 ids = 1; // 短剧ID列表,支持批量操作
  1854. int64 targetStatus = 2; // 目标状态
  1855. }
  1856. service GoShortDramaClient {
  1857. // ShortDrama
  1858. rpc ShortDramaAdd(ShortDramaVo) returns (ShortDramaVo);
  1859. rpc ShortDramaUpdate(ShortDramaVo) returns (Empty);
  1860. rpc ShortDramaDel(Ids) returns (Empty);
  1861. rpc ShortDramaGet(ShortDramaGetReq) returns (ShortDramaVo);
  1862. rpc ShortDramaList(ShortDramaListReq) returns (ShortDramaListResp);
  1863. rpc ShortDramaUpdateModifier(ShortDramaUpdateModifierReq) returns (Empty);
  1864. rpc ShortDramaUpdateReleaseRegions(ShortDramaUpdateReleaseRegionsReq)
  1865. returns (Empty);
  1866. rpc ShortDramaFindIdsWithCopyright(Empty)
  1867. returns (ShortDramaFindIdsWithCopyrightResp);
  1868. rpc ShortDramaFindSchedulePublishList(FindSchedulePublishListReq)
  1869. returns (FindSchedulePublishListResp);
  1870. rpc ShortDramaPublishSchedule(PublishScheduleDramaReq) returns (Empty);
  1871. // ShortDramaLanguage
  1872. rpc ShortDramaLanguageList(ShortDramaLanguageListReq)
  1873. returns (ShortDramaLanguageListResp);
  1874. // ShortDramaEpisode
  1875. rpc ShortDramaEpisodeAdd(ShortDramaEpisodeVo) returns (ShortDramaEpisodeVo);
  1876. rpc ShortDramaEpisodeBatchAdd(ShortDramaEpisodeBatchAddReq) returns (Empty);
  1877. rpc ShortDramaEpisodeUpdate(ShortDramaEpisodeVo) returns (Empty);
  1878. rpc ShortDramaEpisodeDel(Ids) returns (Empty);
  1879. rpc ShortDramaEpisodeGet(ShortDramaEpisodeGetReq)
  1880. returns (ShortDramaEpisodeVo);
  1881. rpc ShortDramaEpisodeList(ShortDramaEpisodeListReq)
  1882. returns (ShortDramaEpisodeListResp);
  1883. rpc ShortDramaEpisodeBatchRefreshUpdateTime(
  1884. ShortDramaEpisodeBatchRefreshUpdateTimeReq) returns (Empty);
  1885. // ShortDramaEpisodeCount
  1886. rpc ShortDramaEpisodeCount(ShortDramaEpisodeCountReq)
  1887. returns (ShortDramaEpisodeCountResp);
  1888. rpc ShortDramaCheckName(ShortDramaCheckNameReq)
  1889. returns (ShortDramaCheckNameResp);
  1890. // ShortDramaStats
  1891. rpc SetTotalStats(SetTotalStatsReq) returns (Empty);
  1892. // ShortDramaStatsPlaysTotal
  1893. rpc ShortDramaStatsPlaysTotalList(ShortDramaStatsPlaysTotalListReq)
  1894. returns (ShortDramaStatsPlaysTotalListResp);
  1895. }
  1896. // 根据需要增加状态
  1897. message SysUserVo {
  1898. int64 id = 1; // ID
  1899. string username = 2; // 登录名
  1900. string password = 3; // 登录密码
  1901. string nickname = 4; // 昵称
  1902. string avatar = 5; // 头像
  1903. string email = 6; // 邮箱
  1904. string phone = 7; // 手机号
  1905. string remark = 8; // 备注
  1906. BoolInt isSuperAdmin = 9; // 是否为超级管理员 1是 2否
  1907. int64 permsLevel = 10; // 权限等级 值越大 权限越小
  1908. Status status = 11; // 状态 1正常 2冻结
  1909. int64 createTime = 12; // 创建时间
  1910. int64 updateTime = 13; // 修改时间
  1911. }
  1912. message SysRoleVo {
  1913. int64 id = 1; // ID
  1914. string productCode = 2; // 所属产品
  1915. string name = 3; // 角色名
  1916. string remark = 4; // 备注
  1917. Status status = 5; // 状态 1启用 2禁用
  1918. int64 createTime = 6; // 创建时间
  1919. int64 updateTime = 7; // 修改时间
  1920. int64 permsLevel = 8; // 权限等级 值越大 权限越小
  1921. }
  1922. message SysPermVo {
  1923. int64 id = 1; // ID
  1924. string name = 2; // 权限名
  1925. string code = 3; // 权限code
  1926. string remark = 4; // 备注
  1927. Status status = 5; // 状态 1启用 2禁用
  1928. int64 createTime = 6; // 创建时间
  1929. int64 updateTime = 7; // 修改时间
  1930. }
  1931. message SysUserRoleVo {
  1932. int64 id = 1; // ID
  1933. int64 userId = 2; // 用户ID
  1934. int64 roleId = 3; // 角色ID
  1935. int64 createTime = 4; // 创建时间
  1936. int64 updateTime = 5; // 修改时间
  1937. }
  1938. message SysRolePermVo {
  1939. int64 id = 1; // ID
  1940. int64 roleId = 2; // 角色ID
  1941. int64 permId = 3; // 权限ID
  1942. int64 createTime = 4; // 创建时间
  1943. int64 updateTime = 5; // 修改时间
  1944. }
  1945. message SysUserPermVo {
  1946. int64 id = 1; // ID
  1947. int64 userId = 2; // 用户ID
  1948. int64 permId = 3; // 权限ID
  1949. string effect = 4; // 权限控制策略 ALLOW允许 DENY拒绝
  1950. int64 createTime = 5; // 创建时间
  1951. int64 updateTime = 6; // 修改时间
  1952. }
  1953. message SysPermRule {
  1954. int64 permId = 1;
  1955. string effect = 2; // ALLOW允许 DENY拒绝
  1956. }
  1957. message SysUserWithRoleIdsAndPermRules {
  1958. SysUserVo user = 1; // 用户信息
  1959. repeated int64 roleIds = 2; // 角色
  1960. repeated SysPermRule permRules = 3; // 权限
  1961. }
  1962. message SysUserWithRolesAndPerms {
  1963. SysUserVo user = 1; // 用户信息
  1964. repeated SysRoleVo roles = 2; // 角色
  1965. repeated SysPermVo perms = 3; // 权限
  1966. }
  1967. message SysUserGetReq { SysUserVo vo = 1; }
  1968. message SysUserListReq {
  1969. Page page = 1;
  1970. SysUserVo vo = 2;
  1971. repeated int64 excludeIds = 3; // 排除的ID
  1972. }
  1973. message SysUserListResp {
  1974. int64 total = 1;
  1975. repeated SysUserVo list = 2;
  1976. }
  1977. message SysUserListWithRolesAndPermsResp {
  1978. int64 total = 1;
  1979. repeated SysUserWithRolesAndPerms list = 2;
  1980. }
  1981. message SysRoleWithPermIds {
  1982. SysRoleVo role = 1;
  1983. repeated int64 permIds = 2;
  1984. }
  1985. message SysRoleWithPerms {
  1986. SysRoleVo role = 1;
  1987. repeated SysPermVo perms = 2;
  1988. }
  1989. message SysRoleGetReq { SysRoleVo vo = 1; }
  1990. message SysRoleListReq {
  1991. Page page = 1;
  1992. SysRoleVo vo = 2;
  1993. repeated string productCodes = 3; // 所属产品
  1994. repeated int64 excludeIds = 4; // 排除的ID
  1995. }
  1996. message SysRoleListResp {
  1997. int64 total = 1;
  1998. repeated SysRoleVo list = 2;
  1999. }
  2000. message SysRoleListWithPermsResp {
  2001. int64 total = 1;
  2002. repeated SysRoleWithPerms list = 2;
  2003. }
  2004. message SysPermGetReq { SysPermVo vo = 1; }
  2005. message SysPermListReq {
  2006. Page page = 1;
  2007. SysPermVo vo = 2;
  2008. repeated int64 excludeIds = 3; // 排除的ID
  2009. }
  2010. message SysPermListResp {
  2011. int64 total = 1;
  2012. repeated SysPermVo list = 2;
  2013. }
  2014. message SysUserRoleGetReq { SysUserRoleVo vo = 1; }
  2015. message SysUserRoleListReq {
  2016. Page page = 1;
  2017. SysUserRoleVo vo = 2;
  2018. repeated int64 excludeIds = 3; // 排除的ID
  2019. }
  2020. message SysUserRoleListResp {
  2021. int64 total = 1;
  2022. repeated SysUserRoleVo list = 2;
  2023. }
  2024. message SysRolePermGetReq { SysRolePermVo vo = 1; }
  2025. message SysRolePermListReq {
  2026. Page page = 1;
  2027. SysRolePermVo vo = 2;
  2028. repeated int64 excludeIds = 3; // 排除的ID
  2029. }
  2030. message SysRolePermListResp {
  2031. int64 total = 1;
  2032. repeated SysRolePermVo list = 2;
  2033. }
  2034. message SysUserPermGetReq { SysUserPermVo vo = 1; }
  2035. message SysUserPermListReq {
  2036. Page page = 1;
  2037. SysUserPermVo vo = 2;
  2038. repeated int64 excludeIds = 3; // 排除的ID
  2039. }
  2040. message SysUserPermListResp {
  2041. int64 total = 1;
  2042. repeated SysUserPermVo list = 2;
  2043. }
  2044. service GoSysClient {
  2045. rpc Ping(Request) returns (Response);
  2046. // 用户管理
  2047. rpc SysUserAdd(SysUserVo) returns (SysUserVo);
  2048. rpc SysUserUpdate(SysUserVo) returns (SysUserVo);
  2049. rpc SysUserDelete(Ids) returns (Empty);
  2050. rpc SysUserGet(SysUserGetReq) returns (SysUserVo);
  2051. rpc SysUserList(SysUserListReq) returns (SysUserListResp);
  2052. rpc SysUserAddWithRolesAndPerms(SysUserWithRoleIdsAndPermRules) returns (SysUserWithRolesAndPerms);
  2053. rpc SysUserUpdateWithRolesAndPerms(SysUserWithRoleIdsAndPermRules) returns (SysUserWithRolesAndPerms);
  2054. rpc SysUserGetWithRolesAndPerms(SysUserGetReq) returns (SysUserWithRolesAndPerms);
  2055. rpc SysUserListWithRolesAndPerms(SysUserListReq) returns (SysUserListWithRolesAndPermsResp);
  2056. // 角色管理
  2057. rpc SysRoleAdd(SysRoleVo) returns (SysRoleVo);
  2058. rpc SysRoleUpdate(SysRoleVo) returns (SysRoleVo);
  2059. rpc SysRoleDelete(Ids) returns (Empty);
  2060. rpc SysRoleGet(SysRoleGetReq) returns (SysRoleVo);
  2061. rpc SysRoleList(SysRoleListReq) returns (SysRoleListResp);
  2062. rpc SysRoleAddWithPerms(SysRoleWithPermIds) returns (SysRoleWithPerms);
  2063. rpc SysRoleUpdateWithPerms(SysRoleWithPermIds) returns (SysRoleWithPerms);
  2064. rpc SysRoleGetWithPerms(SysRoleGetReq) returns (SysRoleWithPerms);
  2065. rpc SysRoleListWithPerms(SysRoleListReq) returns (SysRoleListWithPermsResp);
  2066. // 权限管理
  2067. rpc SysPermAdd(SysPermVo) returns (SysPermVo);
  2068. rpc SysPermUpdate(SysPermVo) returns (SysPermVo);
  2069. rpc SysPermDelete(Ids) returns (Empty);
  2070. rpc SysPermGet(SysPermGetReq) returns (SysPermVo);
  2071. rpc SysPermList(SysPermListReq) returns (SysPermListResp);
  2072. // 用户角色管理
  2073. rpc SysUserRoleAdd(SysUserRoleVo) returns (SysUserRoleVo);
  2074. rpc SysUserRoleUpdate(SysUserRoleVo) returns (SysUserRoleVo);
  2075. rpc SysUserRoleDelete(Ids) returns (Empty);
  2076. rpc SysUserRoleGet(SysUserRoleGetReq) returns (SysUserRoleVo);
  2077. rpc SysUserRoleList(SysUserRoleListReq) returns (SysUserRoleListResp);
  2078. // 角色权限管理
  2079. rpc SysRolePermAdd(SysRolePermVo) returns (SysRolePermVo);
  2080. rpc SysRolePermUpdate(SysRolePermVo) returns (SysRolePermVo);
  2081. rpc SysRolePermDelete(Ids) returns (Empty);
  2082. rpc SysRolePermGet(SysRolePermGetReq) returns (SysRolePermVo);
  2083. rpc SysRolePermList(SysRolePermListReq) returns (SysRolePermListResp);
  2084. // 用户权限管理
  2085. rpc SysUserPermAdd(SysUserPermVo) returns (SysUserPermVo);
  2086. rpc SysUserPermUpdate(SysUserPermVo) returns (SysUserPermVo);
  2087. rpc SysUserPermDelete(Ids) returns (Empty);
  2088. rpc SysUserPermGet(SysUserPermGetReq) returns (SysUserPermVo);
  2089. rpc SysUserPermList(SysUserPermListReq) returns (SysUserPermListResp);
  2090. }
  2091. // 白名单表
  2092. message UserWhiteVo {
  2093. int64 id = 1; // 主键ID
  2094. string userIdentifier = 2; // 用户
  2095. UserType userType = 3; // 用户类型 1 设备 2 账号
  2096. Status status = 4; // 状态
  2097. int64 createTime = 5; // 创建时间
  2098. int64 updateTime = 6; // 更新时间
  2099. }
  2100. // 测试用户表
  2101. message UserTestVo {
  2102. int64 id = 1; // 主键ID
  2103. string userIdentifier = 2; // 用户
  2104. UserType userType = 3; // 用户类型 1 设备 2 账号
  2105. string area = 4; // 指定地区
  2106. string apis = 5; // 指定接口
  2107. string routers = 6; // 指定路由
  2108. Status status = 7; // 状态
  2109. int64 createTime = 8; // 创建时间
  2110. int64 updateTime = 9; // 更新时间
  2111. }
  2112. // Account
  2113. message AccountVo {
  2114. int64 id = 1; // 主键ID
  2115. string userUuid = 2; // 用户UUID
  2116. string productCode = 3; // 产品ID
  2117. string username = 4; // 用户名
  2118. string password = 5; // 密码
  2119. string accountKey = 6; // 账号KEY
  2120. string accountPassword = 7; // 账号密码
  2121. int64 accountType = 8; // 账号类型
  2122. int64 registMode = 9; // 注册方式
  2123. string provider = 10; // 授权登录标识
  2124. BoolInt whitelistUser = 11; // 白名单用户
  2125. BoolInt activated = 12; // 是否激活
  2126. string config = 13; // 配置
  2127. Status status = 14; // 状态
  2128. string avatar = 15; // 头像
  2129. string area = 16; // 指定地区
  2130. string remark = 17; // 备注
  2131. string deviceId = 18; // 设备ID
  2132. string platform = 19; // 平台
  2133. string channel = 20; // 渠道
  2134. string deviceModel = 21; // 设备型号
  2135. string deviceOs = 22; // 设备系统
  2136. int64 timezone = 23; // 时区
  2137. string lang = 24; // 语言
  2138. string ip = 25; // IP
  2139. string country = 26; // 国家
  2140. string province = 27; // 省份
  2141. string city = 28; // 城市
  2142. string isp = 29; // ISP
  2143. int64 appVer = 30; // 产品版本号
  2144. int64 appRuntimeCode = 31; // 产品运行码
  2145. int64 createTime = 32; // 创建时间
  2146. int64 updateTime = 33; // 更新时间
  2147. string version = 34; // 数据版本
  2148. string sessionId = 35; // 登录凭证
  2149. int64 sessionCreateTime = 36; // 凭证创建时间
  2150. }
  2151. message AccountListReq {
  2152. Page page = 1;
  2153. AccountVo vo = 2;
  2154. repeated string productCodes = 3; // 产品code
  2155. repeated int64 excludeIds = 4; // 排除的ID
  2156. }
  2157. message AccountListResp {
  2158. int64 total = 1;
  2159. repeated AccountVo list = 2;
  2160. }
  2161. // AccountDevice
  2162. message AccountDeviceVo {
  2163. int64 id = 1;
  2164. int64 accountId = 2; // 用户ID
  2165. int64 deviceId = 3; // 设备ID
  2166. string sessionId = 4; // 登录凭证
  2167. int64 sessionCreateTime = 5; // 凭证创建时间
  2168. int64 updateTime = 6;
  2169. int64 createTime = 7;
  2170. }
  2171. message AccountDeviceListReq {
  2172. Page page = 1;
  2173. AccountDeviceVo vo = 2;
  2174. repeated int64 excludeIds = 3; // 排除的ID
  2175. }
  2176. message AccountDeviceListResp {
  2177. int64 total = 1;
  2178. repeated AccountDeviceVo list = 2;
  2179. }
  2180. message UserWhiteListReq {
  2181. Page page = 1;
  2182. UserWhiteVo vo = 2;
  2183. repeated int64 excludeIds = 3; // 排除的ID
  2184. }
  2185. message UserWhiteListResp {
  2186. int64 total = 1;
  2187. repeated UserWhiteVo list = 2;
  2188. }
  2189. message UserWhiteAddReq { UserWhiteVo vo = 1; }
  2190. message UserWhiteAddResp { UserWhiteVo vo = 1; }
  2191. message UserWhiteGetReq { UserWhiteVo vo = 1; }
  2192. message UserWhiteGetResp { UserWhiteVo vo = 1; }
  2193. message UserWhiteUpdateReq { UserWhiteVo vo = 1; }
  2194. message UserWhiteUpdateResp { UserWhiteVo vo = 1; }
  2195. message UserWhiteDelReq { repeated int64 ids = 1; }
  2196. message UserTestListReq {
  2197. Page page = 1;
  2198. UserTestVo vo = 2;
  2199. repeated int64 excludeIds = 3; // 排除的ID
  2200. }
  2201. message UserTestListResp {
  2202. int64 total = 1;
  2203. repeated UserTestVo list = 2;
  2204. }
  2205. message UserTestAddReq { UserTestVo vo = 1; }
  2206. message UserTestAddResp { UserTestVo vo = 1; }
  2207. message UserTestGetReq { UserTestVo vo = 1; }
  2208. message UserTestGetResp { UserTestVo vo = 1; }
  2209. message UserTestUpdateReq { UserTestVo vo = 1; }
  2210. message UserTestUpdateResp { UserTestVo vo = 1; }
  2211. message UserTestDelReq { repeated int64 ids = 1; }
  2212. // 用户服务订阅权益表
  2213. message UserServiceVo {
  2214. int64 id = 1; // 主键ID
  2215. string userUuid = 2; // 用户UUID
  2216. string productCode = 3; // 产品ID
  2217. int64 ownerId = 4; // 服务所有者ID
  2218. int64 servicePlanId = 5; // 内部套餐ID
  2219. int64 serviceChannelPlanId = 6; // 渠道套餐ID
  2220. // int64 serviceTypeId = 6; // 服务类型ID
  2221. int64 licenseDays = 7; // 授权天数
  2222. int64 licenseMinutes = 8; // 授权分钟数
  2223. int64 userLevel = 9; // 用户等级
  2224. int64 deviceLimit = 10; // 设备数量限制
  2225. int64 speedLimit = 11; // 速度限制
  2226. int64 trafficLimit = 12; // 流量限制
  2227. // int64 state = 13; // 状态
  2228. Status status = 14; // 状态
  2229. int64 createTime = 15; // 创建时间
  2230. int64 updateTime = 16; // 更新时间
  2231. int64 startTime = 17; // 套餐开始时间
  2232. }
  2233. message UserServiceAddReq { UserServiceVo vo = 1; }
  2234. message UserServiceAddResp { UserServiceVo vo = 1; }
  2235. message UserServiceUpdateReq { UserServiceVo vo = 1; }
  2236. message UserServiceUpdateResp { UserServiceVo vo = 1; }
  2237. message UserServiceDelReq { repeated int64 ids = 1; }
  2238. message UserServiceGetReq { UserServiceVo vo = 1; }
  2239. message UserServiceGetResp { UserServiceVo vo = 1; }
  2240. message UserServiceListReq {
  2241. Page page = 1;
  2242. UserServiceVo vo = 2;
  2243. repeated int64 excludeIds = 3; // 排除的ID
  2244. repeated int64 userIds = 4; // 用户ID
  2245. repeated int64 dids = 5; // device 表的 id
  2246. }
  2247. message UserServiceListResp {
  2248. int64 total = 1;
  2249. repeated UserServiceVo list = 2;
  2250. }
  2251. message DeviceVo {
  2252. int64 id = 1;
  2253. string userUuid = 2;
  2254. string productCode = 3;
  2255. string deviceId = 4;
  2256. string accountKey = 5;
  2257. string accountPassword = 6;
  2258. string platform = 7;
  2259. string channel = 8;
  2260. string referChannel = 9;
  2261. string deviceModel = 10;
  2262. string deviceOs = 11;
  2263. int64 timezone = 12;
  2264. string lang = 13;
  2265. int64 appVer = 14;
  2266. string ip = 15;
  2267. string country = 16;
  2268. string province = 17;
  2269. string city = 18;
  2270. string isp = 19;
  2271. int64 createTime = 20;
  2272. int64 updateTime = 21;
  2273. Status status = 22;
  2274. string refer = 23;
  2275. int64 whitelistUser = 24; // 白名单用户 1正常用户 2: 白名单用户
  2276. int64 testUser = 25; // 测试用户 1正常用户 2: 测试用户
  2277. string mockCountry = 26; // 指定国家
  2278. string mockApi = 27; // 指定API
  2279. string mockRouter = 28; // 指定路由
  2280. string referSubChannel = 29;
  2281. string firebaseToken = 30; // firebase token
  2282. string appVerName = 31; // 版本
  2283. }
  2284. message DeviceListReq {
  2285. Page page = 1;
  2286. DeviceVo vo = 2;
  2287. repeated string productCodes = 3; // 产品code
  2288. repeated int64 excludeIds = 4; // 排除的ID
  2289. repeated string dateRange = 5; // 日期范围
  2290. int64 createStartTime = 6; // 创建开始时间
  2291. int64 createEndTime = 7; // 创建结束时间
  2292. repeated string deviceIds = 8; // 设备IDs
  2293. string country = 9; // 国家
  2294. string vn = 10; // 运营商
  2295. }
  2296. message DeviceListRes {
  2297. int64 total = 1;
  2298. repeated DeviceVo list = 2;
  2299. }
  2300. message UserAppConfigVo {
  2301. int64 id = 1;
  2302. string deviceId = 2;
  2303. string key = 3;
  2304. string value = 4;
  2305. Status status = 5;
  2306. int64 createTime = 6;
  2307. int64 updateTime = 7;
  2308. }
  2309. message UserAppConfigGetReq { UserAppConfigVo vo = 1; }
  2310. message UserAppConfigListReq {
  2311. Page page = 1;
  2312. UserAppConfigVo vo = 2;
  2313. }
  2314. message UserAppConfigListRes {
  2315. int64 total = 1;
  2316. repeated UserAppConfigVo list = 2;
  2317. }
  2318. message UserVo {
  2319. int64 id = 1; // ID
  2320. string productCode = 2; // 产品标识
  2321. string uuid = 3; // 用户唯一ID
  2322. string deviceId = 4; // 注册时使用的设备ID
  2323. int64 accountType = 5; // 值为1时表示实体尚未注册账号, 为其他值时表示实体已经注册了账号(为了让 productCode+deviceId+accountType 能唯一确定一个用户)
  2324. string registType = 6; // 注册方式 normal email phone wechat qq google apple (其实可以通过查询 user_credential 中最早的一条记录的 identityType 来确定)
  2325. int64 registFrom = 7; // 从哪里注册 0: unknown 1: guest 2: app 3: web 4: pc 9999: invalid
  2326. string referChannel = 8; // 推广渠道
  2327. string referSubChannel = 9; // 推广子渠道
  2328. string nickname = 10; // 用户昵称
  2329. string avatar = 11; // 用户头像地址
  2330. string config = 12; // 保留字段,用于扩展
  2331. Status status = 13; // 状态 1: 正常 2: 冻结
  2332. int64 createTime = 14; // 创建时间
  2333. int64 updateTime = 15; // 修改时间
  2334. }
  2335. message UserAddReq { UserVo vo = 1; }
  2336. message UserAddResp { UserVo vo = 1; }
  2337. message UserUpdateReq { UserVo vo = 1; }
  2338. message UserUpdateResp { UserVo vo = 1; }
  2339. message UserDelReq { repeated int64 ids = 1; }
  2340. message UserGetReq { UserVo vo = 1; }
  2341. message UserGetResp { UserVo vo = 1; }
  2342. message UserListReq {
  2343. Page page = 1;
  2344. UserVo vo = 2;
  2345. repeated int64 excludeIds = 3; // 排除的ID
  2346. repeated string productCodes = 4; // 产品code
  2347. repeated string uuids = 5; // 用户唯一ID
  2348. repeated string deviceIds = 6; // 设备ID (device 表的 id)
  2349. }
  2350. message UserListResp {
  2351. int64 total = 1;
  2352. repeated UserVo list = 2;
  2353. }
  2354. message UserCredentialVo {
  2355. int64 id = 1; // ID
  2356. int64 userId = 2; // 用户ID
  2357. string productCode = 3; // 产品标识
  2358. string identityType = 4; // 凭证类型: username, email, phone, wechat, qq, google, apple 等
  2359. string identifier = 5; // 凭证标识
  2360. string credential = 6; // 凭证密钥(密码/token)
  2361. int64 isVerified = 7; // 是否已验证 1: 已验证 2: 未验证
  2362. int64 registFrom = 8; // 从哪里注册 0: unknown 1: guest 2: app 3: web 4: pc 9999: invalid
  2363. Status status = 9; // 状态 1: 正常 2: 禁用
  2364. int64 createTime = 10; // 创建时间/注册时间
  2365. int64 updateTime = 11; // 更新时间
  2366. }
  2367. message UserCredentialAddReq { UserCredentialVo vo = 1; }
  2368. message UserCredentialAddResp { UserCredentialVo vo = 1; }
  2369. message UserCredentialUpdateReq { UserCredentialVo vo = 1; }
  2370. message UserCredentialUpdateResp { UserCredentialVo vo = 1; }
  2371. message UserCredentialDelReq { repeated int64 ids = 1; }
  2372. message UserCredentialGetReq { UserCredentialVo vo = 1; }
  2373. message UserCredentialGetResp { UserCredentialVo vo = 1; }
  2374. message UserCredentialListReq {
  2375. Page page = 1;
  2376. UserCredentialVo vo = 2;
  2377. repeated int64 excludeIds = 3; // 排除的ID
  2378. repeated int64 userIds = 4; // 用户ID
  2379. }
  2380. message UserCredentialListResp {
  2381. int64 total = 1;
  2382. repeated UserCredentialVo list = 2;
  2383. }
  2384. message UserDeviceVo {
  2385. int64 id = 1; // ID
  2386. int64 userId = 2; // 用户ID
  2387. int64 did = 3; // 设备ID
  2388. string sessionId = 4; // 登录凭证
  2389. int64 sessionCreateTime = 5; // 凭证创建时间
  2390. Status status = 6; // 状态 1: 正常 2: 禁用
  2391. int64 updateTime = 7; // 更新时间
  2392. int64 createTime = 8; // 创建时间
  2393. }
  2394. message UserDeviceAddReq { UserDeviceVo vo = 1; }
  2395. message UserDeviceAddResp { UserDeviceVo vo = 1; }
  2396. message UserDeviceUpdateReq { UserDeviceVo vo = 1; }
  2397. message UserDeviceUpdateResp { UserDeviceVo vo = 1; }
  2398. message UserDeviceDelReq { repeated int64 ids = 1; }
  2399. message UserDeviceGetReq { UserDeviceVo vo = 1; }
  2400. message UserDeviceGetResp { UserDeviceVo vo = 1; }
  2401. message UserDeviceListReq {
  2402. Page page = 1;
  2403. UserDeviceVo vo = 2;
  2404. repeated int64 excludeIds = 3; // 排除的ID
  2405. repeated int64 userIds = 4; // 用户ID
  2406. repeated int64 dids = 5; // device 表的 id
  2407. }
  2408. message UserDeviceListResp {
  2409. int64 total = 1;
  2410. repeated UserDeviceVo list = 2;
  2411. }
  2412. // 用户模块
  2413. service GoUserClient {
  2414. rpc Ping(Request) returns (Response);
  2415. // 用户app配置管理(ring)
  2416. rpc UserAppConfigAdd(UserAppConfigVo) returns (UserAppConfigVo);
  2417. rpc UserAppConfigUpdate(UserAppConfigVo) returns (UserAppConfigVo);
  2418. rpc UserAppConfigDel(Ids) returns (Empty);
  2419. rpc UserAppConfigGet(UserAppConfigGetReq) returns (UserAppConfigVo);
  2420. rpc UserAppConfigList(UserAppConfigListReq) returns (UserAppConfigListRes);
  2421. // Device Model
  2422. // DeviceAdd
  2423. rpc DeviceAdd(DeviceVo) returns (DeviceVo);
  2424. rpc DeviceUpdate(DeviceVo) returns (DeviceVo);
  2425. rpc DeviceDel(Ids) returns (Empty);
  2426. rpc DeviceGet(DeviceVo) returns (DeviceVo);
  2427. rpc DeviceList(DeviceListReq) returns (DeviceListRes);
  2428. // Account Model
  2429. // AccountAdd
  2430. rpc AccountAdd(AccountVo) returns (AccountVo);
  2431. rpc AccountUpdate(AccountVo) returns (AccountVo);
  2432. rpc AccountDel(Ids) returns (Empty);
  2433. rpc AccountGet(AccountVo) returns (AccountVo);
  2434. rpc AccountList(AccountListReq) returns (AccountListResp);
  2435. // AccountDevice Model
  2436. // AccountDeviceAdd
  2437. rpc AccountDeviceAdd(AccountDeviceVo) returns (AccountDeviceVo);
  2438. rpc AccountDeviceUpdate(AccountDeviceVo) returns (AccountDeviceVo);
  2439. rpc AccountDeviceDel(Ids) returns (Empty);
  2440. rpc AccountDeviceGet(AccountDeviceVo) returns (AccountDeviceVo);
  2441. rpc AccountDeviceList(AccountDeviceListReq) returns (AccountDeviceListResp);
  2442. // 用户白名单管理
  2443. rpc UserWhiteAdd(UserWhiteAddReq) returns (UserWhiteAddResp);
  2444. rpc UserWhiteUpdate(UserWhiteUpdateReq) returns (UserWhiteUpdateResp);
  2445. rpc UserWhiteDel(UserWhiteDelReq) returns (Empty);
  2446. rpc UserWhiteGet(UserWhiteGetReq) returns (UserWhiteGetResp);
  2447. rpc UserWhiteList(UserWhiteListReq) returns (UserWhiteListResp);
  2448. // 测试用户管理
  2449. rpc UserTestAdd(UserTestAddReq) returns (UserTestAddResp);
  2450. rpc UserTestUpdate(UserTestUpdateReq) returns (UserTestUpdateResp);
  2451. rpc UserTestDel(UserTestDelReq) returns (Empty);
  2452. rpc UserTestGet(UserTestGetReq) returns (UserTestGetResp);
  2453. rpc UserTestList(UserTestListReq) returns (UserTestListResp);
  2454. // User Model
  2455. // UserAdd
  2456. rpc UserAdd(UserAddReq) returns (UserAddResp);
  2457. rpc UserUpdate(UserUpdateReq) returns (UserUpdateResp);
  2458. rpc UserDel(UserDelReq) returns (Empty);
  2459. rpc UserGet(UserGetReq) returns (UserGetResp);
  2460. rpc UserList(UserListReq) returns (UserListResp);
  2461. // UserCredential Model
  2462. // UserCredentialAdd
  2463. rpc UserCredentialAdd(UserCredentialAddReq) returns (UserCredentialAddResp);
  2464. rpc UserCredentialUpdate(UserCredentialUpdateReq) returns (UserCredentialUpdateResp);
  2465. rpc UserCredentialDel(UserCredentialDelReq) returns (Empty);
  2466. rpc UserCredentialGet(UserCredentialGetReq) returns (UserCredentialGetResp);
  2467. rpc UserCredentialList(UserCredentialListReq) returns (UserCredentialListResp);
  2468. // UserDevice Model
  2469. // UserDeviceAdd
  2470. rpc UserDeviceAdd(UserDeviceAddReq) returns (UserDeviceAddResp);
  2471. rpc UserDeviceUpdate(UserDeviceUpdateReq) returns (UserDeviceUpdateResp);
  2472. rpc UserDeviceDel(UserDeviceDelReq) returns (Empty);
  2473. rpc UserDeviceGet(UserDeviceGetReq) returns (UserDeviceGetResp);
  2474. rpc UserDeviceList(UserDeviceListReq) returns (UserDeviceListResp);
  2475. //UserService
  2476. rpc UserServiceAdd(UserServiceAddReq) returns (UserServiceAddResp);
  2477. rpc UserServiceUpdate(UserServiceUpdateReq) returns (UserServiceUpdateResp);
  2478. rpc UserServiceDel(UserServiceDelReq) returns (Empty);
  2479. rpc UserServiceGet(UserServiceGetReq) returns (UserServiceGetResp);
  2480. rpc UserServiceList(UserServiceListReq) returns (UserServiceListResp);
  2481. }
  2482. // VpnTag
  2483. message VpnTagVo {
  2484. int64 id = 1;
  2485. string productCode = 2;
  2486. string type = 3;
  2487. string name = 4;
  2488. int64 sort = 5;
  2489. Status status = 6;
  2490. string remark = 7;
  2491. int64 createTime = 8;
  2492. int64 updateTime = 9;
  2493. string otherConfig = 10;
  2494. }
  2495. message VpnTagGetReq { VpnTagVo vo = 1; }
  2496. message VpnTagListReq {
  2497. Page page = 1;
  2498. VpnTagVo vo = 2;
  2499. repeated string productCodes = 3;
  2500. repeated int64 excludeIds = 4;
  2501. }
  2502. message VpnTagListResp {
  2503. int64 total = 1;
  2504. repeated VpnTagVo list = 2;
  2505. }
  2506. message VpnTagBatchAddReq { repeated VpnTagVo list = 1; }
  2507. message VpnTagBatchAddResp { repeated VpnTagVo list = 1; }
  2508. message VpnTagBatchUpdateReq { repeated VpnTagVo list = 1; }
  2509. message VpnTagBatchUpdateResp { repeated VpnTagVo list = 1; }
  2510. message VpnTagBatchDelReq { repeated int64 ids = 1; }
  2511. // VpnTag
  2512. message VpnGroupVo {
  2513. int64 id = 1;
  2514. string productCode = 2;
  2515. string name = 3;
  2516. string icon = 4;
  2517. int64 sort = 5;
  2518. Status status = 6;
  2519. string remark = 7;
  2520. int64 createTime = 8;
  2521. int64 updateTime = 9;
  2522. string version = 10;
  2523. string otherConfig = 11;
  2524. }
  2525. message VpnGroupExVo {
  2526. VpnGroupVo vo = 1;
  2527. repeated int64 tagIds = 2;
  2528. }
  2529. message VpnGroupAddReq {
  2530. VpnGroupVo vo = 1;
  2531. repeated int64 tagIds = 2;
  2532. }
  2533. message VpnGroupGetReq { VpnGroupVo vo = 1; }
  2534. message VpnGroupListReq {
  2535. Page page = 1;
  2536. VpnGroupVo vo = 2;
  2537. repeated string productCodes = 3;
  2538. repeated int64 excludeIds = 4;
  2539. }
  2540. message VpnGroupListResp {
  2541. int64 total = 1;
  2542. repeated VpnGroupVo list = 2;
  2543. }
  2544. message VpnGroupBatchAddReq { repeated VpnGroupExVo list = 1; }
  2545. message VpnGroupBatchAddResp { repeated VpnGroupExVo list = 1; }
  2546. message VpnGroupBatchUpdateReq { repeated VpnGroupExVo list = 1; }
  2547. message VpnGroupBatchUpdateResp { repeated VpnGroupExVo list = 1; }
  2548. message VpnGroupBatchDelReq { repeated int64 ids = 1; }
  2549. // VpnGroupTag
  2550. message VpnGroupTagVo {
  2551. int64 id = 1;
  2552. int64 groupId = 2;
  2553. int64 tagId = 3;
  2554. int64 createTime = 4;
  2555. int64 updateTime = 5;
  2556. }
  2557. message VpnGroupTagListReq {
  2558. Page page = 1;
  2559. VpnGroupTagVo vo = 2;
  2560. repeated int64 groupIds = 3;
  2561. repeated int64 tagIds = 4;
  2562. }
  2563. message VpnGroupTagListResp {
  2564. int64 total = 1;
  2565. repeated VpnGroupTagVo list = 2;
  2566. }
  2567. // VpnLocation
  2568. message VpnLocationVo {
  2569. int64 id = 1;
  2570. int64 groupId = 2;
  2571. string name = 3;
  2572. string code = 4;
  2573. string icon = 5;
  2574. int64 type = 6;
  2575. string displayPolicyConfig = 7;
  2576. string routePolicyConfig = 8;
  2577. int64 sort = 9;
  2578. Status status = 10;
  2579. string remark = 11;
  2580. int64 createTime = 12;
  2581. int64 updateTime = 13;
  2582. string version = 14;
  2583. string otherConfig = 15;
  2584. }
  2585. message VpnLocationExVo {
  2586. VpnLocationVo vo = 1;
  2587. string productCode = 2;
  2588. }
  2589. message VpnLocationGetReq { VpnLocationVo vo = 1; }
  2590. message VpnLocationListReq {
  2591. Page page = 1;
  2592. VpnLocationExVo vo = 2;
  2593. repeated int64 groupIds = 3;
  2594. repeated int64 excludeIds = 4;
  2595. repeated string productCodes = 5;
  2596. }
  2597. message VpnLocationListResp {
  2598. int64 total = 1;
  2599. repeated VpnLocationExVo list = 2;
  2600. }
  2601. message VpnLocationBatchAddReq { repeated VpnLocationVo list = 1; }
  2602. message VpnLocationBatchAddResp { repeated VpnLocationExVo list = 1; }
  2603. message VpnLocationBatchUpdateReq { repeated VpnLocationVo list = 1; }
  2604. message VpnLocationBatchUpdateResp { repeated VpnLocationExVo list = 1; }
  2605. message VpnLocationBatchDelReq { repeated int64 ids = 1; }
  2606. // VpnServer
  2607. message VpnServerVo {
  2608. int64 id = 1;
  2609. int64 instanceId = 2;
  2610. string name = 3;
  2611. string ip = 4;
  2612. int64 port = 5;
  2613. int64 pingPort = 6;
  2614. string netConfig = 7;
  2615. string routePolicyConfig = 8;
  2616. string serverInfo = 9;
  2617. Status status = 10;
  2618. string remark = 11;
  2619. int64 createTime = 12;
  2620. int64 updateTime = 13;
  2621. string version = 14;
  2622. string otherInfo = 15;
  2623. int64 monitorPort = 16;
  2624. string vpnConfig = 17;
  2625. }
  2626. message VpnServerExVo {
  2627. VpnServerVo vo = 1;
  2628. repeated int64 locationIds = 2;
  2629. }
  2630. message VpnServerListReq {
  2631. Page page = 1;
  2632. VpnServerVo vo = 2;
  2633. repeated int64 excludeIds = 3; // 排除的ID
  2634. repeated string productCodes = 4;
  2635. repeated int64 locationIds = 5;
  2636. repeated int64 instanceIds = 6;
  2637. }
  2638. message VpnServerListResp {
  2639. int64 total = 1;
  2640. repeated VpnServerVo list = 2;
  2641. }
  2642. message VpnServerExListResp {
  2643. int64 total = 1;
  2644. repeated VpnServerExVo list = 2;
  2645. }
  2646. message VpnServerAddReq {
  2647. VpnServerVo vo = 1;
  2648. repeated int64 locationIds = 2;
  2649. }
  2650. message VpnServerBatchAddReq { repeated VpnServerExVo list = 1; }
  2651. message VpnServerBatchAddResp { repeated VpnServerExVo list = 1; }
  2652. message VpnServerBatchUpdateReq { repeated VpnServerExVo list = 1; }
  2653. message VpnServerBatchUpdateResp { repeated VpnServerExVo list = 1; }
  2654. message VpnServerBatchDelReq { repeated int64 ids = 1; }
  2655. message VpnServerLocationVo {
  2656. int64 id = 1;
  2657. int64 serverId = 2;
  2658. int64 locationId = 3;
  2659. int64 createTime = 4;
  2660. int64 updateTime = 5;
  2661. Status status = 6;
  2662. }
  2663. message VpnServerLocationListReq {
  2664. Page page = 1;
  2665. VpnServerLocationVo vo = 2;
  2666. repeated int64 serverIds = 3;
  2667. repeated int64 locationIds = 4;
  2668. }
  2669. message VpnServerLocationListResp {
  2670. int64 total = 1;
  2671. repeated VpnServerLocationVo list = 2;
  2672. }
  2673. message VpnLocationServerCountVo {
  2674. int64 locationId = 1;
  2675. int64 serverCount = 2;
  2676. }
  2677. message VpnLocationServerCountReq {
  2678. Page page = 1;
  2679. Status status = 2;
  2680. repeated int64 serverIds = 3;
  2681. repeated int64 locationIds = 4;
  2682. }
  2683. message VpnLocationServerCountResp {
  2684. int64 total = 1;
  2685. repeated VpnLocationServerCountVo list = 2;
  2686. }
  2687. message VpnProbeTaskVo {
  2688. int64 id = 1;
  2689. string taskId = 2;
  2690. string filter = 3; // 筛选条件
  2691. string type = 4; // 类型
  2692. string uploadDomain = 5; // 配置
  2693. string params = 6;
  2694. int64 answer = 7;
  2695. float percentage = 8; // 进度百分比
  2696. string result = 9; // 结果
  2697. int64 userId = 10;
  2698. int64 createTime = 11;
  2699. int64 updateTime = 12;
  2700. }
  2701. message VpnProbeTaskListReq {
  2702. Page page = 1;
  2703. VpnProbeTaskVo vo = 2;
  2704. }
  2705. message VpnProbeTaskListResp {
  2706. int64 total = 1;
  2707. repeated VpnProbeTaskVo list = 2;
  2708. }
  2709. message VpnWithIPAndPortReq {
  2710. // 产品Code
  2711. string productCode = 1;
  2712. // 国家
  2713. string country = 2;
  2714. // 需要随机的总数
  2715. int64 limitCount = 3;
  2716. }
  2717. message VpnWithIPAndPortResp {
  2718. repeated VpnServerVo list = 1;
  2719. }
  2720. // VpnipWalledVo
  2721. message VpnipWalledVo {
  2722. int64 id = 1; // ID
  2723. int64 ipId = 2; // IP ID
  2724. string area = 3; // 地区
  2725. int64 walledTime = 4; // 被墙时间
  2726. string remark = 5; // 备注
  2727. int64 createTime = 6; // 创建时间
  2728. int64 createAt = 7; // 创建者ID
  2729. int64 updateTime = 8; // 更新时间
  2730. int64 updateAt = 9; // 更新者ID
  2731. }
  2732. message VpnipWalledAddReq { VpnipWalledVo vo = 1; }
  2733. message VpnipWalledAddResp { VpnipWalledVo vo = 1; }
  2734. message VpnipWalledUpdateReq { VpnipWalledVo vo = 1; }
  2735. message VpnipWalledUpdateResp { VpnipWalledVo vo = 1; }
  2736. message VpnipWalledGetReq { VpnipWalledVo vo = 1; }
  2737. message VpnipWalledGetResp { VpnipWalledVo vo = 1; }
  2738. message VpnipWalledListReq {
  2739. Page page = 1;
  2740. VpnipWalledVo vo = 2;
  2741. repeated int64 excludeIds = 3;
  2742. repeated int64 ipIds = 4;
  2743. repeated string ips = 5;
  2744. repeated string areas = 6;
  2745. }
  2746. message VpnipWalledListResp {
  2747. int64 total = 1;
  2748. repeated VpnipWalledVo list = 2;
  2749. }
  2750. message VpnipWalledBatchAddReq { repeated VpnipWalledVo list = 1; }
  2751. message VpnipWalledBatchAddResp { repeated VpnipWalledVo list = 1; }
  2752. message VpnipWalledBatchUpdateReq { repeated VpnipWalledVo list = 1; }
  2753. message VpnipWalledBatchUpdateResp { repeated VpnipWalledVo list = 1; }
  2754. // VpnipVo
  2755. message VpnipVo {
  2756. int64 id = 1; // ID
  2757. int64 rangeId = 2; // IP段ID
  2758. string ip = 3; // IP地址
  2759. string otherInfo = 4; // 其他信息,保留字段,用于扩展
  2760. Status status = 5; // 状态
  2761. string remark = 6; // 备注
  2762. int64 createTime = 7; // 创建时间
  2763. int64 createAt = 8; // 创建者ID
  2764. int64 updateTime = 9; // 更新时间
  2765. int64 updateAt = 10; // 更新者ID
  2766. }
  2767. message VpnipExVo {
  2768. VpnipVo vo = 1;
  2769. repeated VpnipWalledVo walledInfos = 2;
  2770. }
  2771. message VpnipAddReq { VpnipVo vo = 1; }
  2772. message VpnipAddResp { VpnipVo vo = 1; }
  2773. message VpnipExAddReq { VpnipExVo vo = 1; }
  2774. message VpnipExAddResp { VpnipExVo vo = 1; }
  2775. message VpnipUpdateReq { VpnipVo vo = 1; }
  2776. message VpnipUpdateResp { VpnipVo vo = 1; }
  2777. message VpnipExUpdateReq { VpnipExVo vo = 1; }
  2778. message VpnipExUpdateResp { VpnipExVo vo = 1; }
  2779. message VpnipGetReq { VpnipVo vo = 1; }
  2780. message VpnipGetResp { VpnipVo vo = 1; }
  2781. message VpnipExGetResp { VpnipExVo vo = 1; }
  2782. message VpnipListReq {
  2783. Page page = 1;
  2784. VpnipVo vo = 2;
  2785. repeated int64 excludeIds = 3;
  2786. repeated string ips = 4;
  2787. repeated int64 serverIds = 5;
  2788. repeated int64 instanceIds = 6;
  2789. repeated int64 rangeIds = 7;
  2790. }
  2791. message VpnipListResp {
  2792. int64 total = 1;
  2793. repeated VpnipVo list = 2;
  2794. }
  2795. message VpnipExListResp {
  2796. int64 total = 1;
  2797. repeated VpnipExVo list = 2;
  2798. }
  2799. message VpnipBatchAddReq { repeated VpnipVo list = 1; }
  2800. message VpnipBatchAddResp { repeated VpnipVo list = 1; }
  2801. message VpnipBatchUpdateReq { repeated VpnipVo list = 1; }
  2802. message VpnipBatchUpdateResp { repeated VpnipVo list = 1; }
  2803. message VpnipExBatchAddReq { repeated VpnipExVo list = 1; }
  2804. message VpnipExBatchAddResp { repeated VpnipExVo list = 1; }
  2805. message VpnipExBatchUpdateReq { repeated VpnipExVo list = 1; }
  2806. message VpnipExBatchUpdateResp { repeated VpnipExVo list = 1; }
  2807. // VpnipRangeVo
  2808. message VpnipRangeVo {
  2809. int64 id = 1; // ID
  2810. string name = 2; // 名称
  2811. string supplierId = 3; // 供应商ID
  2812. string startIP = 4; // 起始IP
  2813. string endIP = 5; // 结束IP
  2814. int64 expires = 6; // 到期日期
  2815. int64 sort = 7; // 排序
  2816. Status status = 8; // 状态
  2817. string remark = 9; // 备注
  2818. int64 createTime = 10; // 创建时间
  2819. int64 createAt = 11; // 创建者ID
  2820. int64 updateTime = 12; // 更新时间
  2821. int64 updateAt = 13; // 更新者ID
  2822. }
  2823. message VpnipRangeExVo {
  2824. VpnipRangeVo vo = 1;
  2825. repeated VpnipVo ipInfos = 2;
  2826. }
  2827. message VpnipRangeAddReq { VpnipRangeVo vo = 1; }
  2828. message VpnipRangeAddResp { VpnipRangeVo vo = 1; }
  2829. message VpnipRangeExAddReq { VpnipRangeExVo vo = 1; }
  2830. message VpnipRangeExAddResp { VpnipRangeExVo vo = 1; }
  2831. message VpnipRangeUpdateReq { VpnipRangeVo vo = 1; }
  2832. message VpnipRangeUpdateResp { VpnipRangeVo vo = 1; }
  2833. message VpnipRangeExUpdateReq { VpnipRangeExVo vo = 1; }
  2834. message VpnipRangeExUpdateResp { VpnipRangeExVo vo = 1; }
  2835. message VpnipRangeGetReq { VpnipRangeVo vo = 1; }
  2836. message VpnipRangeGetResp { VpnipRangeVo vo = 1; }
  2837. message VpnipRangeExGetResp { VpnipRangeExVo vo = 1; }
  2838. message VpnipRangeListReq {
  2839. Page page = 1;
  2840. VpnipRangeVo vo = 2;
  2841. repeated string names = 3;
  2842. repeated string ips = 4;
  2843. repeated int64 excludeIds = 5; // 排除的ID
  2844. }
  2845. message VpnipRangeListResp {
  2846. int64 total = 1;
  2847. repeated VpnipRangeVo list = 2;
  2848. }
  2849. message VpnipRangeExListResp {
  2850. int64 total = 1;
  2851. repeated VpnipRangeExVo list = 2;
  2852. }
  2853. message VpnipRangeBatchAddReq { repeated VpnipRangeVo list = 1; }
  2854. message VpnipRangeBatchAddResp { repeated VpnipRangeVo list = 1; }
  2855. message VpnipRangeBatchUpdateReq { repeated VpnipRangeVo list = 1; }
  2856. message VpnipRangeBatchUpdateResp { repeated VpnipRangeVo list = 1; }
  2857. message VpnipRangeExBatchAddReq { repeated VpnipRangeExVo list = 1; }
  2858. message VpnipRangeExBatchAddResp { repeated VpnipRangeExVo list = 1; }
  2859. message VpnipRangeExBatchUpdateReq { repeated VpnipRangeExVo list = 1; }
  2860. message VpnipRangeExBatchUpdateResp { repeated VpnipRangeExVo list = 1; }
  2861. // VpnipBindVo
  2862. message VpnipBindVo {
  2863. int64 id = 1; // ID
  2864. int64 ipId = 2; // IP ID
  2865. int64 serverId = 3; // 服务器ID
  2866. string batchId = 4; // 批次ID,用于批量操作和回滚
  2867. string prevBindId = 5; // 上一次绑定记录的ID,为空时表示之前未绑定
  2868. int64 bindTime = 6; // 绑定时间
  2869. int64 unbindTime = 7; // 解绑时间
  2870. int64 isCurrent = 8; // 是否为当前绑定记录
  2871. string remark = 9; // 备注
  2872. int64 createTime = 10; // 创建时间
  2873. int64 createAt = 11; // 创建者ID
  2874. int64 updateTime = 12; // 更新时间
  2875. int64 updateAt = 13; // 更新者ID
  2876. }
  2877. message VpnipBindAddReq { VpnipBindVo vo = 1; }
  2878. message VpnipBindAddResp { VpnipBindVo vo = 1; }
  2879. message VpnipBindUpdateReq { VpnipBindVo vo = 1; }
  2880. message VpnipBindUpdateResp { VpnipBindVo vo = 1; }
  2881. message VpnipBindGetReq { VpnipBindVo vo = 1; }
  2882. message VpnipBindGetResp { VpnipBindVo vo = 1; }
  2883. message VpnipBindListReq {
  2884. Page page = 1;
  2885. VpnipBindVo vo = 2;
  2886. repeated int64 excludeIds = 3;
  2887. repeated int64 ipIds = 4;
  2888. repeated int64 serverIds = 5;
  2889. repeated string ips = 6;
  2890. repeated int64 instanceIds = 7;
  2891. }
  2892. message VpnipBindListResp {
  2893. int64 total = 1;
  2894. repeated VpnipBindVo list = 2;
  2895. }
  2896. message VpnipBindBatchAddReq { repeated VpnipBindVo list = 1; }
  2897. message VpnipBindBatchAddResp { repeated VpnipBindVo list = 1; }
  2898. message VpnipBindBatchUpdateReq { repeated VpnipBindVo list = 1; }
  2899. message VpnipBindBatchUpdateResp { repeated VpnipBindVo list = 1; }
  2900. // VpnConfigTemplatePlanVo
  2901. message VpnConfigTemplatePlanVo {
  2902. int64 id = 1; // id
  2903. string productCode = 2; // 产品Code
  2904. string name = 3; // 配置名称
  2905. string config = 4; // 保留字段,用于扩展配置
  2906. int64 sort = 5; // 排序
  2907. Status status = 6; // 状态
  2908. string remark = 7; // 备注
  2909. int64 createTime = 8; // 创建时间
  2910. int64 createAt = 9; // 创建者Id
  2911. int64 updateTime = 10; // 更新时间
  2912. int64 updateAt = 11; // 更新者Id
  2913. string version = 12; // 数据版本
  2914. }
  2915. // VpnConfigTemplatePlanDetailVo
  2916. message VpnConfigTemplatePlanDetailVo {
  2917. int64 id = 1; // id
  2918. int64 planId = 2; // 配置模板主表id
  2919. string core = 3; // 内核
  2920. string name = 4; // 名称
  2921. string serverConfig = 5; // 服务端配置
  2922. string clientConfig = 6; // 客户端配置
  2923. string policyConfig = 7; // 策略配置
  2924. int64 sort = 8; // 排序
  2925. Status status = 9; // 状态
  2926. string remark = 10; // 备注
  2927. int64 createTime = 11; // 创建时间
  2928. int64 createAt = 12; // 创建者Id
  2929. int64 updateTime = 13; // 更新时间
  2930. int64 updateAt = 14; // 更新者Id
  2931. string version = 15; // 数据版本
  2932. }
  2933. message VpnConfigTemplatePlanAddReq {
  2934. VpnConfigTemplatePlanVo plan = 1;
  2935. repeated VpnConfigTemplatePlanDetailVo details = 2;
  2936. }
  2937. message VpnConfigTemplatePlanAddResp {
  2938. VpnConfigTemplatePlanVo plan = 1;
  2939. repeated VpnConfigTemplatePlanDetailVo details = 2;
  2940. }
  2941. message VpnConfigTemplatePlanUpdateReq {
  2942. VpnConfigTemplatePlanVo vo = 1;
  2943. bool withDetails = 2;
  2944. }
  2945. message VpnConfigTemplatePlanUpdateResp {
  2946. VpnConfigTemplatePlanVo plan = 1;
  2947. repeated VpnConfigTemplatePlanDetailVo details = 2;
  2948. }
  2949. message VpnConfigTemplatePlanDelReq { repeated int64 ids = 1; }
  2950. message VpnConfigTemplatePlanGetReq {
  2951. VpnConfigTemplatePlanVo vo = 1;
  2952. bool withDetails = 2;
  2953. }
  2954. message VpnConfigTemplatePlanGetResp {
  2955. VpnConfigTemplatePlanVo plan = 1;
  2956. repeated VpnConfigTemplatePlanDetailVo details = 2;
  2957. }
  2958. message VpnConfigTemplatePlanListReq {
  2959. Page page = 1;
  2960. VpnConfigTemplatePlanVo vo = 2;
  2961. repeated int64 excludeIds = 3;
  2962. repeated string productCodes = 4;
  2963. bool withDetails = 5;
  2964. }
  2965. message VpnConfigTemplatePlanListResp {
  2966. int64 total = 1;
  2967. repeated VpnConfigTemplatePlanGetResp list = 2;
  2968. }
  2969. message VpnConfigTemplatePlanDetailAddReq {
  2970. VpnConfigTemplatePlanDetailVo vo = 1;
  2971. }
  2972. message VpnConfigTemplatePlanDetailAddResp {
  2973. VpnConfigTemplatePlanDetailVo vo = 1;
  2974. }
  2975. message VpnConfigTemplatePlanDetailUpdateReq {
  2976. VpnConfigTemplatePlanDetailVo vo = 1;
  2977. }
  2978. message VpnConfigTemplatePlanDetailUpdateResp {
  2979. VpnConfigTemplatePlanDetailVo vo = 1;
  2980. }
  2981. message VpnConfigTemplatePlanDetailDelReq { repeated int64 ids = 1; }
  2982. message VpnConfigTemplatePlanDetailGetReq {
  2983. VpnConfigTemplatePlanDetailVo vo = 1;
  2984. }
  2985. message VpnConfigTemplatePlanDetailGetResp {
  2986. VpnConfigTemplatePlanDetailVo vo = 1;
  2987. }
  2988. message VpnConfigTemplatePlanDetailListReq {
  2989. Page page = 1;
  2990. VpnConfigTemplatePlanDetailVo vo = 2;
  2991. repeated int64 planIds = 3;
  2992. repeated int64 excludeIds = 4;
  2993. repeated string productCodes = 5;
  2994. }
  2995. message VpnConfigTemplatePlanDetailListResp {
  2996. int64 total = 1;
  2997. repeated VpnConfigTemplatePlanDetailVo list = 2;
  2998. }
  2999. // govpn 模块,VPN相关服务
  3000. service GoVpnClient {
  3001. rpc Ping(Request) returns (Response);
  3002. // 表的事务操作
  3003. rpc Transaction(TransactionReq) returns (Empty);
  3004. /** VpnTag Model */
  3005. // VpnTagAdd
  3006. rpc VpnTagAdd(VpnTagVo) returns (VpnTagVo);
  3007. rpc VpnTagUpdate(VpnTagVo) returns (VpnTagVo);
  3008. rpc VpnTagDel(Ids) returns (Empty);
  3009. rpc VpnTagGet(VpnTagGetReq) returns (VpnTagVo);
  3010. rpc VpnTagList(VpnTagListReq) returns (VpnTagListResp);
  3011. rpc VpnTagBatchAdd(VpnTagBatchAddReq) returns (VpnTagBatchAddResp);
  3012. rpc VpnTagBatchUpdate(VpnTagBatchUpdateReq) returns (VpnTagBatchUpdateResp);
  3013. /** VpnGroup Model */
  3014. // VpnGroupAdd
  3015. rpc VpnGroupAdd(VpnGroupAddReq) returns (VpnGroupVo);
  3016. rpc VpnGroupUpdate(VpnGroupAddReq) returns (Empty);
  3017. rpc VpnGroupDel(Ids) returns (Empty);
  3018. rpc VpnGroupGet(VpnGroupGetReq) returns (VpnGroupVo);
  3019. rpc VpnGroupList(VpnGroupListReq) returns (VpnGroupListResp);
  3020. rpc VpnGroupBatchAdd(VpnGroupBatchAddReq) returns (VpnGroupBatchAddResp);
  3021. rpc VpnGroupBatchUpdate(VpnGroupBatchUpdateReq) returns (VpnGroupBatchUpdateResp);
  3022. /** VpnGroupTag Model */
  3023. // VpnGroupTagAdd
  3024. rpc VpnGroupTagAdd(VpnGroupTagVo) returns (VpnGroupTagVo);
  3025. rpc VpnGroupTagUpdate(VpnGroupTagVo) returns (VpnGroupTagVo);
  3026. rpc VpnGroupTagDel(Ids) returns (Empty);
  3027. rpc VpnGroupTagGet(VpnGroupTagVo) returns (VpnGroupTagVo);
  3028. rpc VpnGroupTagList(VpnGroupTagListReq) returns (VpnGroupTagListResp);
  3029. /** VpnLocation Model */
  3030. // VpnLocationAdd
  3031. rpc VpnLocationAdd(VpnLocationVo) returns (VpnLocationVo);
  3032. rpc VpnLocationUpdate(VpnLocationVo) returns (Empty);
  3033. rpc VpnLocationDel(Ids) returns (Empty);
  3034. rpc VpnLocationGet(VpnLocationGetReq) returns (VpnLocationVo);
  3035. rpc VpnLocationList(VpnLocationListReq) returns (VpnLocationListResp);
  3036. rpc VpnLocationBatchAdd(VpnLocationBatchAddReq) returns (VpnLocationBatchAddResp);
  3037. rpc VpnLocationBatchUpdate(VpnLocationBatchUpdateReq) returns (VpnLocationBatchUpdateResp);
  3038. /** VpnServer Model */
  3039. // VpnServerAdd
  3040. rpc VpnServerAdd(VpnServerAddReq) returns (VpnServerAddReq);
  3041. rpc VpnServerUpdate(VpnServerAddReq) returns (VpnServerAddReq);
  3042. rpc VpnServerDel(Ids) returns (Empty);
  3043. rpc VpnServerGet(VpnServerVo) returns (VpnServerVo);
  3044. rpc VpnServerExGet(VpnServerVo) returns (VpnServerExVo);
  3045. rpc VpnServerList(VpnServerListReq) returns (VpnServerListResp);
  3046. rpc VpnServerExList(VpnServerListReq) returns (VpnServerExListResp);
  3047. rpc VpnServerBatchAdd(VpnServerBatchAddReq) returns (VpnServerBatchAddResp);
  3048. rpc VpnServerBatchUpdate(VpnServerBatchUpdateReq) returns (VpnServerBatchUpdateResp);
  3049. /** VpnServerLocation Model */
  3050. // VpnServerLocationAdd
  3051. rpc VpnServerLocationAdd(VpnServerLocationVo) returns (VpnServerLocationVo);
  3052. rpc VpnServerLocationUpdate(VpnServerLocationVo) returns (Empty);
  3053. rpc VpnServerLocationDel(Ids) returns (Empty);
  3054. rpc VpnServerLocationGet(VpnServerLocationVo) returns (VpnServerLocationVo);
  3055. rpc VpnServerLocationList(VpnServerLocationListReq) returns (VpnServerLocationListResp);
  3056. rpc VpnWithIPAndPort(VpnWithIPAndPortReq) returns (VpnWithIPAndPortResp);
  3057. // VpnLocationServerCount
  3058. rpc VpnLocationServerCount(VpnLocationServerCountReq) returns (VpnLocationServerCountResp);
  3059. /** VpnProbeTask Model */
  3060. // VpnProbeTaskAdd
  3061. rpc VpnProbeTaskAdd(VpnProbeTaskVo) returns (VpnProbeTaskVo);
  3062. rpc VpnProbeTaskUpdate(VpnProbeTaskVo) returns (Empty);
  3063. rpc VpnProbeTaskList(VpnProbeTaskListReq) returns (VpnProbeTaskListResp);
  3064. /** VpnipWalled Model */
  3065. // VpnipWalledAdd
  3066. rpc VpnipWalledAdd(VpnipWalledAddReq) returns (VpnipWalledAddResp);
  3067. rpc VpnipWalledUpdate(VpnipWalledUpdateReq) returns (VpnipWalledUpdateResp);
  3068. rpc VpnipWalledDel(Ids) returns (Empty);
  3069. rpc VpnipWalledGet(VpnipWalledGetReq) returns (VpnipWalledGetResp);
  3070. rpc VpnipWalledList(VpnipWalledListReq) returns (VpnipWalledListResp);
  3071. rpc VpnipWalledBatchAdd(VpnipWalledBatchAddReq) returns (VpnipWalledBatchAddResp);
  3072. rpc VpnipWalledBatchUpdate(VpnipWalledBatchUpdateReq) returns (VpnipWalledBatchUpdateResp);
  3073. /** Vpnip Model */
  3074. // VpnipAdd
  3075. rpc VpnipAdd(VpnipAddReq) returns (VpnipAddResp);
  3076. rpc VpnipExAdd(VpnipExAddReq) returns (VpnipExAddResp);
  3077. rpc VpnipUpdate(VpnipUpdateReq) returns (VpnipUpdateResp);
  3078. rpc VpnipExUpdate(VpnipExUpdateReq) returns (VpnipExUpdateResp);
  3079. rpc VpnipDel(Ids) returns (Empty);
  3080. rpc VpnipGet(VpnipGetReq) returns (VpnipGetResp);
  3081. rpc VpnipExGet(VpnipGetReq) returns (VpnipExGetResp);
  3082. rpc VpnipList(VpnipListReq) returns (VpnipListResp);
  3083. rpc VpnipExList(VpnipListReq) returns (VpnipExListResp);
  3084. rpc VpnipBatchAdd(VpnipBatchAddReq) returns (VpnipBatchAddResp);
  3085. rpc VpnipBatchUpdate(VpnipBatchUpdateReq) returns (VpnipBatchUpdateResp);
  3086. rpc VpnipExBatchAdd(VpnipExBatchAddReq) returns (VpnipExBatchAddResp);
  3087. rpc VpnipExBatchUpdate(VpnipExBatchUpdateReq) returns (VpnipExBatchUpdateResp);
  3088. /** VpnipRange Model */
  3089. // VpnipRangeAdd
  3090. rpc VpnipRangeAdd(VpnipRangeAddReq) returns (VpnipRangeAddResp);
  3091. // VpnipRangeExAdd 添加IP段及IP数据,如果IP数据已存在,会自动将已经存在的IP的 rangeId 更新为新增的IP段的ID
  3092. rpc VpnipRangeExAdd(VpnipRangeExAddReq) returns (VpnipRangeExAddResp);
  3093. rpc VpnipRangeUpdate(VpnipRangeUpdateReq) returns (VpnipRangeUpdateResp);
  3094. rpc VpnipRangeExUpdate(VpnipRangeExUpdateReq) returns (VpnipRangeExUpdateResp);
  3095. rpc VpnipRangeDel(Ids) returns (Empty);
  3096. rpc VpnipRangeGet(VpnipRangeGetReq) returns (VpnipRangeGetResp);
  3097. rpc VpnipRangeExGet(VpnipRangeGetReq) returns (VpnipRangeExGetResp);
  3098. rpc VpnipRangeList(VpnipRangeListReq) returns (VpnipRangeListResp);
  3099. rpc VpnipRangeExList(VpnipRangeListReq) returns (VpnipRangeExListResp);
  3100. rpc VpnipRangeBatchAdd(VpnipRangeBatchAddReq) returns (VpnipRangeBatchAddResp);
  3101. rpc VpnipRangeExBatchAdd(VpnipRangeExBatchAddReq) returns (VpnipRangeExBatchAddResp);
  3102. rpc VpnipRangeBatchUpdate(VpnipRangeBatchUpdateReq) returns (VpnipRangeBatchUpdateResp);
  3103. rpc VpnipRangeExBatchUpdate(VpnipRangeExBatchUpdateReq) returns (VpnipRangeExBatchUpdateResp);
  3104. /** VpnipBind Model */
  3105. // VpnipBindAdd
  3106. rpc VpnipBindAdd(VpnipBindAddReq) returns (VpnipBindAddResp);
  3107. rpc VpnipBindUpdate(VpnipBindUpdateReq) returns (VpnipBindUpdateResp);
  3108. rpc VpnipBindDel(Ids) returns (Empty);
  3109. rpc VpnipBindGet(VpnipBindGetReq) returns (VpnipBindGetResp);
  3110. rpc VpnipBindList(VpnipBindListReq) returns (VpnipBindListResp);
  3111. rpc VpnipBindBatchUpdate(VpnipBindBatchUpdateReq) returns (VpnipBindBatchUpdateResp);
  3112. // VpnipsBindServer 为一台服务器绑定一批新IP,会解绑上次绑定的IP,再绑定新的IP,仅需提供 ipId, serverId, Remark, createAt, updateAt 即可,其他字段会自动填充
  3113. rpc VpnipsBindServer(VpnipBindBatchAddReq) returns (VpnipBindBatchAddResp);
  3114. /** VpnConfigTemplatePlan Model (Xray配置模板,jump那边叫做配置模板)*/
  3115. // VpnConfigTemplatePlanAdd 添加配置模板及模板详情
  3116. rpc VpnConfigTemplatePlanAdd(VpnConfigTemplatePlanAddReq) returns (VpnConfigTemplatePlanAddResp);
  3117. // VpnConfigTemplatePlanUpdate 更新配置模板(只更新模板,不更新模板详情,如果 withDetails 为 true,则返回结果中包含模板详情)
  3118. rpc VpnConfigTemplatePlanUpdate(VpnConfigTemplatePlanUpdateReq) returns (VpnConfigTemplatePlanUpdateResp);
  3119. // VpnConfigTemplatePlanDel 删除配置模板(会同时删除模板详情)
  3120. rpc VpnConfigTemplatePlanDel(VpnConfigTemplatePlanDelReq) returns (Empty);
  3121. // VpnConfigTemplatePlanGet 获取配置模板(如果 withDetails 为 true,则返回结果中包含模板详情)
  3122. rpc VpnConfigTemplatePlanGet(VpnConfigTemplatePlanGetReq) returns (VpnConfigTemplatePlanGetResp);
  3123. // VpnConfigTemplatePlanList 获取配置模板列表(如果 withDetails 为 true,则返回结果中包含模板详情)
  3124. rpc VpnConfigTemplatePlanList(VpnConfigTemplatePlanListReq) returns (VpnConfigTemplatePlanListResp);
  3125. /** VpnConfigTemplatePlanDetail Model (Xray配置模板详情,jump那边叫做传输配置)*/
  3126. // VpnConfigTemplatePlanDetailAdd 添加模板详情
  3127. rpc VpnConfigTemplatePlanDetailAdd(VpnConfigTemplatePlanDetailAddReq) returns (VpnConfigTemplatePlanDetailAddResp);
  3128. rpc VpnConfigTemplatePlanDetailUpdate(VpnConfigTemplatePlanDetailUpdateReq) returns (VpnConfigTemplatePlanDetailUpdateResp);
  3129. rpc VpnConfigTemplatePlanDetailDel(VpnConfigTemplatePlanDetailDelReq) returns (Empty);
  3130. rpc VpnConfigTemplatePlanDetailGet(VpnConfigTemplatePlanDetailGetReq) returns (VpnConfigTemplatePlanDetailGetResp);
  3131. rpc VpnConfigTemplatePlanDetailList(VpnConfigTemplatePlanDetailListReq) returns (VpnConfigTemplatePlanDetailListResp);
  3132. }