gorpc.proto 105 KB

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