gorpc.proto 105 KB

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